Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

[BUG] model_supports_reasoning() misses mixed-case model ids, so reasoning_effort is never sent

Aperta Adatta ai principianti
#1,607 1 commento 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
2/5
Tempo stimato
1-3 ore
Idoneità per principianti
76/100
Tipo di issue
Bug
Chiarezza
Specificata chiaramente
Stato di attività
Attiva
Stack tecnologico
python
Ambito
ai, backend

Direzione di ricerca

Inizia con _catalog_entry() e _bare_openai_name() in strix/config/models.py, poi esamina i test di model_supports_reasoning(). Verifica come vengono cercati l’ID esatto del modello e la sua forma in minuscolo in litellm.model_cost. Il lavoro è completato quando gli ID con maiuscole e minuscole miste presenti nella mappa riportano le capacità loro associate e i test coprono il supporto al ragionamento e il comportamento di ricerca correlato.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

Describe the bug
_catalog_entry() (strix/config/models.py) lowercases the model name through _bare_openai_name() before
looking it up in litellm.model_cost, and LiteLLM's map is keyed case-sensitively. A provider id with capitals
therefore misses its own entry, model_supports_reasoning() returns False, and make_model_settings() never
sends reasoning_effort. The model runs at its server default (for DeepSeek V4 Flash, thinking off) while the
run's configuration records the effort that was asked for. model_supports_images() and the Responses vs. chat
completions choice read the same lookup.

To Reproduce

import litellm
from strix.config.models import model_supports_reasoning

m = "deepinfra/deepseek-ai/DeepSeek-V4-Flash-0731"
print(m, "| in map:", m in litellm.model_cost,
      "| map says reasoning:", litellm.model_cost.get(m, {}).get("supports_reasoning"),
      "| strix says:", model_supports_reasoning(m))

mixed = [k for k, v in litellm.model_cost.items()
         if k != k.lower() and isinstance(v, dict) and v.get("supports_reasoning")]
print(len(mixed), "mixed-case reasoning ids;",
      sum(not model_supports_reasoning(k) for k in mixed), "read False")

With the litellm in Strix's own lock (1.101.0, bundled map via LITELLM_LOCAL_MODEL_COST_MAP=True) this prints
in map: True | map says reasoning: True | strix says: False, then 130 mixed-case reasoning ids; 125 read False.
With the fix described below: strix says: True, and 0 read False.

Expected behavior
An id present in the map under its exact spelling reads that entry.

System Information

  • OS: macOS 26 (Darwin 25.6)
  • Strix: 1.7.0 (run), and main @ ffa35e2 (run, with Strix's own lock). model_supports_reasoning, _catalog_entry and _bare_openai_name are
    byte-identical to 1.7.0.
  • Python: 3.12.13
  • LLM: none needed (no model call)

Additional context
I have a tested fix: try the name as given before its lowercased form, with tests (make check-all clean apart
from main's own pyright errors). Happy to open a PR if you'd like one.

Lingua principale
Python
Stelle
66.5k
Fork
7.3k
Merge medio
13h 50m
PR unite (30g)
69

Preparare l'ambiente

Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di usestrix/strix

Tutte le issue di usestrix/strix

Issue simili

Altre issue su Python

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.