Skip to content

Commit 47ddfbe

Browse files
authored
Merge pull request #1501 from Concordium/update-maintenance-commands
Add llms.txt maintenance steps to /add-doc and /remove-doc commands
2 parents 25568eb + e606eb2 commit 47ddfbe

3 files changed

Lines changed: 21 additions & 2 deletions

File tree

.claude/commands/add-doc.md

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,15 @@ Add a `:doc:` entry for the new page under the correct section heading in the tw
109109

110110
The rules for map labels are in `CLAUDE.md` under *Documentation Maintenance*.
111111

112-
## Step 8: Confirm
112+
## Step 8: Update llms.txt
113+
114+
Check whether the new page should be listed in `public/llms.txt` as a key entry point. Ask the maintainer: "Should this page be added to llms.txt as a key entry point for AI assistants? This is appropriate for pages that cover important concepts, common tasks, or major features that developers are likely to ask about."
115+
116+
If yes, add an entry under the correct section in `public/llms.txt` following the existing format:
117+
```
118+
- [Nav label](https://docs.concordium.com/en/mainnet/<path>.html): Short description
119+
```
120+
121+
## Step 9: Confirm
113122

114123
Show the maintainer a summary of everything that was created or changed and ask them to review.

.claude/commands/remove-doc.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,10 @@ Find the toctree in the parent `index.rst` that references this page and remove
2626

2727
Find the `:doc:` entry for this page in the relevant section landing page map and remove it. If the page had sub-page entries listed below it, remove those too. If removing the entry leaves a section heading with no entries, remove the heading as well.
2828

29-
## Step 6: Confirm
29+
## Step 6: Update llms.txt
30+
31+
Check whether the removed page is listed in `public/llms.txt`. If it is, remove the entry. If the removal leaves a section with no entries, remove the section heading as well.
32+
33+
## Step 7: Confirm
3034

3135
Show the maintainer a summary of everything that was removed or changed and ask them to review.

CLAUDE.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,3 +86,9 @@ The four section landing pages each contain a **manually maintained document map
8686
### Why manual maps?
8787

8888
An automatic approach (visible toctrees with `maxdepth: 2`) was considered but rejected because it renders plain indented lists instead of the current two-column grid layout. The manual maps look significantly better and the maintenance overhead is low when AI handles the updates as part of every structural change.
89+
90+
### llms.txt
91+
92+
`public/llms.txt` is a machine-readable index of key entry points in the documentation, following the [llms.txt standard](https://llmstxt.org/). It helps AI assistants discover and understand the documentation structure.
93+
94+
**Keep it current:** When adding or removing a page that covers an important concept, common task, or major feature, update `public/llms.txt` accordingly. The `/add-doc` and `/remove-doc` commands include a step for this.

0 commit comments

Comments
 (0)