Skip to content

Claude Code skill for multi-agent orchestration using the Planner-Worker-Judge pattern

License

Notifications You must be signed in to change notification settings

sidmohan0/agentbase

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

AgentBase

A Claude Code skill that implements the Planner-Worker-Judge pattern for multi-agent orchestration, based on Cursor's "Scaling Long-Running Autonomous Coding" research.

What It Does

AgentBase turns Claude Code into a hierarchical multi-agent system where you are the master orchestrator and an autonomous Agent Planner does the work:

┌─────────────────────────────────────────────────────────┐
│              YOU (Master Orchestrator)                   │
│  - Set goals: /agentbase goals set "fix all bugs"       │
│  - Launch:    /agentbase go                             │
│  - Monitor:   /agentbase status                         │
│  - Stop:      /agentbase stop                           │
└─────────────────────────────────────────────────────────┘
                           │
                    /agentbase go
                           ▼
┌─────────────────────────────────────────────────────────┐
│              AGENT PLANNER (Autonomous)                  │
│  - Discovers tasks from codebase                        │
│  - Triages and prioritizes                              │
│  - Spawns workers, evaluates progress                   │
│  - Reports back to you periodically                     │
└─────────────────────────────────────────────────────────┘
                           │
           ┌───────────────┼───────────────┐
           ▼               ▼               ▼
    ┌──────────┐    ┌──────────┐    ┌──────────┐
    │ Worker 1 │    │ Worker 2 │    │ Worker 3 │
    └──────────┘    └──────────┘    └──────────┘

Workers operate on isolated workstreams (e.g., frontend, backend, api) with non-overlapping ownership, enabling true parallel development.

Requirements

  • macOS or Linux: Works out of the box
  • Windows: Requires Git Bash (included with Git for Windows). Native CMD/PowerShell is not supported.
  • Claude Code: The CLI must be installed and configured

Quick Start

# 0. Clone repo
git clone https://github.com/sidmohan0/agentbase.git

# 1. Install the skill
cp -r skill/ ~/.claude/skills/agentbase/
# Or for project-local: cp -r skill/ .claude/skills/agentbase/

# 2. In Claude Code, initialize your repo
/agentbase init

# 3. Set your goal and let it run
/agentbase goals set "Fix all failing tests"
/agentbase go          # Launch autonomous Agent Planner

# 4. Monitor and control
/agentbase status      # Check progress anytime
/agentbase stop        # Stop when needed

Commands

Primary (Autonomous Mode)

Command Description
/agentbase go [goal] Launch autonomous Agent Planner - the main command
/agentbase goals View/set high-level goals
/agentbase status Check current state and progress
/agentbase stop Signal Agent Planner to stop gracefully
/agentbase resume Resume from last saved state
/agentbase cleanup Remove old state files and reports

Setup

Command Description
/agentbase init Initialize scaffolding in a new repo
/agentbase setup Create isolated worktree for experimentation
/agentbase worktree <ws> Create a worktree for a specific workstream

Manual Mode (run individual phases)

Command Description
/agentbase triage Analyze failures, create prioritized task list
/agentbase discover Scan codebase for tasks
/agentbase plan <ws> Create detailed plan for a workstream
/agentbase work <ws> Spawn a worker for a specific workstream
/agentbase parallel <n> Spawn n workers on top-priority tasks
/agentbase judge Evaluate progress, decide continue/stop/pivot

Features

Automatic Task Discovery

AgentBase finds work from 7 sources:

  1. Failing tests (P0-P1) - crashes, timeouts, assertions
  2. Type/lint errors (P1-P2) - TypeScript, ESLint, mypy
  3. GitHub issues (P2-P4) - bugs, features by label
  4. Code TODOs (P3-P5) - TODO, FIXME, HACK comments
  5. Coverage gaps (P3-P4) - untested code paths
  6. Mutation testing (P3) - weak test detection
  7. Progress files (varies) - existing scoreboard

Git Worktree Integration

For true parallel isolation, each workstream can run in its own worktree:

/agentbase worktree frontend   # Creates ../project-frontend/ on branch agentbase/frontend
/agentbase worktree backend    # Creates ../project-backend/ on branch agentbase/backend

Workers in separate worktrees can't conflict—they own different files.

Multi-Session Scaling

For hundreds of parallel agents, use the included shell script:

./skill/scripts/multi-session.sh --worktrees --tmux

Installation

See INSTALL.md for detailed instructions.

Quick version:

# Clone this repo
git clone https://github.com/sidmohan0/agentbase.git

# Copy skill to Claude Code skills directory
cp -r agentbase/skill/ ~/.claude/skills/agentbase/

How It Works

  1. Scaffolding - /agentbase init analyzes your repo and generates:

    • AGENTS.md - Master coordination document
    • docs/philosophy.md - Development principles
    • docs/triage.md - Priority framework
    • instructions/<workstream>.md - Scope definitions
    • progress/ - Committed scoreboard
  2. Task Discovery - Automatically finds work from tests, types, issues, TODOs

  3. Worker Spawning - Uses Claude's Task tool to spawn sub-agents with:

    • Specific task assignment
    • Workstream scope (owns / does not own)
    • Definition of done
    • Resource limits
  4. Progress Tracking - JSON files committed to git track status

Key Principles

From the Cursor research:

  • Role Separation: Planner plans, Workers execute, Judge evaluates
  • Non-Overlapping Ownership: Workstreams have explicit scope boundaries
  • Measurable Outcomes: "If you can't show a delta, you're not done"
  • Prompting > Infrastructure: The skill IS the coordination mechanism
  • Simplicity: Remove complexity rather than add it

Documentation

Contributing

Contributions welcome! See CONTRIBUTING.md.

Updating

# If you cloned the repo, just pull and re-copy
cd ~/path/to/agentbase && git pull && cp -r skill/ ~/.claude/skills/agentbase/

See INSTALL.md for more update options.

Version

Current version: 1.2.0

Check your installed version:

cat ~/.claude/skills/agentbase/VERSION

License

MIT - see LICENSE

Acknowledgments

Based on Wilson Lin's research at Cursor: "Scaling Long-Running Autonomous Coding"

About

Claude Code skill for multi-agent orchestration using the Planner-Worker-Judge pattern

Resources

License

Contributing

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •  

Languages