Dashboard › institutional-transition-lab › Distillation
7a0f2519-cbac-41b3-8ada-931b77636ecb["lore_tm_v1_U52nVGUiu-LitVTumRNJ7J4AMOj7p7co5kdoCa7J0-M","lore_tm_v1_Gyd7MELj8v0mx_eY-OXI87ghseYwPHGgrNXSknMJANU","lore_tm_v1_o_DLNlQtA2O5k9O28KANqkPBqHyRdkQmPbAiggJbkLM"]
Date: Sep 8, 2026
/home/byk/Code/institutional-transition-lab; files must not be modified.src/institution_lab/governance_adjudication.py, schema/governance-adjudication-v1.schema.json, tests/test_governance_adjudication.py, pyproject.toml, cases/review/oss-governance-adjudication-v1.inputs.json, and, only if needed, src/institution_lab/governance_coding.py.file:line, an adversarial input, and an expected regression test; specifically requested manual-validator/schema parity and CLI-composition checks.PASS and identify residual risks.src/institution_lab/governance_adjudication.py imports validate_response from institution_lab.governance_coding; defines DECISIONS={"accept","revise","reject","abstain"}, institutional classes effective_institutional_change, announced_institutional_change, proposal_only, reviewer types human, llm, human_llm_assisted, reviewer roles source_adjudicator, evidence_auditor, synthesizer, and response sources luna_a, luna_b, terra_advisory (lines 13-23).governance_adjudication.py defines 9 REQUIRED_INPUT_PINS: workflow_run_id, artifact_id, artifact_sha256, documents_sha256, documents_file_sha256, coding_package_file_sha256, protocol_sha256, coding_schema_sha256, and adjudication_schema_sha256 (lines 24-34).governance_adjudication.py hard-codes FROZEN_INPUT_PINS: workflow_run_id=33063470968, artifact_id=9642983578, artifact_sha256=1f6be91fcd98e43e99d82d5f274536f6c23616e7e6c711e26324a2cc4b06ef06, documents_sha256=d70f7f795847968339a645b6dbd6d4428af6bd6044de44fa2602d4c4343b0ee9, documents_file_sha256=2a62ab05687982c112a29f6126227c26c3ff8defc89ca64662753aaf85c3c0ce, coding_package_file_sha256=14644759f53071adfe1173d4e25bb01931b8c1591fa8a48295dbd0556a754769, protocol_sha256=06d4b3407677fe7fb23046f70164a366db06638e8a29af3daf7661f00d565933, coding_schema_sha256=bfc735a7d8602d1f236a88c2d23b195f0600a8bae86fb8c8936afe7883a41b8e, and adjudication_schema_sha256=6181f5cb60a0462f83be00be301763daa89f11581e68ee1c46a84e8bf4e5be31 (lines 35-49).verify_input_manifest() requires the manifest key set to equal REQUIRED_INPUT_PINS, compares every pin to FROZEN_INPUT_PINS, hashes six supplied files, checks ZIP members documents.json and v1.2-adjudication-package.json byte-for-byte against durable files, and verifies the canonical documents hash (lines 74-119)._source_index() indexes each valid document sourceβs source_id β text and adds synthetic source record_metadata, whose searchable text is compact sorted JSON containing record_id, source_url, published_on, publisher, and source_type (lines 127-140)._evidence_errors() requires exact evidence-reference keys, verifies claim fields against CLAIM_FIELDS, checks source existence, and treats a quote as grounded whenever the non-empty quote is a substring of the indexed source text (lines 143-167).graph_edge_diff() obtains power_changes with .get() from baseline/final coding, keys each edge using compact sorted JSON, and reports sorted set differences as added and removed (lines 178-193)._validate_reviewer() requires exactly reviewer_id, reviewer_type, model, role, and assistance; requires null model for humans and a non-empty model string for non-humans; its only named-model restriction is rejecting any model string containing case-insensitive "gemini" because Gemini is restricted to event triage (lines 196-221)._validate_record() compares source_url to the frozen document, validates decision/reviewer IDs/rationale/source audit, requires evidence_limitations only when specific evidence-bound flags indicate truncation or unavailable patches, validates accept/revise/reject/abstain semantics, calls validate_response(final_coding, document), applies class/date/status constraints, checks claim evidence, and derives graph-edge revisions (lines 224-389)._validate_record() creates grounded_fields from every dictionary in claim_evidence_refs without limiting that set to references that passed _evidence_errors(); it then only checks whether each non-null CLAIM_FIELDS field name appears in that set (lines 353-369).basis in RESPONSE_SOURCES | {None}; only accept requires basis == accepted_from; baseline is None for null basis, and graph_edge_diff(baseline, final_coding) determines expected added and removed (lines 371-388).validate_adjudication() checks transition_dates_excluded, outcome_data_used, adjudication input values against verified_pins, and the coding package summaryβs documents_sha256; it does not itself validate the artifact or call verify_input_manifest() (lines 392-415).validate_adjudication() requires non-empty reviewers, applies _validate_reviewer(), detects duplicate reviewer IDs, maps IDs to roles, and requires each matched adjudication record to list at least one reviewer whose mapped role is source_adjudicator (lines 416-434 and 467-487).validate_adjudication() checks adjudication and coding record IDs against document IDs for exact order and duplicates; it builds documents_by_id and coding_by_id using dictionary comprehensions keyed by row["record_id"], then validates only adjudication records whose ID exists in both maps (lines 436-487).validate_adjudication() derives decision/class counts, considers only records with decision=="abstain" unresolved, copies dictionary-valued graph_edge_revision objects into the summary, and sets canonicalization_gate to "closed" if manual errors or unresolved abstentions exist, otherwise "open" (lines 489-536).validate_against_schema() uses Draft202012Validator(schema, format_checker=FormatChecker()) and returns formatted schema errors sorted by instance path (lines 539-545).render_markdown() emits canonicalization status, decision and class counts, record decisions, unresolved IDs, frozen inputs iterated from the adjudication object, reviewer provenance, and only graph-edge revisions having at least one added or removed edge; it appends - None only when the final list element remains the blank section separator (lines 548-594).main() directly json.loads() the adjudication, manifest, documents, coding package, and adjudication schema; calls verify_input_manifest(), then schema and manual validation; merges errors only after validate_adjudication() returns; forces the summary gate closed on merged errors; writes JSON and Markdown summaries; then raises ValueError if errors exist (lines 597-638).schema/governance-adjudication-v1.schema.json is Draft 2020-12, disallows additional root properties, requires schema_version=1, non-empty adjudication_id, design_status="performance_blinded_llm_assisted_source_adjudication", transition_dates_excluded=true, outcome_data_used=false, inputs, reviewers, and records; records must contain exactly 40 items (lines 1-36).human, llm, and human_llm_assisted; model is any non-empty string or null; roles are source_adjudicator, evidence_auditor, or synthesizer; the schema does not encode the manual human/null, non-human/non-empty, or Gemini restrictions (lines 69-83).record_class also permits control_event, no_event, and abstain; power_changes has no minimum item count; confidence is 0 through 1; dates use JSON Schema format: date (lines 109-182).edge_revision requires exactly basis, added, and removed; basis may be luna_a, luna_b, terra_advisory, or null; both edge arrays may be empty (lines 184-199).source_audit.source_ids requires at least 1 unique non-empty string, and each record requires record_id, source_url, decision, accepted_from, reviewer_ids, source_audit, rationale, evidence_limitations, unresolved_reason, claim_evidence_refs, final_coding, and graph_edge_revision with no additional properties (lines 200-267).