seo-sitemaps
Audit and generate sitemaps and discovery files — validate XML sitemap presence/size/extensions/lastmod, check robots.txt referencing and sitemap-to-canonical consistency, reconcile orphans against the link graph, and produce repaired sitemap entries plus a robots.txt Sitemap line. Module M17. Feeds the Search SEO score.
适合你,如果你需要确保网站站点地图正确无误以提升搜索引擎排名。
用别的 agent?下载 .zip 解压,把文件夹放进它的技能目录
~/.claude/skills/(项目级 .claude/skills/)~/.codex/skills/npx oh-my-skill add hainrixz/claude-seo-ai/seo-sitemapscurl -fsSL https://oh-my-skill.com/install.sh | bash -s -- hainrixz/claude-seo-ai/seo-sitemapsnpx oh-my-skill verify hainrixz/claude-seo-ai/seo-sitemaps怎么用
技能原文 SKILL.md
seo-sitemaps (M17)
Sitemaps are the discovery contract you hand the crawler — they should list exactly the canonical, indexable URLs and nothing else. Schema rules for related markup: references/schema-tier1.md.
Audits
Working from the PageSnapshot (rendered_dom if present, else raw_html) plus fetched /sitemap.xml and /robots.txt:
- Presence & validity: locate XML sitemap(s) (
/sitemap.xml, robotsSitemap:lines, sitemap index); parse as well-formed XML against the sitemaps.org schema. - Size limits: each sitemap
<=50,000URLs and<=50MBuncompressed; if exceeded, expect a sitemap index splitting the set. - Extensions: where relevant, validate
image:,video:, andnews:namespace entries (correct namespace declared, required child elements present). - lastmod accuracy:
<lastmod>is valid ISO 8601 and reflects real last-modified time — not a build-time stamp on every URL (which trains crawlers to ignore it). - robots referencing: at least one absolute
Sitemap:line inrobots.txt. - Sitemap-to-canonical consistency: no URL in the sitemap is
noindex, redirected, 4xx/5xx, or non-canonical (self-referencing canonical only). Cross-check indexability with M-indexability. - Orphan reconciliation: diff sitemap URLs against the internal link graph — flag indexable pages absent from the sitemap and sitemap URLs unreachable by internal links.
Fixes
- AUTO: generate or repair XML sitemap entries (correct
<loc>, accurate<lastmod>from observed last-modified data, validimage:/video:extension children where media exists) and add an absoluteSitemap:line torobots.txt. These are additive/deterministic diffs forfix. - PROPOSED: removing or splitting entries (e.g. dropping non-canonical/noindex URLs, sharding into a sitemap index) — drafted, accepted per-item.
- ADVISORY: changing site-wide lastmod strategy or canonical decisions — described, never written by the tool.
- Never fabricate lastmod times, media URLs, or canonical targets — pull from observed data, ask the user, or leave a clearly-marked
TODOplaceholder per the schemafixablecontract.
Verification
- Offline:
node ${CLAUDE_SKILL_DIR}/../../scripts/parse-robots-sitemap.mjs --url <u>— methodxml_parse: parses robots.txt + sitemap XML, checks well-formedness, size caps, namespace/extension validity, and the canonical/noindex consistency assertion. - When the required data tier (live fetch of sitemap/robots, or the resolved link graph) is unavailable, status is
needs_api— never a falsepass.
Findings
Emit findings per schema/finding.schema.json. Examples:
M17.sitemap.missing— no XML sitemap found at/sitemap.xmlor in robots.txt (statusfail, severity 3,fixable: auto, axissearch, confidenceestablished).M17.robots.no_sitemap_line— sitemap exists but noSitemap:line in robots.txt (statuswarn, severity 3,fixable: auto, axissearch, confidenceestablished).M17.sitemap.noindex_url— a<loc>in the sitemap points to anoindex/non-canonical URL (statusfail, severity 3,fixable: proposed, axissearch, confidenceestablished).
Each finding: evidence.observed quotes the page/sitemap verbatim; verification.reproduce is the runnable command above; expected_impact is banded + confidence-tagged (no naked %).
Honesty
- A sitemap is a discovery aid, not a ranking signal or an indexing guarantee — Google treats
<lastmod>,<priority>, and<changefreq>as hints, and<priority>/<changefreq>are largely ignored, so don't promise ranking lift from tuning them (label any such tactic low-magnitude/directional). - Submitting a sitemap won't force indexing of low-quality or non-canonical pages; orphan and canonical hygiene matters more than sitemap size.