https://github.com/spring-projects/spring-ai/blob/4230038b28d854bcec27d8c0a454a6c96840ea50/models/spring-ai-openai/src/main/java/org/springframework/ai/openai/OpenAiAudioSpeechClient.java#L136
Here the default options take precedence over the runtime ones. The parameters to the merge call should be in reverse order to accomplish what is wanted.
Comment From: tzolov
Agree this looks like a bug. Thanks @hnybom
Comment From: tzolov
Same bug applies to the transcribe client as well: https://github.com/spring-projects/spring-ai/blob/0eaf7d05c9bc509f8ae2d9e16594ec2db4fd2b4a/models/spring-ai-openai/src/main/java/org/springframework/ai/openai/OpenAiAudioTranscriptionClient.java#L181