Skip to content

feat(audio): list available TTS voices - #11607

Open
localai-org-maint-bot wants to merge 1 commit into
masterfrom
cron/issue-11604-tts-voices-20260819
Open

feat(audio): list available TTS voices#11607
localai-org-maint-bot wants to merge 1 commit into
masterfrom
cron/issue-11604-tts-voices-20260819

Conversation

@localai-org-maint-bot

Copy link
Copy Markdown
Collaborator

Description

Adds GET /v1/audio/voices and /audio/voices so clients can discover named voices for installed TTS models. The optional model query filters the response. The endpoint respects per-user model allowlists and resolves aliases.

Model configs can declare tts.voices entries with name, language, and gender metadata. Pocket TTS receives a built-in catalog, including pinned backend variants. The change also updates route discovery, API instructions, Swagger, authorization, configuration metadata, tests, and TTS documentation.

Closes #11604

Verification

  • go test ./core/config -ginkgo.focus='TTSVoicesForModel'
  • go test ./core/http/endpoints/localai -ginkgo.focus='TTSVoicesEndpoint'
  • go test ./core/config/meta ./core/http/auth
  • go test ./core/http/routes -run '^$'
  • jq -e '.paths["/v1/audio/voices"].get.responses["200"]' swagger/swagger.json
  • git diff --check

The full routes suite was not run because one existing spec requires a rootless Docker/Postgres provider that is unavailable in this worktree.

Notes for Reviewers

The endpoint returns only models with known voice metadata when unfiltered. A filtered installed model without metadata returns an empty voices list.

Signed commits

  • Yes, I signed my commits.
  • Documentation updated (docs/content/) for user-facing changes, or not applicable

Clients cannot discover the named voices that an installed TTS model accepts without consulting backend-specific documentation. Expose voice metadata through the audio API and let custom model configs declare their own catalog.

Assisted-by: Codex:gpt-5
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.

API to list TTS voices

1 participant