Skip to content

fix(agent-docs): fix llms.txt missing 16 reference pages + rename References index title#194

Merged
marc0olo merged 1 commit intomainfrom
infra/fix-llms-txt-references-coverage
May 5, 2026
Merged

fix(agent-docs): fix llms.txt missing 16 reference pages + rename References index title#194
marc0olo merged 1 commit intomainfrom
infra/fix-llms-txt-references-coverage

Conversation

@marc0olo
Copy link
Copy Markdown
Member

@marc0olo marc0olo commented May 5, 2026

Summary

  • plugins/astro-agent-docs.mjs: Fixed a bug in deriveSections() where explicit { slug } sidebar entries were silently ignored when computing the common-prefix fallback for a group. The References section uses explicit slugs for 15 pages (only ic-interface-spec/ used autogenerate), so the fallback resolved to references/ic-interface-spec instead of references. All 16 pages under references/ were excluded from llms.txt as a result. Fix: also collect directory prefixes from direct { slug } children when computing the group fallback.
  • docs/references/index.md: Renamed page title from "Reference" to "References".

Impact

llms.txt coverage goes from 142/158 (90%) to 158/158 (100%), clearing the llms-txt-coverage warning in the afdocs check output.

Sync recommendation

hand-written

…ctions

The deriveSections() function only processed autogenerate and items
entries, silently skipping { slug } entries. The References section uses
explicit slugs for 15 pages, so the common-prefix fallback resolved to
references/ic-interface-spec instead of references, leaving all 15 pages
(plus references/index.md and references/developer-tools) out of llms.txt.

Fix: collect directory prefixes from direct { slug } children when
computing the common-prefix fallback for a group. This gives the
References group a { dir: "references" } section entry so all 16 pages
are correctly included.

Also rename references/index.md title from "Reference" to "References".
@marc0olo marc0olo requested a review from a team as a code owner May 5, 2026 07:52
Copy link
Copy Markdown

@ggreif ggreif left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Other than the silly (c) => (could be c => ), looks good to me!

@marc0olo
Copy link
Copy Markdown
Member Author

marc0olo commented May 5, 2026

@ggreif thanks, the silly (c) => is used in other places on the file already. I will leave it for now and if somebody cares we can fix all at once.

@marc0olo marc0olo merged commit 87db4c5 into main May 5, 2026
7 checks passed
@marc0olo marc0olo deleted the infra/fix-llms-txt-references-coverage branch May 5, 2026 09:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants