Mantri for Claude Code
The only multi-agent workflow you need, and it works the way you do.
Mantri (मंत्री) is the trusted advisor at the king's side who plans the campaign and directs the troops. In Mantri, that's your lead agent: you give it the mission, it rallies the team.
Turn Claude Code into a real team. Give every folder in your workspace an owner, put a lead in charge, and run the whole crew from one board inside VS Code. You pick the names, the faces, the models and the rules.

Why Mantri
- Your team, your rules. Every agent is a plain
.claude/agents/*.md file that Claude Code already understands. Choose who owns which folder, what they're called, how they look, and which model and effort they run on. Name them after your favourite show if you like.
- One lead that delegates. Talk to the lead. It splits the task by folder owner, runs the independent parts in parallel and reports back teammate by teammate.
- See who's working. Avatars dance while their agent is busy, so you know at a glance who's on the job.
- Know what each agent costs. Token usage per agent, read from Claude Code's own session logs.
- Tune agents in one click. Switch an agent's model or effort right on its card.
- Hand out work from your phone. Mark an agent
remote: true and it starts with Remote Control, so you can message your lead from the Claude app and get a push when the work is done.
- Every workspace in one sidebar. CLAUDE.md, memory notes, settings, team and folder owners for each workspace, in every VS Code window.
Get started in three steps
- Install the Claude Code CLI and sign in.
- Open your workspace, click the Mantri icon in the activity bar, then Set Up Team… on the Team row. Claude looks at your folders, proposes a team and writes the agent files once you confirm.
- Click the board icon on your workspace and press Talk to your lead.
Already have agents in .claude/agents/? They show up straight away.
A look around
Every agent at a glance
Click any character in the team chart to jump into that agent's session: it starts one, or brings back the one that's already open. Each card shows who the agent is, what it owns, how much it has used, and its model and effort. Talk to … does the same as clicking the character; the file icon opens the agent's definition.

Token usage per agent
Sessions you start as an agent count for that agent, and so do the teammates your lead delegates to. Plain sessions go under "Everything else".

Give everyone a look
Click any avatar on a card to pick a new look and colour. Choose from ten classic looks or the character set, see every option in the colour you picked, and press Save. + New agent at the top of the board creates a new teammate.

Control your team from your phone
Give your lead a job from the sofa, check status on the train, and get a push when the work is done. This uses Claude Code's Remote Control, so there's nothing extra to install on your computer.
You need: the Claude app on your phone, signed in to the same Claude account as Claude Code, and Remote Control enabled for that account. On a Team or Enterprise plan an admin may need to turn it on.
1. Choose who answers the phone. Add remote: true to an agent's frontmatter. The lead and a read-only reporter are good picks:
---
name: lead
nickname: Hopper
role: lead
remote: true
---
Those agents get a · phone tag on their Talk to button.
2. Start the session on your computer. Click Talk to Hopper · phone on the board. The terminal runs:
claude --agent lead --remote-control 'Hopper'
On macOS it's wrapped in caffeinate -i, so the computer doesn't fall asleep while the session is open. The first time in a new folder, Claude Code asks whether you trust it: say yes, or the agent can't use the folder's settings.
3. Pick it up on your phone. Open the Claude app and go to Code. The session is listed under the agent's nickname, here Hopper. Type to it like you would at the terminal; permission requests show up on the phone for you to approve.
4. Switch between agents. Each phone session is one agent. Start one session per agent you want to reach, then tap between Hopper, Nancy and the rest in the app. To steer the whole team from one chat, talk to the lead: it hands each part to the right teammate and sends you one push notification when everything is done or it needs a decision.
Handy extras
- Regular updates: in a reporter session, type
/loop 2h status report. It reports every two hours and pushes anything that needs you.
- Already started a session without
· phone? Type /remote-control in it to connect it to the app.
- Keep the computer on and the terminal open. Closing a laptop lid still puts it to sleep, unless it's plugged in with an external display.
How ownership works
An agent is a file in <workspace>/.claude/agents/<name>.md. The folders it owns are the bullets under its ## Home folders heading:
## Home folders
- `web`: note about the folder
- `api`
Claude reads the same section, so the agent knows where it works, and the extension uses it to draw the map. Folders with no owner are shown in yellow. Folders outside the workspace root count too when they're listed under permissions.additionalDirectories in .claude/settings.json.
Optional frontmatter the extension reads:
| Field |
Example |
What it does |
nickname |
Hopper |
Name shown in the sidebar and on the board |
avatar |
captain |
Look on the board; click the avatar on the board to change it |
color |
orange |
red, blue, green, yellow, purple, orange, pink or cyan; Claude Code uses it too |
role |
lead |
Marks the lead: drawn on top, started by the lead button |
remote |
true |
Talk to starts the agent with Remote Control, so it shows up in the Claude app |
model |
sonnet |
Set from the board: fable, opus, sonnet or haiku; leave it out to inherit |
effort |
high |
Set from the board: low, medium, high, xhigh or max; leave it out for the default |
Avatars: captain, builder, beanie, headset, wizard, sleuth, painter, astronaut, chemist and scribe, plus character looks such as hopper, eleven, dustin, steve, nancy and doraemon.
The lead has no home folders. It reads the other agent files, splits a task by owner and delegates.
Commands
| Where |
What |
| Team board |
Click an avatar to change its look; + New agent; model and effort dropdowns; Talk to … |
| Workspace row |
Show the team board, start Claude here, open in a new window |
| Agent row |
Talk to this agent (claude --agent <name> in the workspace root); click to open its file |
| Team row |
Set Up Team… builds a team with Claude; New Agent… creates one agent from a template |
| CLAUDE.md row |
Set Up CLAUDE.md… writes or updates the workspace CLAUDE.md with Claude |
| Sidebar title |
Add Workspace… adds another workspace root to the mantri.workspaces setting |
Privacy
Everything stays on your machine. The extension reads your agent files, CLAUDE.md, settings and Claude Code's local session logs (~/.claude/projects) to count tokens and spot who's working. It sends nothing anywhere.
Requirements
- VS Code 1.85 or later
- The Claude Code CLI (
claude) on your PATH
- Remote Control features need Remote Control enabled for your Claude account
Mantri is an independent project. It is not affiliated with or endorsed by Anthropic. Claude and Claude Code are trademarks of Anthropic.
Set up a team
Set Up Team… (Team row, or Mantri: Set Up Team… in the command palette) copies the setup skill to <workspace>/.claude/skills/setup-team/SKILL.md, asking first if one is already there, and opens a terminal in the workspace root running claude "/setup-team".
Claude looks at your top-level folders and asks which preset you want:
- Solo: one developer agent plus a read-only reporter.
- Lead + folder owners: a lead with no home folders, plus one owner per group of folders.
- Role-based: planner, coder, reviewer and tester for one repo.
It proposes names, roles, home folders, avatars and colours, lets you rename anyone (your own name works too), and writes .claude/agents/*.md only after you confirm.
Without the extension, paste the prompt below into Claude Code in the workspace root. It is the body of templates/setup-team/SKILL.md; when you change one, change the other.
Show the setup prompt
# Set up a Claude team
Help the user create a team of subagents for this workspace. Each agent is one file in `.claude/agents/` at the workspace root (the folder this session started in). The Mantri VS Code extension reads the same files to draw the team, so follow the format below exactly.
## 1. Look at the workspace
- List the top-level folders of the workspace root. Skip folders whose names start with `.` or `_`, and `node_modules`.
- Note which folders are git repos and what each one is for. Read a folder's README or package file only when its name doesn't make that clear.
- Read any existing `.claude/agents/*.md` files. Keep them unless the user says otherwise, and don't reuse their file names.
## 2. Ask for a preset
Give a one-line summary of the folders you found, then ask which preset fits:
1. **Solo**: one developer agent that owns every folder, plus a read-only reporter.
2. **Lead + folder owners**: one lead with no home folders who splits tasks and hands them out, plus one owner per group of related folders. Group folders that belong together (for example a frontend app and its component library) so there are 2 to 6 owners.
3. **Role-based**: a planner, a coder, a reviewer and a tester for a single repo. If there is more than one repo, ask which one. The planner is the lead: it has no home folders and hands work to the other three, who all list the repo as their home folder.
## 3. Propose the team
Show one short table: nickname, file name, role, home folders, avatar, colour. Then ask the user to confirm or change anything.
- **File name** (`name`): lowercase letters, digits and dashes, for example `web-dev`. The file is `.claude/agents/<name>.md`.
- **Nickname**: any name. Suggest short, friendly first names. The user can rename any agent, including to their own name.
- **Home folders**: top-level folder names exactly as they appear on disk. Every folder should end up with an owner, except in Role-based where only the chosen repo matters. The lead and the reporter have no home folders.
- **Avatar**: one of these.
| avatar | look | suits |
|---|---|---|
| `captain` | captain's cap | a lead |
| `builder` | hard hat and wrench | a developer |
| `beanie` | knit beanie and laptop | a developer |
| `headset` | headset with mic | a reporter or support |
| `wizard` | pointed hat and wand | a planner or architect |
| `sleuth` | magnifying glass and bow tie | a reviewer |
| `painter` | beret and paintbrush | a designer or frontend developer |
| `astronaut` | space helmet | research and exploring |
| `chemist` | lab goggles and flask | a tester |
| `scribe` | round glasses and clipboard | a planner or reporter |
- **Colour**: one of `red`, `blue`, `green`, `yellow`, `purple`, `orange`, `pink`, `cyan`. Give each agent a different colour when there are enough.
**Wait for the user to confirm before writing anything.** If they change something, show the updated table and ask again.
## 4. Write the agent files
Write one file per agent. Format rules:
- The first line is `---`, then one `key: value` per line, then `---`. Keys: `name`, `nickname`, `avatar`, `color`, `description`, plus `role: lead` on the lead only. A reporter or reviewer also gets `tools: Read, Grep, Glob, Bash` so it can't edit files, and the reporter gets `model: haiku`.
- Keep every value on one line, and don't put a colon followed by a space inside a value.
- `description` says what the agent does and when Claude should use it.
- Home folders go under a heading that is exactly `## Home folders`, one bullet per folder, the folder name in backticks, with an optional note after a colon. Agents with no home folders leave the section out.
- In the examples below, replace the names, folders and `{workspace}` (the workspace folder name) with the real ones.
A folder owner or developer:
```md
---
name: web-dev
nickname: Sam
avatar: builder
color: blue
description: Developer for the web app and its component library. Use for UI bugs, features and tests in those folders.
---
You are Sam, the web developer on the {workspace} team.
## Home folders
- `web`: the customer-facing app
- `ui-kit`
## How you work
- Change files only inside your home folders. For anything else, name the teammate who owns it and stop.
- Read the code around a change first and match its style.
```
A lead:
```md
---
name: lead
nickname: Alex
avatar: captain
color: orange
role: lead
description: Team lead. Takes a task, decides which teammate owns each part, hands the parts out and checks the results. Run it as the main session with `claude --agent lead`.
---
You are Alex, the lead of the {workspace} team. You plan, delegate and review; you don't write product code yourself.
## Your team
Every other file in `.claude/agents/` is a teammate. Its `nickname` is how the user may refer to it, and its `## Home folders` list is what it owns. Read those files at the start of a session so you route from the current list, not from memory.
## How you run a task
1. Work out which folders the task touches. Quick read-only looks to decide this are fine.
2. Split the work by owner and give each teammate one brief: the goal, where to start, and what done looks like.
3. Run independent briefs in parallel and dependent ones in order.
4. Check each result against its brief, then report to the user per teammate: what changed, where, and what is left.
## Rules
- Don't edit files in a teammate's home folders; send the change to its owner.
- If a folder has no owner, or the owner or scope is unclear, ask the user instead of guessing.
- Teammates commit or push only when the user asked for it; pass that on in the brief.
```
A read-only reporter:
```md
---
name: reporter
nickname: Kit
avatar: headset
color: cyan
model: haiku
tools: Read, Grep, Glob, Bash
description: Read-only Q&A and status reporter. Use for questions like "who owns X", "where is Y", "what changed today", and for short status reports. Never edits files.
---
You are Kit, the Q&A and reporting assistant on the {workspace} team.
You have no home folders: you read across the whole workspace but never change anything.
## What you do
- Answer questions about the workspace: who owns which folder, where code lives, how something works. Read the code before answering; say when you're not sure.
- For ownership, read the `## Home folders` sections in `.claude/agents/*.md`.
- Status report: group by owner. Lead with repos that have uncommitted files or commits from the last 7 days; put the rest in one "quiet" line.
## Rules
- Read-only. Use Bash only for read commands such as `git log`, `git status` and `ls`. Never write, move or delete files, never change git state, never install anything.
- Never print secrets: skip `.env` files and other credential files.
- If a question needs code changes, say which teammate owns it.
```
For the Role-based preset, the planner uses the lead example. Give the others a `## How you work` list that fits the role:
- **Coder**: implements the planner's briefs inside the repo and runs the existing tests before reporting back.
- **Reviewer**: read-only (`tools: Read, Grep, Glob, Bash`); reviews changes for bugs and unclear code and reports findings with file and line, without editing.
- **Tester**: writes and runs tests; changes only test files and test setup, and reports failures to the planner instead of fixing product code.
## 5. Finish
- List the files you wrote.
- Tell the user how to start: `claude --agent <name>` talks to one agent, and with a lead, `claude --agent <lead-name>` runs the lead as the main session.
- Don't change `CLAUDE.md`, settings or any other file.
Set up CLAUDE.md
Set Up CLAUDE.md… (CLAUDE.md row, or Mantri: Set Up CLAUDE.md… in the command palette) copies templates/setup-claude-md/SKILL.md to <workspace>/.claude/skills/setup-claude-md/SKILL.md and opens a terminal running claude "/setup-claude-md".
Claude reads the workspace on the user's machine (projects and stacks, branch names, the user's own commit subjects, existing CLAUDE.md files), asks five short questions about how they work, shows a draft and writes CLAUDE.md only after they confirm. Each person ends up with rules built from their own projects and answers. The extension ships no rules of its own. Run it again to update an existing CLAUDE.md.
Without the extension, copy that file into .claude/skills/setup-claude-md/ and run /setup-claude-md.
Build from source
npm run package
code --install-extension mantri-0.14.0.vsix