Skip to content

Assync Synthesis Engine

Purpose

Deterministically combine structured run reports, normalized findings, and evidence into one SynthesisResultno LLM is involved; identical inputs always produce identical output regardless of input ordering (synthesis/engine.py::synthesize, verified in tests/test_synthesis.py::test_deterministic_regardless_of_input_order).

The 14 Ordered Rules (synthesis/rules.py)

  1. Verified evidence outranks unsupported opinion.
  2. FRESH_EVIDENCE outranks HISTORICAL_EVIDENCE for current-state claims.
  3. INFERRED claims may not override verified evidence.
  4. UNVERIFIED claims must be reported as unresolved.
  5. Blocking security or governance findings override majority approval.
  6. Critical findings require a human decision.
  7. Missing mandatory evidence prevents completion.
  8. Conflicting recommendations must be surfaced, not averaged away.
  9. Human authorization overrides AI recommendation.
  10. No synthesis result may grant its own authorization.
  11. Separation-of-duty violations block progression.
  12. A failed mandatory run blocks synthesis completion.
  13. Optional run failures may be reported without blocking when policy permits.
  14. COMMIT_GO, PUSH_GO, MERGE_GO, and RELEASE_GO must never be inferred.

Every rule maps to a concrete check in engine.py; rule 14 is additionally asserted at the end of synthesize() and unit-tested directly (test_never_recommends_commit_push_merge_release).

Evidence-Strength Bookkeeping (rules 1–4)

A finding with no evidence_ids is reported in unsupported_claims. A finding whose evidence is entirely INFERRED/UNVERIFIED/BLOCKED is flagged as unable to override verified evidence — it is never silently dropped, only labeled. EvidenceClassification.BLOCKED here means verification could not be completed — a distinct concept from mission runtime state BLOCKED; see security-model.md for why these intentionally share one literal value.

Overall Recommendation (priority order)

blockers present            → BLOCK
conflicting recommendations → REQUEST_CHANGES
any REQUEST_CHANGES/BLOCK/ABORT among runs → REQUEST_CHANGES
any NO_OPINION among runs   → NO_OPINION
all runs APPROVE            → APPROVE
mixed APPROVE/APPROVE_WITH_CONDITIONS → APPROVE_WITH_CONDITIONS

Synthesis only ever recommends — it never calls authorization/service.py itself. If human decisions or blockers exist, it recommends DECISION_GO. Otherwise it recommends REVIEW_GO (on approval) or ANALYSIS_GO (on missing evidence). It is structurally incapable of recommending COMMIT_GO, PUSH_GO, MERGE_GO, or RELEASE_GO — those four are excluded from every branch and asserted absent before the function returns.

Finding Normalization (findings/normalization.py)

Deterministic, not semantic: findings are merged only when they share the exact (category, normalized_title) key. When uncertain, findings are kept separate — no opaque similarity scoring exists in this MVP.

MVP Limitations

  • Evidence-classification precedence (rules 1–4) is currently applied per-finding, not used to resolve two findings that directly contradict each other with different evidence strength — that remains a documented gap for the contradiction mock scenario, which synthesis currently surfaces via conflicts rather than auto-resolving.