Merge pull request 'Fix: exclude temperature parameter for reasoning-tier models' (#4) from feat/ai-pipeline-hardening-phase-2 into main
All checks were successful
On Push to Main / test (push) Successful in 25s
On Push to Main / publish (push) Successful in 57s
On Push to Main / deploy-dev (push) Successful in 1m33s

Reviewed-on: #4
This commit was merged in pull request #4.
This commit is contained in:
2026-05-20 15:18:00 +00:00

View File

@@ -303,9 +303,12 @@ export async function callLLM(options) {
const body = {
model,
max_tokens: maxTokens,
temperature,
messages: messagesPayload,
};
// Temperature is not supported for reasoning tier models
if (tier !== 'reasoning') {
body.temperature = temperature;
}
if (system !== undefined) body.system = system;
if (tools && tools.length) body.tools = tools;
if (toolChoice) body.tool_choice = toolChoice;