Coding agents
A new agent usually writes text-sm text-muted-foreground until it learns the primitive exists. This package ships a summary for that, plus two checks that catch the gaps the summary misses.
The one line
llms.txt installs alongside dist/. Reference it from whatever file your agent reads at the start of a session:
npx foundations init prints this line for you to paste. The file it belongs in is yours.
What is in the file
206 lines, in 9 sections: Rules, Which component, Entry points, Props worth knowing, Writing copy, Common mistakes, Surfaces, Upgrading from 0.3, Docs. It is written for a first-time agent, so it leads with the rules and gets to the API afterward.
Then a table mapping what you want to the component that does it, the entry point each one ships from, and the props worth knowing. A section on writing copy sets the register for the words themselves, and one on common mistakes covers what goes through silently:
How it stays current
The prose is hand-written, since the guidance is the useful part. Coverage is mechanical: a build-time check walks the real exports of every entry point and fails the build when a name is missing from the file.
yarn build runs the check across all 9 entry points in the exports map and reports the count it covered, so every component that ships appears here. Judging whether the advice still holds stays a human job, so keep the guidance short enough to re-read.
The lint rules
An agent can miss the summary. The same design rules ship as ESLint selectors from @supertype.ai/foundations/eslint, which fail a build where the summary only advises:
An agent reaches for a utility class before a primitive, so the rules are written around that habit. They catch hand-rolled colour (bg-zinc-800, a hex, a dark: override of a token), a type style written out on a <p> where a primitive exists, a size class on a component that owns its size, a surface token printed as ink, and a margin nudging an icon into line. Plain data, no plugin, ESM and CommonJS builds both. The philosophy page has the full set and why each one is there. See the tooling docs.
doctor in CI
The wiring an agent gets wrong sits outside the JSX. A missing @source line, imports in the wrong order, a font bound with .className: all silent, all invisible to a linter.
llms.txt tells the agent what to write. The lint rules catch what it wrote anyway. doctor checks the wiring both of them are blind to, and exits non-zero on a real problem.