Parent: #648
Outcome
Create a trustworthy engineering foundation before adding new product capabilities.
Phase 0 must eliminate known silent semantic loss, establish reliable protected test gates, remove qualification-repository contamination from production behavior, and create a small independent evaluator that can stop unsafe changes.
Why this phase comes first
At v0.32.1:
- distinct graph relationships can overwrite each other;
- dangling graph candidates can disappear without a durable terminal record;
- production ranking and claim generation contain exact status-page qualification knowledge;
- the broad local test suite has exhibited worker-start and timeout failures under the audited environment;
- the public production benchmark has no valid Native-vs-Madar comparison.
Building ranking, framework, indexing, or host features on this base would make an unqualified system more complex without making it more trustworthy.
Ordered child issues
Immediate parallel starters
#654 blocks every roadmap merge until the complete suite is reliable. #655 establishes the independent evaluation contract used by later semantic and product gates.
Strict graph-integrity sequence
The implementation order is strictly:
#656 → #657 → #658 → #659
#656 may be implemented while #654 is investigated, but no graph PR may merge until #654 is resolved and all stated gates pass. Agents must stop after their assigned PR slice.
Qualification independence and Tier 1 gate
#660 depends on the frozen qualification contract and graph answerability foundation. #661 closes Phase 0 by turning the independent truth, graph invariants, false-readiness cases, and benchmark-independence rules into a protected pull-request gate.
Dependency summary
#654 ───────────────────────────────┐
#655 ───────────────┐ │
│ │
#656 → #657 → #658 → #659 → #660 → #661
│
└── every merge also requires #654
Characterization/evaluator work may run in parallel where it does not modify production semantics. The graph storage and answerability sequence itself is not parallelizable.
Non-negotiable architecture decisions
- The canonical relationship is a deterministic semantic fact.
- A fact has one or more separately identified evidence occurrences.
- Topology operates on unique endpoint pairs.
- Semantic queries operate on facts.
- Evidence/provenance queries operate on occurrences.
- Missing, unresolved, rejected, or conflicting candidates remain durably accounted for outside traversable topology.
- No internal caller may select an arbitrary fact from a parallel set.
- Artifact v2 must be impossible for v0.32.1 to silently down-read.
- Evidence occurrences must not multiply topology, centrality, communities, bridges, or traversal steps.
Phase-wide non-goals
- Retrieval redesign or new ranking model.
compileContext architecture work.
- SPI/legacy consolidation.
- Incremental indexing.
- MCP profile/default changes.
- New frameworks or languages.
- Broad CLI cleanup.
- New product claims.
- Publishing a release while the four graph-integrity slices are incomplete.
Phase exit criteria
Phase 0 is complete only when:
- the full protected suite completes reliably on supported Node/OS lanes;
- every valid fact admitted at the graph boundary survives or follows a documented merge policy;
- no normalized graph candidate disappears without a terminal state;
- parallel facts round-trip deterministically;
- old artifact compatibility and old-reader rejection are proven;
- invalid, incompatible, or unaccounted graph state cannot produce
ready;
- no qualification-repository path, symbol, phrase, or equivalent special rule remains in production retrieval/context logic without an approved generic justification;
- Tier 1 independent tests cover graph preservation, false readiness, critical retrieval facts, Pack compatibility, and forbidden benchmark knowledge;
- build, typecheck, package parity, Registry validation, release verification, and exact-head protected CI pass.
Completion rule
Do not close this phase because implementation PRs merely exist. Close it only after every linked child issue is complete, every checkbox above is updated, and the complete Phase 0 protected gate is green.
Parent: #648
Outcome
Create a trustworthy engineering foundation before adding new product capabilities.
Phase 0 must eliminate known silent semantic loss, establish reliable protected test gates, remove qualification-repository contamination from production behavior, and create a small independent evaluator that can stop unsafe changes.
Why this phase comes first
At
v0.32.1:Building ranking, framework, indexing, or host features on this base would make an unqualified system more complex without making it more trustworthy.
Ordered child issues
Immediate parallel starters
#654 blocks every roadmap merge until the complete suite is reliable. #655 establishes the independent evaluation contract used by later semantic and product gates.
Strict graph-integrity sequence
The implementation order is strictly:
#656 may be implemented while #654 is investigated, but no graph PR may merge until #654 is resolved and all stated gates pass. Agents must stop after their assigned PR slice.
Qualification independence and Tier 1 gate
#660 depends on the frozen qualification contract and graph answerability foundation. #661 closes Phase 0 by turning the independent truth, graph invariants, false-readiness cases, and benchmark-independence rules into a protected pull-request gate.
Dependency summary
Characterization/evaluator work may run in parallel where it does not modify production semantics. The graph storage and answerability sequence itself is not parallelizable.
Non-negotiable architecture decisions
Phase-wide non-goals
compileContextarchitecture work.Phase exit criteria
Phase 0 is complete only when:
ready;Completion rule
Do not close this phase because implementation PRs merely exist. Close it only after every linked child issue is complete, every checkbox above is updated, and the complete Phase 0 protected gate is green.