authoravatarclover caruso<git@paperclover.net>2026-10-20 02:45:44-07:00
committeravatarclover caruso<git@paperclover.net>2026-10-21 02:52:29-07:00
log0fa203ae84d258b3be1dceeb06e8d8b39c2bb957
tree0ddfeda3e535229b2d1e5c2cf8b61d6a785faa4d
parente8cd1a11eb7145e44b519fac430b643512b4a52b
signature Signed by SSH key SHA256:52mNGHRsVFBDED9IAX5pe+LRWUefqTbxEReunq21QvU

Expose disabled reasoning through the provider schema

Use the revised schema’s none effort for Golden Gate and Owl directly from the catalog. Remove the Codex escape hatch and its special-case branch. Verified gateway tests and schema constraints, with an isolated browser preview. Assisted-by: gpt-6.1-sol

2 files changed, 6 insertions(+), 13 deletions(-)

service/local-ai/gateway.py+3-10
......@@ -26,9 +26,6 @@ def agent_provider():
2626 models = []
2727 for entry in catalog:
2828 model = {**base, **entry}
29 reasoning = {"summaries": model["supports_reasoning_summary_parameter"]}
30 if model["default_reasoning_level"] != "none":
31 reasoning.update(levels=model["supported_reasoning_levels"], default=model["default_reasoning_level"])
3229 models.append({
3330 "id": model["slug"], "name": model["display_name"], "description": model["description"],
3431 "hidden": model["visibility"] != "list",
......@@ -36,17 +33,13 @@ def agent_provider():
3633 "effectiveContextWindowPercent": model["effective_context_window_percent"],
3734 "autoCompactTokenLimit": model["auto_compact_token_limit"],
3835 "inputModalities": model["input_modalities"],
39 "reasoning": reasoning,
36 "reasoning": {"levels": model["supported_reasoning_levels"],
37 "default": model["default_reasoning_level"],
38 "summaries": model["supports_reasoning_summary_parameter"]},
4039 "tools": {"applyPatch": model["apply_patch_tool_type"], "shell": model["shell_type"],
4140 "webSearch": model["supports_search_tool"], "mode": model["tool_mode"]},
4241 "truncation": model["truncation_policy"], "verbosity": model["support_verbosity"],
4342 })
44 if model["default_reasoning_level"] == "none":
45 # The discovery effort enum excludes the harness's "none" value.
46 models[-1]["harnessOverrides"] = {"codex": {"catalogEntry": {
47 "default_reasoning_level": "none",
48 "supported_reasoning_levels": model["supported_reasoning_levels"],
49 }}}
5043 return {
5144 "version": 1, "name": "Snow Globe", "icon": {"emoji": "❄️", "color": "teal"},
5245 "harness": "codex", "harnesses": ["codex", "claude"],
service/local-ai/test_gateway.py+3-3
......@@ -52,9 +52,9 @@ class ResponsesCompatibility(unittest.TestCase):
5252 self.assertEqual(model["inputModalities"], ["text", "image"])
5353 self.assertEqual([level["effort"] for level in provider["models"][0]["reasoning"]["levels"]], ["low", "medium", "xhigh"])
5454 for model in provider["models"][1:]:
55 self.assertNotIn("default", model["reasoning"])
56 self.assertNotIn("levels", model["reasoning"])
57 self.assertEqual(model["harnessOverrides"]["codex"]["catalogEntry"]["default_reasoning_level"], "none")
55 self.assertEqual(model["reasoning"]["default"], "none")
56 self.assertEqual(model["reasoning"]["levels"], [{"effort": "none", "description": "No reasoning"}])
57 self.assertNotIn("harnessOverrides", model)
5858
5959 def test_unsupported_inference_routes_never_reach_backend(self):
6060 server = ThreadingHTTPServer(("127.0.0.1", 0), Handler)