ADR-240 D1+D2: BackendRaceChain + CostAwareRouter (dual-provider autonomy) v0.78.0#224
Merged
Merged
Conversation
…nomy) v0.78.0 Public release of the two new multi-provider primitives (merged private #266). Everything else for dual-provider use already ships in the SDK (fallback, parallel BackendPool, debate); these are the only 2 gaps. - graqle/backends/race.py BackendRaceChain(BaseBackend): first-to-finish (asyncio.wait FIRST_COMPLETED, cancel losers) or best-of-N (scorer, deterministic). Drop-in ModelBackend, mirrors BackendFallbackChain. - graqle/routing.py CostAwareRouter + Difficulty: auto-select cheapest backend meeting task difficulty (SIMPLE→cheapest, HARD→strongest); provider-agnostic (relative cost); TaskRouter untouched (stays advisory). Generic asyncio/cost primitives — NO patented debate/clearance machinery (those stay private, D4). Additive, backward-compatible. 13 new + 156 backends+routing tests pass. Version 0.77.0 → 0.78.0. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
🛡️ GraQle PR Guardian💥 Blast Radius: 6 modules affected
Total blast radius: 6 🏛️ Governance Verdict
|
| Metric | Value |
|---|---|
| Blast Radius | 6 |
| Files Analyzed | 6 |
| Blocked | 0 |
| SHACL Violations | 0 |
| Verdict | WARN |
🔬 Powered by GraQle PR Guardian v0.1.0 · Scan completed 2026-07-08T13:43:08.200420+00:00
harishquantamix
approved these changes
Jul 8, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Public release of the 2 new multi-provider primitives (merged private #266)
The SDK already ships fallback, parallel BackendPool, and debate for multi-provider use. These are the only 2 gaps — both generic, IP-clean (the patented debate/clearance machinery stays private).
graqle/backends/race.pyBackendRaceChain — first-to-finish (asyncio.wait FIRST_COMPLETED, cancel losers) or best-of-N. Drop-inModelBackend, mirrorsBackendFallbackChain.graqle/routing.pyCostAwareRouter +Difficulty— auto-select cheapest backend meeting task difficulty.TaskRouteruntouched (advisory).IP: generic asyncio/cost patterns — NO debate/clearance imports. Sentinel confirmed clean.
Tests: 13 new + 156 backends+routing pass, 0 regression. Version 0.77.0 → 0.78.0.
Merge → publish: on merge, tag
v0.78.0on public master → PyPI trusted publishing (same as v0.77.0). Note: the 'Release Gate (PyPI)' required check is the known false-failing CI-RELEASE-GATE-001 — admin-override as before.🤖 Generated with Claude Code