Using o4-mini complains of bad "temperature" value in API
Wanted to upgrade to o4-mini, but apparently the API for o4-mini only accepts "1.0" for the temperature field. I didn't have much success in setting this on the terminal, and didn't find a well documented .sgptrc variable I could set.
As a workaround for now, you can indeed set --temperature=1.0 on the command line, e.g
sgpt "Say hello, world" --temperature 1.0 --model o4-mini
I ran into this same issue, but I'm using the _sgpt_zsh bindkey integration. I had to redefine it to be something like this. Would be nice if the .sgptrc config could set a default TEMPERATURE value so avoid this. Or just ideally if it was aware of which models don't support temperature, but that's a bigger project.
function _sgpt_zsh() {
...
local SGPT_EXTRAS=(--temperature=1.0 --no-functions)
...
BUFFER="$(sgpt --shell $SGPT_EXTRAS <<< "$_sgpt_prev_cmd")"
...
}
(passing --no-functions is also required for o4-mini to work)
There is no way to just set the temperature to 0.7, for example? It's just about the o4-mini, or all the reasoning models don't support custom temperature.
As an FYI, this also affects the new GPT5 models released today.