diff --git a/packages/ai/src/utils/models/anthropic-cached.ts b/packages/ai/src/utils/models/anthropic-cached.ts index 7ea20f9fe..5aa45a54a 100644 --- a/packages/ai/src/utils/models/anthropic-cached.ts +++ b/packages/ai/src/utils/models/anthropic-cached.ts @@ -37,7 +37,7 @@ export const anthropicCachedModel = (modelId: string) => { .filter((systemMessage: { text?: string; content?: string }) => { // Filter out messages with empty text or content const messageContent = systemMessage.text || systemMessage.content || ''; - return messageContent.trim() !== ''; + return messageContent.trim() !== '' && messageContent.trim() !== '.'; }) .map( (systemMessage: {