Vercel releases vgpu, a WebGPU library that runs in the browser, Node and CI

Vercel has open-sourced vgpu, a TypeScript library originally built to run shaders on vercel.com. The package is published on npm under an MIT license at version v0.3.1, so `pnpm add vgpu` is all that is required to get started; there is no hosted service, no quotas and no inference billing. The core concept is a single GPU context that holds an adapter and a device, with no hidden global state. Everything else—surface, effects, frame loop—relies on that handle.
The main distinction from hand-written WebGPU code is the treatment of .wgsl files as modules. They import and export like TypeScript modules, and vgpu resolves the dependency graph, performs reflection on bindings and layouts, strips unused declarations, and emits compressed shader code at build time. The result is a bundle for a full-screen effect that is 25 KB gzipped, a size budget enforced by the repository in CI. This eliminates manual bindings that often fall out of sync with the shader.
The package exposes subpath exports for vgpu, vgpu/node, vgpu/mock, vgpu/scene, vgpu/client and vgpu/core. The Node path is backed by Chromium’s Dawn and renders offscreen, creating a 256×256 target in `rgba8unorm` format and calling `read` to retrieve pixels. This makes rendering in CI practical: the package includes `pixelmatch` and `pngjs` as direct dependencies, and the documented flow compiles the shader, renders a headless frame and compares it to a snapshot. The mock adapter is deterministic and intended for tests that do not need any GPU at all.
Vercel describes the distribution as “agent-first”, and the package backs that claim: the vgpu binary ships with the package, so `npx vgpu docs`, `npx vgpu examples` and `npx vgpu check` work without a global installation. The site vgpu.sh publishes `agents.md`, `llms.txt`, full export documentation and API discovery for examples without a token, with an OpenAPI 3.1 description. A read-only MCP server is available at `vgpu.sh/api/mcp`, and `@modelcontextprotocol/server` is listed as a direct dependency. The repository also contains a skill that can be installed for agents.