Skip to content

Fix AI Chat in 3D models: keep save and publish tools out of the strict grammar - #85

Merged
pfsteve merged 1 commit into
mainfrom
fix/ai-chat-loose-publish-tools
Nov 6, 2026
Merged

pfsteve merged 1 commit into
mainfrom
fix/ai-chat-loose-publish-tools

Conversation

@pfsteve

@pfsteve pfsteve commented Nov 6, 2026

Copy link
Copy Markdown
Collaborator

Since the last backend deploy, every AI Chat message from a 3D model tab fails with "The service is unavailable." The API refuses the turn with 400 invalid_request_error: The compiled grammar is too large… reduce the number of strict tools. A model tab's editing, guidance and clone tools already filled the strict grammar, and the three tools added in #84 pushed it over.

document_save, commons_publishing_info and commons_publish_propose are now loose tools, the same way the batch tool is. The model still gets their schemas, and the browser checks their inputs. A test keeps the model tab's strict tool set the same as before #84.

Verified against the real API: the backend's warmed first-message prompts for Home, a model tab (editing, guidance, clone, save and publish) and a Layout tab are all accepted. Production logged the same 400 for the model-tab prompt before this fix.

🤖 Generated with Claude Code

A model tab's editing, guidance and clone tools already fill the strict
grammar the API compiles for each request. Adding three more strict tools
made the API refuse every model-tab turn with "The compiled grammar is too
large", so AI Chat failed in 3D models. The save and publishing tools are
now loose tools, like the batch tool: the model still gets their schemas,
and the browser checks their inputs. A test keeps the strict set unchanged.
All warmed tab prompts were checked against the real API.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@pfsteve
pfsteve merged commit d52ebe9 into main Nov 6, 2026
20 of 22 checks passed
@pfsteve
pfsteve deleted the fix/ai-chat-loose-publish-tools branch November 6, 2026 23:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant