Skip to main content

agroute

Which agent should run this task within your live usage limits?

Read the documentation.

agroute routes delegated coding-agent tasks across Codex (codex), Claude Code (claude), and Antigravity (agy) within live subscription quota and rate-limit windows. It filters available (agent, model, effort) candidate routes, emits a howhard 2.1+ candidate inventory with provider-qualified model identities (<agent>/<model>), and resolves a howhard decision into a deterministic execution plan.

When the selected target agent matches the current host agent, agroute emits a native delegation tool directive (invoke_subagent, Agent, or spawn_agent). When the target agent differs from the host, agroute emits a non-interactive CLI execution plan (codex exec, claude -p, or agy -p). agroute never spawns worker processes itself; selection, outcome observation, execution accounting, and writable semantic memory remain in howhard.

Quickstart

You need Python 3.11+, a POSIX shell, Git, howhard 2.1.0+ and a current Codex, Claude Code or Antigravity client with native plugin support.

Install the Python backend from PyPI in your project directory:

python3 -m venv .venv-agroute
. .venv-agroute/bin/activate
python -m pip install "agroute==0.2.0" "howhard>=2.1.0"
agroute --version

Expect agroute 0.2.0. Keep the environment active and start your agent from the same shell so it can find agroute and howhard. An existing GUI session may need the absolute path to .venv-agroute/bin/agroute in your project.

Install the native plugin for your host:

# Codex
codex plugin marketplace add xu-hao/agroute
codex plugin add agroute@agroute
# Claude Code
claude plugin marketplace add xu-hao/agroute
claude plugin install agroute@agroute
# Antigravity
agy plugin install https://github.com/xu-hao/agroute
agy plugin list

The plugin supplies the agroute routing skill. Backend and plugin updates are separate; the native installation guide covers scopes and lifecycle commands.

Ask your coordinating agent to use agroute and howhard on a real, authorized task before starting a worker:

Use agroute and howhard to choose the target agent, model and reasoning effort for this task within live usage limits. Inspect or refresh quota state, emit eligible candidates, obtain an independent baseline and consult memory in howhard, resolve the execution plan, execute with the host's native delegation tool or cross-agent CLI, then record the actual outcome and measured usage and update memory.

Invoke the skill explicitly with $agroute or /skills in Codex, /agroute:agroute in Claude Code, or /agroute in Antigravity.

To require agroute and howhard before worker delegation across sessions, paste this into your repository's AGENTS.md or CLAUDE.md (see requiring agroute before delegation):

Before delegating an authorized task to a worker, use the installed agroute and howhard
skills:
1. Inspect or refresh live agent quota state with `agroute usage`.
2. Emit eligible provider-qualified candidates for this host with
   `agroute candidates --host <codex|claude|agy> --output /tmp/TASK-candidates.json --json`.
3. Select a route with `howhard` (`context`/`retrieve`/`decide` with an independent
   stateless baseline forecast, or `pick`), then resolve the execution plan with
   `agroute plan --host <codex|claude|agy> --decision /tmp/TASK-decision.json --json`.
4. Honor `needs_review`. Execute native plans (`target_agent == host_agent`) with the
   host's native subagent tool and cross-agent plans (`target_agent != host_agent`) with
   the returned non-interactive CLI command.
5. Record the actual outcome and measured usage in `howhard` following the plan's
   `feedback` block (`matched_receipt` or `raw_native`), then update `howhard` memory.

The complete quickstart walks through quota inspection, candidate emission, execution-plan resolution, feedback and memory learning. If all candidate routes are exhausted or a required execution control is unavailable, agroute refuses selection explicitly.

Inspect local state, discovered models, effective quota windows, eligible candidate routes, and realtime routing decisions with:

agroute paths --json
agroute models --json
agroute usage show --json
agroute candidates --host agy --json
agroute list
agroute show <id>
agroute tui

agroute ships with no hardcoded model list in its packaged defaults: unless native_candidates or cli_candidates are explicitly pinned in configuration, agroute automatically discovers the live available models and supported reasoning efforts from the locally installed agents (~/.codex/models_cache.json for Codex, ~/.claude/cache/model-catalog/ for Claude Code, and agy models for Antigravity).

The routing and storage contracts and configuration guide describe the CLI/API, live model discovery, native versus CLI candidate surfaces, host_affinity_epsilon, [inventories] generation for howhard.toml, and the realtime model-route TUI. Contributors use isolated worktrees and the documentation-only exemption.

Metadata

Release files for agroute 0.2.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for agroute 0.2.1
File Size Uploaded Provenance Actions
agroute-0.2.1.tar.gz 85.0 kB Without provenance Details for agroute-0.2.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for agroute 0.2.1
File Interpreter ABI Platform Actions
agroute-0.2.1-py3-none-any.whl Python 3 none any Details for agroute-0.2.1-py3-none-any.whl

Total release size: 138.8 kB

Release files / agroute-0.2.1.tar.gz

Download URL agroute-0.2.1.tar.gz
Size 85.0 kB
Tags Source
SHA-256 checksum
How to use checksums
6dbe9aaba1df8ca0284a165bdd2fc37beaf4746f0ae86523943b4d9366119398
BLAKE2b-256 checksum
How to use checksums
71e012414bfbed1a9c4d6e86765691514673d7a8cab5d01d575656e431692fd2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.5

Release files / agroute-0.2.1-py3-none-any.whl

Download URL agroute-0.2.1-py3-none-any.whl
Size 53.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
f6106d72068ddf4ef2e68827733bade2011fca079f127cd9fa579848847d38cd
BLAKE2b-256 checksum
How to use checksums
0be6d1995ce9a3327ee332fbc1ed356b27f415390d37038e3e1b051d89bb0197
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.5

Security for agroute 0.2.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page