Skip to content

Commit 13f5545

Browse files
fix
1 parent 4ab2d76 commit 13f5545

1 file changed

Lines changed: 7 additions & 1 deletion

File tree

packages/web/src/features/chat/utils.server.ts

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -210,11 +210,17 @@ export const getAISDKLanguageModelAndOptions = async (config: LanguageModel): Pr
210210
: undefined,
211211
});
212212

213+
const isAdaptiveThinkingSupported =
214+
modelId === 'claude-opus-4-7';
215+
213216
return {
214217
model: anthropic(modelId),
215218
providerOptions: {
216219
anthropic: {
217-
thinking: {
220+
thinking: isAdaptiveThinkingSupported ? {
221+
type: "adaptive",
222+
"display": "summarized"
223+
} : {
218224
type: "enabled",
219225
budgetTokens: env.ANTHROPIC_THINKING_BUDGET_TOKENS,
220226
}

0 commit comments

Comments
 (0)