feat: ollama support
This commit is contained in:
@@ -451,7 +451,7 @@ export interface ChatReadyStatus {
|
||||
ready: boolean;
|
||||
error?: string;
|
||||
backend?: string;
|
||||
providers?: { opencode: boolean; mistral: boolean };
|
||||
providers?: { opencode: boolean; mistral: boolean; ollama: boolean };
|
||||
}
|
||||
|
||||
export interface ChatApiKeyStatus {
|
||||
@@ -832,6 +832,13 @@ export interface ElectronAPI {
|
||||
setMistralApiKey: (apiKey: string) => Promise<{ success: boolean; error?: string }>;
|
||||
getMistralApiKey: () => Promise<ChatApiKeyStatus>;
|
||||
|
||||
// Ollama (local)
|
||||
getOllamaEnabled: () => Promise<boolean>;
|
||||
setOllamaEnabled: (enabled: boolean) => Promise<{ success: boolean; error?: string }>;
|
||||
getOllamaModels: () => Promise<ChatModel[]>;
|
||||
getOllamaModelCapabilities: () => Promise<Record<string, { tools: boolean; vision: boolean }>>;
|
||||
setOllamaModelCapabilities: (modelId: string, caps: { tools: boolean; vision: boolean }) => Promise<{ success: boolean; error?: string }>;
|
||||
|
||||
// Settings
|
||||
getAvailableModels: () => Promise<{ success: boolean; models?: ChatModel[]; selectedModel?: string; error?: string }>;
|
||||
setDefaultModel: (modelId: string) => Promise<{ success: boolean; error?: string }>;
|
||||
|
||||
Reference in New Issue
Block a user