§16. Synthesis
What this section covers
POST /v1/synthesis — a confidence-weighted summary view of the
live facts in a scope. Where lint reports raw health findings and
decay sweeps apply remediation, synthesis answers: "given everything
I know right now, what is the current state of this scope?"
Status: Experimental / dormant source package
Source material: Archived evolutionary spec snapshots. This page is the maintained Spec-X home for synthesis semantics.
Each subsection below shows the most recent normative text from the spec source. When earlier spec drafts also contained text for the same subsection, those revisions are collapsed under a Revisions accordion beneath it — open one to see what changed. Subsections that only appear in one draft render as plain text with no accordion.
Pre-reset status: Draft. The
synthesize_scopeMCP tool andPOST /v1/synthesisroute are specified here. Implementation is the D4 deliverable. Conformance test vectors (SYNTHESIS_VECTORS) will be finalized with D4 implementation. This section will be promoted to normative in the pre-reset spec.
Synthesis is designed for agent context injection.
An agent querying synthesize_scope("company") gets a structured
view of the most reliable current knowledge without needing to
manually filter contradictions, expired facts, or low-confidence noise.
§16.1 SynthesisEntry Shape
Each row in the synthesis response is a SynthesisEntry — the collapsed, current-state view of a single (entity, relation, scope) triple. Where a raw fact query might return ten historical assertions for "Alice's role," synthesis returns one entry with the highest-confidence live value. If that triple is contradicted (two live values competing), synthesis surfaces both via the alt_value/alt_confidence fields and flags contradicted: true so the consuming agent can decide whether to act on or escalate the ambiguity.
SynthesisEntry {
entity: URI
relation: string
scope: FactScope
value: FactValue
confidence: float // confidence of the winning fact
hlc: string // HLC of the winning fact
contradicted: boolean // true if unresolved contradiction exists for this (entity, relation, scope)
alt_value: FactValue? // populated if contradicted=true: the other live value
alt_confidence: float? // populated if contradicted=true
}
§16.2 Synthesis Algorithm
For each (entity, relation, scope) triple with at least one live fact (confidence > 0.0, not expired):
- Apply contradiction resolution order (§3.3): higher confidence wins; equal confidence → higher HLC wins.
- If an unresolved contradiction exists, set
contradicted=trueand populatealt_value/alt_confidencewith the losing fact's value and confidence. - Filter by
min_confidence(if provided): skip entries where the winning fact's confidence is below the threshold. - Include the entry in the response.
Expired facts (valid_until < now) and retracted facts (confidence=0.0) are excluded unless include_expired=true is passed.