Skip to content

Model routing: route Sergo #74191

Done

Description

@rabeckett

Estimated saving: about 650-1,070 AIC/week, from roughly 1,430 to 370-780 modeled AIC/week.

Use balanced: Sergo does more than report findings; it opens Go-fix PRs using the Serena language server. This adds Claude code-changing and language-server coverage. Keep validation and human PR review as the quality checks rather than choosing the cheapest mode.

Today's default is claude-sonnet-5. For likely subsystem/medium work, balanced selects claude-sonnet-5.5:high for fixes/refactoring or claude-opus-5.5:medium for planning, at about 25-54% of the modeled agent cost. Economy can choose Haiku for fixes; robust costs more than balanced for these cells.

Change

In .github/workflows/sergo.md, replace engine: claude with:

engine:
  id: claude
  model-provider: github
  model-routing:
    goal: cost
    mode: balanced

Use the existing Claude-on-Copilot authentication pattern: inference billing moves from the Anthropic key to Copilot, using COPILOT_GITHUB_TOKEN. Preserve the prompt, Serena tools, evals and safe outputs. Do not pin the predicted model or add model restrictions.

Run make recompile; include only this workflow and its matching lock file. Verify routing is enabled and generated inference authentication changes from Anthropic to Copilot.

Check

Audit initial runs with gh aw audit <run> against the roughly 205-AIC/run baseline. Check Serena tool use, fix correctness, test results and PR usefulness; successful execution alone does not establish quality.

Estimates use 19/26 October usage, 22 October routing tables and 2 November fitted cost ratios, assuming unchanged workload. Classification and org model availability can change picks. Cross-system classifications may select Opus at xhigh and eliminate the projected saving.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions