documentation-layout - tier the validator, replace hardcoded cap numbers in docs with pointer references #82
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Problem
Markdown size caps are restated in at least 8 places across
agentic-osandagentic-os-kai, with two conflicting numbers depending on which doc you land on:500 lines / 10 KB(loader-bound files: AGENTS.md, SKILL.md)80 lines / 4000 chars(regular Markdown viadocumentation-layouthook)agentic-os-kai/AGENTS.mdcontradicts itself within the same file (L5 says 500/10KB, L68 says 80/4000, L304 says 500/10KB again).Inventory of hardcoded numbers:
agentic-os-kai/AGENTS.mdlines 5, 68, 304agentic-os/docs/skill-discipline/handbook.mdline 178agentic-os/docs/skill-discipline/authoring-walkthrough.mdline 40agentic-os/docs/skill-discipline/templates/SKILL.md.templateline 24agentic-os/.agents/skills/tooling-skill-authoring/references/authoring-walkthrough.mdlines 36, 56agentic-os/.agents/skills/tooling-skill-authoring/references/handbook.mdlines 104, 245, 247, 267Fix
Two parts:
Tier the validator.
agentic_os/check_documentation_layout.pycurrently has a single cap. AddLOADER_BOUND_BASENAMES = {"AGENTS.md", "CLAUDE.md", "SKILL.md"}withLOADER_MAX_LINES = 500,LOADER_MAX_CHARS = 10_000. Apply the higher tier when basename matches; fall back toMAX_MARKDOWN_LINES/MAX_MARKDOWN_CHARS(80 / 4_000) otherwise. After this, the validator is a single source of truth for both caps.Replace hardcoded numbers in docs with pointer references. Each callsite gets rewritten to point at the validator instead of restating the number, so the docs can never drift again. Format:
No numbers in the prose. The validator is read directly when anyone needs the value.
Out of scope
agentic-ositself pass the hook (#81). This issue just stops the docs from disagreeing; it doesn't fix any size violations.Acceptance
check_documentation_layouthas two named cap tiers, both as module-level constants.grep -rn '500 lines\|10 KB\|80 lines\|4000 char'against both repos returns only matches inside the validator source file itself.