Too Many Images of Documents?

Where does the bug appear (feature/product)?

Cursor IDE

Describe the Bug

Request ID: 013405c5-bfe3-40fd-b554-ea3a184f3834
{“error”:“ERROR_OPENAI”,“details”:{“title”:“Unable to reach the model provider”,“detail”:“Request contained too many images or documents supported by the model provider. A maximum of 20\"","request_id":"c8dd0f1c-1c5c-4211-beca-e19b7578abed"}\n images or documents are allowed.”,“additionalInfo”:{},“buttons”:,“planChoices”:},“isExpected”:true}
ConnectError: [invalid_argument] Error
at t7l.$endAiConnectTransportReportError (vscode-file://vscode-app/Applications/Cursor.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:7337:375292)
at TMr._doInvokeHandler (vscode-file://vscode-app/Applications/Cursor.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:489:35946)
at TMr._invokeHandler (vscode-file://vscode-app/Applications/Cursor.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:489:35688)
at TMr._receiveRequest (vscode-file://vscode-app/Applications/Cursor.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:489:34453)
at TMr._receiveOneMessage (vscode-file://vscode-app/Applications/Cursor.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:489:33275)
at cEt.value (vscode-file://vscode-app/Applications/Cursor.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:489:31369)
at _e._deliver (vscode-file://vscode-app/Applications/Cursor.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:49:2962)
at _e.fire (vscode-file://vscode-app/Applications/Cursor.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:49:3283)
at cdt.fire (vscode-file://vscode-app/Applications/Cursor.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:7322:12154)
at MessagePort. (vscode-file://vscode-app/Applications/Cursor.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:9402:18292)

Steps to Reproduce

Not much just maintaining an active chat, then this error appears

Expected Behavior

Carry on with chat…Model is Claude 4.5, added a few images in the earlier chat thread.

Operating System

MacOS

Current Cursor Version (Menu → About Cursor → Copy)

Version: 1.7.54
VSCode Version: 1.99.3
Commit: 5c17eb2968a37f66bc6662f48d6356a100b67be0
Date: 2025-10-21T19:07:38.476Z
Electron: 34.5.8
Chromium: 132.0.6834.210
Node.js: 20.19.1
V8: 13.2.152.41-electron.0
OS: Darwin arm64 24.6.0

For AI issues: which model did you use?

Claude 4.5

Does this stop you from using Cursor

No - Cursor works, but with this issue

Hey, thanks for the report. The error indicates you’ve reached the 20 image/document limit enforced by the model provider.

Could you clarify approximately how many images you added throughout the chat conversation? Even if you added “a few”, images from earlier messages may be accumulating in the chat context.

Workaround: Start a new chat to reset the image count.

This might be expected behavior based on model provider limits, but I’d like to understand better how many images you included to see if there’s an issue with how images are being counted or retained in context. Let me know!

Yeah I don’t think 20 but a bit hard to count there could be some data point to add. I wanted to continue the thread you see more more task level context.

Thanks for the info. I understand it’s important to maintain task-level context during the conversation.

Since the 20-image limit is enforced by the model provider (Anthropic), the main workaround is to start a new chat or duplicate the existing one.

Let me know if you keep running into this unexpectedly (for example, with fewer than ~15–20 total images in the conversation) that could indicate images aren’t being cleared from context properly.