Skip to content

v0.3.0

Choose a tag to compare

@bikemeardsley bikemeardsley released this 23 Oct 21:13
· 28 commits to main since this release

Route mode: agent clients on a collection

A panel's several answers can't drive an agent's tool loop, so a collection now has a third reply mode beside all and merged: route. Ask for bench/<collection>:route, or set it as the collection's reply.

  • One member answers each turn, picked by its record (useful verdicts, then suite findings). One new conversation in four goes to the member heard from least, so the record doesn't narrow to one model. Members cooling down after a rate limit go last.
  • Tools, streaming and images pass through. OpenAI chat relays the upstream stream exactly. Anthropic Messages, OpenAI Responses (including Codex-style custom tools), Gemini and Ollama translate tool definitions, calls and results both ways.
  • Sticky: a conversation stays on the model that started it, held for an hour idle, so an agent isn't switched mid-task.
  • Failover: a 429, a 5xx, a pacing refusal, no first token within 90 s, or an empty reply moves the turn to the next member before anything reaches the client.
  • Recording: every call goes in the usage ledger, and each conversation is one record per model that answered it, with a verdict optional. Route conversations get their own table on the Gateway card and don't count toward Owed.
  • Skipped, with the reason given: retired and ad hoc members; members that can't call tools when the request has tools, or can't see when it has images; vision specialists on a turn without images; and members whose window is too small.
  • Panels still refuse tools; the 400 now points to :route.

Claude Code, tested end to end:

export ANTHROPIC_BASE_URL=http://127.0.0.1:8122
export ANTHROPIC_API_KEY=<a gateway key, or any text on this machine>
export ANTHROPIC_MODEL=bench/core:route
export ANTHROPIC_DEFAULT_HAIKU_MODEL=bench/fast:route

GATEWAY.md also covers Codex and other Responses clients, opencode, and OpenAI- or Ollama-speaking agents. Those are documented but not yet tested against the real clients.

Native Anthropic and Gemini endpoints

An endpoint can now declare api: "anthropic" or api: "gemini" (a new API choice in the Add endpoint dialog). The built-in client speaks that API natively: its key header, its stream, its usage and its errors, with pacing, quota records and the ledger as for any endpoint. No new dependency: this replaces the plan's aisuite backend. So far it has been checked against fake servers only.

Also

  • Every collection is listed in all three modes on /v1/models, /api/tags and /v1beta/models, so agents' model pickers can choose :route.
  • An output budget above a model's known maximum is cut to it (Claude Code asks every model for 32,000 tokens).

Known limits: route mode doesn't send turns to members on native or Responses endpoints yet, and the capability probe records tool and reasoning support as unknown for native-API models.