Harden Epiphany proposal evidence selection

This commit is contained in:
Meta Vens 2026-04-25 03:08:59 +01:00
commit 698f19c221
7 changed files with 266 additions and 57 deletions

View file

@ -107,3 +107,5 @@
{"ts": "2026-04-25T01:31:16+00:00", "type": "verification", "status": "ok", "note": "Reverified final proposal-quality hardening with cargo fmt, cargo test --manifest-path .\\epiphany-core\\Cargo.toml proposal, full cargo test --manifest-path .\\epiphany-core\\Cargo.toml (24 tests), CARGO_TARGET_DIR=C:\\Users\\Meta\\.cargo-target-codex cargo test -p codex-core --lib proposal, and CARGO_TARGET_DIR=C:\\Users\\Meta\\.cargo-target-codex cargo test -p codex-app-server --lib epiphany."}
{"ts": "2026-04-25T01:44:47+00:00", "type": "verification", "status": "ok", "note": "Verified linked-frontier proposal hardening with cargo fmt --manifest-path .\\epiphany-core\\Cargo.toml, cargo test --manifest-path .\\epiphany-core\\Cargo.toml proposal (7 tests), full cargo test --manifest-path .\\epiphany-core\\Cargo.toml (25 tests), CARGO_TARGET_DIR=C:\\Users\\Meta\\.cargo-target-codex cargo test -p codex-core --lib proposal, and CARGO_TARGET_DIR=C:\\Users\\Meta\\.cargo-target-codex cargo test -p codex-app-server --lib epiphany."}
{"ts": "2026-04-25T01:44:47+00:00", "type": "implementation", "status": "ok", "note": "Hardened read-only thread/epiphany/propose frontier focus in epiphany-core. Proposal now expands focused graph nodes through existing architecture/dataflow links and marks named incident graph edges active, so promoted frontier patches carry connected map context rather than only the directly observed architecture node."}
{"ts": "2026-04-25T02:08:39+00:00", "type": "implementation", "status": "ok", "note": "Hardened read-only thread/epiphany/propose selection and churn semantics in epiphany-core. propose_map_update now requires selected accepting observations to cite accepting recent_evidence, summarizes evidence-backed selection quality in proposal observation/evidence, and derives churn diff_pressure from reused/created nodes, touched paths, observation count, existing pressure, and unresolved write risk."}
{"ts": "2026-04-25T02:08:39+00:00", "type": "verification", "status": "ok", "note": "Verified evidence-backed proposal selection/churn hardening with cargo fmt --manifest-path .\\epiphany-core\\Cargo.toml, cargo test --manifest-path .\\epiphany-core\\Cargo.toml proposal (10 tests), full cargo test --manifest-path .\\epiphany-core\\Cargo.toml (28 tests), CARGO_TARGET_DIR=C:\\Users\\Meta\\.cargo-target-codex cargo test -p codex-core --lib proposal, and CARGO_TARGET_DIR=C:\\Users\\Meta\\.cargo-target-codex cargo test -p codex-app-server --lib epiphany."}

View file

@ -49,7 +49,7 @@ active_subgoals:
- Keep the Phase 5 distill/propose/promote/update work aligned with reality in code and repo memory.
- Keep vendored Codex as a thin typed host seam while Epiphany-owned prompt and retrieval/indexing logic live in the repo-owned `epiphany-core` crate.
- Preserve exact/path lookup and BM25 fallback while the Qdrant path stays explicit and bounded.
- Harden the next layer above the landed typed distill/propose/promote/update paths: richer evidence-to-map proposal quality beyond graph-node reuse and linked frontier focus while keeping verifier-backed acceptance/rejection explicit.
- Harden the next layer above the landed typed distill/propose/promote/update paths: richer evidence-to-map proposal quality beyond graph-node reuse, linked frontier focus, evidence-backed selection, and map-delta churn pressure while keeping verifier-backed acceptance/rejection explicit.
accepted_design:
- external typed state files
@ -99,6 +99,7 @@ accepted_design:
- keep Windows app-server verification explicit about stack pressure: Cargo config sets `RUST_MIN_STACK=67108864` so the test binary does not depend on shell folklore or tiny default test-thread stacks
- harden read-only map/churn proposal quality incrementally: `thread/epiphany/propose` should reuse existing architecture graph nodes by exact code-ref, same-path overlap, or deterministic path-node id before creating new candidate nodes, preserve existing node identity/metadata, and describe whether the candidate refines, expands, or updates the map in churn
- harden proposal frontier focus incrementally: `thread/epiphany/propose` should follow existing graph links between architecture and dataflow nodes and mark named incident graph edges active so prompt rendering sees relevant connected context
- harden proposal selection and churn incrementally: `thread/epiphany/propose` should require selected verified observations to cite accepting `recent_evidence`, summarize the evidence-backed selection in the candidate observation/evidence, and derive `diff_pressure` from the candidate map delta, touched paths, selected observation count, and unresolved write risk instead of merely inheriting old churn
rejected_paths:
- name: pinned_map_only
@ -115,5 +116,5 @@ rejected_paths:
reason: audited candidates were either terminal-only, stale/aspirational, or incoherent wrappers; the comparison clones were removed from vendor to avoid building on untrusted drift
current_status:
summary: Workspace initialized with protocol files, typed state, handoff notes, architecture maps, and a rolling implementation plan against vendored Codex. Phase 1 durable state, Phase 2 prompt integration, the minimal Phase 3 typed read surface, and Phase 4 retrieval/indexing/core-extraction are landed on `main`. Phase 5 semantic distillation/promotion/proposal is now active: the current baseline includes explicit Qdrant indexing with BM25 fallback, typed `thread/epiphany/update`, read-only `thread/epiphany/distill`, read-only `thread/epiphany/propose`, verifier-backed `thread/epiphany/promote`, structural map/churn promotion validation, graph-node reuse and linked frontier focus in `epiphany-core`, and thin vendored Codex host seams. The Windows app-server stack-pressure regression was narrowed to test-thread stack size; repo-local Cargo config sets `RUST_MIN_STACK=67108864`, and boxed-future request-dispatch experiments were removed after config-only verification passed. The repo also has source-available/commercial licensing plus a CLA gate for external contributions.
next_action: Continue Phase 5 by hardening the layer above `thread/epiphany/distill`, `thread/epiphany/propose`, `thread/epiphany/promote`, and `thread/epiphany/update`: richer evidence-to-map proposal quality beyond current exact-ref/same-path/deterministic-id/graph-link matching, better observation selection and churn semantics, while keeping retrieval/distillation/proposal read-only and avoiding watcher, GUI, or specialist-agent machinery.
summary: Workspace initialized with protocol files, typed state, handoff notes, architecture maps, and a rolling implementation plan against vendored Codex. Phase 1 durable state, Phase 2 prompt integration, the minimal Phase 3 typed read surface, and Phase 4 retrieval/indexing/core-extraction are landed on `main`. Phase 5 semantic distillation/promotion/proposal is now active: the current baseline includes explicit Qdrant indexing with BM25 fallback, typed `thread/epiphany/update`, read-only `thread/epiphany/distill`, read-only `thread/epiphany/propose`, verifier-backed `thread/epiphany/promote`, structural map/churn promotion validation, graph-node reuse, linked frontier focus, evidence-backed proposal selection, map-delta churn pressure in `epiphany-core`, and thin vendored Codex host seams. The Windows app-server stack-pressure regression was narrowed to test-thread stack size; repo-local Cargo config sets `RUST_MIN_STACK=67108864`, and boxed-future request-dispatch experiments were removed after config-only verification passed. The repo also has source-available/commercial licensing plus a CLA gate for external contributions.
next_action: Continue Phase 5 by hardening the layer above `thread/epiphany/distill`, `thread/epiphany/propose`, `thread/epiphany/promote`, and `thread/epiphany/update`: richer evidence-to-map proposal quality beyond current exact-ref/same-path/deterministic-id/graph-link/recent-evidence matching and map-delta churn pressure, especially stronger graph-semantic heuristics and observation prioritization, while keeping retrieval/distillation/proposal read-only and avoiding watcher, GUI, or specialist-agent machinery.

View file

@ -4,7 +4,7 @@ This file is intentionally disposable.
## Current Subgoal
- Continue Phase 5 proposal-quality hardening beyond graph-node reuse and linked frontier focus, without hidden writes.
- Continue Phase 5 proposal-quality hardening beyond graph-node reuse, linked frontier focus, evidence-backed selection, and map-delta churn pressure, without hidden writes.
## Working Notes
@ -12,9 +12,11 @@ This file is intentionally disposable.
- First read-only `thread/epiphany/propose` slice is landed in the working tree:
- `epiphany-core/src/proposal.rs` owns deterministic `propose_map_update`
- selected observations must already exist in thread state, have accepting status, and carry code refs
- selected observations must cite accepting `recent_evidence`; missing or failed backing evidence now rejects proposal before graph/churn drafting
- proposal now tries exact code-ref overlap, same-path overlap, and deterministic path-node id fallback against existing architecture graph nodes before creating new candidate path nodes
- matching nodes are focused and enriched with newly observed refs without overwriting their existing title, purpose, or status
- proposal expands frontier focus through existing graph links, marks named incident architecture/dataflow edges active, emits proposal observation/evidence with reused/created node counts, and marks churn as `proposal_refines_map`, `proposal_expands_map`, or `proposal_updates_map`
- proposal expands frontier focus through existing graph links, marks named incident architecture/dataflow edges active, emits proposal observation/evidence with evidence-backed selection counts plus reused/created node counts, and marks churn as `proposal_refines_map`, `proposal_expands_map`, or `proposal_updates_map`
- churn `diff_pressure` now comes from the candidate map delta, touched path count, selected observation count, and existing unexplained write risk, with existing pressure kept as a floor
- app-server exposes experimental loaded-thread-only `thread/epiphany/propose`
- live stdio smoke proved propose is read-only, and propose -> promote persists graph/churn only after verifier evidence
- The Phase 4 retrieval/indexing/core-extraction anchor is `80c29e0` on `main`. The older `360dfea` commit is only the first hybrid retrieval anchor, and later `main` also includes the typed update/distill/promote surfaces, promotion safety layer, and app-server stack-pressure fix.
@ -158,6 +160,6 @@ This file is intentionally disposable.
## Open Questions
- How much more can move into `epiphany-core` without sacrificing the typed Codex host seam that makes the integration first-class?
- How should verified observations propose map/churn edits without turning promotion into automatic graph fanfic?
- How should verified evidence-backed observations be prioritized automatically without turning proposal into automatic graph fanfic?
Do not promote anything from here into the map unless it survives verification or repeated reuse without contradiction.