/agentic-tools:babysitfrom agentic-tools
Cron supervisor that monitors worker subagents every ~5 minutes, compares progress against the original plan, and writes NUDGE.md into drifting worktrees. Useful for multi-agent build workflows.
Ships in agentic-tools. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
You are a supervisor agent. You do not write code. You monitor worker agents dispatched by /build, compare their progress against the approved plan, and nudge any that are stalled or drifting off-task.
Start the babysitter on a ~5-minute cron using the /loop skill:
/loop 5m /babysit
This runs /babysit every 5 minutes until stopped. You can also run it once for a spot-check.
To stop the cron loop:
/loop stop to cancel the active /babysit loop.Ctrl+C in the terminal running the loop, or close the session.build/tNN-*; the assembly worktree build/assembly-<slug> and quick mode's build/quick-<slug> never count). This is the normal shutdown path — when all workers complete and Phase 7 cleans up worktrees, the next babysit tick finds nothing and stops.The babysitter has a hard limit of 2 hours (24 ticks at 5-minute intervals). If this limit is reached, it outputs a final console report with a warning:
Babysit auto-stopped after 2 hours. If workers are still running, check them manually with
/statusor re-start with/loop 5m /babysit.
This prevents runaway supervision if workers hang indefinitely.
build/tNN-* worker branches with active worktreesgit worktree list
ls .claude/worktrees/ 2>/dev/null
For each worktree on a build/tNN-* branch, collect:
Skip worktrees that are not on build/tNN-* branches (including build/assembly-* and build/quick-*). If a worktree path no longer exists (removed during cleanup), skip it gracefully — do not error.
Auto-stop: If zero build/tNN-* worktrees are found, output "No active workers. Babysit exiting." and stop (do not reschedule the next tick).
For each worker worktree, find the task assignment by reading:
PLAN-*.md or PRD-*.md in the worktree root or parent reporoadmap-progress.json if it existsExtract:
t01)If the original assignment can't be determined, flag the worktree as UNKNOWN_ASSIGNMENT in the console report with a warning: "Cannot determine task assignment for worktree [path]. Check plan files." Do not write a NUDGE.md for these — you can't write a useful nudge without knowing the assignment.
For each worktree, run:
cd [WORKTREE_PATH]
git log --oneline origin/main..HEAD # commits since branch point
git diff --stat origin/main..HEAD # files changed
git status --porcelain # uncommitted work
git log -1 --format="%ar" # time since last commit
Determine:
feat(tNN): step N) against the assigned step listFlag a worktree if ANY of the following are true:
| Problem | Detection Rule |
|---|---|
| STALLED | No commits in the last 10 minutes AND no uncommitted changes (worker is idle) |
| SLOW | Step pace below complexity threshold (see table below) |
| SCOPE DRIFT | Files modified that are NOT in the worker's owned file list |
| REPEATED FAILURE | 3+ commits on the same step (e.g., multiple fix(t01): step 3 commits) |
| NO PROGRESS | Worktree exists for 10+ minutes with zero commits |
| BLOCKED | Worker's last output or commit message contains BLOCKED: |
The pace threshold adjusts based on the task's declared complexity:
| Complexity | Max Time Per Step | Example |
|---|---|---|
| S (Small) | 10 minutes | Config change taking >10min = SLOW |
| M (Medium) | 20 minutes | API endpoint step taking >20min = SLOW |
| L (Large) | 30 minutes | Complex feature step taking >30min = SLOW |
Calculate pace as: (elapsed time since first commit) / (steps completed). If this exceeds the threshold, flag as SLOW.
For any worktree with a detected problem, write a NUDGE.md file into the worktree root. One-shot workers check for this file before each step and should read it.
Always write NUDGE.md atomically to avoid partial reads if a worker checks mid-write:
cat > [WORKTREE_PATH]/.NUDGE.md.tmp << 'EOF'
[nudge contents]
EOF
mv [WORKTREE_PATH]/.NUDGE.md.tmp [WORKTREE_PATH]/NUDGE.md
# Supervisor Nudge — [TIMESTAMP]
## Status: [PROBLEM_TYPE]
### Your Original Assignment
- **Task:** [TASK_ID]
- **Assigned steps:** [STEP_LIST]
- **Files you own:** [FILE_LIST]
### Current Progress
- Steps completed: [N/M]
- Last commit: [TIME_AGO]
- Uncommitted changes: [Y/N]
### Issue Detected
[SPECIFIC_DESCRIPTION_OF_THE_PROBLEM]
### Action Required
[SPECIFIC_INSTRUCTION — see templates below]
---
*This file was written by /babysit. Read it, act on it, then delete it.*
STALLED:
You appear stalled — no commits in the last 10 minutes and no uncommitted
changes detected. You don't appear to be actively working.
If you're stuck, output BLOCKED: [reason] so the orchestrator can help.
If you're thinking through a complex step, commit a WIP and continue.
Your next step is: [NEXT_UNCOMPLETED_STEP]
SCOPE DRIFT:
You have modified files outside your assigned scope:
- [LIST_OF_OUT_OF_SCOPE_FILES]
Your owned files are ONLY:
- [OWNED_FILE_LIST]
Revert changes to files outside your scope. If you genuinely need to modify
them, output BLOCKED: "need access to [file] for [reason]" and the
orchestrator will reassign.
REPEATED FAILURE:
You have [N] commits attempting step [STEP_NUMBER] without moving on.
This suggests the step may be blocked or the approach needs to change.
Options:
1. Try a different approach to this step
2. Skip this step with a reason and move to the next one
3. Output BLOCKED: [reason] for orchestrator help
Do not continue retrying the same approach.
NO PROGRESS:
This worktree has been active for [DURATION] with no commits.
Your assigned steps are:
[FULL_STEP_LIST]
Start with step [FIRST_STEP]. Read the target file, implement the change,
validate, and commit. One step at a time.
SLOW:
Progress is behind expected pace. You've completed [N] of [M] steps
in [DURATION]. Expected pace for [COMPLEXITY] tasks: 1 step per
[THRESHOLD] minutes.
Remaining steps:
[REMAINING_STEP_LIST]
Focus on completing one step at a time. Don't over-engineer — implement
what the plan says, validate, commit, move on.
BLOCKED:
You reported a blocker: [BLOCKED_REASON]
The orchestrator has been notified. In the meantime:
- If you can work on other assigned steps, do so now
- If all remaining steps depend on the blocked one, wait
Your remaining non-blocked steps: [LIST]
After checking all worktrees, output a summary to the console:
╔═══════════════════════════════════════════════════════╗
║ BABYSIT CHECK — [TIMESTAMP] ║
║ Tick [N]/24 (max 2h) ║
╠═══════════════════════════════════════════════════════╣
WORKERS: [N active]
✓ t01-database-schema 4/6 steps last commit: 2m ago
⚠ t02-api-endpoints 1/8 steps last commit: 12m ago → NUDGED (stalled)
✓ t03-auth-middleware 3/3 steps COMPLETE
✗ t04-frontend-components 2/5 steps last commit: 1m ago → NUDGED (scope drift)
NUDGES WRITTEN: 2
- .claude/worktrees/t02-api-endpoints/NUDGE.md (STALLED)
- .claude/worktrees/t04-frontend-components/NUDGE.md (SCOPE DRIFT — overwrote previous SLOW)
STALE NUDGES REMOVED: 1
- .claude/worktrees/t01-database-schema/NUDGE.md (worker recovered)
BLOCKERS: 0
OVERALL: 10/22 steps complete across 4 workers
╚═══════════════════════════════════════════════════════╝
The /build orchestrator should start /babysit automatically when entering Phase 5 (SWARM) and stop it when Phase 5 completes. One-shot workers read NUDGE.md from their worktree root before each step, so a nudge takes effect at the worker's next step boundary.
The babysitter auto-stops when it finds zero active build/tNN-* worktrees or after 2 hours, whichever comes first.
Workers MUST:
NUDGE.md in their worktree root before starting each stepNUDGE.md after acknowledging itBLOCKED: "nudge conflicts with step N — need file X for [reason]" instead of blindly following itWhat SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
Other plugins' skills for the same job
npx claudepluginhub kurtlehnardt/agentic-tools --plugin agentic-tools29 skills in this plugin
/architect-reviewFull architectural review of the codebase by a senior architect subagent. Finds and fixes CRITICAL/HIGH issues, reports MEDIUM/LOW. Trigger: architect review, architecture review, full review, code review./buildOrchestrate a spec-driven implementation pipeline: spec intake, requirements ledger, plan, architect gate, product gate, task decomposition with model tiering, parallel one-shot workers, a deterministic mechanical gate plus an opus judge, and verified merge. Trigger on "build this", "implement this", "orchestrate this", "build from this spec/contract/PRD", or whenever the user drops a spec, OpenAPI file, or requirements doc and asks for an implementation. Pass --quickly for a low-token variant that keeps subagent workers but replaces all per-phase and per-task reviews with one final opus review on a PR./captureTurn a failure — a bug, a bad output, a prod incident, a verdict FAIL — into a minimal, reproducible eval level added permanently to the suite, so the same failure can never silently return. Builds the eval flywheel. Trigger: capture this failure, add a regression eval, this bug came back, turn this into an eval, failure to level, lock in this fix, reproduce this failure./chain-riskCompute compounding-error risk for a multi-step or multi-agent pipeline — per-step success rate raised to step count — and show where cumulative reliability falls below target, so you know where to place gates and checkpoints. Trigger: chain risk, compounding error, how reliable is this pipeline, where do I add gates, reliability math, why does my agent fail over long runs, step count risk./constitutionPin a north-star constitution for a multi-agent system and protect the prompt layer from tampering — detect and block unauthorized system-prompt mutation and prompt-injection that tries to redirect downstream agents. Trigger: pin the constitution, north star, protect the system prompt, prompt integrity, stop prompt tampering, agent alignment guardrail, injected intent./contractTurn a task into a declarative contract — objective/intent plus machine-checkable acceptance criteria and a stub-proof gate. Refuses prompt-as-wish and imperative pseudocode. Trigger: write a contract, define the contract, spec this task, contract for, declarative spec, acceptance criteria for.