Skip to content

Add /llms.txt and /llms-full.txt via payload-plugin-llms-txt - #2

Open
logankuzyk wants to merge 4 commits into
mainfrom
feat/llms-txt
Open

Add /llms.txt and /llms-full.txt via payload-plugin-llms-txt#2
logankuzyk wants to merge 4 commits into
mainfrom
feat/llms-txt

Conversation

@logankuzyk

Copy link
Copy Markdown
Owner

Summary

  • Registers payload-plugin-llms-txt (a new plugin published as part of this work — repo) in src/plugins/index.ts for the Posts, Projects, and Pages collections.
  • Adds /llms.txt and /llms-full.txt Next.js route handlers, mirroring the existing sitemap route pattern (unstable_cache + tags) already used for *-sitemap.xml.
  • Includes the plugin's optional admin-editable settings global ("LLMs.txt Settings" — enable toggle + intro override), reflected in the regenerated payload-types.ts.
  • Bumps payload-plugin-llms-txt to the published ^0.2.0 (supports fallback description fields, e.g. a dedicated llmsDescription field falling back to the SEO meta.description) — not yet wired up to a dedicated field in this PR, still using meta.description directly.
  • Adds .claude/launch.json for local dev-server preview tooling.

Closes the "Generate LLM txt" and "LLMs.txt support - want a way of updating it within the payload dashboard" items from the personal-website task list.

Test plan

  • npx tsc --noEmit passes
  • npm run lint passes (no new warnings)
  • npm ci succeeds against the regenerated lockfile
  • Verified locally: /llms.txt and /llms-full.txt render real published content (Pages), correctly exclude unpublished Posts/Projects
  • Verified the settings global: enable toggle blanks output, intro override replaces the default site description
  • Follow-up (separate, not in this PR): add a dedicated llmsDescription field to Pages/Posts/Projects and wire descriptionField: ['llmsDescription', 'meta.description']

🤖 Generated with Claude Code

logankuzyk and others added 4 commits August 1, 2026 11:15
…-llms-txt

Registers the payload-plugin-llms-txt plugin for Posts, Projects, and
Pages, adds Next.js route handlers at /llms.txt and /llms-full.txt
mirroring the existing sitemap route pattern (unstable_cache + tags),
and includes the plugin's optional admin-editable settings global
(enable toggle + intro override) in the regenerated payload-types.ts.

Also adds .claude/launch.json for the dev server preview tooling.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
The previous commit's lockfile was produced by a full rm -rf
node_modules package-lock.json && npm install, which re-resolved
every transitive dependency rather than just the new one. That
silently changed something that broke `payload generate:importmap`
in CI (npm 10, unlike local npm 11) even though direct version
pins looked identical.

Redone surgically: restore package.json/package-lock.json to the
branch point and add only payload-plugin-llms-txt via a scoped
`npm install`, so the diff is 18 lines instead of ~4800.
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.

1 participant