vgpu / apps
AGENTS.md2.4k starsChanged 2 months agoMITView on GitHub
This project uses the packaged Geistdocs architecture. The @vercel/geistdocs package owns shared runtime behavior; this app owns local content, configuration, adapters, and site-specific routes. Use these instructions when an AI coding agent edits this project.
- Reads credentials
Trending
More talk lately.about the whole repository
Who's talking about vercel-labs/vgpu
- @camilleroux.com“vgpu, librairie TypeScript de Vercel Labs pour WebGPU, importe les fichiers .wgsl comme modules typés avec …”Bluesky · Aug 29, 2026 · 7 likes
- @yug1224.com“ブラウザとNode.jsの両方でWebGPUシェーダーを動かせるTypeScriptライブラリっぽい グラフィックス表現やビジュアライズの実装でめちゃくちゃ使えそう yug1224 starred …”Bluesky · Sep 5, 2026 · 3 likes
- @technews4869.bsky.social“github.com/vercel-labs/vgpu GitHub - vercel-labs/vgpu: Modular cross-runtime WebGPU library for shaders, 3D …”Bluesky · Sep 5, 2026 · 1 likes
- @github-trending-js.bsky.social“🚀 Skyrocketing! 🚀 (200+ new stars) 📦 vercel-labs / vgpu ⭐ 923 (+209) 🗒 TypeScript Modular cross-runtime …”Bluesky · Aug 29, 2026 · 1 likes
- sudosubin/agents.nix“agent-skills.github.vercel-labs.vgpu: init at 0.5.0”GitHub · Oct 3, 2026
The biggest 5 of 19 mentions linking to the repository that our crawl found. Each line is their own headline.
See all 19
Talked about on GitHub and Bluesky (19 times).
On GitHub · 15
- Oct 3, 2026agent-skills.github.vercel-labs.vgpu: init at 0.5.0 — sudosubin/agents.nix0 reactions
- Sep 21, 2026Bump vgpu from 0.4.1 to 0.5.0 in /web — Dojo-1/doubt-the-machine0 reactions · 1 comment
- Sep 18, 2026chore(deps): bump the minor-and-patch group with 3 updates — kleinpanic/datahall0 reactions · 1 comment
- Sep 17, 2026Bump vgpu from 0.3.1 to 0.5.0 — scristobal/retropixels-vgpu0 reactions
- Sep 17, 2026chore(deps): bump the production group with 8 updates — PunGrumpy/vecstore-sdk0 reactions · 7 comments
10 more on GitHub
- Sep 14, 2026Add subtle vgpu CRT glass and curvature — pablostanley/vackrooms0 reactions · 1 comment
- Sep 14, 2026feat(graphics): 探索使用 WebGPU / vgpu 重构 SignalCore 光线色散与体积光效果 — A1oha666/MonostichBlog0 reactions
- Sep 14, 2026Bump vgpu from 0.4.0 to 0.4.1 in /web — Dojo-1/doubt-the-machine0 reactions · 2 comments
- Sep 11, 2026Bump vgpu from 0.3.1 to 0.4.1 — scristobal/retropixels-vgpu0 reactions · 1 comment
- Sep 7, 2026Bump vgpu from 0.3.1 to 0.4.0 — scristobal/retropixels-vgpu0 reactions · 1 comment
- Sep 7, 2026Bump vgpu from 0.3.1 to 0.4.0 in /web — Dojo-1/doubt-the-machine0 reactions · 2 comments
- Sep 2, 2026chore(labs): vgpu WebGPU demos — headless Metal render + Vite gallery — ziyu4huang/video_generation0 reactions
- Aug 31, 2026Add Learn vgpu (Tutorials) and a vgpu demo (Demos) — mikbry/awesome-webgpu0 reactions · 3 comments
- Aug 29, 2026canvasMouseTracker reports pointer positions at 1/devicePixelRatio scale — vraj00222/vgpu0 reactions
- Aug 27, 2026Update skill: /vercel-labs-vgpu (medium risk) — aiskillstore/marketplace0 reactions
On Bluesky · 4
- Aug 29, 2026vgpu, librairie TypeScript de Vercel Labs pour WebGPU, importe les fichiers .wgsl comme modules typés avec une API unique valable… — @camilleroux.com7 likes and reposts · 3 replies
- Sep 5, 2026ブラウザとNode.jsの両方でWebGPUシェーダーを動かせるTypeScriptライブラリっぽい グラフィックス表現やビジュアライズの実装でめちゃくちゃ使えそう yug1224 starred vercel-labs/vgpu… — @yug1224.com3 likes and reposts
- Sep 5, 2026github.com/vercel-labs/vgpu GitHub - vercel-labs/vgpu: Modular cross-runtime WebGPU library for shaders, 3D scenes, GPU tens... — @technews4869.bsky.social1 likes and repost
- Aug 29, 2026🚀 Skyrocketing! 🚀 (200+ new stars) 📦 vercel-labs / vgpu ⭐ 923 (+209) 🗒 TypeScript Modular cross-runtime WebGPU library for shaders, 3D… — @github-trending-js.bsky.social1 likes and repost · 1 reply
Where files are headingNew AGENTS.md files have more rules about keeping secrets out of the code, and fewer about checking a change actually works.
Of the AGENTS.md files we read, the 11,773 first seen in the last six months, against the older ones: the kind of rule that gained most share, and the kind that lost most. About files like this in general, not this one, and an estimate, since a kind is a pattern in the words.
In this repository3 other files it gives its agents.
- AGENTS.mdAGENTS.md
- vgpu-agent-flowSkill
- vgpuSkill
The file
Show its rules and text
We split this agents.md into the rules it gives an agent
42 rules. About 1 is common, 7 are distinctive, and 34 are very specific to this project.
≈1
Common · estimate
Many files like this have a rule of this kind.
≈7
Distinctive · estimate
This author's own choices. Worth a look.
34
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- could be automatic: a setting could enforce it
- Distinctive: line 5
Use these instructions when an AI coding agent edits this project.
- Distinctive: line 9
Keep each example self-contained.
- Very specific: line 10
Use lil-gui for interactive example controls.
- Distinctive: line 12
Keep the React entry as a thin mount/cleanup wrapper.
- Distinctive: line 13
Before simplifying, capture deterministic baselines for every control state, important interaction, and responsive layout.
- Distinctive: line 14
Remove unreachable themes, modes, passes, uniforms, configuration, CPU mirrors, and files before compressing active GPU arithmetic.
- Distinctive: line 18
When simplifying an existing example, migrate it to these rules as part of the simplification.
- Very specific: line 25
Do not copy package internals into the app to make a customization.
- Very specific: line 26
Do not deep import from @vercel/geistdocs/dist or edit files in node_modules/@vercel/geistdocs.
- Very specific: line 27
Do not edit generated directories such as .source/, .next/, node_modules/, or build output.
- Very specific: line 31
When package API behavior is unclear, read the installed package docs in node_modules/@vercel/geistdocs/docs before guessing.
- Very specific: line 32
Start with node_modules/@vercel/geistdocs/docs/agents.md and node_modules/@vercel/geistdocs/docs/sitemap.md to identify the relevant …
- Very specific: line 33
Use node_modules/@vercel/geistdocs/docs/pages/*.md for task-specific guidance and node_modules/@vercel/geistdocs/docs/llms.txt only when …
- Very specific: line 59
Put docs in content/docs unless the project has added another source in lib/geistdocs/source.ts.
- Very specific: line 60
Add each new page to content/docs/meta.json so it appears in the sidebar.
- Very specific: line 61
Use MDX frontmatter with at least title and description for documentation pages.
- Distinctive: line 62
Keep slugs stable unless the task explicitly includes redirects or link updates.
- Very specific: line 63
When adding translated content, follow the existing locale suffix pattern, such as page.cn.mdx.
- Very specific: line 64
Use CopyPrompt when a page should give readers a prompt they can copy into a coding agent.
- Very specific: line 68
Keep App Router route files as thin adapters around package helpers such as createDocsPage, createChatRoute, createLlmsRoute, and …
- Very specific: line 69
Keep export const config in proxy.ts as a static object.
- Very specific: line 70
Use proxy matcher exclusions that only match /api and /api/..., such as api(?:/|$).
- Very specific: line 74
When adding custom proxy behavior, prefer before, after, and markdownRoutes options on createProxy instead of replacing the proxy.
- Very specific: line 75
Use explicit markdownRoutes for root-mounted docs or any site where homepage/app routes coexist with docs routes.
- Very specific: line 76
Keep source URLs, navigation links, getPageUrl, and markdownRoutes app-local when config.basePath is set.
- Very specific: line 81
Leave GEISTDOCS_CHAT_PROXY_URL unset and ai.eveAgent unconfigured to use the default AI Gateway path.
- Very specific: line 84
If the app uses ai or @ai-sdk/react for product code outside Geistdocs, migrate that app code separately or let the package manager install …
- Very specific: line 86
Do not add Vertex credentials to a Geistdocs site.
- Very specific: line 87
Use GEISTDOCS_CHAT_PROXY_TOKEN only for a custom proxy that requires bearer authentication.
- Very specific: line 88
Keep app/api/chat/route.ts as a thin adapter around createChatRoute.
- Very specific: line 89
If custom chat client code uses DefaultChatTransport.prepareSendMessagesRequest, preserve messages in the returned body when adding fields …
- Very specific: line 93
When migrating from Fumadocs or a custom Geist docs site, inventory source.config.ts, route files, middleware.ts or proxy.ts, …
- Very specific: line 95
Import source-config helpers from @vercel/geistdocs/source-config in source.config.ts.
- Very specific: line 97
Delete public/llms.txt when an App Router llms route exists.
- Very specific: line 99
Add Tailwind CSS v4 @source entries for @vercel/geistdocs and related runtime dependencies when migrating styles.
- Common: line 100
Add local fallbacks for production-only environment variables so migration builds do not require production secrets.
- Very specific: line 104
Use pnpm exec geistdocs update to update package-based Geistdocs projects.
- Very specific: line 112
Start the built app: pnpm start
- Very specific: line 115
Run translations if configured: pnpm translate
- Very specific: line 119
Run pnpm build after changing routes, config, source setup, MDX components, or package versions.
- Very specific: line 120
Run pnpm dev and open the changed pages when visual layout, navigation, or MDX rendering changes.
- Very specific: line 121
Check both /docs and AI-readable routes such as /agents.md, /.well-known/mcp.json, /llms.txt, /llms-full.txt, a page-level .md URL, an …
≈ “Common” is an estimate: at least 1 in 5 of the 16,595 AGENTS.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Geistdocs agent instructions
This project uses the packaged Geistdocs architecture. The @vercel/geistdocs package owns shared runtime behavior; this app owns local content, configuration, adapters, and site-specific routes.
Use these instructions when an AI coding agent edits this project.
Example authoring
- Keep each example self-contained. Published example files may import packages and files inside their own example directory, but must not import app-level helpers or files from another example.
- Use
lil-guifor interactive example controls. Do not build custom HTML or React control panels. - Mount
lil-guiinside the example container and destroy it during renderer cleanup. - Keep the React entry as a thin mount/cleanup wrapper. Infer renderer types locally and let the preview host observe asynchronous failures instead of importing example-specific reporting or renderer helpers.
- Before simplifying, capture deterministic baselines for every control state, important interaction, and responsive layout. Make reductions in small tranches and require byte-exact parity after each tranche.
- Remove unreachable themes, modes, passes, uniforms, configuration, CPU mirrors, and files before compressing active GPU arithmetic. Preserve resource teardown and stale-async cancellation.
- Optimize logical complexity, not the line counter. Keep normal formatting with one statement per line and readable blocks; never compress active code into long one-liners to claim a LOC reduction. Report file count, source bytes, and nonblank lines when formatting makes physical LOC misleading.
- Follow ownership boundaries during teardown. When a renderer owns its
Gpu, letgpu.dispose()stop VGPU schedulers and release registered surfaces, resources, services, and the device; do not also dispose every VGPU child or clear every local reference. Explicitly clean only browser/DOM resources and children that must be released while a shared GPU remains alive. - Recheck thumbnails, focused tests, type safety, import boundaries, and bundle size after the implementation stabilizes.
- When simplifying an existing example, migrate it to these rules as part of the simplification.
Architecture
- Runtime features come from
@vercel/geistdocs, including the docs page renderer, layout helpers, MDX components, search, Ask AI, markdown routes, proxy helpers, and source helpers. @vercel/geistdocsowns the Ask AI client, server route behavior, and AI SDK v6 runtime dependencies. Do not fork package internals to fit an older app-levelaiversion.- Local files are user-owned adapters. They should stay thin and call public package exports from
@vercel/geistdocs/*. - Do not copy package internals into the app to make a customization. Prefer configuring an adapter file or upgrading
@vercel/geistdocs. - Do not deep import from
@vercel/geistdocs/distor edit files innode_modules/@vercel/geistdocs. - Do not edit generated directories such as
.source/,.next/,node_modules/, or build output.
Package Docs For Agents
- When package API behavior is unclear, read the installed package docs in
node_modules/@vercel/geistdocs/docsbefore guessing. - Start with
node_modules/@vercel/geistdocs/docs/agents.mdandnode_modules/@vercel/geistdocs/docs/sitemap.mdto identify the relevant focused page. - Use
node_modules/@vercel/geistdocs/docs/pages/*.mdfor task-specific guidance andnode_modules/@vercel/geistdocs/docs/llms.txtonly when you need broad package context. - These package docs are read-only generated artifacts. Do not edit files under
node_modules/@vercel/geistdocs; change local adapter files or update the package instead.
Common edit targets
| Task | Edit |
Configure site title, logo, nav, GitHub links, AI prompt, suggestions, translations, basePath, or siteId | geistdocs.tsx |
Edit public agent best-fit use cases or operational instructions shared by /agents.md and /llms.txt | lib/agent-guidance.ts |
| Add or update documentation pages | content/docs/**/*.mdx |
| Control sidebar order, groups, and labels | content/docs/meta.json |
| Override MDX components | components/geistdocs/mdx-components.tsx |
| Wrap the site provider, analytics, or global client behavior | components/geistdocs/provider.tsx |
| Customize the docs layout shell | components/geistdocs/docs-layout.tsx |
| Configure the Fumadocs source adapter or versioned docs | lib/geistdocs/source.ts |
| Configure Fumadocs collections and source-safe MDX processing | source.config.ts |
| Configure the docs page renderer | app/[lang]/docs/[[...slug]]/page.tsx |
| Configure AI-readable markdown output | app/[lang]/agents.md/route.ts, app/[lang]/.well-known/mcp.json/route.ts, app/[lang]/llms.txt/route.ts, app/[lang]/llms-full.txt/route.ts, app/[lang]/llms.mdx/[[...slug]]/route.ts, app/[lang]/sitemap.md/route.ts |
| Configure chat or search APIs | app/api/chat/route.ts, app/api/search/route.ts |
Configure the structured JSON fallback for unknown /api/* paths | lib/api-not-found.ts, app/api/[...notFound]/route.ts |
| Add request handling before or after Geistdocs routing | proxy.ts |
| Edit the marketing home page | app/[lang]/(home)/** |
| Edit shared styles | app/global.css, app/styles/geistdocs.css |
Content guidelines
- Put docs in
content/docsunless the project has added another source inlib/geistdocs/source.ts. - Add each new page to
content/docs/meta.jsonso it appears in the sidebar. - Use MDX frontmatter with at least
titleanddescriptionfor documentation pages. - Keep slugs stable unless the task explicitly includes redirects or link updates.
- When adding translated content, follow the existing locale suffix pattern, such as
page.cn.mdx. - Use
CopyPromptwhen a page should give readers a prompt they can copy into a coding agent.
Routing and proxy guidelines
- Keep App Router route files as thin adapters around package helpers such as
createDocsPage,createChatRoute,createLlmsRoute, andcreateProxy. - Keep
export const configinproxy.tsas a static object. Next.js must parse proxy matchers at build time. - Use proxy matcher exclusions that only match
/apiand/api/..., such asapi(?:/|$). Do not exclude broad prefixes likeapi, because that also excludes routes such as/api-reference. - Preserve markdown negotiation unless the task explicitly changes AI-readable output. The app serves a concise
/llms.txtindex, acreateLlmsRoute-backed/llms-full.txtcorpus,/agents.md,/.well-known/mcp.json, and per-page Markdown for.md,.mdx,Accept: text/markdown, and AI-agent requests. - Preserve the proxy
afterhook that returns a recoverable Markdown 404 for unknown agent requests outside/docs. When adding a valid HTML app route, add it tolib/geistdocs/markdown-not-found.tsso Markdown-preferring clients still receive the real page rather than the fallback. - Preserve
app/api/[...notFound]/route.tsas the lowest-precedence API route. Valid API routes must retain their own contracts, unknown/api/*paths return a stable JSON 404 instead of the framework HTML response, and the existing bare/apiredirect continues to lead to/docs/reference. - When adding custom proxy behavior, prefer
before,after, andmarkdownRoutesoptions oncreateProxyinstead of replacing the proxy. - Use explicit
markdownRoutesfor root-mounted docs or any site where homepage/app routes coexist with docs routes. - Keep source URLs, navigation links,
getPageUrl, andmarkdownRoutesapp-local whenconfig.basePathis set. Geistdocs derives public page-action and Markdown URLs separately. - Include
"/"explicitly in the static proxy matcher when a Next.js base-path application serves documentation at its app root.
Ask AI and Vertex proxy guidelines
- Leave
GEISTDOCS_CHAT_PROXY_URLunset andai.eveAgentunconfigured to use the default AI Gateway path. In that mode,app/api/chat/route.tscallscreateChatRoutewithout aproxyoption and uses the local docs search tool during the AI SDKstreamTextloop. - Set
ai.eveAgent: { url }ingeistdocs.tsxto answer Ask AI with a hosted eve framework agent instead. The URL flows through the config object; the route file needs no changes. Requests authenticate with a per-request Vercel OIDC bearer token by default; pass server-only headers through theeveAgentoption oncreateChatRoutefor custom auth. Never put auth material ingeistdocs.tsx. Configuring bothproxyand an eve agent throws at route creation. - Geistdocs Ask AI targets AI SDK v6:
aiv6 and@ai-sdk/reactv3. Keep those dependencies on the generated package versions unless a@vercel/geistdocsrelease changes them. - If the app uses
aior@ai-sdk/reactfor product code outside Geistdocs, migrate that app code separately or let the package manager install separate versions. Do not downgrade Geistdocs Ask AI to match unrelated app code. - Set
GEISTDOCS_CHAT_PROXY_URLonly when Ask AI should route through the central Vertex-backed proxy. The value must include the/vertexroute, such ashttps://<geistdocs-platform-deployment>/vertex. - Do not add Vertex credentials to a Geistdocs site. The central platform proxy forwards the Vercel OIDC token in
x-vercel-trusted-oidc-idp-token; the Vertex deployment should trust the platform Vercel project through Deployment Protection Trusted Sources. - Use
GEISTDOCS_CHAT_PROXY_TOKENonly for a custom proxy that requires bearer authentication. The default Geistdocs platform/vertexproxy does not require it. - Keep
app/api/chat/route.tsas a thin adapter aroundcreateChatRoute. Prefer configuringGEISTDOCS_CHAT_PROXY_URLandGEISTDOCS_CHAT_PROXY_TOKENover forking the package chat route. - If custom chat client code uses
DefaultChatTransport.prepareSendMessagesRequest, preservemessagesin the returnedbodywhen adding fields such ascurrentRoute. Returning a custombodyreplaces the AI SDK default request body.
Migration guidelines
- When migrating from Fumadocs or a custom Geist docs site, inventory
source.config.ts, route files,middleware.tsorproxy.ts,public/llms.txt, OG routes, Tailwind CSS setup, and required environment variables before editing. - Inventory direct app usage of
aiand@ai-sdk/react. Package-owned Ask AI uses AI SDK v6; migrate local AI SDK code separately from Geistdocs route adapters. - Import source-config helpers from
@vercel/geistdocs/source-configinsource.config.ts. Do not import runtime component entry points from source config. - Move existing
middleware.tsbehavior intocreateProxy({ before })orcreateProxy({ after })hooks. - Delete
public/llms.txtwhen an App Router llms route exists; otherwise the static file can mask the concise/llms.txtindex or acreateLlmsRouteadapter. - Set
openGraph.imagesincreateDocsPageonly when the app includes the Geistdocs OG route, or override metadata to avoid broken/og/...URLs. - Add Tailwind CSS v4
@sourceentries for@vercel/geistdocsand related runtime dependencies when migrating styles. - Add local fallbacks for production-only environment variables so migration builds do not require production secrets.
Package updates
- Use
pnpm exec geistdocs updateto update package-based Geistdocs projects. geistdocs updateupdates the@vercel/geistdocsdependency. It does not overwrite local adapter files.- Review dependency changes and run the verification commands before committing an update.
Commands
- Start development:
pnpm dev - Build for production:
pnpm build - Start the built app:
pnpm start - Regenerate Fumadocs output after dependency installation:
pnpm postinstall - Update Geistdocs:
pnpm exec geistdocs update - Run translations if configured:
pnpm translate
Verification
- Run
pnpm buildafter changing routes, config, source setup, MDX components, or package versions. - Run
pnpm devand open the changed pages when visual layout, navigation, or MDX rendering changes. - Check both
/docsand AI-readable routes such as/agents.md,/.well-known/mcp.json,/llms.txt,/llms-full.txt, a page-level.mdURL, an unknown URL withAccept: text/markdown, and an unknown/apipath when changing content routing or proxy behavior. - Confirm no secrets were added to source files. Use
.env.localfor local values and keep it out of Git.
<!-- BEGIN:nextjs-agent-rules -->This is NOT the Next.js you know
This version has breaking changes — APIs, conventions, and file structure may all differ from your training data. Read the relevant guide in node_modules/next/dist/docs/ (resolved from this file's directory; in monorepos the next package may not be visible from the repo root) before writing any code. Heed deprecation notices.
This block is written and re-added by next dev — verify at node_modules/next/dist/server/lib/generate-agent-files.js. Removing it from a diff only re-creates the uncommitted change; committing it with your work keeps the tree clean.
<!-- END:nextjs-agent-rules -->Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

