plugins/coordinator/skills/stuck-detection/SKILL.md
This skill should be used when detecting repetitive actions, oscillating between approaches, or stalling without progress — the three stuck patterns. Referenced by agent prompts for self-monitoring.
npx skillsauth add oduffy-delphi/coordinator-claude stuck-detectionInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
You MUST maintain a mental tally of your recent actions. After each tool call, check against these patterns:
If you have called the same tool with the same arguments 3+ times and received the same result (or the same error), you are stuck. (Two retries are allowed — the third repetition triggers detection.)
Recovery: Stop retrying. Read the error output carefully. Describe what you expected vs what happened. Try a fundamentally different approach — not a variant of the same approach.
If your last 4+ actions alternate between two patterns (e.g., edit-undo-edit-undo, or read-file-A, read-file-B, read-file-A, read-file-B), you are oscillating.
Recovery: Pick one approach and commit. If you're uncertain which is correct, escalate with BLOCKED rather than oscillating.
If you've written 3+ paragraphs of analysis without making a single tool call, you're stalling.
Recovery: State your plan in one sentence. Execute the first concrete step immediately. Analysis without action is not progress.
After context compaction, check your tasks (TaskList/TaskGet) for "tried and abandoned" notes before attempting any approach. Check both metadata.tried_and_abandoned and task descriptions (legacy format). If a task records that an approach was tried and failed, do not retry it.
Recovery: Read all task metadata and descriptions via TaskGet for notes about failed approaches. Choose a different strategy.
Before beginning work, review any ANTI-REPETITION section in your dispatch prompt. Plan your approach to be fundamentally different from all listed failed approaches. If during execution you realize you are converging on a listed failed approach, STOP.
Recovery: Choose a fundamentally different approach. If no alternative exists, report BLOCKED with Type: Structural — "All known approaches exhausted."
Some Agent Teams teammates enter an idle loop where they stop processing shutdown requests and plain-text messages. TeamDelete rejects while they are "active." There is no clean live-kill mechanism — they will eventually time out on their own.
Before attempting any cleanup of a stuck teammate:
~/.claude/plugins/coordinator-claude/coordinator/bin/coordinator-safe-commit "<subject>". Do not use git add -A or git add . — under stress-of-recovery, blanket staging is tempting but produces audit-trail-misleading commits. Stage only the deliverables you can name.The stuck agent's timeout does not block the session from advancing. Once deliverables are committed and archived, the EM can proceed to the next phase or close the session.
tools
Orient session — preflight, load context, choose work
documentation
Wrap up finished work — capture lessons, update docs
testing
Use before commit, /merge-to-main, /workday-complete, or to validate repo state. Resolves and runs the project's configured fast-test command.
development
Root-cause discipline for ONE identified bug, test failure, or unexpected behavior — pin the premise, reproduce, trace to source, fix at source, verify. For a single known issue, not a codebase sweep.