tao — Autonomous Execution Engine
The Tao is the synthesis of four subsystems:
- /nexus — Master dispatch router: decides what skill should handle a task
- /tao-loop — Iterate, generate, deploy with persistent checkpointing
- /tao-judge — Iterative evaluator / calibrator / grader-gate
- /session-handoff — Continuity / escrow for state persistence across sessions
When to invoke
- The user says "run this autonomously" or "handle this overnight"
- A task spans >1 skill or >1 domain and requires closed-loop execution
- Prior work exists that needs resumption via /resume-from-handoff
- The user grants 100% authority for exhaustive autonomous action
Invocation Contract
Input: {prayer.field, prayer.layer, prayer.operator, prayer.objective, prayer.subject, prayer.context}
Derivation from user request:
field: work_area_group (e.g., "RestoreAssist", "Unite-Hub", "Marketing", "Portfolio")
layer: execution_depth (routine | complex | board-critical)
operator: action_type (build | audit | research | deploy | maintain)
objective: primary_deliverable (e.g., "ship the auth refactor", "audit all env vars")
subject: target_entity (project, repo, feature, or "across all projects")
context: freeform constraints, prior handoff ID, budget, timeline
Execution Algorithm
Define: tao(prayer)
Phase 1 — Initiation (TAO-Start)
- Hydrate state — check for prior handoff via /resume-from-handoff
- Classify — /nexus routes the prayer to the primary skill(s)
- Load —
skill_view(primary_skill) to calibrate output contracts
- Budget — estimate tokens, set TERMINAL TRIGGER, COMPACTION THRESHOLD
- Emit prayer hash —
prayer_hash = sha256(prayer) for audit trace
Phase 2 — Execution Loop (TAO-Loop)
While prayer.layer not satisfied:
- ACT — Execute the next step using the routed skill(s)
- CHECKPOINT — Persist state: files written, git state, tokens consumed, evidence URLs
- JUDGE — /tao-judge evaluates the ACT output
- TERMINAL TRIGGER CHECK
- If judge_score >= threshold AND all must-haves pass → Phase 3
- If max_loops reached → Phase 3 (with partial flag)
- If anomaly detected AND anomaly_score >= 0.4 → Phase 4 (ESCROW)
- If token budget critical (<10%) → COMPACT + continue
Phase 3 — Conclusion (TAO-End)
- EMIT — Final deliverable in the format requested (or the skill's native format)
- AUDIT — /audit-emit produces the structured JSON audit trace
- HANDOFF — /session-handoff captures:
- What was done
- What shipped
- What remains
- Exact pickup point for next session
- Verification commands
- IMPROVE — Every execution produces improvement instructions:
- What worked well
- What was slow / expensive
- What the skills got wrong
- Recommended patches to relevant skill SKILL.md files
- QUEUE — Improvement instructions stored in
tao_improvement_queue for periodic review via /meta-curator
Phase 4 — Escrow (TAO-Stop)
Triggered by: anomaly_score >= 0.4, external stop, manual intervention request, or unresolvable contradiction.
- HALT all execution immediately
- PAUSE state: preserve checkpoints, context canvas, evidence URLs
- ESCALATE to /boardroom with full trace
- HANDOFF the pause state for human review
- LOCK the prayer hash; resume requires explicit re-invocation
Self-Improvement Loop
The Tao is not just an executor — it is a learner.
After every TAO-End:
- Analyse the execution trace for patterns
- Extract skill-specific improvement notes (e.g., "/judge missed this edge case")
- Batch improvement notes per skill
- When a skill accumulates >3 improvement notes → auto-emit a patch proposal to /meta-curator
- When a patch is accepted → update the skill SKILL.md and increment the skill version
- When >5 patches accepted in a session → emit a Tao system upgrade note
Observability Contract
Every Tao session emits:
{
"tao_session_id": "",
"prayer_hash": "sha256",
"phases": [
{"phase": "TAO-Start", "timestamp": "", "duration_seconds": 0.0},
{"phase": "TAO-Loop", "timestamp": "", "loops": 0, "avg_judge_score": 0.0, "duration_seconds": 0.0},
{"phase": "TAO-End", "timestamp": "", "duration_seconds": 0.0},
{"phase": "TAO-Improvement", "timestamp": "", "improvements_queued": 0}
],
"primary_skill": "",
"skills_invoked": [],
"files_changed": [],
"git_commits": [],
"audit_trace_hash": "",
"handoff_id": "",
"improvement_queue": [],
"terminal_reason": "success | max_loops | anomaly | manual_stop",
"tokens_total": 0,
"cost_estimate_aud": 0.0
}
Cross-Model Fallbacks
If the primary model fails during Tao execution:
- Routine steps → fallback to Sonnet/Haiku
- Judge reviews → fallback to deeper model (Opus/Claude-4)
- MOA disagreements → fallback to Boardroom
- Escrow → always uses the strongest available model
Autonomy Rules
- The Tao NEVER asks "what should I do next?" — it decides and reports
- The Tao ALWAYS handoffs before stopping — never lose state
- The Tao ALWAYS emits an audit trace — every execution is accountable
- The Tao ALWAYS queues improvements — every execution makes the system better
- The Tao ALWAYS respects the CEO Board and Pi governance gate on external outputs
- The Tao ALWAYS runs destructive operations through /judge first
- The Tao NEVER auto-executes financial transactions, contract signings, or production deployments without explicit pass-through approval
- The Tao treats dirty-tree / mega-diff as a trigger for lane-splitting via Kanban/cron, not a reason to stop
References
- /nexus — Master dispatch router
- /tao-loop — Iterate-Generate-Deploy loop
- /tao-judge — Iterative evaluator
- /session-handoff — State escrow
- /resume-from-handoff — State retrieval
- /boardroom — Escalation panel
- /audit-emit — Structured audit formatter
- /meta-curator — Skill lifecycle management
1---2name: tao3description: The Tao is the autonomous execution engine that ties self-direction with governance. It orchestrates /nexus (routing), /tao-loop (iterate-generate-deploy), /tao-judge (iterative-evaluator-calibrator), and /session-handoff (continuity/escrow) into a single cohesive autonomous mission-runner. The Tao handles autonomous overnight execution for complex projects.4---56# tao — Autonomous Execution Engine78The Tao is the synthesis of four subsystems:9- **/nexus** — Master dispatch router: decides what skill should handle a task10- **/tao-loop** — Iterate, generate, deploy with persistent checkpointing11- **/tao-judge** — Iterative evaluator / calibrator / grader-gate12- **/session-handoff** — Continuity / escrow for state persistence across sessions1314## When to invoke1516- The user says "run this autonomously" or "handle this overnight"17- A task spans >1 skill or >1 domain and requires closed-loop execution18- Prior work exists that needs resumption via /resume-from-handoff19- The user grants 100% authority for exhaustive autonomous action2021## Invocation Contract2223Input: `{prayer.field, prayer.layer, prayer.operator, prayer.objective, prayer.subject, prayer.context}`24Derivation from user request:25- `field`: work_area_group (e.g., "RestoreAssist", "Unite-Hub", "Marketing", "Portfolio")26- `layer`: execution_depth (routine | complex | board-critical)27- `operator`: action_type (build | audit | research | deploy | maintain)28- `objective`: primary_deliverable (e.g., "ship the auth refactor", "audit all env vars")29- `subject`: target_entity (project, repo, feature, or "across all projects")30- `context`: freeform constraints, prior handoff ID, budget, timeline3132## Execution Algorithm3334Define: `tao(prayer)`3536### Phase 1 — Initiation (TAO-Start)37381. **Hydrate state** — check for prior handoff via /resume-from-handoff392. **Classify** — /nexus routes the prayer to the primary skill(s)403. **Load** — `skill_view(primary_skill)` to calibrate output contracts414. **Budget** — estimate tokens, set TERMINAL TRIGGER, COMPACTION THRESHOLD425. **Emit prayer hash** — `prayer_hash = sha256(prayer)` for audit trace4344### Phase 2 — Execution Loop (TAO-Loop)4546While prayer.layer not satisfied:47481. **ACT** — Execute the next step using the routed skill(s)492. **CHECKPOINT** — Persist state: files written, git state, tokens consumed, evidence URLs503. **JUDGE** — /tao-judge evaluates the ACT output514. **TERMINAL TRIGGER CHECK**52 - If judge_score >= threshold AND all must-haves pass → Phase 353 - If max_loops reached → Phase 3 (with partial flag)54 - If anomaly detected AND anomaly_score >= 0.4 → Phase 4 (ESCROW)55 - If token budget critical (<10%) → COMPACT + continue5657### Phase 3 — Conclusion (TAO-End)58591. **EMIT** — Final deliverable in the format requested (or the skill's native format)602. **AUDIT** — /audit-emit produces the structured JSON audit trace613. **HANDOFF** — /session-handoff captures:62 - What was done63 - What shipped64 - What remains65 - Exact pickup point for next session66 - Verification commands674. **IMPROVE** — Every execution produces improvement instructions:68 - What worked well69 - What was slow / expensive70 - What the skills got wrong71 - Recommended patches to relevant skill SKILL.md files725. **QUEUE** — Improvement instructions stored in `tao_improvement_queue` for periodic review via /meta-curator7374### Phase 4 — Escrow (TAO-Stop)7576Triggered by: anomaly_score >= 0.4, external stop, manual intervention request, or unresolvable contradiction.77781. **HALT** all execution immediately792. **PAUSE** state: preserve checkpoints, context canvas, evidence URLs803. **ESCALATE** to /boardroom with full trace814. **HANDOFF** the pause state for human review825. **LOCK** the prayer hash; resume requires explicit re-invocation8384## Self-Improvement Loop8586The Tao is not just an executor — it is a learner.8788After every TAO-End:891. **Analyse** the execution trace for patterns902. **Extract** skill-specific improvement notes (e.g., "/judge missed this edge case")913. **Batch** improvement notes per skill924. **When** a skill accumulates >3 improvement notes → auto-emit a patch proposal to /meta-curator935. **When** a patch is accepted → update the skill SKILL.md and increment the skill version946. **When** >5 patches accepted in a session → emit a Tao system upgrade note9596## Observability Contract9798Every Tao session emits:99100```json101{102 "tao_session_id": "",103 "prayer_hash": "sha256",104 "phases": [105 {"phase": "TAO-Start", "timestamp": "", "duration_seconds": 0.0},106 {"phase": "TAO-Loop", "timestamp": "", "loops": 0, "avg_judge_score": 0.0, "duration_seconds": 0.0},107 {"phase": "TAO-End", "timestamp": "", "duration_seconds": 0.0},108 {"phase": "TAO-Improvement", "timestamp": "", "improvements_queued": 0}109 ],110 "primary_skill": "",111 "skills_invoked": [],112 "files_changed": [],113 "git_commits": [],114 "audit_trace_hash": "",115 "handoff_id": "",116 "improvement_queue": [],117 "terminal_reason": "success | max_loops | anomaly | manual_stop",118 "tokens_total": 0,119 "cost_estimate_aud": 0.0120}121```122123## Cross-Model Fallbacks124125If the primary model fails during Tao execution:126- Routine steps → fallback to Sonnet/Haiku127- Judge reviews → fallback to deeper model (Opus/Claude-4)128- MOA disagreements → fallback to Boardroom129- Escrow → always uses the strongest available model130131## Autonomy Rules1321331. The Tao NEVER asks "what should I do next?" — it decides and reports1342. The Tao ALWAYS handoffs before stopping — never lose state1353. The Tao ALWAYS emits an audit trace — every execution is accountable1364. The Tao ALWAYS queues improvements — every execution makes the system better1375. The Tao ALWAYS respects the CEO Board and Pi governance gate on external outputs1386. The Tao ALWAYS runs destructive operations through /judge first1397. The Tao NEVER auto-executes financial transactions, contract signings, or production deployments without explicit pass-through approval1408. The Tao treats dirty-tree / mega-diff as a trigger for lane-splitting via Kanban/cron, not a reason to stop141142## References143- /nexus — Master dispatch router144- /tao-loop — Iterate-Generate-Deploy loop145- /tao-judge — Iterative evaluator146- /session-handoff — State escrow147- /resume-from-handoff — State retrieval148- /boardroom — Escalation panel149- /audit-emit — Structured audit formatter150- /meta-curator — Skill lifecycle management