GenAi Apis is taking much time in generating response

Hi Team,

I’m facing a delay of around 7–8 minutes when using the Gemini 2.5 Pro model via the google.genai SDK, especially with larger input data.

Can you please help me with if this is expected or if there’s any way to improve the response time?

Hi @Ajinkya_Sonwane , welcome to the forum.

To reduce the delay, try lowering the thinkingBudget parameter. You can set it in the range of 128 to 32768.

Thanks