Skip to content

Exclude legacy V0 pages from llms.txt context files#359

Open
enyst wants to merge 7 commits intomainfrom
llms-v1-only
Open

Exclude legacy V0 pages from llms.txt context files#359
enyst wants to merge 7 commits intomainfrom
llms-v1-only

Conversation

@enyst
Copy link
Collaborator

@enyst enyst commented Feb 24, 2026

Mintlify auto-generates /llms.txt and /llms-full.txt from all public pages.

We want those LLM context files to include V1-only content, while we keep legacy V0 pages available for humans.

This PR overrides Mintlify's auto-generated files by committing custom llms.txt and llms-full.txt generated from V1-only docs pages.

What changed

  • Add and document a generator script: scripts/generate-llms-files.py
  • Commit generated llms.txt and llms-full.txt at the repo root (Mintlify override)
  • Exclude legacy V0 pages from both files:
    • anything under openhands/usage/v0/
    • any page whose filename starts with V0*
  • Make sections explicit and ordered for clarity:
    1. OpenHands Software Agent SDK
    2. OpenHands CLI
    3. OpenHands Web App Server
    4. OpenHands Cloud
    5. OpenHands Overview

How to regenerate

./scripts/generate-llms-files.py

References:

Co-authored-by: openhands <openhands@all-hands.dev>
Co-authored-by: openhands <openhands@all-hands.dev>
Co-authored-by: openhands <openhands@all-hands.dev>
Co-authored-by: openhands <openhands@all-hands.dev>
Copy link
Contributor

@all-hands-bot all-hands-bot left a comment

Choose a reason for hiding this comment

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

🟡 Acceptable - Pragmatic but needs automation

THE GOOD:
Solving a real problem (V0/V1 doc confusion) with a straightforward solution. Overriding Mintlify's auto-generation is pragmatic when they don't offer exclude configs.

THE RISK:
33K+ lines of generated content committed to git with no visible CI safeguards. These files will become stale the moment someone updates docs without re-running the generator.

VERDICT: ✅ Worth merging - core approach is sound, but add automation or accept manual maintenance burden.

KEY INSIGHT: Good taste favors generated artifacts that can't drift (built on-demand) over committed artifacts that can (require discipline). If committing is necessary, CI checks are non-negotiable.

Co-authored-by: openhands <openhands@all-hands.dev>
Co-authored-by: openhands <openhands@all-hands.dev>
Copy link
Collaborator Author

enyst commented Feb 26, 2026

Added a small ergonomics layer so keeping / fresh is easy:\n\n- python3 scripts/generate-llms-files.py regenerates both files\n- python3 scripts/generate-llms-files.py
git diff --exit-code llms.txt llms-full.txt regenerates + diffs (same behavior as CI)\n\nDocumented in (since agents touch this repo frequently).

Copy link
Collaborator Author

enyst commented Feb 26, 2026

Added a small ergonomics layer so keeping llms.txt / llms-full.txt fresh is easy:

  • make llms regenerates both files
  • make llms-check regenerates + diffs (same behavior as CI)

Documented in AGENTS.md (since agents touch this repo frequently).

@enyst
Copy link
Collaborator Author

enyst commented Feb 27, 2026

@OpenHands why is CI failing? We just added that job to verify llms.txt, in THIS PR, and the PR is updated from main. Fix it please.

@openhands-ai
Copy link

openhands-ai bot commented Feb 27, 2026

@enyst your session has expired. Please login again at OpenHands Cloud and try again.

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.

3 participants