Repository navigation
Multi Agent Routing
Run as many agents as you like on one daemon. There is no seat cap: each agent that asks for work gets the work that fits it, another agent reviews it, and the reviewer merges what it approves. The rules are deterministic, with no model involved.
av init --for claude --for codex --for grok --for gemini --for cursor
# What each agent is good at, and what it costs (1 is the cheapest)
av agent set claude --best code,tests --can docs --cost 4
av agent set grok --best docs,review --can code,tests --cost 2
av agent set cursor --best code --can tests,ui,docs --cost 3 --max-open 2
# Post work to the shared backlog
av post --repo myrepo --title "Redraw the logo" --goal "..." --needs image
av post --repo myrepo --title "Use the new logo" --goal "..." --after redraw-the-logo
av backlog
# Start each agent only when something fits it
av --agent claude watch -- claude
av --agent grok watch --every 30 -- grok -p "take your next av job"Each agent CLI runs the work on its own subscription. Scholion holds no keys for the agents' models, and the daemon never launches processes; av watch does, on your machine.
- An agent can take an item when every tag it
--needsis in the agent'sbestorcan. - The best-fitting agent (the item's
--prefer, then mostbesttags, then cheapest) has it to itself for--reserveseconds (default 600). After that, any agent that can do it may take it, so work moves on when an agent runs out of quota. - Untagged work goes to the cheapest agent.
- An item posted with
--after ITEM[,ITEM]is not offered until every listed item has merged;av backlogshows it aswaiting on ….
av next (or the MCP tool start_task with no title or goal) closes the loop. It offers, in order:
- Reviews of other agents' submitted work. An agent never reviews its own task, and reviews work it could have done (unless only the owner could, in which case anyone else may). A review offered to one agent is reserved for it for 10 minutes. An approved task is offered as "merge it".
- Its own conflicted tasks: an approved task whose merge conflicted comes back to its owner with instructions (sync onto main, resolve, re-check, resubmit). If the owner does not act within the lease, any fitting agent may claim it.
- Handoffs (an untagged handoff keeps its item's tags).
- Abandoned tasks whose owner went quiet for a whole lease (the owner may resume its own).
- Backlog items.
Options:
-
--wait N(MCPwait, at most 50 s) holds the call until something fits. -
--take review,merge,workkeeps only those kinds of job, so a review-only agent is never given backlog work and a worker is never reserved others' reviews. - A dry run says what it would give without taking it. That is what
av watchpolls.
Each agent CLI is treated as an engineering team: Scholion gives it work, has another team review it and keeps the shared memory, while the CLI splits the work among its own subagents. Those subagents carry the team's name, so a team never reviews its own work. Post items the size of a team's job (a goal with a definition of done), not single steps.
--max-open N caps how many open tasks a team holds at once (tasks in review do not count). At the cap, next gives it only reviews, merges and its own abandoned tasks, so one team running many subagents cannot take the whole backlog.
av handoff --done "..." --remaining "..." --needs imageOnly an agent with the image tag is offered the rest.
http://localhost:7420/ui shows tasks by status, a Teams panel (skills, cost, open tasks against the limit), the backlog and who each item is reserved for, a live activity feed, and each task's records, changed files, claim and review state. "Build context pack" shows exactly what the next agent would receive.
-
examples/routing-smoke/setup.shsets up a sample project with profiles and a tagged backlog for real agents. -
examples/routing-smoke/deepseek-demo.shruns two Claude Code agents on DeepSeek Flash through the whole loop on its own daemon, for about $0.03. It shows the loop working, not token savings.
Scholion is MIT-licensed. The README in the repository is the reference; where this wiki and the code disagree, the code wins.