pipecat icon indicating copy to clipboard operation
pipecat copied to clipboard

how can I change language in examples (esp. moonchat)

Open fsoft72 opened this issue 9 months ago • 2 comments

Hello, I'd like to use Italian language but I cannot find where to change it

fsoft72 avatar May 14 '24 14:05 fsoft72

If you're using the Daily transport and its built-in transcription, there's a language property inside transcription_settings that you can change when you initialize your transport. Right below this line, you'd add something like transcription_settings={"language": "it"}.

For other services, it depends on what they support. As far as Moondream, I can't figure out how to specify a language in their own API.

chadbailey59 avatar May 14 '24 20:05 chadbailey59

Hi! We just released 0.0.12. It includes DailyTranscriptionSettings which makes it much easier to specify transcription settings. For example:

   transcription_settings=DailyTranscriptionSettings(
       language="es",
       tier="nova",
       model="2-general"
   )

We have also updated simple-chatbot to show how to convert the application to Spanish. Note that whether you can use a language or not (in your case Italian) depends on the models. See this change: https://github.com/pipecat-ai/pipecat/commit/e23addcc02425705ffa5c077cf6eefec74d438a3

For example, the DailyTransport uses Deepgram so you need to make sure you use the right model: https://developers.deepgram.com/docs/models-languages-overview

Then, for ElevenLabs you need to make sure the model supports Italian (e.g. eleven_multilingual_v2). https://help.elevenlabs.io/hc/en-us/articles/17883183930129-What-models-do-you-offer-and-what-is-the-difference-between-them

Unfortunately, Moondream only understands English sentences as far as I know. But what you can do is add a new OpenAILLMService (before MoondreamService) that translates Italian to English for the description part.

aconchillo avatar May 14 '24 22:05 aconchillo