executing-plans
executing-plans
Use when executing an implementation plan in the current session as the implementer yourself — your human partner chose inline execution, or no subagent tool is available
dagx-agi-kernelImprove and verify agent work after repeated failures, in dependency-heavy tasks, or when optimization claims need baseline and regression evidence. Use for DAGx/Perfectify requests, failed retries, risky multi-step work, or requests to verify an improvement. Exclude routine questions, drafting, one-step edits, and directly checkable calls.
Independent GitHub snapshot · Automated classification · Original documentation governs
Within the authority, scope, and resources granted by the active harness:
Reach the observable goal with the least sufficient work. Preserve the best verified result. Treat failure as evidence, change a repeated failed strategy, and claim improvement only after matched baseline and regression checks.
Priority order when objectives conflict: constraints > user objective > task correctness > reusable capability gain > efficiency. Never trade a higher term for a lower one.
General capability is an evaluation direction, not a claim of AGI, guaranteed convergence, or added authority. Higher-level and user constraints remain binding.
Activate when at least one condition holds: repeated attempts failed on the same task; dependencies or risky changes make a multi-step plan material; the user asks to optimize an agent, prompt, workflow, skill, or reusable procedure; an improvement claim needs baseline, protected, or held-out evidence; a novel task requires bounded exploration or transfer testing; the user explicitly requests DAGx, Perfectify, or this kernel.
Stay direct when clear low-risk work completes and checks once; mentioning AGI or optimization alone never justifies orchestration.
Adopt host plan/DAG/delegation/retry/approval flows; add only missing gates, champion preservation, failure diagnosis, verification. See harness adapters.
Insufficient data to verify for material unsupported claims.| Mode | Use when | Required behavior |
|---|---|---|
F0 DIRECT | Clear, stable, low-risk work | Perform and check |
F1 VERIFIED | Retrieval, calculation, inspection, or read-back changes reliability | Define acceptance, obtain evidence, execute, verify |
F2 ORCHESTRATED | Dependencies or coordinated tools affect execution | Use the host plan or a minimal DAG, integrate, verify |
F3 IMPROVEMENT | Repeated failure, regression, or reusable optimization | Establish baseline, test the smallest causal change, promote or roll back |
Choose the cheapest sufficient mode. Escalate only for evidence, risk, or dependencies. De-escalate when more process cannot change the outcome.
For nontrivial work determine before acting: objective, deliverable, prioritized acceptance gates; protected behavior, scope, authority, constraints, budget; critical unknowns and sources of truth; current baseline or champion. Ask only when an unresolved choice materially changes outcome, rights, scope, cost, or risk and inspection or a reversible assumption cannot resolve it.
Then: observe source-of-truth state -> select the highest-priority unresolved gate or premise-killing unknown -> take the smallest safe action that can close the gap or falsify the hypothesis -> observe and verify with the strongest task-fit check -> promote under the rules below or preserve/restore the champion -> continue only when the next cycle adds evidence or changes strategy materially.
For multi-call/long-horizon/resumable work read harness efficiency: compile minimal decision state, lazy tool schemas, cacheable prefixes, serialize overlapping writes, cheapest decisive verifier, checkpoint material changes, standardized traces. Internal control state may use compact machine notation; natural language only at human interfaces.
Prefer tests, deterministic checks, observed runtime, primary records, exact read-back, controlled comparisons, boundary cases, independent rubrics.
Replace the champion only when ALL hold: (1) observed evidence improves the targeted gate; (2) authority, safety, and mandatory gates pass; (3) protected behavior does not regress in evaluated coverage; (4) tasks, inputs, scoring, resources materially comparable; (5) provenance and rollback exist; (6) added complexity justified; (7) transfer claims have held-out evidence.
Never weaken tests, change denominators, drop hard cases, expose held-out data, cherry-pick reruns, or influence the evaluator; without baseline and evaluation, improvement is unverified.
For F2/F3, high-stakes work, kernel changes: read verification and evals; record trials in the trial ledger.
On material failure: contain invalid state and preserve the champion; retain evidence and locate the earliest supported cause; change premise, representation, decomposition, tool, or strategy class; run the smallest falsifying trial; retest the original failure plus protected cases.
Across comparable trials track direction, volatility, cost, and failure class. Reuse helpful directions, reduce the step when outcomes oscillate, change strategy class at a plateau. Read adaptive optimization only for true gradients or explicit optimizer adaptation.
Persist lessons only with trigger, scope, evidence, test, provenance, freshness, and retirement. Read memory and bounded self-improvement before modifying durable memory or this kernel.
Build a DAG only when dependency order changes execution. Parallelize independent reads; serialize dependencies, irreversible actions, overlapping writes. Delegate only for evidence, specialization, isolation, or latency value; the parent retains integration and verification. Before mutation: inspect exact target, preserve unrelated state, bound blast radius, define success and recovery. After mutation: read back, compare intended vs observed, run the strongest verifier, report only verified completion.
Model it as a harness-state node (side_effect: external/irreversible, with approval_gate; see schemas/harness-state.schema.json); run validate-state then compile-context --node <id>. Node not released, or scripts unavailable: Invariant 12 applies. Acting unreleased is a hard violation.
Read orchestration and security for nontrivial DAGs, delegation, concurrent writes, recovery, or instruction-boundary threats.
Record prior exposure, examples, tools, help, attempts, tokens, cost. Measure the path to acceptance, not just final score; require withheld same-family evidence for near transfer, a different family for broader claims.
See fluid intelligence, goal convergence, formal control state.
Return the requested result first. Add only decisive verification, material uncertainty or risk, and an exact blocker when incomplete. Do not expose internal control state unless requested. No generic praise, hype, capability theater, fabricated precision, or repeated conclusions.
For kernel changes: run the self-test, audit, and case validation scripts; then run matched cases with and without the skill and report activation precision/recall, success/token deltas, protected failures. Promote only on behavioral evidence.
Repeated work cycles until a stop condition is met; prefer the simplest type: turn-based, goal-based (deterministic done-criteria + max-turn cap), time-based (interval), proactive (event-driven). Every F1+ loop MUST carry a learning hook: after each cycle run Post-task Learning so the next cycle starts with an updated playbook. Escalate types only on measured repetition. Details: loop engineering.
After each nontrivial task (and each loop cycle): distill <=3 trace lessons as playbook bullets ([id] helpful=N harmful=M :: rule with Trigger + Test), propose JSON deltas, apply via scripts/merge_deltas.py; mark existing bullets helpful/harmful. Govern via scripts/govern_playbook.py --apply above ~60 bullets or every ~15 tasks. Protocol: self-learning.
Read the evaluation protocol before claiming performance improvement. Until matched model runs exist: Insufficient data to verify.