Skip to content

Conversation

@jamesrochabrun
Copy link
Owner

Groq

Screenshot 2024-10-11 at 11 49 04 PM

Groq API is mostly compatible with OpenAI's client libraries like SwiftOpenAI to use Groq using this library you just need to create an instance of OpenAIService like this:

let apiKey = "your_api_key"
let service = OpenAIServiceFactory.service(apiKey: apiKey, overrideBaseURL: "https://api.groq.com/", proxyPath: "openai")

For Supported API's using Groq visit its documentation.

⚠️ Note: You can probably use the OpenAIServiceFactory.service(apiKey:overrideBaseURL:proxyPath) for any OpenAI compatible service.

@jamesrochabrun jamesrochabrun merged commit 2e74797 into main Oct 12, 2024
@jamesrochabrun jamesrochabrun deleted the jroch-path-updates branch October 12, 2024 06:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant