Skip to content

Gemini TTS API Static Noise #2220

@leocoppens

Description

@leocoppens

Hi,

I am trying to use Gemini 2.5 Pro/Flash TTS. However when I use the exact script provided in the google aistudio , the audio responds and saves, but is just static noise. The duration varies with the length of the text though.

Please help.
Thanks


Environment details

  • Programming language: Python 3.14.3
  • OS: Debian GNU/Linux 13.3 (trixie)

Steps to reproduce "A" (No code)

  1. Go to: https://aistudio.google.com/generate-speech?model=gemini-2.5-flash-preview-tts
  2. Press "Run Ctrl" (Bottom right)
  3. Listen to auto-generated sound that comes out imperfect, grainy, with white noise.

Steps to reproduce "B" (Via code)

  1. Go to: https://aistudio.google.com/generate-speech?model=gemini-2.5-flash-preview-tts
  2. Press "<> Get Code" (Top right)
  3. Execute Python code autogenerated in any container machine just replacing your api key "GEMINI_API_KEY" and output wav filename "ENTER_FILE_NAME" values.
  4. Listen to auto-generated sound that comes out imperfect, grainy, with white noise.

(My environment: Python 3.14.3 - OS: Debian GNU/Linux 13.3 - (trixie) - google-genai version: 1.69.0 (https://github.com/googleapis/python-genai) )

Thanks for looking.

Metadata

Metadata

Labels

priority: p2Moderately-important priority. Fix may not be included in next release.status:awaiting user responsetype: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions