lewtun HF Staff OpenAI Codex commited on
Commit
13ff73d
·
unverified ·
1 Parent(s): aade9ae

Remove unused model provider metadata (#330)

Browse files

Co-authored-by: OpenAI Codex <codex@openai.com>

backend/routes/agent.py CHANGED
@@ -122,33 +122,27 @@ def _available_models() -> list[dict[str, Any]]:
122
  {
123
  "id": DEFAULT_OPUS_MODEL_ID,
124
  "label": "Claude Opus 4.8",
125
- "provider": "huggingface",
126
  "recommended": True,
127
  },
128
  {
129
  "id": DEFAULT_GPT_MODEL_ID,
130
  "label": "GPT-5.5",
131
- "provider": "huggingface",
132
  },
133
  {
134
  "id": KIMI_K27_CODE_MODEL_ID,
135
  "label": "Kimi K2.7 Code",
136
- "provider": "huggingface",
137
  },
138
  {
139
  "id": MINIMAX_M3_MODEL_ID,
140
  "label": "MiniMax M3",
141
- "provider": "huggingface",
142
  },
143
  {
144
  "id": DEFAULT_FREE_MODEL_ID,
145
  "label": "GLM 5.2",
146
- "provider": "huggingface",
147
  },
148
  {
149
  "id": DEEPSEEK_V4_PRO_MODEL_ID,
150
  "label": "DeepSeek V4 Pro",
151
- "provider": "huggingface",
152
  },
153
  ]
154
  return models
 
122
  {
123
  "id": DEFAULT_OPUS_MODEL_ID,
124
  "label": "Claude Opus 4.8",
 
125
  "recommended": True,
126
  },
127
  {
128
  "id": DEFAULT_GPT_MODEL_ID,
129
  "label": "GPT-5.5",
 
130
  },
131
  {
132
  "id": KIMI_K27_CODE_MODEL_ID,
133
  "label": "Kimi K2.7 Code",
 
134
  },
135
  {
136
  "id": MINIMAX_M3_MODEL_ID,
137
  "label": "MiniMax M3",
 
138
  },
139
  {
140
  "id": DEFAULT_FREE_MODEL_ID,
141
  "label": "GLM 5.2",
 
142
  },
143
  {
144
  "id": DEEPSEEK_V4_PRO_MODEL_ID,
145
  "label": "DeepSeek V4 Pro",
 
146
  },
147
  ]
148
  return models
frontend/src/components/Chat/ChatInput.tsx CHANGED
@@ -124,7 +124,6 @@ const modelOptionId = (modelPath: string) => (
124
  const modelOptionFromApi = (model: {
125
  id?: string;
126
  label?: string;
127
- provider?: string;
128
  recommended?: boolean;
129
  }): ModelOption | null => {
130
  if (!model.id) return null;
 
124
  const modelOptionFromApi = (model: {
125
  id?: string;
126
  label?: string;
 
127
  recommended?: boolean;
128
  }): ModelOption | null => {
129
  if (!model.id) return null;
tests/unit/test_agent_model_gating.py CHANGED
@@ -27,6 +27,7 @@ def test_available_models_exclude_sonnet_and_have_no_pro_gate():
27
  assert models["moonshotai/Kimi-K2.7-Code:novita"]["label"] == "Kimi K2.7 Code"
28
  assert models["MiniMaxAI/MiniMax-M3:novita"]["label"] == "MiniMax M3"
29
  assert "recommended" not in models[agent.DEFAULT_FREE_MODEL_ID]
 
30
  assert all("minimum_plan" not in model for model in models.values())
31
  assert all("tier" not in model for model in models.values())
32
 
 
27
  assert models["moonshotai/Kimi-K2.7-Code:novita"]["label"] == "Kimi K2.7 Code"
28
  assert models["MiniMaxAI/MiniMax-M3:novita"]["label"] == "MiniMax M3"
29
  assert "recommended" not in models[agent.DEFAULT_FREE_MODEL_ID]
30
+ assert all("provider" not in model for model in models.values())
31
  assert all("minimum_plan" not in model for model in models.values())
32
  assert all("tier" not in model for model in models.values())
33