Show team health and agent activity for a running team session. Checks agent commits, file changes, task progress, and context exhaustion. Use when user says 'team status', 'how is the team doing', 'check agents', or 'who is stuck'.
Show health and activity for a running agent team. Auto-detects the team if only one is active.
Resolve team: If team-name provided, use it. Otherwise, check ~/.claude/teams/ for active teams — if exactly one, use it; if multiple, ask via output which to inspect.
Load team config: Read ~/.claude/teams/{team-name}/config.json to get member list (name, agentType, agentId).
Check agent activity:
git log --author={agent} --since="30 minutes ago" --oneline for recent commitsClassify each agent:
Context exhaustion detection: 3+ consecutive idle notifications with an in_progress task and no file edits = likely exhausted.
Output summary:
Team: {team-name}
Members: {count} agents
Agent | Status | Current Task | Last Activity
---------------|---------|---------------------|---------------
backend-eng | Active | Implement converter | 2m ago (commit)
frontend-eng | Quiet | Build settings page | 8m ago (file edit)
backend-qa | Stale | Write auth tests | 22m ago
Alerts:
- backend-qa may be context-exhausted (3 idle cycles, no edits)
Actionable suggestions: For stale/exhausted agents, suggest respawn or task reassignment.