mirror of
https://github.com/jeffusion/gitea-ai-assistant.git
synced 2026-06-06 23:16:49 +00:00
refactor(ui): use tokenlens as sole model source, remove provider listModels
Remove the per-provider listModels API (GET /providers/:id/models) and all four provider implementations (OpenAI Compatible, OpenAI Responses, Anthropic, Gemini). ModelCombobox now only shows tokenlens suggestions (tagged '推荐') plus free-form custom input — no more unfiltered 'API' models from provider SDKs. Fixes: switching provider type in ProviderDialog no longer shows stale models from the original provider's API. Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode)
This commit is contained in:
@@ -134,7 +134,6 @@ function ProviderDialogInner({ onOpenChange, provider }: Omit<ProviderDialogProp
|
||||
<div className="space-y-2">
|
||||
<Label htmlFor="defaultModel">默认模型 <span className="text-red-500">*</span></Label>
|
||||
<ModelCombobox
|
||||
providerId={provider?.hasKey ? provider.id : null}
|
||||
providerType={type}
|
||||
value={defaultModel}
|
||||
onChange={setDefaultModel}
|
||||
|
||||
Reference in New Issue
Block a user