Keep machine docs in sync with the product
Mantén la documentación para máquinas sincronizada con el producto
Tie agent-facing documentation to releases so agents never act on stale endpoints or deprecated parameters.
Why
Stale machine docs generate broken code: Fern notes that outdated authentication flows or removed endpoints make AI tools suggest calls that no longer work, and that coding assistants cache these files, so a stale version can persist for days or weeks. The canonical AX framework (agentexperience.ax, Contextual Alignment) asks that agent-facing content stay consistent with what the human documentation says, and Biilmann adds that agent docs must make clear anything that changed after the model's knowledge cut-off. Unlike human users who see deprecation banners, agents act on the documentation they receive with no fallback.
Do
Practice docs-as-code in the same PR as API changes.
Don't
Maintain docs on a separate, slower cycle.
Artifact
Process artifact: add a CI check that fails the build if an API schema changes without a matching docs update in the same pull request. The artifact is a required status check, not code to ship.
Citations
- [01]agentexperience.ax: Principles of AX(opens in a new tab)
Contextual Alignment: maintain consistency of content with the information accessible from human-oriented context systems (e.g. documentation sites), with context robust enough to work across various models
- [02]Fern: API Docs for AI Agents (llms.txt guide)(opens in a new tab)
Stale llms.txt files generate broken code: outdated authentication flows or removed endpoints make AI tools suggest non-functional code, and cached copies can persist for days or weeks
- [03]Mathias Biilmann: AX in Practice(opens in a new tab)
It must be clear which unique APIs, versions, or knowledge the LLM needs to apply, along with anything that may have changed since the model's knowledge cut-off