Skip to content

fix: ElevenLabs voice_id is hardcoded, add ELEVENLABS_VOICE_ID and ELEVENLABS_LANGUAGE to settings #2562

Description

@immuhammadfurqan

Bug Description

application/tts/elevenlabs.py hardcodes the ElevenLabs voice ID with no way to change it without editing source code:

voice_id="nPczCjzI2devNBz1zQrb",  # hardcoded, line 19

There is no ELEVENLABS_VOICE_ID key in application/core/settings.py. The local lang = "en" variable is also dead — assigned but only returned, never used to configure synthesis language. Every other ElevenLabs setting (ELEVENLABS_API_KEY) is env-configurable. The voice ID is the only exception.

Expected Behavior

Operators should be able to set ELEVENLABS_VOICE_ID and ELEVENLABS_LANGUAGE via environment variables, consistent with how all other provider settings work.

Proposed Fix

Add ELEVENLABS_VOICE_ID: str = "nPczCjzI2devNBz1zQrb" and ELEVENLABS_LANGUAGE: str = "en" to Settings (keeping existing values as defaults for backward compatibility) and update elevenlabs.py to read from settings.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions