Features
One command handles the whole run
Baya plans, routes, parallelizes, groups, hands off context, and recovers — coordinating the AI subscriptions and coding agents already on your machine. Here is everything it does, grouped by what it buys you.
Fits the setup you already have
No API keys, no config file, no new subscription. Baya drives the coding CLIs already installed and logged in on your machine.
- Works out of the box
- Zero config. One prompt on first run for your default provider and model, stored in ~/.config/baya/config.json, then never again.
- Multi-provider
- Routes each task to codex, claude, copilot, or opencode — whichever CLIs baya doctor finds installed and authenticated.
- No API keys
- Runs entirely under the CLI subscriptions you already pay for. Nothing new to bill, nothing new to store.
- Plain-text task lists
- Markdown, TODO.txt, YAML, or any UTF-8 text. No DSL, no schema — the planner reads whatever you already write for intent, whether a task is a one-liner or a paragraph of constraints.
- One-command upgrades
- baya upgrade updates every installed provider CLI to its latest version in one shot; baya upgrade <provider> narrows to one.
Plans and coordinates the whole run
One command turns the list into a graph, decides what runs where, and keeps independent work moving in parallel.
- LLM-planned dependency graph
- A model turns your list into a DAG of tasks and dependencies. If it can’t produce a valid graph, a deterministic splitter falls back to a linear chain in the order you wrote them.
- Model per task
- Name luna, sonnet, and friends in the task text. Baya resolves each alias to the real model id and the provider that serves it, so light steps stay cheap and hard steps get the strong model.
- Parallel execution
- Independent read-only tasks run concurrently, bounded by --max-parallel and a per-provider cap. Every read-write task takes a single writer key and runs alone, because agents sharing one tree collide on the build, not just on files.
- Preview gate
- See the full plan — every task, its provider, its resolved model, what waits for what, and what shares a process — before anything runs. --dry-run shows it and stops.
Doesn’t make you pay twice
Baya spawns as few agent processes as it can and carries forward what earlier tasks already discovered.
- One process, many tasks
- Tasks that share a provider, model, and permission level are packed into one agent process and worked through in order, so the repo is read and oriented once instead of once per task. --group-size defaults to 3.
- Cross-task memory
- What earlier tasks found — commands that worked, commands that failed, files changed — is derived from the providers’ own logs and handed to tasks that couldn’t share a process. --no-memory to start every task blind.
- Skips what you already ticked off
- A task marked [x], [done], (complete), or ✅ is read for context and never planned as work, so re-running a part-finished list doesn’t re-pay for what already landed.
Survives a failure without losing work
The run is checkpointed before every transition, so an interruption or a spent quota is a pause, not a restart.
- Checkpointed resume
- Run out of credits mid-graph and baya resume <runId> picks up where it stopped — optionally on a different provider. Succeeded tasks are kept as context and never re-run. baya runs lists what is resumable.
- Failures don’t cascade
- A failed task marks its descendants skipped, never failed — the distinction drives the exit code and the report. A quota failure halts the run cleanly instead of feeding the wall every remaining task.
- Ctrl+C actually stops
- SIGTERM to every provider’s process group, a grace window, then SIGKILL; a second Ctrl+C skips the wait. Grandchildren are reaped, not orphaned, and the same path covers SIGHUP and an uncaught crash.
Settles a question across models
Point baya consensus at a spec, a diff, or a plain question and several models review it at once. A moderator reconciles each round into a new draft; you get back what they agree on — and what they don’t. Its own command, not a mode of a run.
- Multi-provider debate
- baya consensus <file|"prompt"> fans one artifact out to several provider CLIs, then a moderator merges their findings into a new draft. Repeat until nothing blocking is left or the round ceiling hits. Not a run — no DAG, no lock, invisible to baya runs and baya resume.
- Blind, independent review
- No reviewer sees another’s findings in the same round — independence is the whole reason to pay for N CLIs. They answer each other only through the reconciled draft the next round critiques, and rivals appear under stable pseudonyms so a finding stands on its evidence, not a brand name.
- The moderator never picks the answer
- It writes the criteria, reconciles each round, and reports whether the reviewers agree — nothing it believes about the subject reaches the output. A plain question gets no criteria at all: agreement prints the first reviewer’s answer, disagreement prints every answer side by side, none marked best.
- Stops when the debate does
- --rounds is a ceiling, not a count. The run ends early when no reviewer raised a blocker or major finding, or when a round breaks no new ground the last one already fixed. Deterministic and computed by Baya, never a model’s self-assessment.
- Real code review, gated
- When settling the question needs the filesystem, reviewers get the full tool set in your working directory and can run the suite to ground a finding. A confirm gate names the blast radius first: agents run unsupervised, several at once, nothing isolating them — commit or stash before you start.
- The whole debate on disk
- Every round, every critique, and each reviewer’s append-only ledger land in .baya/consensus/<runId>/ as the round settles, so Ctrl+C on round 3 leaves rounds 1–2 complete and diffable. The report adds per-provider token spend, agreement counts, and the disagreements that never resolved.
Try it on a task list
Install the CLI, point it at any plain-text list, and approve the plan.
npm install -g baya-clibaya ./tasks.mdNew to the format? The docs walk through task lists, model routing, providers, and how a run recovers.