fix(stainless): remove deprecated AI chat plugin to fix build OOM#258
Open
erinmikailstaples wants to merge 3 commits intomainfrom
Open
fix(stainless): remove deprecated AI chat plugin to fix build OOM#258erinmikailstaples wants to merge 3 commits intomainfrom
erinmikailstaples wants to merge 3 commits intomainfrom
Conversation
The @stainless-api/docs-ai-chat plugin is deprecated upstream — the chat widget on the live site returns "Something went wrong" for any query, and the AI chat examples endpoint (api.stainless.com/api/ai/steelie-examples/tiger-cloud) now 404s. The plugin was also the root cause of the post-vite build OOMs on Vercel: it indexed all 692 pages for vector search at build time, pushing the Node heap past 2GB during the astro:build:done phase. With the plugin removed, the local build finishes in ~40s with no heap pressure (down from ~150s + OOM crash). Removed: - astro.config.ts: aiChat import and experimental.aiChat config - package.json + lockfile: @stainless-api/docs-ai-chat dependency (plus 54 transitive deps it pulled in) - AGENTS.md: outdated "experimental AI chat" reference Verified locally: pnpm build:local builds 692 pages in 39.57s.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
✅ Checklist CompleteThank you for taking the time to properly review your PR! All checklist items are complete. |
@stainless-api/docs/stl-docs/aiChatExamples.ts has a top-level `import z from 'zod'`, but zod is declared as a devDependency in that package's package.json — so it isn't installed at runtime. Previously zod was satisfied transitively through @stainless-api/docs-ai-chat; removing that plugin in the prior commit broke the chain and Vercel's clean install failed with "Cannot find module 'zod'". Pinning zod as a direct dependency restores the resolution path without bringing back the deprecated AI chat plugin. Verified with a full `pnpm build`: 774 pages in 49.44s, no errors.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Describe your changes
The
@stainless-api/docs-ai-chatplugin is deprecated upstream — the chat widget on the live site returns "Something went wrong" for any query, and the AI chat examples endpoint (api.stainless.com/api/ai/steelie-examples/tiger-cloud) now 404s on every build.The plugin was also the root cause of the post-vite build OOMs killing Vercel deploys: it indexed all 692 pages for vector search during the
astro:build:donephase, pushing the Node heap past the ~2GB default. With the plugin removed:[stainless] failed to fetch AI chat examples: 404 Not Foundlog line is gone too — same pluginWhat changed
astro.config.ts— removedaiChatimport and theexperimental.aiChatconfig entrypackage.json+pnpm-lock.yaml— dropped@stainless-api/docs-ai-chatdependencyAGENTS.md— removed the outdated "experimental AI chat" mention from the project overviewWhat did not change
@stainless-api/docs(the main Stainless integration) and@stainless-api/ui-primitivesare untouched — only the AI chat sub-plugin was removed.Affected pages
No content pages affected by this PR. Open the preview to confirm the build deployed successfully.
Related Issues
Issue: #number
Checklist before requesting a review