diff --git a/src/aichatassistant.cpp b/src/aichatassistant.cpp index 2bce15ead..0c63181d4 100644 --- a/src/aichatassistant.cpp +++ b/src/aichatassistant.cpp @@ -166,10 +166,18 @@ void AIChatAssistant::slotSend() QJsonObject dd; dd["model"]=config->ai_preferredModel; - if(config->ai_provider!=2){ + if(config->ai_provider==0){ // work-around for llamafile for now dd["temperature"]=config->ai_temperature; } + if(config->ai_provider==1){ + // work-around for openai + bool ok; + float val=config->ai_temperature.toFloat(&ok); + if(ok){ + dd["temperature"]=val; + } + } if(config->ai_streamResults){ dd["stream"] = "True"; m_timer=new QTimer();