Skip to content

feat(context): slice 2 — structural-v1 policy, path index, replay-lite #181

Description

@akougkas

Part of #179. Depends on slice 1.

path-index.ts (paths from tool-call args, fileEntry entries, write/edit results; no fingerprints), protect.ts, policies/structural.ts with rules in order: stale_after_mutation, superseded_read, failure_resolved, listing_consumed, thinking_turn_closed, age_horizon (last rung, newest-safe-first, batched to target). replay/ over Clio ledgers only: loader, reference graph (file_reread, file_discovery, file_rewrite), oracle and random controls, metrics (retention, eviction_precision, tokens_evicted, churn), JSON + markdown report. CLI clio-coder context replay --sessions <dir>.

Acceptance

  • Frozen fixture under tests/fixtures/context-replay/ produces the same contextEviction sequence through the replay runner and the live engine.
  • On local Clio ledgers, structural-v1 retention >= age-horizon and eviction precision >= random; table committed under benchmarks/results/context-replay/.
  • Only then: default policy flips to structural-v1.
  • Supersession is range-aware (a range read supersedes only an identical or containing range).

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:contextContext engine: working set, compaction, project contextenhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions