Blog
Technical Deep Dives

The synthesis pipeline: contradictions, budgets, approval

The synthesis pipeline: an archive's documents become combined wiki pages - budgeted runs, judged contradictions, human-approved writes only. Census: F-SYNTH-1.

Simmetric Team7 min read16/10/2026
The synthesis pipeline: contradictions, budgets, approval

Where documents disagree, it says so

The wiki engine's pages solve storage; the synthesis pipeline solves agreement. Given a set of an archive's documents, the pipeline produces combined wiki pages - each one unites its sources and, where the sources disagree, says so with a contradiction marker. Nothing lands on the filesystem until a human approves precisely what got proposed, and every run is bounded by an explicit budget of tokens, calls, and pages.

This article walks the design: the staged pipeline, how contradiction candidates form and get judged, how the budget keeps a run honest, and why the approval gate - not the model - decides what ships.

A Community feature (the pipeline runs on the same infrastructure as the chat orchestrator; per-run budgets). Facts per FACT-CENSUS.md F-SYNTH-1.

The staged pipeline

A synthesis run is orchestrated by the service's facade over a set of stages:

  1. Entity extraction - over the selected corpus.
  2. Per-page summaries - the pipeline drafts each source's own page.
  3. The final blocks - the wiki's combined page, written with the archive's advisory block riding the decision pass's system role (the injection seam is explicit: the advisory rails enter only the final, decisive pass).

The stages run through a single LLM-call wrapper, so a budget can count every call in one place.

Contradiction detection: pre-filter, then judge

Comparing every claim against every other claim is quadratic and mostly noise. The pipeline's split:

  • The candidate pairs form by similarity - a Jaccard-style pre-filter at a low threshold (0.15) surfaces the pairs worth a second look.
  • The suspicious pairs go to the LLM judge - a per-pair judgment call reads the two claims and decides: contradiction or not.
  • The verdict lands as a contradiction marker on the involved pages, with a one-line claim summary pulled from each side.

Then a weekly fidelity sample measures the process's accuracy over time - the detector's quality is itself a recorded, watched number.

The budget tracker

Every run bounds THREE budgets - tokens, LLM calls, and produced pages. They feed off the same call wrapper's metering:

  • Stop = a named, expected state: the already-written output stays valid; the run's result is never a half-page limbo.
  • The watchdog parallels the chat orchestrator's behavior - a runaway run cannot outspend its config.

That is the operator's guard: synthesis is a background consumer, and its appetite is explicit.

Selective approval - the thing that makes it safe

The pipeline's proposed changes do NOT land automatically. Every write passes through the approval flow:

  1. The proposed page generates a deterministic preview first (the same machinery as the wiki's write path) - what you review is what would land.
  2. The approver confirms - and only the approved modifications persist (applyApprovedChanges).
  3. Every proposed page carries its source frontmatter - the provenance rides with the proposal.

The model proposes; the human ships. That division is the pipeline's whole security posture: an LLM may read everything, but the filesystem only ever hears from the approver.

The housekeeping: triggers and the reaper

  • Post-OCR triggers - when a scan completes, the trigger service queues a synthesis run (with a cooldown, so a batch of scans does not storm the queue).
  • The reaper - a 15-minute scheduler flips orphaned PROCESSING runs to FAILED - a crashed run can never be mistaken for a busy one.

Reading on

The guide carries the operator-level detail - the stages' tables, the trigger endpoints, the budget keys - at /en/docs/synthesis-pipeline:

Provenance: Simmetric Chat docs/SERVICES.md (the Synthesis domain; the synthesis* modules) + README.md:33, docs/WIKI_SCHEMA_LAYER.md (the Pass-4 injection seam), CHANGELOG.md v0.28.1 - at the census's pinned docs state (SHA aca5b8ff).

Related articles