plugins/lt-dev/skills/coordinating-agent-teams/SKILL.md
Provides auto-detection heuristics, coordination patterns, and worktree isolation guidance for parallel Claude Code operations. Covers Agent Teams (independent sessions with messaging) and parallel subagent spawning (Agent tool with isolation worktree). Activates when user mentions "agent team", "parallel review", "parallel agents", "team debug", "parallel worktrees", "batch rebase", "parallel backend frontend", "implement in parallel", or when commands evaluate team suitability via CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS. Also activates when spawning multiple file-modifying subagents concurrently. NOT for single sequential subagent invocations.
npx skillsauth add lennetech/claude-code coordinating-agent-teamsInstall 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.
Claude Code Agent Teams (CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS=1) coordinate multiple independent Claude Code sessions with inter-agent messaging and a shared task list. Unlike subagents (Agent tool), teammates communicate directly and challenge each other.
CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS=1 must be set BEFORE session start — Setting it mid-session has no effect. The flag is read once at startup. Team-capable commands silently fall back to single-agent mode if the env var is missing. Verify with echo $CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS before running /debug, /review, or any team command.--no-team for simple tasks.claude --resume cannot restore a multi-teammate session. If a team run is interrupted (crash, network, user exit), the teammates' transcripts are lost. Treat every team run as one-shot and save important findings to disk before stopping.Agent tool does NOT work inside a subagent or teammate — Nested spawning is blocked. Teammates can message each other, but they cannot spawn their own subagents. Structure workflows as flat teams, not hierarchies.isolation: worktree gets its own worktree. Shared state must go through the messaging channel or through files written to the parent repo after merge. Teammates cannot see each other's unmerged worktree files.pkill in one teammate can kill processes of another — If pkill -f "nuxt dev" runs in one teammate, it kills ALL nuxt dev processes on the machine, including ones owned by other teammates. Use PID-tracked kills (save PID at start, kill by PID at end) in team contexts.Every team-capable command follows this decision tree:
1. Is CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS=1 set?
No → Single Agent Mode (existing behavior)
2. Did user pass --no-team?
Yes → Single Agent Mode (forced)
3. Did user pass --team?
Yes → Team Mode (forced)
4. Does complexity heuristic match?
Yes → Team Mode (auto-detected)
No → Single Agent Mode (overhead not justified)
| Command | Team Trigger |
|---------|-------------|
| /review | >100 changed lines AND >3 files, OR changes in both projects/api/ and projects/app/ |
| /create-story (TDD) | Fullstack monorepo detected AND story involves backend + frontend |
| /rebase-mrs | >2 branches selected |
| /debug | Always team (the workflow requires it) |
| Task Type | Team Advantage | Token Overhead | |-----------|---------------|----------------| | Multi-dimension review | Independent analysis prevents anchoring bias | ~3x | | Fullstack test writing | Parallel backend + frontend, contract sharing | ~2x | | Adversarial debugging | Competing hypotheses with falsification | ~3-5x | | Batch rebase | True parallelism via worktrees | ~1.5x per branch |
Each pattern is described in detail in patterns.md. Summary:
Agent Teams cost approximately 3-5x a single agent run. This is justified when:
Not justified when:
When spawning multiple file-modifying subagents concurrently via the Agent tool (not Agent Teams), use isolation: "worktree" to prevent file conflicts:
Agent tool call:
subagent_type: "lt-dev:backend-dev"
isolation: "worktree" ← each gets its own working copy
prompt: "Implement feature X in projects/api/..."
Agent tool call:
subagent_type: "lt-dev:frontend-dev"
isolation: "worktree"
prompt: "Implement feature X in projects/app/..."
isolation: "worktree"| Scenario | Isolation needed? | |----------|-------------------| | Multiple file-modifying agents in parallel | Yes | | Single agent (sequential) | No | | Read-only agents (reviewers) in parallel | No | | Agent modifying lockfiles/dependencies | No — needs in-place access |
| Supports worktree | No worktree (in-place only) |
|-------------------|-----------------------------|
| backend-dev, frontend-dev, devops, branch-rebaser | fullstack-updater, nest-server-updater, npm-package-maintainer, all reviewers |
See worktree-guide.md for setup, cleanup, naming conventions, performance settings (worktree.sparsePaths, worktree.symlinkDirectories), dependency isolation, and known limitations.
CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS=1 environment variable| Element | Relationship |
|---------|-------------|
| /lt-dev:debug | Always uses team (Adversarial Convergence pattern) |
| /lt-dev:review | Auto-detects team for large/fullstack changes |
| /lt-dev:create-story | Auto-detects team for fullstack TDD |
| /lt-dev:git:rebase-mrs | Auto-detects team for batch operations |
Note: /lt-dev:debug REQUIRES Agent Teams (no single-agent fallback). All other commands auto-detect based on complexity heuristics and fall back to single-agent mode gracefully.
development
Single source of truth for the lenne.tech fullstack production-readiness checklist. Defines the eight pillars (configuration & secrets, observability & logging, health & lifecycle, security hardening, data durability, resilience under load, deployment hygiene, runbook & rollback) with concrete file/line evidence requirements per pillar, severity classification (Critical / Major / Minor), and a canonical machine-parseable report block. Activates whenever an agent or command needs to gate a release on production-readiness — currently used by /lt-dev:production-ready, lt-dev:production-readiness-orchestrator, and the devops-reviewer (read-only). NOT for OWASP-style code-level security review (use security-reviewer). NOT for npm dependency audits (use maintaining-npm-packages).
development
Single source of truth for executing GitLab CI/CD pipelines locally with the same image, env vars, and service containers as the real runner — so pipeline failures are caught before push. Defines pipeline discovery (.gitlab-ci.yml + includes), per-job execution via gitlab-runner exec, service-container orchestration (Mongo, Redis, MailHog), env injection without secrets, cache/artifact handling, and a job-by-job verdict report. Also describes the GitHub Actions equivalent via act for projects that mirror to GitHub. Activates whenever an agent or command needs to validate that the CI pipeline will pass — currently used by /lt-dev:production-ready and lt-dev:production-readiness-orchestrator. NOT for running the local check script (use running-check-script). NOT for writing or refactoring CI configs (use the devops agent).
development
Single source of truth for designing, running, and interpreting k6 load tests against lenne.tech fullstack APIs. Defines installation paths (brew, docker, npm), the three canonical scenarios (smoke / load / soak), endpoint discovery from the generated SDK, realistic Better-Auth login flows, threshold defaults for ~10 concurrent users (p95 < 500ms, error rate < 1%, http_req_failed < 1%), result interpretation, and the optimisation ladder when the system fails (DB indices, query rewrites, caching, connection pool sizing, rate-limit relaxation, payload trimming). Activates whenever an agent or command needs to validate that the API is stable for ~10 concurrent users performing many actions in short time, or to detect performance regressions via k6. Currently used by /lt-dev:production-ready, lt-dev:production-readiness-orchestrator, and lt-dev:performance-reviewer. NOT for Lighthouse frontend performance (use a11y-reviewer). NOT for unit performance assertions (use the test runner directly).
tools
Migrates lenne.tech projects from the legacy jest+eslint+prettier toolchain to the current vitest+oxlint+oxfmt baseline used by nest-server-starter and nuxt-base-starter. Covers swc decoratorMetadata config, the @Prop union-type fix for SWC, supertest default-import correction, ESM/CJS interop, the Nitro PORT-vs-NITRO_PORT bug, ANSI escape stripping in workspace runners (lerna/nx), free-port logic for check-server-start.sh, the offers-pattern config.env.ts (NSC__-only + fail-fast + auto-derived appUrl), and the multi-phase check-envs.sh smoke test. Activates whenever someone is migrating an existing project to the new toolchain, debugging "Cannot determine a type for the X field" Mongoose errors, ERR_SOCKET_BAD_PORT crashes from check-server-start, or wants to align an existing project with the current starter conventions.