Skip to content

[duplicate] feat(ai): add AGENTS.md to npm package#11774

Closed
kairosci wants to merge 3 commits intovercel:mainfrom
kairosci:feature/add-agents-md-to-npm-package
Closed

[duplicate] feat(ai): add AGENTS.md to npm package#11774
kairosci wants to merge 3 commits intovercel:mainfrom
kairosci:feature/add-agents-md-to-npm-package

Conversation

@kairosci
Copy link
Copy Markdown

@kairosci kairosci commented Jan 13, 2026

Background

LLM agents and AI coding assistants frequently hallucinate when using the AI SDK by attempting to use deprecated or removed APIs (like maxTokens, maxSteps, or generateObject). Providing a dedicated AGENTS.md file within the published package helps these agents understand the correct modern API usage patterns.

Summary

  • Moved AGENTS.md from the repository root to packages/ai/AGENTS.md to ensure inclusion in the npm package.
  • Expanded the content of AGENTS.md with a comprehensive list of common mistakes and their corrections for both AI SDK Core and UI.
  • Added a reference to the official documentation for further guidance.
  • Formatted the file using Prettier to match project standards.
  • Added a patch changeset for the ai package.

Manual Verification

  • Verified that packages/ai/package.json includes AGENTS.md in the files array.
  • Ran pnpm prettier --check packages/ai/AGENTS.md to confirm correct formatting.

Checklist

  • Tests have been added / updated (for bug fixes / features)
  • Documentation has been added / updated (for bug fixes / features)
  • A patch changeset for relevant packages has been added (for bug fixes / features - run pnpm changeset in the project root)
  • I have reviewed this pull request (self-review)

Related Issues

Fixes #11759
Related to #11723

@vercel-ai-sdk vercel-ai-sdk bot added the maintenance CI, internal documentation, automations, etc label Jan 13, 2026
@kairosci kairosci marked this pull request as draft January 13, 2026 21:54
This commit updates the AGENTS.md file to focus on how to use the AI SDK, not how to develop it.
This is based on the feedback from the community and the tracking issue for common AI agent mistakes.

Fixes vercel#11759
Fixes vercel#11723
@kairosci kairosci force-pushed the feature/add-agents-md-to-npm-package branch from dd274b4 to f9d4856 Compare January 13, 2026 22:19
@kairosci kairosci marked this pull request as ready for review January 13, 2026 22:21
@kairosci kairosci force-pushed the feature/add-agents-md-to-npm-package branch 2 times, most recently from 8670915 to aed9b69 Compare January 13, 2026 22:24
Moves AGENTS.md to packages/ai/ so it is included in the published npm package.

Closes vercel#11759
Related to vercel#11723
@kairosci kairosci force-pushed the feature/add-agents-md-to-npm-package branch from 210c8ba to 296823d Compare January 13, 2026 22:28
@aayush-kapoor
Copy link
Copy Markdown
Collaborator

there's already a PR in flight for this (#11760) - so marking this as closed!

@kairosci kairosci changed the title feat(ai): add AGENTS.md to npm package [duplicate] feat(ai): add AGENTS.md to npm package Jan 13, 2026
@kairosci kairosci deleted the feature/add-agents-md-to-npm-package branch January 13, 2026 22:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

maintenance CI, internal documentation, automations, etc

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add AGENTS.md to ai npm package

2 participants