improves interoperability of model providers, local and remote providers can be used together seemlessly

This commit is contained in:
geoffsee
2025-06-09 13:54:37 -04:00
committed by Geoff Seemueller
parent ad7dc5c0a6
commit f29bb6779c
14 changed files with 526 additions and 234 deletions

View File

@@ -7,11 +7,12 @@ import {
UnionStringArray,
} from "mobx-state-tree";
import { BaseChatProvider, CommonProviderParams } from "./chat-stream-provider.ts";
import {ProviderRepository} from "./_ProviderRepository";
export class GroqChatProvider extends BaseChatProvider {
getOpenAIClient(param: CommonProviderParams): OpenAI {
return new OpenAI({
baseURL: "https://api.groq.com/openai/v1",
baseURL: ProviderRepository.OPENAI_COMPAT_ENDPOINTS.groq,
apiKey: param.env.GROQ_API_KEY,
});
}