Releases: jamesrochabrun/SwiftOpenAI
SwiftOpenAI v3.9.5
What's Changed
- Updates from latest OpenAI API. by @jamesrochabrun in #104
Added reasoning_effort parameter for o1 models.
Added metadata for Chat Completions.
Model updates.
Full Changelog: v3.9.4...v3.9.5
SwiftOpenAI v3.9.4
SwiftOpenAI v3.9.3
Support for additional parameters, users now can use open router.
let service = OpenAIServiceFactory.service(
apikey: "${OPENROUTER_API_KEY}",
baseURL: "https://openrouter.ai",
proxyPath: "api"
headers: ["HTTP-Referer": "${YOUR_SITE_URL}", "X-Title": "${YOUR_SITE_NAME}")What's Changed
- Adding additional parameters in API. by @jamesrochabrun in #101
Full Changelog: v3.9.2...v3.9.3
SwiftOpenAI v3.9.2
Gemini
Gemini is now accessible from the OpenAI Library. Announcement .
SwiftOpenAI support all OpenAI endpoints, however Please refer to Gemini documentation to understand which API's are currently compatible'
Gemini is now accessible through the OpenAI Library. See the announcement here.
SwiftOpenAI supports all OpenAI endpoints. However, please refer to the Gemini documentation to understand which APIs are currently compatible."
You can instantiate a OpenAIService using your Gemini token like this...
let geminiAPIKey = "your_api_key"
let baseURL = "https://generativelanguage.googleapis.com"
let version = "v1beta"
let service = OpenAIServiceFactory.service(
apiKey: apiKey,
overrideBaseURL: baseURL,
overrideVersion: version)You can now create a chat request using the .custom model parameter and pass the model name as a string.
let parameters = ChatCompletionParameters(
messages: [.init(
role: .user,
content: content)],
model: .custom("gemini-1.5-flash"))
let stream = try await service.startStreamedChat(parameters: parameters)SwiftOpenAI v3.9.1
SwiftOpenAI v3.9.0
- Added store parameters for new Evals framework
- Added support for Chat Completions Audio generation.
What's Changed
- Chat Completions Audio generation by @jamesrochabrun in #94
Full Changelog: v3.8.2...v3.9.0
SwiftOpenAI v3.8.2
What's Changed
- Fix decoding error triggered by Assistants API responses with data from searching a vector database by @mplawley in #91
- Fixing issue 88 by @jamesrochabrun in #92
- Groq support by @jamesrochabrun in #93
New Contributors
Full Changelog: v3.8.1...v3.8.2
SwiftOpenAI v3.8.1
SwiftOpenAI v3.8.0
SwiftOpenAI v3.7.0
Fixing version issues.
What's Changed
- Remove 'some' from factory return type by @lzell in #73
- Touch up the AIProxy section of README by @lzell in #72
- Fixup sample project after removing 'some' from factory methods by @lzell in #74
- Fix for chat stream demo with function call. by @jamesrochabrun in #77
- Adding support for JsonSchema as response format. by @jamesrochabrun in #78
- Demo for structured outputs in response format. by @jamesrochabrun in #79
- Support for Structure outputs in tools by @jamesrochabrun in #80
- Updating READ.me by @jamesrochabrun in #81
Full Changelog: v3.6.2...v3.7


