tools/generate_sitemaps.py).
When to use this skill
- When creating or modifying markdown files and needing to ensure sitemaps and search indexes are updated.
- When validating the integrity of
SUMMARY.mdnavigation links for GitBook compatibility. - When diagnosing robots.txt, sitemap.xml, or sitemap.txt indexing pathways.
How to use it
1. Execute Sitemap & SEO Generation
AI agents execute sitemap generation natively viauv run (Rule 16 Mandate):
2. Validation and Output Locations
The script performs the following actions:- Builds the MkDocs site (
site/folder) to compile the base sitemap. - Parses
site/sitemap.xmlfor all GitHub Pages URLs. - Derives all corresponding Read the Docs URLs.
- Processes
SUMMARY.mdto map and validate all GitBook URLs. - Ensures all referenced markdown files exist in the repository to prevent broken links.
- Writes three files (
sitemap.txt,sitemap.xml, androbots.txt) to the root,docs/, andsite/directories.
Quality Gates & Compliance
- Rule 16 (
uvMandate): Never execute with raw python or pip; always useuv run. - Rule 25 (BOM-less & Quoting): Ensure all sitemaps are generated with valid absolute URIs.
Deep State of Mind (DSOM) For My AI Protocol | Harisfazillah Jamel (LinuxMalaysia) | 2026-08-12 Standard: UK English | DBP-standard Bahasa Melayu Malaysia (Piawai) | GNU General Public License v3.0