mirror of
https://github.com/Routstr/routstr-core.git
synced 2026-08-11 11:47:50 +00:00
The failover loop resolved a single Model for the request and reused it for every provider: a fallback provider was asked to serve the routing winner's model id and billed at the winner's pricing and fee. The alias map now keeps (model, provider) candidate pairs, the proxy rebinds both per attempt, and forwarding, max-cost echo, and settlement all use the candidate actually being tried. On a failover serve the response's model field now names the serving candidate's id. The unified candidate lookup also applies the version-suffix strip (-YYYYMMDD) that model resolution already had, so version-suffixed requests no longer resolve a model yet 400 with "no provider found". Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>