Skip to content

Commit c16eb08

Browse files
committed
remove model validation
1 parent c9f50d0 commit c16eb08

File tree

2 files changed

+1
-12
lines changed
  • apps/desktop/src/components/settings/views
  • plugins/connector/src

2 files changed

+1
-12
lines changed

apps/desktop/src/components/settings/views/ai.tsx

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -194,9 +194,6 @@ export default function LocalAI() {
194194

195195
const setCustomLLMModel = useMutation({
196196
mutationFn: (model: string) => connectorCommands.setCustomLlmModel(model),
197-
onSuccess: () => {
198-
customLLMModels.refetch();
199-
},
200197
});
201198

202199
const setCustomLLMConnection = useMutation({
@@ -212,11 +209,6 @@ export default function LocalAI() {
212209
queryFn: () => connectorCommands.getCustomLlmEnabled(),
213210
});
214211

215-
const customLLMModels = useQuery({
216-
queryKey: ["custom-llm-models"],
217-
queryFn: () => connectorCommands.listCustomLlmModels(),
218-
});
219-
220212
const setCustomLLMEnabled = useMutation({
221213
mutationFn: (enabled: boolean) => connectorCommands.setCustomLlmEnabled(enabled),
222214
onSuccess: () => {

plugins/connector/src/ext.rs

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -157,10 +157,7 @@ impl<R: tauri::Runtime, T: tauri::Manager<R>> ConnectorPluginExt<R> for T {
157157
.flatten();
158158

159159
let conn = ConnectionLLM::Custom(Connection { api_base, api_key });
160-
match conn.models().await {
161-
Ok(models) if !models.is_empty() => Ok(conn),
162-
_ => Err(crate::Error::NoModelsFound),
163-
}
160+
Ok(conn)
164161
} else {
165162
self.get_local_llm_connection().await
166163
}

0 commit comments

Comments
 (0)