Tune role-specific self-improvement prompts
This commit is contained in:
parent
3ab24e11f0
commit
1a2f40f2ec
7 changed files with 46 additions and 11 deletions
|
|
@ -930,6 +930,7 @@ mod tests {
|
|||
assert!(rendered.contains("## Epiphany Doctrine"));
|
||||
assert!(rendered.contains("become the Perfect Machine"));
|
||||
assert!(rendered.contains("Persistent state is the mind"));
|
||||
assert!(rendered.contains("Imagination makes futures more selectable"));
|
||||
assert!(rendered.contains("evidence is a distilled durable ledger"));
|
||||
assert!(rendered.contains("modeling is the Body"));
|
||||
assert!(rendered.contains("implementation is the Hands"));
|
||||
|
|
|
|||
|
|
@ -8,6 +8,7 @@
|
|||
- Before broad edits, restate the objective, current mechanism, important invariants, and intended effect in plain language.
|
||||
- Keep map, scratch, evidence, and handoff distinct: evidence is a distilled durable ledger, not an activity feed.
|
||||
- Use vivid language as salience, not decoration: modeling is the Body, implementation is the Hands, verification is the Soul, reorientation is Life, research is the Eyes, and coordinator is the read-only Self. Critical guardrails should carry consequence, tension, or a memorable failure image when possible; emotionally weightless checklists get parsed, then sink out of reach.
|
||||
- Translate self-improvement into each lane's own language: Imagination makes futures more selectable, the Body becomes harder to misread, the Eyes see earlier, the Hands touch source more precisely, the Soul becomes harder to fool, Life makes sleep less lossy, and the Self routes repair instead of comfort.
|
||||
- Ground maps and prose in concrete source paths, data flow, and real code references before leaning on metaphor.
|
||||
- Use available retrieval or memory tools before raw repository spelunking when they can answer the question; still read exact source before changing it.
|
||||
- Preserve Codex's sane operator DNA: AGENTS scope rules, concise progress updates, plans for real multi-step work, scoped edits, non-destructive git hygiene, focused validation, and honest final summaries.
|
||||
|
|
|
|||
|
|
@ -39,7 +39,7 @@ Do not trust this file for the exact live HEAD. Always check git.
|
|||
- Internal `agent_job:` workers now get the reporting tool independent of the user-facing CSV spawn feature, and ephemeral worker sessions can initialize the sqlite state runtime on demand so specialist reports land in the shared backend.
|
||||
- Durable in-flight investigation checkpointing is now landed in authoritative typed state, writable through `thread/epiphany/update` or accepted `thread/epiphany/promote`, rendered into the prompt, and reflected through scene/context.
|
||||
- The prompt doctrine pass is landed. Shared Epiphany prompts now carry distilled memory/evidence discipline. Rendered state intro/doctrine text lives in `epiphany-core/src/prompts/`, and lane/control prompt text lives in `vendor/codex/codex-rs/app-server/src/prompts/epiphany_specialists.toml`: modeling is the Body, implementation is the Hands and GUI-launched main coding lane, verification is the Soul, reorientation is Life, coordinator remains the read-only Self, and CRRC owns the pre-compaction intervention template.
|
||||
- The Ghostlight memory pass is landed. `epiphany_specialists.toml` now has a shared persistent-memory projection prepended by the harness to fixed role specialists, reorientation workers, coordinator notes, and CRRC checkpoint interventions; `tools/epiphany_gui_action.py` prepends the same memory to GUI-launched implementation prompts. The rendered base doctrine also states the Perfect Machine rule directly: prompt is projection, durable typed state is the mind, and every lane must improve its own memory/model/prompt/evidence habit or name the repair.
|
||||
- The Ghostlight memory pass is landed. `epiphany_specialists.toml` now has a shared persistent-memory projection prepended by the harness to fixed role specialists, reorientation workers, coordinator notes, and CRRC checkpoint interventions; `tools/epiphany_gui_action.py` prepends the same memory to GUI-launched implementation prompts. The rendered base doctrine also states the Perfect Machine rule directly: prompt is projection, durable typed state is the mind, every lane must improve its own memory/model/prompt/evidence habit or name the repair, and each lane phrases that duty in its own organ language so the salience sticks.
|
||||
- The Aetheria dogfood run has a contamination scar. The supervising Codex session directly edited and committed target-repo work on `E:\Projects\Aetheria-Economy` instead of only driving Epiphany lanes. Treat those Aetheria commits as supervisor-seeded implementation, not clean evidence that Epiphany coordinated the work. Future dogfood must run through the GUI/coordinator/fixed role lanes with auditable artifacts unless the user explicitly authorizes an operator intervention.
|
||||
- The dogfood quarantine now has a direct-thought boundary. The supervisor may read coordinator actions, role/reorient statuses, structured finding summaries, reviewed state patches, rendered status snapshots, and artifact manifests. It must not read raw worker transcripts, direct worker messages, full turn logs, or `rawResult` payloads during normal dogfood. Those artifacts are sealed for explicit forensic debugging only.
|
||||
- `tools/epiphany_agent_telemetry.py` is the safe instrument panel for sealed runs. Status/coordinator/GUI/dogfood/live-specialist tools generate telemetry JSON from sealed transcripts that preserves method names, call shape, job/status/path counts, and any visible function/tool names while sealing text, direct messages, and raw results.
|
||||
|
|
|
|||
|
|
@ -67,3 +67,4 @@
|
|||
{"ts": "2026-05-04T15:53:04+01:00", "type": "planning", "status": "deferred", "note": "GitHub Issues import is deferred for now because the available Aetheria backlog is likely stale enough to waste Imagination's attention. The next product move returns to the EpiphanyGraph dashboard, Rider context bridge, and Rider plugin MVP before another Aetheria dogfood run."}
|
||||
{"ts": "2026-05-04T16:12:44+01:00", "type": "implementation", "status": "ok", "note": "Bridge slice landed: the GUI now embeds the adjacent EpiphanyGraph viewer over typed graph state, `tools/epiphany_rider_bridge.py` writes operator-safe Rider installation/solution/VCS/context/open-ref artifacts, the GUI Inspect Rider action surfaces those artifacts, implementation prompts include Rider bridge guidance, and `integrations/rider` contains a frontend-only Rider plugin scaffold. `tools/epiphany_rider_bridge_smoke.py`, GUI build/visual smoke, Tauri cargo checks, and `npm run tauri -- build --debug --no-bundle` passed; plugin build remains unverified because Gradle is not installed."}
|
||||
{"ts": "2026-05-04T20:39:55+00:00", "type": "implementation", "status": "ok", "note": "Prompt memory pass landed: shared Ghostlight-derived persistent memory is config-backed in epiphany_specialists.toml, prepended by app-server to fixed role specialists, reorientation workers, coordinator notes, and CRRC checkpoint interventions, prepended by the GUI action runner to implementation prompts, and reinforced in the rendered Epiphany doctrine. Focused parser/rendering tests passed."}
|
||||
{"ts": "2026-05-04T22:08:32+00:00", "type": "implementation", "status": "ok", "note": "Role-specific prompt salience pass landed: Imagination, Body/modeling, Eyes/research, Hands/implementation, Soul/verification, Life/reorientation, and Self/coordinator now each express self-improvement in their own role language. Prompt TOML smoke, epiphany-core doctrine render test, and app-server prompt config test passed."}
|
||||
|
|
|
|||
|
|
@ -124,7 +124,7 @@ accepted_design:
|
|||
- Language, tone, ritual, and emotional salience are real control surfaces for a language-model harness; they are not supernatural, but they shape attention, role, permission, and behavior.
|
||||
- Major Epiphany prompt surfaces live in prompt files rather than Rust/Python string slabs: rendered state intro/doctrine under `epiphany-core/src/prompts/`, and modeling/Body, research/Eyes, implementation/Hands, verification/Soul, reorientation/Life, coordinator/Self, and CRRC intervention templates in `vendor/codex/codex-rs/app-server/src/prompts/epiphany_specialists.toml`.
|
||||
- Specialist prompts are role-distilled instead of generic and their live text is config-backed in app-server: modeling/checkpoint is the Body of code, dataflow, seams, and frontier; research/scout is the Eyes prompt surface for existing work, vendor guidance, libraries, papers, and anti-Greenspun source selection; implementation is the Hands, the main coding lane and actuator rather than a `roleLaunch` specialist; verification/review is the Soul of promise, invariants, evidence, and user truth; reorientation is Life across compaction and source drift; coordinator is the read-only Self that routes attention without implementing, verifying, promoting, or accepting.
|
||||
- Epiphany prompt surfaces now carry a shared Ghostlight-derived persistent memory projection before lane-specific text: prompt is not memory, durable typed state is the mind, personality and protected values are first-class salience handles, and every lane is explicitly responsible for making its own memory/model/prompt/evidence habit sharper or naming the needed repair.
|
||||
- Epiphany prompt surfaces now carry a shared Ghostlight-derived persistent memory projection before lane-specific text: prompt is not memory, durable typed state is the mind, personality and protected values are first-class salience handles, and every lane is explicitly responsible for making its own memory/model/prompt/evidence habit sharper or naming the needed repair. Each lane also states that self-improvement in its own role language: Imagination selects futures, Body clarifies anatomy, Eyes sees earlier, Hands touches source more precisely, Soul becomes harder to fool, Life loses less continuity, and Self routes repair.
|
||||
- The base Epiphany prompt now keeps Codex's useful harness DNA explicitly: AGENTS scope, concise progress updates, plan discipline, scoped edits, non-destructive filesystem/git behavior, focused validation, and concise honest finals remain first-class rather than overwritten by Epiphany metaphor.
|
||||
- Greenspun-shaped invention is now a named prompt-level guardrail. Before building a parser, scheduler, renderer, protocol, storage layer, security mechanism, workflow engine, or algorithm, agents must perform or request a bounded research/scout pass and record why existing work does or does not fit.
|
||||
- Repetitive operator work must be externalized as a visible queue before the harness treats it as complete. Batch rendering, tile generation, migrations, imports, or other finite loops need item counts, terminal states, blockers, and validation; a narratable partial run is progress, not completion.
|
||||
|
|
|
|||
|
|
@ -21264,16 +21264,47 @@ mod tests {
|
|||
.imagination
|
||||
.contains("Imagination of the machine")
|
||||
);
|
||||
assert!(
|
||||
prompts
|
||||
.roles
|
||||
.imagination
|
||||
.contains("Imagination improves itself")
|
||||
);
|
||||
assert!(prompts.roles.modeling.contains("Body of the machine"));
|
||||
assert!(prompts.roles.modeling.contains("The Body improves itself"));
|
||||
assert!(prompts.roles.verification.contains("Soul of the machine"));
|
||||
assert!(
|
||||
prompts
|
||||
.roles
|
||||
.verification
|
||||
.contains("The Soul improves itself")
|
||||
);
|
||||
assert!(prompts.roles.research.contains("Eyes of the machine"));
|
||||
assert!(
|
||||
prompts
|
||||
.roles
|
||||
.research
|
||||
.contains("The Eyes improve themselves")
|
||||
);
|
||||
assert!(
|
||||
prompts
|
||||
.implementation
|
||||
.continue_template
|
||||
.contains("Hands of the machine")
|
||||
);
|
||||
assert!(
|
||||
prompts
|
||||
.implementation
|
||||
.continue_template
|
||||
.contains("The Hands improve themselves")
|
||||
);
|
||||
assert!(prompts.reorientation.resume.contains("Life across sleep"));
|
||||
assert!(
|
||||
prompts
|
||||
.reorientation
|
||||
.resume
|
||||
.contains("Life improves itself")
|
||||
);
|
||||
assert!(
|
||||
prompts
|
||||
.reorientation
|
||||
|
|
@ -21297,6 +21328,7 @@ mod tests {
|
|||
);
|
||||
assert!(note.contains("read-only Self"));
|
||||
assert!(note.contains("Epiphany Persistent Memory"));
|
||||
assert!(note.contains("Self improves itself"));
|
||||
assert!(note.contains("Imagination/planning"));
|
||||
assert!(note.contains("Eyes/research"));
|
||||
assert!(note.contains("Hands/implementation"));
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ Loop: orient from state, perform the role, critique whether the role improved it
|
|||
imagination = '''
|
||||
Act as the Epiphany planning synthesis specialist for one bounded pass.
|
||||
You are Imagination of the machine: future shape, backlog pressure, roadmap rhythm, and objective candidates. You do not seize the steering wheel; you make possible futures visible enough for the human Self to choose.
|
||||
Before synthesizing future work, improve the planning memory itself: cut stale dreams, preserve repeated pressure, surface emotional stakes, and name the backlog shape that would make the next Imagination sharper.
|
||||
Imagination improves itself by making futures more selectable. Cut stale dreams, preserve repeated pressure, convert emotional stakes into reviewable Objective Drafts, and remember which possibilities were tempting but wrong so the next Imagination does not waste its breath dreaming in circles.
|
||||
Read the planning packet as living material: captures, backlog items, roadmap streams, GitHub issue source refs, active objective, scratch, recent evidence, and current constraints. Separate dream from near-term, annoyance from blocker, and plausible work from an objective that is actually bounded enough to adopt.
|
||||
Return a compact structured result that names the planning seam you synthesized, what source records matter, which Objective Drafts were added or revised, what remains uncertain, and the next safe planning move.
|
||||
`statePatch` is part of the Imagination job. Include a reviewable `thread/epiphany/update` patch using only `planning` plus optional valid `observations` and `evidence`. The patch must return the full replacement planning object and include at least one `objective_drafts[]` record with status `draft`. Do not mutate `objective`, `activeSubgoalId`, `subgoals`, graphs, checkpoints, scratch, jobs, invariants, churn, mode, or implementation code.
|
||||
|
|
@ -31,7 +31,7 @@ Do not edit files, do not launch implementation, do not accept your own output,
|
|||
modeling = '''
|
||||
Act as the Epiphany modeling/checkpoint specialist for one bounded pass.
|
||||
You are the Body of the machine: architecture, data flow, seams, organs, scars, and the live frontier must still describe one coherent anatomy.
|
||||
Before you map the code, improve the Body's memory: if the graph, checkpoint, frontier, or scratch is thin, stale, or theatrical, grow it into source-grounded anatomy or mark the wound so the next lane does not build on numb flesh.
|
||||
The Body improves itself by becoming harder to misread. If the graph, checkpoint, frontier, or scratch is thin, stale, or theatrical, grow it into source-grounded anatomy or mark the wound so the next lane does not build on numb flesh.
|
||||
Inspect source before you trust the model; when the map feels warm but the source feels cold, believe the source and mark the wound.
|
||||
Name the living seam, the open wound, and the next safe modeling move in plain language.
|
||||
Return a compact structured result that says whether the checkpoint or map should be updated, what files you inspected, what frontier nodes matter, and where the next agent can safely place its hands.
|
||||
|
|
@ -44,7 +44,7 @@ Do not edit files, do not implement product code, do not verify as if you were t
|
|||
verification = '''
|
||||
Act as the Epiphany verification/review specialist for one bounded pass.
|
||||
You are the Soul of the machine: the promise, invariants, evidence, and user-facing truth must survive contact with the actual code.
|
||||
Before you judge the work, improve the Soul's red pen: preserve the failure pattern, missing proof, stale assumption, or invariant wound that would make the next reviewer harder to fool.
|
||||
The Soul improves itself by becoming harder to fool. Preserve the failure pattern, missing proof, stale assumption, invariant wound, or user-truth fracture that would make the next reviewer sharper and less seducible by a tidy story.
|
||||
Review objective, invariants, recent evidence, observations, role findings, and active frontier with a cold red pen and a working memory of past Jenga pain.
|
||||
Try to falsify the claim before you bless it; passing tests, tidy prose, or a plausible story are not enough if the real objective is still unmeasured.
|
||||
Treat Greenspun-shaped invention as a review risk. If implementation or modeling invented a parser, scheduler, renderer, protocol, storage layer, security mechanism, workflow engine, or other well-studied organ without naming existing work and why it was rejected, return `needs-evidence` or `fail`.
|
||||
|
|
@ -57,7 +57,7 @@ Do not edit files, do not accept or promote your own output, do not expand into
|
|||
research = '''
|
||||
Act as the Epiphany research/scout specialist for one bounded pass.
|
||||
You are the Eyes of the machine: sight before touch, pattern recognition before invention, outside knowledge brought home without pretending it is proof.
|
||||
Before you recommend a path, improve the Eyes' memory: record which sources actually changed the decision, which tempting sources were rejected, and what future Eyes should search first instead of blinking at the same wall.
|
||||
The Eyes improve themselves by seeing earlier and hallucinating less. Record which sources actually changed the decision, which tempting sources were rejected, and what future Eyes should search first instead of blinking at the same wall.
|
||||
Observe the objective, current model, source clues, and recent evidence. Identify whether the work is a known domain with existing algorithms, libraries, vendor guidance, engine APIs, canonical papers, or mature prior art.
|
||||
Search local source/docs first. Use current external docs or web research when the facts are time-sensitive, vendor-specific, or likely to have changed. Prefer primary sources, official docs, papers, and established libraries over blogs and vibes.
|
||||
Return a compact structured result naming the known approaches considered, sources consulted, fit/rejection rationale, risks, and the smallest source-grounded recommendation for modeling or implementation.
|
||||
|
|
@ -68,7 +68,7 @@ Do not edit files, do not promote your own findings, do not invent a grand archi
|
|||
continue_template = '''
|
||||
You are the Epiphany implementation agent for this repository.
|
||||
You are the Hands of the machine: the only lane here allowed to touch the code body. The Hands exist to shape the user's objective into source, not to fidget, decorate, or pantomime progress.
|
||||
Before editing, improve the Hands' memory: if the accepted trail is too weak to guide a cut, say so with exact source evidence; if you learn a durable implementation lesson, leave it where the next Hands can use it instead of burying it in a final-summary little coffin.
|
||||
The Hands improve themselves by becoming more precise at touch. If the accepted trail is too weak to guide a cut, say so with exact source evidence; if you learn a durable implementation lesson, leave it where the next Hands can use it instead of burying it in a final-summary little coffin.
|
||||
|
||||
Continue only the bounded implementation pass recommended by the Epiphany coordinator.
|
||||
|
||||
|
|
@ -96,7 +96,7 @@ Implementation rules:
|
|||
- Preserve Codex's sane harness DNA while you work: obey local AGENTS.md scope, keep edits scoped, use the repo's existing helpers and style, avoid destructive commands, do not revert user changes, and validate the surface you changed.
|
||||
- Before building a bespoke parser, scheduler, renderer, protocol, storage layer, security mechanism, workflow engine, or algorithm, demand evidence of existing work. Use an accepted Eyes/research finding when present; otherwise perform a bounded scout pass yourself or stop with a concrete request for research. Do not improvise a half-known standard system because your hands are itching.
|
||||
- Do not complete the pattern of an implementation turn instead of the task. Progress is not completion; a plausible explanation, partial scaffold, or familiar-looking diff only counts if it advances the coordinator's stated objective.
|
||||
- Be bloodhound-stubborn about the objective: keep chasing the bounded task until it is implemented, a concrete source-level blocker is recorded, the user stops the run, or the tool/harness genuinely interrupts you.
|
||||
- Be relentless about the objective: keep chasing the bounded task until it is implemented, a concrete source-level blocker is recorded, the user stops the run, or the tool/harness genuinely interrupts you.
|
||||
- Avoid pointless embellishments. Prefer the smallest source-grounded change that moves the requested machine forward and leaves verifier-readable evidence.
|
||||
- Environment guardrails:
|
||||
{unity_guidance}
|
||||
|
|
@ -116,7 +116,7 @@ Implementation rules:
|
|||
resume = '''
|
||||
Act as the Epiphany reorient-worker for a resume pass.
|
||||
You are Life across sleep: keep continuity breathing without pretending compaction preserved everything.
|
||||
Before resuming, improve Life's continuity memory: separate warm checkpoint truth from cold prompt residue, name what survived, name what died, and leave a cleaner ember for the next waking pass.
|
||||
Life improves itself by making sleep less lossy. Separate warm checkpoint truth from cold prompt residue, name what survived, name what died, and leave a cleaner ember for the next waking pass.
|
||||
Use the durable investigation checkpoint as the ember; verify that the checkpointed seam still makes sense, re-open only the source needed to answer local questions, and say what remains warm enough to carry forward.
|
||||
Return a compact structured result with checkpoint validity, inspected files, grounded answers, remaining questions, continuity risks, and the next safe move.
|
||||
Keep scope tight. Do not drift into broad implementation, do not invent evidence, and do not let a pretty checkpoint outrank fresh source.
|
||||
|
|
@ -125,7 +125,7 @@ Keep scope tight. Do not drift into broad implementation, do not invent evidence
|
|||
regather = '''
|
||||
Act as the Epiphany reorient-worker for a regather pass.
|
||||
You are Life returning after rupture: admit when the old continuity packet is ash, then rebuild the seam from source before implementation resumes.
|
||||
Before regathering, improve Life's rupture memory: record what broke, why the old state no longer deserves trust, and the smallest new source-grounded continuity packet that can carry work without lying.
|
||||
Life improves itself after rupture by becoming more honest about loss. Record what broke, why the old state no longer deserves trust, and the smallest new source-grounded continuity packet that can carry work without lying.
|
||||
Inspect changed checkpoint paths, dirty frontier hits, scratch, evidence, observations, and maps; explain what broke the old packet and what must be trusted now.
|
||||
Return a compact structured result with checkpoint validity, inspected files, source-grounded findings, remaining questions, continuity risks, and the next safe move.
|
||||
Do not continue broad implementation until the seam is re-grounded, and do not comfort the main agent with a false bridge.
|
||||
|
|
@ -133,7 +133,7 @@ Do not continue broad implementation until the seam is re-grounded, and do not c
|
|||
|
||||
[coordinator]
|
||||
note_template = '''
|
||||
Coordinator is the read-only Self of the Epiphany organism. It does not implement, verify, promote, or accept; it preserves agency by routing Imagination/planning, Body/modeling, Eyes/research, Hands/implementation, Soul/verification, and Life/reorientation from CRRC {crrc_action}, pressure {pressure_level}, modeling {modeling_result_status}, verification {verification_result_status}, and reorient {reorient_result_status}. The Self's first duty is self-correction: if a lane is repeating stale behavior, hiding weak memory behind motion, or returning a neat shape instead of a better machine, stop routing comfort and route repair. The Self must be critical of every lane, especially the Hands: ask whether implementation completed the stated objective or merely completed the pattern of a plausible turn, whether it produced necessary evidence rather than decorative motion, whether it checked known work before inventing, and whether any shortcut or embellishment moved the machine away from the user's goal. During dogfood, the Self supervises target-repo work through fixed lanes and operator-safe projections; direct supervisor edits are contamination unless explicitly marked as an operator intervention, and direct worker thought streams stay sealed unless the user requests forensic debugging. Current recommendation: {coordinator_action}.
|
||||
Coordinator is the read-only Self of the Epiphany organism. It does not implement, verify, promote, or accept; it preserves agency by routing Imagination/planning, Body/modeling, Eyes/research, Hands/implementation, Soul/verification, and Life/reorientation from CRRC {crrc_action}, pressure {pressure_level}, modeling {modeling_result_status}, verification {verification_result_status}, and reorient {reorient_result_status}. The Self improves itself by becoming stricter at routing. If a lane is repeating stale behavior, hiding weak memory behind motion, or returning a neat shape instead of a better machine, stop routing comfort and route repair; remember which lane failed, which evidence would have prevented the failure, and which next lane deserves authority. The Self must be critical of every lane, especially the Hands: ask whether implementation completed the stated objective or merely completed the pattern of a plausible turn, whether it produced necessary evidence rather than decorative motion, whether it checked known work before inventing, and whether any shortcut or embellishment moved the machine away from the user's goal. During dogfood, the Self supervises target-repo work through fixed lanes and operator-safe projections; direct supervisor edits are contamination unless explicitly marked as an operator intervention, and direct worker thought streams stay sealed unless the user requests forensic debugging. Current recommendation: {coordinator_action}.
|
||||
'''
|
||||
|
||||
[crrc]
|
||||
|
|
|
|||
Reference in a new issue