fix(reasoning): thinking control for ds v3.1 of tencent platform (#10333)

* feat(reasoning): add Hunyuan and Tencent TI thinking config

* fix: style

* fix(reasoning): merge same type providers
This commit is contained in:
George·Dong 2025-09-24 18:38:13 +08:00 committed by GitHub
parent bf2ffb7465
commit 09e9b95e08
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 13 additions and 1 deletions

View File

@ -112,6 +112,8 @@ export function getReasoningEffort(assistant: Assistant, model: Model): Reasonin
return {
enable_thinking: true
}
case SystemProviderIds.hunyuan:
case SystemProviderIds['tencent-cloud-ti']:
case SystemProviderIds.doubao:
return {
thinking: {

View File

@ -93,7 +93,17 @@ export function isSupportedThinkingTokenModel(model?: Model): boolean {
// Specifically for DeepSeek V3.1. White list for now
if (isDeepSeekHybridInferenceModel(model)) {
return (
['openrouter', 'dashscope', 'modelscope', 'doubao', 'silicon', 'nvidia', 'ppio'] satisfies SystemProviderId[]
[
'openrouter',
'dashscope',
'modelscope',
'doubao',
'silicon',
'nvidia',
'ppio',
'hunyuan',
'tencent-cloud-ti'
] satisfies SystemProviderId[]
).some((id) => id === model.provider)
}