feat: add CAMB AI API compatibility layer#8753
Conversation
✅ Deploy Preview for localai ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
Add CAMB AI-compatible API endpoints to LocalAI, enabling apps using the CAMB AI SDK/API to use LocalAI as a drop-in local replacement. Follows the existing ElevenLabs integration pattern (schema structs, endpoint handlers, route registration). Includes e2e tests covering all endpoints via the mock backend.
Tested against the real camb-sdk Python package. Fixes: - list-voices returns flat array (SDK expects list, not wrapped object) - text-to-sound returns task_id JSON (SDK expects OrchestratorPipelineCallResult) - translated-tts returns task_id JSON (SDK expects CreateTranslatedTtsOut) - translation/stream returns JSON (SDK parses response as JSON) - transcribe accepts media_url form field without requiring file upload
4851502 to
733d573
Compare
|
Hello! Thank you for your contribution. Before we can proceed with this PR, we need to have a discussion about the proposed changes. LocalAI doesn't support cloud-based backends, and there was no issue opened for this feature prior to the PR. We encourage contributors to first open an issue to discuss their proposed changes with the maintainers. Could you please open an issue describing your use case and proposed implementation? Once we've had a chance to discuss and align on the direction, we can then continue reviewing this PR. Thank you for your understanding! |
|
This PR is stale because it has been open 90 days with no activity. Remove stale label or comment or this will be closed in 10 days. |
Summary
camb-sdkPython package to ensure SDK compatibilityEndpoints
/apis/tts-streamModelTTSStream/ModelTTSFLAG_TTS/apis/ttsModelTTS(async)FLAG_TTS/apis/tts/:task_id/apis/translated-ttsModelTTSFLAG_CHAT/apis/translateFLAG_CHAT/apis/translation/streamFLAG_CHAT/apis/transcribeModelTranscriptionFLAG_TRANSCRIPT/apis/text-to-soundSoundGenerationFLAG_SOUND_GENERATION/apis/list-voices/apis/create-custom-voice/apis/audio-separation