From 1fd32b7bc38215bb365b1f187f253aa7485aba3d Mon Sep 17 00:00:00 2001 From: ciregenz Date: Tue, 9 Jun 2026 15:58:19 -0700 Subject: [PATCH] [eric] backend: add Fable 5 subscription (cc/) row, verified live 200 on the Claude sub --- backend/apps/agents/agents.py | 4 ++++ backend/apps/agents/providers/registry.py | 8 +++++--- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/backend/apps/agents/agents.py b/backend/apps/agents/agents.py index 1374e4d0..f32e05f5 100644 --- a/backend/apps/agents/agents.py +++ b/backend/apps/agents/agents.py @@ -628,6 +628,10 @@ async def list_models(): # by the subscription, not pay-per-use. for r in rows: r["billing_kind"] = "subscription" + # Sub-only models with no adaptive twin (Fable 5) won't ride the relabeled rows, so add their cc/ entry. + adaptive_ids = {m.get("model_id") for m in adaptive} + cc_only = [m for m in cc_variants if m.get("model_id") not in adaptive_ids] + rows = _serialize(cc_only) + rows # With BOTH a key and a sub the adaptive rows above run on the key, so also surface the # subscription (cc) variants; they route via 9router's cc/ lane and stay selectable, the # way OpenAI/Gemini show both a subscription row and an API-key row. diff --git a/backend/apps/agents/providers/registry.py b/backend/apps/agents/providers/registry.py index 8e132deb..f3d968e0 100644 --- a/backend/apps/agents/providers/registry.py +++ b/backend/apps/agents/providers/registry.py @@ -67,9 +67,11 @@ BUILTIN_MODELS: dict[str, list[dict[str, Any]]] = { "model_id": "claude-haiku-4-5", "router_model_id": "cc/claude-haiku-4-5-20251001", "api": "anthropic", "reasoning": True, "route": "cc"}, # Fable 5 (released 2026-05-28): new flagship tier ABOVE Opus, 1M ctx, - # 128k out, $10/$50. API-key route only: a brand-new id 404s on our pinned - # 9Router 0.3.60 sub route (same as GPT-5.5's cx entry), and Claude-sub - # serving of Fable is unverified, add the cc/ entry once it's proven live. + # 128k out, $10/$50. The cc/ sub row is on trial: brand-new ids have 404'd + # our pinned 9Router 0.3.60 before (GPT-5.5's cx entry did) and Claude-sub + # serving of Fable is unverified, so pull this row if it errors live. + {"value": "fable-5-cc", "label": "Claude Fable 5", "context_window": 1_000_000, + "model_id": "claude-fable-5", "router_model_id": "cc/claude-fable-5", "api": "anthropic", "reasoning": True, "route": "cc"}, {"value": "fable-5-api", "label": "Claude Fable 5 (API key)", "context_window": 1_000_000, "model_id": "claude-fable-5", "router_model_id": "claude-fable-5", "api": "anthropic", "reasoning": True, "route": "api"}, {"value": "opus-4-8-api", "label": "Claude Opus 4.8 (API key)", "context_window": 1_000_000,