Agent-friendly docs for documentarians


"Here’s what we can piece together from the available information:
  • Truncation is real and varies by platform. Claude Code truncates between 100-150k of text. Other platforms presumably have limits too, but won’t say what they are. If your page is large, some of it is getting cut.
  • Source order matters. Whatever content appears first in your page source is what the agent is most likely to see. Tabs, accordions, and other UI patterns that flatten into long sequential content in the source mean that later sections may be invisible to agents.
  • Serving markdown helps, but only if the agent requests it. Most agents don’t. And even if they do, you need your server configured to respond appropriately to content negotiation.
  • Character count is the metric that matters, not line count. As I showed earlier, a 97-line HTML file can be 4.5x larger than the portion of a 6,000-line markdown file that an agent can process.
"The lack of transparency here isn’t just an inconvenience. It’s a real barrier to the agent-friendly docs movement. 

"Documentarians can’t optimize for constraints they can’t see. We’re left running experiments, comparing notes, and hoping the platforms eventually decide to tell us what’s going on under the hood."

Comments

Popular posts from this blog

Hamza Chaudhry

When their AI chums have Bob's data

Swarm 🦹‍♂️