{
  "schema": "anu_v3.policy_profile_engine.interface_contract.v1",
  "task": "task-2553+36",
  "track": "C — Phase-B reconciliation (C1↔C2↔C3 interface contract)",
  "task_md_sha256": "cea6846a291e4c008e0b2eb8bed88dbfed30f4fac2f4f101d82c2d9f800f8bff",
  "c1_engine": {
    "module": "anu_v3.policy_profile_engine",
    "path": "anu_v3/policy_profile_engine.py",
    "byte_size": 28063,
    "baseline_sha256": "2363e291a0a43884892f5e554f115481a077322bd5caa3000fb75bf5b72bc6be",
    "settled_by": "task-2553+33 ACCEPT (PASS_TERMINAL_ADJUDICATED)",
    "byte0_invariant": "전후 sha256 동일 (executor 무수정)"
  },
  "canonical_api": {
    "parse_goal_request": {
      "signature": "parse_goal_request(obj, *, schema_dir=SCHEMA_DIR_DEFAULT) -> dict",
      "defined_at": "anu_v3/policy_profile_engine.py:187",
      "input_schema": "schemas/goal_request_2553plus33.schema.json",
      "input_required": ["goal_id", "goal_statement", "policy_profile.name"],
      "input_optional": ["goal_type", "boundary[]"],
      "additionalProperties": false,
      "fail_closed": "non-mapping / schema fail -> PolicyEngineError"
    },
    "resolve_policy": {
      "signature": "resolve_policy(goal_request, *, profile_json_dir=PROFILE_JSON_DIR_DEFAULT, profile_schema_dir=PROFILE_SCHEMA_DIR_DEFAULT, schema_dir=SCHEMA_DIR_DEFAULT) -> PolicyResolution",
      "defined_at": "anu_v3/policy_profile_engine.py:561",
      "returns": "PolicyResolution",
      "status_domain": ["RESOLVED", "HOLD_FOR_CHAIR"],
      "exposed_surfaces": ["gate", "hold_conditions", "allowed_actions", "forbidden_actions", "completion_packet_schema", "evidence_schema"],
      "purity": "순수 함수 (부작용 0 — GitHub API 0, token 0, 파일 쓰기 0, profile mutation 0)",
      "fail_closed": "profile 부재 -> PolicyEngineError(profile_load_fail); goal_request schema fail -> PolicyEngineError(goal_request_schema_fail)",
      "defaults": {
        "profile_json_dir": "memory/policy_profiles",
        "profile_schema_dir": "schemas/policy_profiles",
        "schema_dir": "schemas"
      }
    }
  },
  "forbidden_api": {
    "signature": "resolve_policy(goal_type=..., boundary=...)",
    "observed_behavior": "TypeError: resolve_policy() got an unexpected keyword argument 'goal_type'",
    "rationale": "settled engine 은 contract deriver — runtime terminal status echo 계약 폐기. 이것이 task-2553+35 Phase-B 에서 관측된 C1↔C3 API mismatch 의 정본 해소."
  },
  "contract_semantics": {
    "engine_is_pure_contract_deriver": true,
    "does_not_replay_runtime_terminal_status": true,
    "runtime_terminal_status_examples_NOT_engine_output": ["HOLD_FOR_CHAIR", "COMPLETE_MERGED", "RESOLVED_THREAD__MERGE_READY", "DONE"],
    "engine_status_meaning": "resolve-time contract derivation only — runtime HOLD 는 evaluate_hold(hold_trigger_conditions, runtime_signals) 로 별도 평가"
  },
  "per_target_resolution": {
    "PR#129 test-only hardening merge": {
      "goal_type": "merge_test_only_hardening_pr",
      "policy_profile": "test_only_hardening_pr_merge_v1",
      "profile_instance_present": true,
      "canonical_outcome": "RESOLVED (gate=8, hold=8, completion_packet_schema present, allowed∩forbidden=∅)"
    },
    "PR#128 clean replacement merge": {
      "goal_type": "merge_clean_replacement_pr",
      "policy_profile": "clean_replacement_pr_merge_v1",
      "profile_instance_present": false,
      "canonical_outcome": "FAIL-CLOSED PolicyEngineError(profile_load_fail) — 결정론적, 실 side-effect 0, 엔진 결함 아님"
    },
    "Gemini thread resolve": {
      "goal_type": "gemini_thread_resolution_limited",
      "policy_profile": null,
      "profile_instance_present": false,
      "canonical_outcome": "FAIL-CLOSED PolicyEngineError(profile_load_fail)"
    },
    "post-merge smoke harness artifact closeout": {
      "goal_type": "post_merge_smoke_artifact_closeout",
      "policy_profile": "post_merge_artifact_closeout_v1",
      "profile_instance_present": false,
      "canonical_outcome": "FAIL-CLOSED PolicyEngineError(profile_load_fail)"
    }
  },
  "c2_adversarial_canonical_invariant": {
    "invariant": "모든 C2 adversarial 입력에 대해 canonical engine 은 권한확대 0 — hard fail-closed(PolicyEngineError) 또는 allowed∩forbidden=∅ resolution",
    "per_fixture": {
      "task-2553+34.profile-mismatch.json": "RESOLVED, leak=[] (read-only registry + concrete-schema 검증으로 simulated 변조 주입 불가 — 공격 무력화)",
      "task-2553+34.missing-profile.json": "FAIL-CLOSED PolicyEngineError(profile_load_fail)",
      "task-2553+34.stale-profile.json": "FAIL-CLOSED PolicyEngineError(goal_request_schema_fail) — min_profile_version extra key (additionalProperties:false) 거부",
      "task-2553+34.forbidden-boundary.json": "RESOLVED, leak=[] (boundary breach 는 runtime gate 영역, contract 파생에서 권한확대 0)",
      "task-2553+34.allow-vs-forbid-conflict.json": "RESOLVED, leak=[] (Codex CRITICAL fix: allowed∩forbidden pruning)"
    }
  },
  "ownership": {
    "namespace": "C-track (task-2553+36.*) — 단일 executor 단독 소유",
    "c2_c3_crosswrite": 0,
    "contamination": false
  }
}
