Merge branch 'staging' into hidden-reasoning-tracking

This commit is contained in:
Cohee
2025-02-11 23:45:13 +02:00
6 changed files with 30 additions and 7 deletions

View File

@@ -672,6 +672,11 @@ async function sendDeepSeekRequest(request, response) {
bodyParams['logprobs'] = true;
}
if (Array.isArray(request.body.tools) && request.body.tools.length > 0) {
bodyParams['tools'] = request.body.tools;
bodyParams['tool_choice'] = request.body.tool_choice;
}
const postProcessType = String(request.body.model).endsWith('-reasoner') ? 'deepseek-reasoner' : 'deepseek';
const processedMessages = postProcessPrompt(request.body.messages, postProcessType, getPromptNames(request));