Repository navigation
feat(router)!: update the bundled routing tables to schema version 2 - #11198
Conversation
Replace the six routing tables in containers/router/routing/ with newly trained tables, and adopt routing-table schema version 2, which replaces the explain task type with analyze and review (240 label cells instead of 210). - Publish schemas/routing-table.v2.schema.json; v1 stays frozen. The loader now accepts only schema_version 2. - Classifier labels, the classification contract, the heuristic labels and the api-proxy's classifier-output schema use the new task types. - Bump the router to 0.3.0. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
|
🚀 Security Guard has started processing this pull request |
There was a problem hiding this comment.
🟡 Changes recommended
Routing smoke tests still reference removed models and fail with 422 no_route, while classification rule ordering can bypass the balanced fallback for unintelligible requests.
2 open issues
What changed in this PR
Migrates AWF’s router to routing-table schema v2 and release 0.3.0, keeping the router and API proxy aligned on the new task labels.
Changes:
- Adds the frozen v2 schema and updates table loading for 240 label cells.
- Replaces
explainwithanalyzeandreview, and revises classifier guidance. - Synchronizes version metadata, documentation, tests and contract fixtures.
| File | Description |
|---|---|
containers/router/testdata/routing-contract/errors.json |
Updates accepted task types in error expectations. |
containers/router/testdata/routing-contract/discovery.json |
Expects router version 0.3.0. |
containers/router/testdata/routing-contract/classify-response.json |
Refreshes the classifier prompt fixture. |
containers/router/testdata/parity/labels.json |
Changes explanation expectations to analyze. |
containers/router/testdata/parity/classification.json |
Synchronizes classification-contract text. |
containers/router/table.go |
Accepts schema version 2 instead of 1. |
containers/router/table_test.go |
Updates version checks and cell-count expectations. |
containers/router/serve_test.go |
Updates logged cell and model counts. |
containers/router/schemas/routing-table.v2.schema.json |
Defines the v2 table format and task labels. |
containers/router/schema_test.go |
Pins the v2 schema hash and checks runtime alignment. |
containers/router/route_test.go |
Uses new labels and table-provided classifier ordering. |
containers/router/README.md |
Documents v2 support and migration incompatibility. |
containers/router/openapi.yaml |
Updates API version and task-type enumeration. |
containers/router/main.go |
Bumps the router release version. |
containers/router/heuristics.go |
Maps existing explanation cues to analyze. |
containers/router/heuristics_test.go |
Updates heuristic label expectations. |
containers/router/Dockerfile |
Bumps container version metadata. |
containers/router/contract.go |
Defines analyze and review task types. |
containers/router/cli_test.go |
Updates validation-summary counts. |
containers/router/classify.go |
Revises classifier guidance and classifier-request labels. |
containers/api-proxy/routing-controller.test.js |
Uses analyze in classifier-response coverage. |
containers/api-proxy/routing-contract.test.js |
Tests new labels and rejection of explain. |
containers/api-proxy/routing-contract.js |
Aligns classifier-output validation with v2 labels. |
containers/api-proxy/fixtures/routing-contract/cases.json |
Synchronizes the proxy’s classifier-prompt fixture. |
Review effort: Max (auto)
|
@copilot merge main, resolve conflicts, and address all review feedback |
Co-authored-by: lpcox <15877973+lpcox@users.noreply.github.com>
The new routing tables drop github-copilot/claude-haiku-4.5 and openai/gpt-5.4, so the routed smoke steps that offered only them would get no_route. Use claude-haiku-5.5 for the routed Copilot steps and openai/gpt-5.6-luna for the native OpenAI job. Every model in the new catalogue has reasoning efforts, so the two-candidate step now sends the routed effort for either model, and low for the model it deviates to. The cross-endpoint step doesn't route and keeps claude-haiku-4.5. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
|
✅ Copilot review passed with no inline comments. @rabeckett Add the |
Co-authored-by: lpcox <15877973+lpcox@users.noreply.github.com>
No further changes are needed: |
…outer-tables-2026-11-06 # Conflicts: # .github/workflows/test-model-routing.yml Co-authored-by: lpcox <15877973+lpcox@users.noreply.github.com>
✅ Coverage Check PassedOverall Coverage
📁 Per-file Coverage Changes (1 files)
Coverage comparison generated by |
Move "unknown = no intelligible request." back after the mode rules, where it is on every other axis, and drop the test that pinned it first. The contract is used exactly as it was evaluated, and in that evaluation unintelligible requests got unknown for mode on every call, so the reordering changed a tested prompt without re-testing it. The review thread on classify.go has the details. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
|
8115315 restores the classification contract to the evaluated text and removes the test that pinned |
|
✅ Security Guard completed successfully! Security GuardOutcome: The agent completed and reported no action. A no-op output alone does not verify that all required work was completed or that publication was possible. Agent messages are omitted from this comment. The category uses structured run status, not interpretation of agent prose.
|
|
✨ The prophecy is fulfilled... Smoke Codex has completed its mystical journey. The stars align. 🌟
|
|
🪪 Smoke Copilot BYOK AOAI (Entra) is testing Azure OpenAI BYOK (Entra / GitHub OIDC) mode on this pull request... |
|
✅ Smoke Copilot BYOK completed. Copilot BYOK mode operational. 🔓
|
|
📰 VERDICT: Smoke Copilot has concluded. All systems operational. This is a developing story. 🎤
|
|
✅ Smoke Claude passed
|
|
Smoke test: FAIL
|
Smoke Claude Results
Overall result: PASS
|
|
Cloud Hypervisor + Copilot smoke test
Overall: PASS
|
|
EGRESS_RESULT allow=pass deny=pass
Overall: PASS — @rabeckett
|
🏗️ Build Test Suite Results
Overall: 7/8 ecosystems passed — FAIL Java failure details:
.NET note: the first attempt crashed because
|
Smoke Test: Copilot BYOK (Direct) Mode ✅
Mode: Direct BYOK (COPILOT_PROVIDER_API_KEY) via api-proxy → api.githubcopilot.com Status: PASS
|
|
chore: refresh canonical model sources
|
|
Smoke Copilot: PRs: "feat(router)!: update the bundled routing tables to schema version 2"
Overall: PASS — @rabeckett
|
Chroot Version Comparison
Result: Not all tests passed (Node.js mismatch), so the
|


Closes #11197
Replaces the six routing tables in
containers/router/routing/with newly trained tables in routing-table schema version 2, and bumps the router version to 0.3.0 because the table format and the HTTP contract change.Schema version 2
schemas/routing-table.v2.schema.json, which is version 1 with only the version, the label pattern and the cell count changed. Version 1 stays frozen and pinned. The loader accepts onlyschema_version2.explaintask type withanalyzeandreviewincontract.go,openapi.yamland the api-proxy's classifier-output schema inrouting-contract.js.ClassificationContractwith a new classification contract. It defines the version 2 task types, revises the guidance for scope, complexity and mode, and adds guidance for long agentic-workflow prompts.SystemPrompt, the output shape and the mode values are unchanged.ClassificationLabelsis nowanalyze/local/trivial.analyzeinstead ofexplain. The cues are unchanged.TestBundledProfilesRouteAndClassifyno longer requires the classifier order to equal the balanced table's ranking of the classifier cell, because the tables now carry their own classifier order. Loading still requires every table to share it.Fixture changes
testdata/parity/labels.json: the 69 expectations that wereexplainare nowanalyze. No other expectation changes.testdata/parity/classification.json,testdata/routing-contract/classify-response.jsonand the api-proxy's copy infixtures/routing-contract/cases.json: the new contract text. The conversation data is unchanged.testdata/routing-contract/errors.json: the recorded detail lists the new task types.Smoke workflow
test-model-routing.ymloffered models that these tables no longer rank. The routed Copilot steps now useclaude-haiku-5.5instead ofclaude-haiku-4.5, and the native OpenAI job usesopenai/gpt-5.6-lunainstead ofopenai/gpt-5.4. Every model in the new catalogue has reasoning efforts, so the two-candidate step sends the routed effort for the selected model andlowfor the model it deviates to. The cross-endpoint step doesn't route and is unchanged.Models added
Models removed
Testing
gofmt -l .,go vet ./...andgo test ./...incontainers/router.linux/arm64image (GH_AW_ROUTER_TEST_IMAGE=... go test -run '^TestContainer' .).npx jestincontainers/api-proxy. On Windows, 23 tests fail onmainas well (symlinks and POSIX file permissions); no other test fails./healthz,/capabilities,/classifyand/routefor all six profiles. A live classifier call on the/classifyplan returned version 2 labels, which the api-proxy's validation accepted and the router routed.