Swift SDK for OpenAI's Realtime API, enabling multimodal conversations
Top 81.1% on sourcepulse
This Swift SDK provides a modern, high-level interface for OpenAI's Realtime API, targeting Swift developers building applications that require multi-modal conversational AI. It simplifies the integration of features like automatic microphone recording, audio playback, and transparent API management, enabling rapid development of interactive AI experiences.
How It Works
The SDK offers two primary interaction layers: RealtimeAPI
for direct, low-level API access via WebSockets or WebRTC, and Conversation
for a managed, stateful experience. The Conversation
class abstracts away the complexities of sending/receiving messages, managing conversation history, and optionally handling audio input/output, making it easier to build features like voice-enabled chatbots.
Quick Start & Requirements
https://github.com/m1guelpf/swift-realtime-openai.git
to your Xcode project or Package.swift
.Highlighted Details
Conversation
class manages state and audio I/O.RealtimeAPI
(WebSocket/WebRTC).Maintenance & Community
The project is maintained by m1guelpf. No specific community channels or roadmap links are provided in the README.
Licensing & Compatibility
Limitations & Caveats
WebRTC support is listed as a planned feature but not yet implemented. The README indicates that direct RealtimeAPI
event sending bypasses some Conversation
class logic, suggesting preference for the higher-level interface where possible.
2 weeks ago
1+ week