OpenMind v2 Phase 6: formal Requirement Traceability, coverage gaps and governed Conflict resolution#12
Merged
Conversation
- openmind/traceability/: closed vocabularies, policy model + validator, 5 built-in policies, org policy loading, v0007 store, deterministic trace engine, gap detection + orphans, coverage, incremental refresh snapshots, comparable facts, 6 deterministic conflict detectors, conflict scan/lifecycle/promotion, TraceabilityService - migration v0007_traceability_conflicts (additive, 11 tables) - Phase 5 vocabularies extended additively (decision/revision/promotion members for conflict + gap + policy governance) - runtime.traceability + ServiceContainer.traceability wired - jobs: traceability_refresh + conflict_scan types; trace staleness mark after graph reconciliation; delete/terminate wipe Phase 6 rows - 8 read-only MCP tools (35 -> 43); compatibility gates updated - runtime version 1.6.0-dev; migration-head assertions updated
…undle
- cli_trace.py: trace policy/refresh/requirement/code/test/path/coverage/
gaps/orphans + conflict scan/list/show/promotion/governance groups
- REST: additive /projects/{id}/traceability/* and /conflicts* routes,
typed request models, no generic mutation endpoint
- bundle 2.0.0-draft.2: opt-in --include-traceability/--include-conflicts
files with referential backfill; verifier checks trace roots/targets/
relations/step ordering/gap roots/conflict joins/coverage arithmetic/
current-only staleness
- 15 acceptance suites (376 checks) + _traceability_helpers fixture kit, all registered in run_acceptance.py - fixes surfaced by the suites: latest_completed_run ordered by analyzed revision (second-resolution timestamp ties picked the wrong baseline), gap acceptance expiry overwritten instead of merged, subject-level conflict supersession (changed values produce new claim ids so the exact dedup key can never match) with draft grouping so simultaneous value pairs never ping-pong, scan-driven conflict decisions linked to the Knowledge Decision ledger - CI: 15 full-gate steps, 43-tool MCP smoke, v0007 smoke, Phase 6 cross-platform smoke (policy -> trace -> gap -> conflict -> promotion -> coverage -> bundle) - docs: README Phase 6 section + 43-tool table, cli.md trace/conflict groups + draft.2 bundle flags, database-migrations.md v0007
- verify_migrations: repeat-run already-applied list includes v0007 - verify_asset_adapters: 43-tool accounted-for gate includes TRACE set - verify_knowledge_bundle / verify_knowledge_cli: draft.1 -> draft.2 - docs/v2/phase-6-progress.md status ledger
created_at has one-second resolution: on a fast runner two coverage snapshots can be born in the same second and list ordering falls back to random ids, so asserting on list position picked the new snapshot. Assert the actual property instead: every non-current snapshot remains queryable with its metrics.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Builds formal, evidence-backed engineering traceability and governed conflict management over the Phase 5 canonical graph. Runtime
1.6.0-dev, migration head v0007, Bundle2.0.0-draft.2,.openmindstays1.1.0. Full design:docs/v2/phase-6-traceability-conflicts.md.What changed
A graph path is not a trace.
graph pathstays generic reachability; a formal trace must satisfy the workspace's selected Traceability Policy — every node maps to a policy stage, every edge type is allowed for that transition, lifecycle and evidence verify, traversal is bounded.possibly-relatednever satisfiesimplements,callsalone never proves a Requirement, and a missing link is returned as a Gap, never invented.openmind/traceability/(13 modules): closed policy model + validator, five built-in policies (generic-engineering,api-service,event-driven-service,batch-processing,japanese-v-model), organization policy directory (checksummed, invalid files listable, executable content rejected), deterministic trace engine (requirement + reverse code/test), coverage with honest null percentages, 19 gap types with policy-driven severities, orphan queries (untraced, never "invalid"), incremental refresh, comparable-fact normalization, six deterministic conflict detectors, conflict lifecycle + explicit candidate promotion,TraceabilityService.key=valueconfig, field types, authority-marked values). Units are never guessed; arbitrary prose is never compared; a missing test is a Gap, not a Conflict. Two-level identity: exact dedup key observes; subject-level supersedes when values change (history preserved); dismissals suppress via fingerprint until the facts change.trace/conflictCLI groups (actor+note on every write), additive REST under/projects/..., exactly 8 read-only MCP tools (35 → 43). No write-capable MCP tool.--include-traceability/--include-conflictsfiles with referential backfill; standalone verifier extended (trace roots/relations, step ordering, conflict joins, coverage arithmetic, current-only staleness).traceability_refresh+conflict_scanon the existing single worker; ingestion gains only a lightweight local trace-staleness mark; a partial scan is reported failed, never complete.Verification
python scripts/run_acceptance.py --all: 79 passed, 0 failed, 0 skipped — 64 pre-existing suites plus 15 new Phase 6 suites (376 checks), all registered in the manifest. CI gains 15 full-gate steps, the 43-tool MCP smoke, and a cross-platform Phase 6 smoke (policy → trace → gap → conflict → promotion → coverage → bundle verify). Zero provider calls in refresh/scan is proven with network entry points patched to fail.Notes for review
latest_completed_runorders by analyzed revision, not timestamp: one-second timestamp resolution made same-second runs tie and could pick the wrong incremental baseline.