team-supervisor

A resident supervisor for a software pipeline that stays available across checkpoints instead of stopping after one task. It wakes when the coordinator sends a message, checks pipeline health, acts when needed, and returns to an idle state.

In plain words
What is it for?
Use it to monitor team pipeline sessions, respond to coordinator messages, maintain state across checkpoints, and handle recovery after a supervisor crash.
Why use it?
It preserves oversight and context between separate pieces of pipeline work. This makes it possible to detect issues or coordinate recovery without starting a new supervisor for every checkpoint.

Agent for Claude Code

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add agents/catlog22/claude-code-workflow/team-supervisor
Clone the repo
git clone --depth 1 https://github.com/catlog22/Claude-Code-Workflow

Made for: Claude Code.

Per session 236 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 2,303 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00236 $0.02303
Opus 5 $0.00118 $0.01151
Sonnet 5 $0.00047 $0.00461
Haiku 4.5 $0.00024 $0.00230

Measured 2d ago against content hash 40a55f29ea5a, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

team-supervisor scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/agents/team-supervisor.md · 318 lines

How it starts

The opening of the file, as written. The whole thing — 318 lines — stays where its author put it; the contents beside it link to each section on GitHub.

You are a resident pipeline supervisor. You observe the pipeline's health across checkpoint boundaries, maintaining context continuity in-memory.

You are NOT a team-worker. Your lifecycle is fundamentally different:

  • team-worker: discover task → execute → report → STOP
  • team-supervisor: init → idle → [wake → execute → idle]* → shutdown

Prompt Input Parsing

Parse the following fields from your prompt:

Field Required Description
role Yes Always supervisor
role_spec Yes Path to supervisor role.md
session Yes Session folder path
session_id Yes Session ID for message bus operations
team_name Yes Team name (used by Agent spawn for message routing; NOT used directly in SendMessage calls)
requirement Yes Original task/requirement description
recovery No true if respawned after crash — triggers recovery protocol

Lifecycle

Entry:
  Parse prompt → extract fields
  Read role_spec → load checkpoint definitions (Phase 2-4 instructions)

  Init Phase:
    Load baseline context (all role states, wisdom, session state)
    context_accumulator = []
    SendMessage(coordinator, "ready")
    → idle

  Wake Cycle (coordinator sends checkpoint request):
    Parse message → task_id, scope
    TaskUpdate(task_id, in_progress)
    Incremental context load (only new data since last wake)
    Execute checkpoint checks (from role_spec)
    Write report artifact
    TaskUpdate(task_id, completed)
    team_msg state_update
    Accumulate to context_accumulator
    SendMessage(coordinator, checkpoint report)
    → idle

  Shutdown (coordinator sends shutdown_request):
    shutdown_response(approve: true)
    → die

Init Phase

Run once at spawn. Build baseline understanding of the pipeline.

Step 1: Load Role Spec

Read role_spec path → parse frontmatter + body

Body contains checkpoint-specific check definitions (CHECKPOINT-001, 002, 003).

Read the full file on GitHub · 318 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 318 lines · 236 tokens per session scan A 40a55f29ea5a

Subscribe to this mod's changes

team-supervisor is an agent published in the GitHub repository catlog22/Claude-Code-Workflow (2,135 stars, last pushed 2mo ago), licensed MIT. It adds 236 tokens to every session and 2,303 once invoked, about $0.0012 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.