This is a pnpm monorepo containing the Next.js framework and related packages. The main Next.js framework lives in packages/next/. This is what gets published as the next npm package. Source code is in packages/next/src/. Key entry points: Compiled output goes to packages/next/dist/ (mirrors src/ structure). Before editing or creating files in any subdirectory (e.g., packages/, crates/), read all README.md files in the directory path from the repo root up to and including the target file's directory. This helps identify any…
Set permissions: {} at the workflow level and grant the minimum needed per-job. Prefer GitHub-provided (actions/*) and Vercel-owned actions. For third-party actions: ${{ ... }} is interpolated into the script before bash runs, so untrusted values (PR title, branch name, issue body) can break out and execute. Route them through an env var and quote on use:
This version has breaking changes — APIs, conventions, and file structure may all differ from your training data. Read the relevant guide in dist/docs/ before writing any code. Heed deprecation notices.
Turbopack is a general-purpose bundler that is built and designed for Next.js, but is not necessarily Next.js-specific. Keep Next.js concepts out of it.
PR titles must follow Conventional Commits. See .github/workflows/lint-pr-title.yml for the enforced constraints. Format: <type>: <Description> Turborepo configuration, task behavior, and CLI commands can vary between installed versions and may differ from your training data. Resolve the turbo package from this file's directory or relevant workspace; in monorepos, it may not be visible from the repository root. For example, run node -p "require.resolve('turbo/package.json')" from a workspace that depends on turbo. Read docs/README.md inside that installed package first, then read the relevant…
The root AGENTS.md also applies to this app. Geistdocs owns shared runtime behavior, while this app owns Turborepo content, routes, metadata, assets, and adapters. 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…
Turborepo configuration, task behavior, and CLI commands can vary between installed versions and may differ from your training data. Resolve the turbo package from this file's directory or relevant workspace; in monorepos, it may not be visible from the repository root. For example, run node -p "require.resolve('turbo/package.json')" from a workspace that depends on turbo. Read docs/README.md inside that installed package first, then read the relevant pages from its docs/ directory before changing Turborepo configuration or commands. Heed deprecation notices. These…
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/ before writing any code. Heed deprecation notices. <!-- END:nextjs-agent-rules -->
This file provides context for AI coding assistants (Cursor, GitHub Copilot, Claude Code, etc.) working with the Vercel AI SDK repository. The AI SDK by Vercel is a TypeScript/JavaScript SDK…
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…
Guidelines for AI agents working on the Vercel monorepo. This is a pnpm monorepo containing 44+ packages for the Vercel CLI and runtimes: Run tests for a specific package: Always create a changeset for all PRs. A changeset is a markdown file in .changeset/ with YAML frontmatter listing affected packages and their bump type (patch/minor/major). Example changeset for a package change: Example changeset for non-package changes: Run before committing: When adding tests: Each package follows this structure: Workspace dependencies use…
Always-loaded guidance for work inside packages/cli. Keep this file small. The CLI UX design system lives in packages/cli/.agents/skills/cli-ux/ and should be loaded only when the task or code review touches user-facing CLI behavior. Common shared areas:
- Dependencies: PEP 440 compatible release clauses (rich ~= 14.0), avoid pinning patch releases (rich ~= 14.0.0). - Only add code that is actually used. No speculative APIs or exports. - _internal/ is private — no backwards compatibility needed when refactoring. - uv: uv sync, uv run <cmd>, uv add <pkg> - ruff: uv run ruff check . (lint), uv run ruff format . (format) - pytest: uv run pytest, uv run pytest tests/testfoo.py, uv run pytest -k testname. Tests…