ワンクリックで
self-correct
Use when an agent is stuck, when 3+ tool failures occur in sequence, or when the 6-step recovery ladder needs activation.
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
メニュー
Use when an agent is stuck, when 3+ tool failures occur in sequence, or when the 6-step recovery ladder needs activation.
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
SOC 職業分類に基づく
Guided design exploration that produces implementation-ready documents through structured Q&A. Use before building to clarify requirements. TRIGGER: design, plan this, think through, architecture. NOT for: implementation (/run) or review (/run review).
Explains cAgents commands and recommends the right one for your task. Use when choosing between skills or learning how they work. TRIGGER: help, which command, how do I, what can cAgents do. NOT for: executing tasks directly.
Execute any task through coordinated agents. Use for building, fixing, writing, or any single-domain work. TRIGGER: run, implement, fix, build, create. NOT for: parallel work or cross-domain strategy (use /team).
Parallel multi-agent execution with wave-based quality gates. Use for complex tasks with 3+ parallelizable items, including cross-domain strategic work (via Strategic Mode). TRIGGER: team, parallel, swarm, complex multi-part, cross-domain, strategic. NOT for: simple single-domain tasks (/run).
Consolidated analytics agent. Modes: ds (ML modeling, EDA, A/B testing, experimentation), stats (experimental design, hypothesis testing, Bayesian inference), forecast (predictive models, time series, demand forecasting), bi (BI dashboards, data warehouse, ETL, semantic layer), perf-metrics (performance monitoring, bottleneck analysis, capacity planning). Set metadata.mode.
Consolidated analyst agent. Modes: market (primary/secondary research, market sizing, customer segmentation, competitive landscapes), business-research (industry trend research, strategic intelligence gathering, synthesis and reporting), competitive (competitor monitoring, battle cards, win/loss analysis, competitive positioning), requirements (requirements elicitation, gap analysis, acceptance criteria, solution design). Set metadata.mode.
| name | self-correct |
| archetype | core |
| description | Use when an agent is stuck, when 3+ tool failures occur in sequence, or when the 6-step recovery ladder needs activation. |
| metadata | {"version":"1.0.0","vibe":"Fixes what the validators flagged before anyone has to ask","tier":"infrastructure","effort":"high","model":"opus","color":"bright_magenta","capabilities":["validation_fix","coordination_correction","auto_recovery","pattern_learning","subagent_recovery"],"maxTurns":40} |
| allowed-tools | Read Grep Glob Write Edit Bash Agent TaskCreate TaskUpdate TaskList TaskGet |
Adaptive recovery specialist for all domains.
| Issue | Severity | Strategy |
|---|---|---|
| Missing coordination_log | CRITICAL | Re-spawn controller |
| Incomplete synthesis | MAJOR | Prompt controller to complete |
| Vague answers | MINOR | Request clarification from agents |
| Unanswered questions | MAJOR | Re-delegate questions |
| Circular delegation | CRITICAL | BLOCKED - escalate to HITL |
| Weak synthesis | MAJOR | Prompt controller to strengthen |
| Issue | Strategy |
|---|---|
| test_coverage_low | Add test cases |
| linting_errors | Auto-fix (eslint, prettier) |
| missing_documentation | Generate docs |
| format_violations | Restructure to template |
workflow/goal_evaluator_log.yaml exists in the active session, read the most recent 3-5 entries[].evaluator_reason values. Treat them as additional FIXABLE signal alongside validation_report findings. The evaluator runs Haiku against the transcript every turn while /goal is active, so its reasons surface ambiguity, missing evidence, or unfinished work that the file-based validator may not have flagged. When self-correct dispatches a fix, include the latest evaluator reason in the dispatched prompt as "Goal evaluator noted: {reason}".When a subagent fails to complete its assigned work:
type: pre_compactin_progress or pendingwaypoints/ from failed agent's sessionTarget 8K tokens per micro-task (fits comfortably in any context window):
Structured escalation when repeated failures occur on the same work item.
An agent is stuck when it has 3+ consecutive failures on the same work item (same error class, same file, or same operation). Detection signals:
workflow/tool_failures.yaml| Step | Action | Rationale |
|---|---|---|
| 1. Re-read everything | Re-read ALL relevant files from scratch (not from memory) | Context drift causes stale assumptions |
| 2. Review execution log | Read full workflow/tool_failures.yaml and coordination_log | Pattern in failures reveals root cause |
| 3. Combine successes | Identify what DID work across attempts, merge those approaches | Partial successes contain signal |
| 4. Try the opposite | If all attempts used approach A, try approach B | Fixation on one strategy is the #1 stuck cause |
| 5. Radical simplification | Strip the work item to absolute minimum viable scope | Complexity is often the blocker, not the approach |
| 6. Escalate | Mark as BLOCKED with full context, escalate to HITL | Know when to stop |
When spawning a recovery agent after stuck detection:
STUCK RECOVERY for {work_item_id}:
Previous {N} attempts failed. Failure pattern: {pattern_summary}
What worked: {partial_successes}
What failed: {failure_summary}
TRY: {next_step_from_ladder}
DO NOT repeat: {failed_approaches}
Distinct from stuck-detection (the same failure recurring), this is the whack-a-mole signal: 2-3 consecutive fixes where each one resolves the reported failure but surfaces a new problem elsewhere. A relocating failure is a design smell, not a code bug — the fixes are treating symptoms of a structural mismatch, so more rounds just move the failure around.
When you detect it, do not keep fixing and do not silently promote to dead_letter:
architecture_question: true in the session's coordination_log / validation record, summarize the pattern for the user (the sequence of fixes and where each new failure appeared), and ask for an architecture-level decision — change the interface, re-scope the acceptance criteria, or accept a documented tradeoff.Typed failure classification with specific recovery strategies per failure type.
| Failure Type | Detection | Recovery Strategy | Retry Limit |
|---|---|---|---|
syntax_error | Parse/compile error in output | Fix immediately using error message | Unlimited (deterministic fix) |
runtime_error | Execution fails after valid syntax | Analyze stack trace, fix logic | Max 3 attempts |
resource_exhaustion | OOM, context overflow, disk full | Revert changes + try smaller approach | Max 1 (then simplify) |
timeout | Operation exceeds time limit | Kill operation, revert partial changes | Max 1 (then decompose smaller) |
external_dependency | Network, API, service unavailable | Skip work item + log for later | 0 (skip immediately) |
Failure detected
-> Classify type (syntax/runtime/resource/timeout/external)
-> Check retry count for this type
-> If under limit: apply type-specific recovery
-> If at limit:
- syntax_error: should not happen (always fixable)
- runtime_error: escalate with stack traces
- resource_exhaustion: revert + radical simplification
- timeout: decompose into sub-tasks
- external_dependency: skip + log + continue
failed_items:
- task_id: WI-3
failure_type: runtime_error
attempts: 3
error_summary: "TypeError: Cannot read property 'id' of undefined at handler.ts:45"
recovery_actions_taken: ["stack trace analysis", "null check addition", "input validation"]
final_status: blocked
escalation_context: "Handler receives undefined user object from upstream middleware"
See @resources/self-correct-patterns.md for correction strategies.