Extract Epiphany jobs projection

This commit is contained in:
Meta Vens 2026-05-13 01:14:55 +01:00
commit d5f7516464
7 changed files with 111 additions and 100 deletions

View file

@ -419,21 +419,23 @@ mapping into `vendor/codex/codex-rs/app-server/src/epiphany_reorient.rs`,
taking the processor to about 19,708 lines. The sixth cut moved
context/planning/graph-query projection into
`vendor/codex/codex-rs/app-server/src/epiphany_context.rs`, taking the processor
to about 19,462 lines. This is progress, not absolution: handlers,
jobs/roles/coordinator mappers, route orchestration, accept policy plumbing, and
to about 19,462 lines. The seventh cut moved jobs projection into
`vendor/codex/codex-rs/app-server/src/epiphany_jobs.rs`, taking the processor to
about 19,377 lines. This is progress, not absolution: handlers,
roles/coordinator mappers, route orchestration, accept policy plumbing, and
tests still keep too much Epiphany inside Codex.
Also: MCP itself is allowed to be JSON. The target is not "replace MCP JSON";
the target is an Epiphany-owned boundary that speaks typed Epiphany
intent/result/receipt documents internally and normal MCP JSON-RPC externally.
Continue with the actual whale-carcass cut: extract Epiphany jobs/roles/
coordinator projection mappers, route handlers, and remaining policy-shaped
code out of `codex_message_processor.rs` into Epiphany-owned app-server modules,
moving logic further into `epiphany-core` whenever it owns real policy. Success
is a visibly smaller `codex_message_processor.rs`, not merely nicer payload
names. Do not resume Rider, Unity, Aquarium, Face, dogfood, planning, app,
skill, marketplace, or bridge expansion until this organ is being cut cleanly.
Continue with the actual whale-carcass cut: extract Epiphany roles/coordinator
projection mappers, route handlers, and remaining policy-shaped code out of
`codex_message_processor.rs` into Epiphany-owned app-server modules, moving
logic further into `epiphany-core` whenever it owns real policy. Success is a
visibly smaller `codex_message_processor.rs`, not merely nicer payload names. Do
not resume Rider, Unity, Aquarium, Face, dogfood, planning, app, skill,
marketplace, or bridge expansion until this organ is being cut cleanly.
The Phase 6 freshness slice is landed. It exposes read-only
`thread/epiphany/freshness` from live retrieval summaries plus graph

View file

@ -62,6 +62,6 @@ Rule: JSON is allowed at external schema/wire boundaries. Inside Epiphany, live
3. Done: replace role `statePatch` JSON with typed map/planning/graph patch documents. `EpiphanyRoleFindingInterpretation` now carries `EpiphanyRoleStatePatchDocument`; app-server maps it to the legacy protocol patch without JSON round-tripping.
4. Done: replace runtime job result JSON projections. Runtime-spine results now project through typed role/reorient interpreters instead of `runtime_job_result_to_role_json` and `runtime_job_result_to_reorient_json`.
5. Done: replace app-server launch protocol `input_json` / `output_schema_json` with typed launch documents and `output_contract_id`.
6. Continue the whale-carcass cut: the first cuts moved Epiphany launch doctrine and protocol-to-core launch document mapping into `epiphany_launch.rs`, role/reorient result projection into `epiphany_results.rs`, scene projection into `epiphany_scene.rs`, freshness/reorientation mapping into `epiphany_reorient.rs`, and context/planning/graph-query projection into `epiphany_context.rs`, reducing `codex_message_processor.rs` from about 21,263 to 19,462 lines. Next move jobs/roles/coordinator projection mappers, route handlers, and policy-shaped code out of the processor; success means the processor keeps shrinking and ownership gets clearer, not merely better typed.
6. Continue the whale-carcass cut: the first cuts moved Epiphany launch doctrine and protocol-to-core launch document mapping into `epiphany_launch.rs`, role/reorient result projection into `epiphany_results.rs`, scene projection into `epiphany_scene.rs`, freshness/reorientation mapping into `epiphany_reorient.rs`, context/planning/graph-query projection into `epiphany_context.rs`, and jobs projection into `epiphany_jobs.rs`, reducing `codex_message_processor.rs` from about 21,263 to 19,377 lines. Next move roles/coordinator projection mappers, route handlers, and policy-shaped code out of the processor; success means the processor keeps shrinking and ownership gets clearer, not merely better typed.
7. Seal MCP payloads behind an Epiphany boundary that speaks typed Epiphany documents internally and MCP JSON externally.
8. Audit heartbeat cognition values and either type them or explicitly expire them.