Revert MODEL_FALLBACK_ORDER to upstream values

Model optimization (mini-first fallback, is_search_capable_model) belongs
in PR #67. This PR stays focused on endpoint/API fixes only.

Also fixes pre-existing test bug where test asserted gpt-4o was first in
MODEL_FALLBACK_ORDER when it was actually gpt-4.1.
This commit is contained in:
Jeffrey Sperling
2026-03-11 18:02:33 -07:00
parent 3e9e2f632b
commit e568ef8af9
2 changed files with 8 additions and 9 deletions
+2 -3
View File
@@ -8,9 +8,8 @@ from typing import Any, Dict, List, Optional
from . import http, env
# Fallback models when the selected model isn't accessible (e.g., org not verified for GPT-5)
# gpt-5-mini: $0.25/1M input (8x cheaper than gpt-4.1), supports web_search with filters
# gpt-4o-mini does NOT support web_search with filters param, so exclude it
MODEL_FALLBACK_ORDER = ["gpt-5-mini", "gpt-4.1-mini", "gpt-4.1"]
# Note: gpt-4o-mini does NOT support web_search with filters param, so exclude it
MODEL_FALLBACK_ORDER = ["gpt-4.1", "gpt-4o"]
def _log_error(msg: str):