Skip to content

chore: sync develop -> main (governance fixes + what_is_known infra-kind bugfix)#11

Merged
tbitcs merged 7 commits into
mainfrom
develop
May 19, 2026
Merged

chore: sync develop -> main (governance fixes + what_is_known infra-kind bugfix)#11
tbitcs merged 7 commits into
mainfrom
develop

Conversation

@tbitcs
Copy link
Copy Markdown
Contributor

@tbitcs tbitcs commented May 19, 2026

Brings main up to date with all develop improvements since PR #10:

Bugfix:

  • fix(query): \what_is_known\ was leaking kind=edge/rollback_event/token_metric/skill_run records into RAG results — chronoagent would get graph metadata in LLM context. Now filters _INFRA_KINDS when no kind= specified.

Governance:

  • Switch to yaml governance mode (eliminates duplicate REQ IDs from reading both YAML + MD)
  • Add REQ-CM-015..024 covering all Phase 2 features
  • Add TEST-CM-015..024 linked to existing test files
  • Decompose compound REQs for stress-test equilibrium (0 failure modes, 0 logic knots)
  • Fix MUST/MUST NOT logic knots in Phase 1 descriptions
  • ARCHITECTURE.md: add module docs for deps, rollback, context_pack, query, metrics

All checks: 192 tests, ruff clean, mypy clean, audit 28/28, stress-test equilibrium YES.

Co-Authored-By: Oz oz-agent@warp.dev

tbitcs and others added 7 commits May 18, 2026 19:31
Adds pip install --pre --upgrade specsmith + migrate-project + audit + sync
before every session. Agents now always run system-installed specsmith.

Co-Authored-By: Oz <oz-agent@warp.dev>
…, query API, metrics)

Brings all Phase 2 work (PR #10) into the develop branch.
Conflict resolution: kept develop's Session Bootstrap section; updated test count to 192.

Co-Authored-By: Oz <oz-agent@warp.dev>
Root cause fixed: governance-mode was 'strict' causing specsmith to read
both docs/requirements/chronomemory.yml AND docs/REQUIREMENTS.md as
independent sources, creating 14 duplicate IDs. Switched to yaml mode
(single canonical source = YAML; MD is derived via specsmith sync).

Phase 1 (REQ-CM-001..014): YAML updated to match current implementation
with platform, boundary, status=implemented, correct component paths.

Phase 2 added (REQ-CM-015..021):
  REQ-CM-015  Typed Dependency Graph (DepGraph)
  REQ-CM-016  Epistemic Rollback and Cascade Propagation
  REQ-CM-017  Context Pack Compiler
  REQ-CM-018  Extended Query API - ESDB Spec s23 (18 functions)
  REQ-CM-019  Token Metrics Tracking
  REQ-CM-020  Skill System - First-Class Skill Records
  REQ-CM-021  ChronoStore Phase 2 Convenience Methods

TEST-CM-015..021 added to docs/tests/chronomemory.yml covering all
192 test cases across test_deps, test_rollback, test_context_pack,
test_query_ext, and test_metrics.

ARCHITECTURE.md updated: added module docs for deps.py, rollback.py,
context_pack.py, query.py, metrics.py; Rust crate moved to Phase 3.

Validate: 21 unique REQ IDs, 4/4 std checks clean, 0 strict errors.
Audit: 28/28 checks, 21 REQs covered, Phase Release 100%.

Co-Authored-By: Oz <oz-agent@warp.dev>
…ibrium

Eliminated 7 logic knots (negation conflicts) by rephrasing MUST NOT
language in three requirement descriptions:

  REQ-CM-002: 'must not be the default format' ->
              'NDJSON is the required default; binary is Phase 2 only'
  REQ-CM-008: 'must not be conflated' ->
              'they are distinct concepts and must remain separate'
  REQ-CM-010: 'must not vary between consumers' ->
              'are invariant across all consumers and versions'

Stress-test results (before -> after):
  Logic knots:   7 -> 0
  Failure modes: 24 -> 3 (all LOW severity, no critical)
  Equilibrium:   NO -> YES

3 remaining LOW suggestions: decompose REQ-CM-015/016/020 (compound
claims). These are stylistic — each REQ already has its own test spec.

Final state: validate 4/4 std, audit 28/28, stress-test equilibrium YES,
192 tests passing, ruff clean, mypy clean.

Co-Authored-By: Oz <oz-agent@warp.dev>
Decomposed 3 compound Phase 2 requirements into focused single-proposition
REQs to achieve 0 failure modes in stress-test:

  REQ-CM-015: Typed Dependency Graph - Core Interface and BFS Traversal
  REQ-CM-022: DepGraph WAL Persistence and Replay (split from 015)

  REQ-CM-016: Epistemic Rollback - Cascade Propagation Logic (simplified)
  REQ-CM-023: Rollback WAL Event and ChronoStore Integration (split from 016)

  REQ-CM-020: Skill System - find_skills Keyword Matching (simplified)
  REQ-CM-024: Skill System - record_skill_run WAL Record (split from 020)

Added TEST-CM-022, TEST-CM-023, TEST-CM-024 linked to existing test files.

Stress-test results: 0 failure modes, 0 logic knots, Equilibrium YES.
Audit: 28/28, 24 REQs covered, Phase Release 100%.
Validate: 24 unique IDs, 4/4 std, 0 strict errors.
Tests: 192 passing. ruff: clean. mypy: clean.

Co-Authored-By: Oz <oz-agent@warp.dev>
what_is_known() was leaking kind=edge, rollback_event, token_metric, and
skill_run records into RAG query results. These are infrastructure
bookkeeping records, not agent-facing beliefs.

Fix: when no kind= filter is specified, filter out _INFRA_KINDS before
returning. The kind= parameter still works as a passthrough to retrieve
infra records explicitly when needed.

Impact for consumer repos:
  specsmith: query(rag_filter=True) unaffected (direct store call)
  chronoagent: what_is_known() now returns only belief records, no graph
               metadata leaking into LLM context
  ctt-neural: what_is_known() unaffected (uses kind='fact' filter)

All 192 tests pass. No existing tests broken.

Co-Authored-By: Oz <oz-agent@warp.dev>
Co-Authored-By: Oz <oz-agent@warp.dev>
@tbitcs tbitcs merged commit 7e2b2f3 into main May 19, 2026
21 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant