关于 gr-seo-patrol
用于日常 SEO/GEO 检查与内容诊断的 Skill,适合负责网站搜索表现的团队。它汇总排名、索引、llms.txt 和 GA4 检查,并提供文章修复及全站审计流程。
主要功能
- 01关键词排名日报与异常提示
- 02索引、llms.txt 和 GA4 检查
- 03关键词及落地页诊断
- 04批量修复 canonical
- 05文章 SEO 修复与全站审计
适用场景
- 01每日查看关键词排名变化
- 02排查关键词排名下降原因
- 03批量统一同主题文章的 canonical
- 04审计网站页面和结构化数据
安装
复制下面的命令,在终端中运行。
npx skills add https:/ / github.com/ gingiris-1031/ gingiris-skills --skill gr-seo-patrol安装后在 Claude Code 中输入/gr-seo-patrol确认已加载。
包含的文件
除 SKILL.md 外,安装时一起下载的参考资料和脚本。
gr-seo-patrol/scripts/canonical-fix.pycheck-page.pycheck-schema.pycheck-site.pycheck-social.pydaily-report.pyREADME.mdrescue-post.pyscripts/canonical-fix.pycheck-page.pycheck-schema.pycheck-site.pycheck-social.pydaily-report.pyREADME.mdrescue-post.py详细介绍
gr-seo-patrol — SEO/GEO 日常巡逻
什么时候用
| 场景 | 动作 |
|---|---|
| "跑今日 SEO 日报" | 执行完整巡逻(scripts/daily-report.py) |
| "某关键词排名掉了" | 单词诊断(Claude 直接执行下方诊断流程) |
| "修 canonical" | 批量合并(scripts/canonical-fix.py) |
| "救一下这篇文章" | 社媒救援(scripts/rescue-post.py)—— title 前置 + 3 个高权重内链 |
| "检查 GA4 部署" | 扫 HTML 里的 G-XXXXX tag |
| "查 llms.txt" | HTTP 200 + 字节数 |
核心流程
1. 日报模式
输入:无(全自动) 或 指定关键词清单 输出:
- 关键词排名 diff 表(今日 vs 昨日基线)
- Google 索引数
- llms.txt 状态
- GA4 覆盖状态
- 🚨 异常提示(跌出 top 100、整体刷新)
2. 单词诊断
输入:1 个关键词 过程:
- 跑 4-5 个 long-tail 变体 SERP
- 检查目标 URL 是否 HTTP 200
- 用
site:查询确认是否索引 - 对比 3 天前的数据(如果有历史)
- 2026-06-24 新增检查:
- 确认关键词在 volume 300–1,000 / KD 5–35 区间(若不在,标注为低优先级)
- 检查该页面 title 是否含 best/free/top/guide+年份(CTR 公式)
- 检查该页面内链密度是否超 2-3/段
- 确认页面有 BreadcrumbList schema
- 确认 last-updated 日期已展示(freshness 信号) 输出:雪崩 / 个别 / SERP 刷新 / 死链 四选一,附 2026 合规评分
3. Canonical 批量修复
输入:同主题的 N 篇文章 + 1 个 master URL
过程:替换每篇 frontmatter 里的 canonical_url: → master,GitHub API PUT
安全护栏:
- 只改
_posts/下的 .md - 每篇 commit 独立(方便回滚)
- 跳过 ja/ko(hreflang 替代,保持 self-canonical)
4. 社媒救援
输入:1 个雪崩 URL 动作:
- a. 重写 title:主关键词前置,长度 ≤ 60 字,必须含 best/free/top/guide+年份(2026-06-24 CTR 公式)
- b. 重写 meta description:关键词 rephrase(如 "figma alternative" → "the alternative to Figma")
- c. 从 top-3 高权重文章注入内链(带 anchor text = 目标关键词),每段 ≤ 2-3 个内链上限
- d. 主动添加 1-2 个竞品 blog 外链(提信用分 → 提 ranking)
- e. 检查并添加/更新【最后更新日期】(freshness 信号)
- f. 确认 BreadcrumbList schema 已配置
- g. 记录修改前后到日志
API 依赖
| Service | Env var | 用途 |
|---|---|---|
| DataForSEO | DATAFORSEO_B64 | SERP 查询 |
| GitHub PAT | GITHUB_TOKEN | 读写 _posts/ |
完整 key 模板见 docs/api-keys-template.md。
SERP 查询模板
import urllib.request, json
def serp(kw, loc=2840, lang="en", depth=100):
key = os.environ["DATAFORSEO_B64"]
payload = json.dumps([{"keyword": kw, "location_code": loc,
"language_code": lang, "device": "desktop",
"depth": depth}]).encode()
req = urllib.request.Request(
"https://api.dataforseo.com/v3/serp/google/organic/live/advanced",
data=payload,
headers={"Authorization": f"Basic {key}",
"Content-Type": "application/json"})
with urllib.request.urlopen(req, timeout=40) as r:
return json.loads(r.read())
常用 location_code:
- 2840 US / 2826 UK / 2392 JP / 2410 KR / 2156 CN(无效,中国不返回)
执行脚本
实际可执行的脚本在 scripts/ 下:
daily-report.py— 完整日报canonical-fix.py— canonical 批量合并rescue-post.py— 社媒文章救援diag-keyword.py— 单关键词诊断(roadmap,暂用下方「单词诊断」流程替代)
每个脚本独立可跑。调用时优先用 Bash 工具,不要重写脚本。
输出规范
- 先给表格,再给结论
- 差异用箭头:
#6 ↑/#19 ↓↓ - 超过 3 项异常 → 单独开"🚨 异常"一节
- 所有排名必须带 location_code,不要假设
级联推荐
- 发现 cannibalization(同一关键词多篇排名接近) →
gr-blog-post做 canonical 整合 - 发现 N 个关键词同日跌出 top 100 → 先等 24h,不要硬改内容
- 发现新关键词机会(长尾 top 30) →
gr-blog-post扩写
反模式
- ❌ 不要用
grep/find扫_posts/,改用 GitHub Contents API - ❌ 不要在生产环境直接
git push—— 用 Contents API 的 PUT - ❌ 不要一次 serp 50 个关键词 —— 批量过大易触发 rate limit,按 6-10 个一批
- ❌ canonical 改到 master 后不要立刻 force Google 重新索引 —— 等 3-7 天自然爬取
Monthly Full-Site Audit Workflow
Validated 2026-05-07 on 58 pages: caught 43 SERP-truncating titles + 36 schema warns + 27 stop-word slugs in a single 30-min pass. Single layout-level fix (commit
24a0410e) resolved 20 of 43 title issues.
Run once per month before phase2-monthly-checkpoint. Output: HTML report + machine-readable findings.json archived to ~/Downloads/seo-audit/audit-{YYYY-MM-DD}.json.
Stage 1 — Discovery (5 min)
import urllib.request, re
sm = urllib.request.urlopen("https://gingiris.tools/sitemap.xml").read().decode()
urls = [u for u in re.findall(r"<loc>([^<]+)</loc>", sm) if "/blog/" in u]
# typically 50-70 URLs
Stage 2 — Parallel Audit (20 min for 60 pages, 4 threads)
Use the adopted seo-audit-skill scripts in scripts/:
# For each URL — run 2 scripts in parallel
python3 scripts/check-page.py URL --timeout 20 # title, H1, meta, canonical, slug, alt, keyword placement
python3 scripts/check-schema.py URL --timeout 20 # JSON-LD validation
Or batch with Python's concurrent.futures.ThreadPoolExecutor(max_workers=4). Don't go higher than 4 — GitHub Pages CDN throttles aggressive parallel hits.
Each script outputs structured JSON envelope:
{"field": {"status": "pass|warn|fail|info", "detail": "...", "llm_review_required": false}}
Stage 3 — Aggregate Findings
Bucket by category:
- Title length > 70 chars (SERP truncation risk)
- H1 length > 70 chars (mobile readability)
- Meta description < 80 or > 170 chars
- Schema warns by @type (BlogPosting, Article, Organization)
- Canonical issues (mismatch with final URL)
- Slug issues (stop words, uppercase, missing keyword)
- Image alt text missing on content images
Save aggregated counts + per-issue URL lists to findings.json.
阶段 4 — 分层修复策略(高投资回报率优先)
1️⃣ 优先修复布局层(1 次提交,修复 20 多个页面):
_layouts/default.html中的 Schema 错误<title>标签中的站点名称后缀last_modified_atfrontmatter 中缺少dateModified- Organization / Publisher / contactPoint 完整性
2️⃣ 修复配置层(1 次提交,修复全站问题):
_config.yml— logo URL(必须为绝对 URL)、twitter、social、author 结构
3️⃣ 批量修复各篇文章(每个文件 1 次提交,可并行处理):
- 缩短过长的标题,同时保留关键词(目标 ≤ 70 个字符,理想范围为 50–60 个字符)
- 缩短过长的 H1(目标 ≤ 70 个字符)
- 扩充过短的 meta description(目标为 120–160 个字符)
- 为 GSC 展示量最高的页面补充缺失的 Citable Statistics 区块
4️⃣ 跳过以下项目(投资回报率低):
- Slug 中的停用词(更改会导致 301 重定向失效)
- 每月展示量低于 50 的旧文章(流量低,修复优先级低)
阶段 5 — 验证(Jekyll 重建后约 60–90 秒)
对示例页面重新运行 check-schema.py。确认以下项目至少显示 status: pass:
Article · BlogPosting · Organization · FAQPage
阶段 6 — 归档
将 findings.json 提交至 ~/Downloads/seo-audit/audit-{YYYY-MM-DD}.json,用于趋势追踪。
添加 2–5 条 atoms,记录任何新近总结的经验。
严格规则(防止幻觉的护栏)
采用自 JeffLi1993/seo-audit-skill 的严格白名单模式。
⛔ 仅输出审计脚本 JSON 封装中定义的检查项。
- 不要添加脚本输出中没有的“额外”检查项
- 除非有额外的可观察证据,否则不要与脚本的
status字段矛盾 - 不要编造“EEAT 得分 89”之类的指标 — 第三方评分工具并非官方工具(依据 Google 的 2026 年指导)
- 不要在判断说明中包含标记为
llm_review_required: false的检查项 — 脚本的status即为最终结果 - 如果
llm_review_required: true,请明确给出判断并记录推理,然后更新状态
脚本封装是唯一的事实来源。请将其视为严格白名单。
配套 skill
对于单页审计(非全站审计),相同脚本也支持 JeffLi1993/seo-audit-skill,可生成精美的 HTML 审计报告。 如果你需要可展示给客户的单页审计报告,可以将其安装为配套 skill。
平台描述
EN: 每日 SEO/GEO 巡检 skill(2026-06-24 标准)。追踪 SERP 关键词排名(DataForSEO,筛选 volume 300–1,000 / KD 5–35),检查 Google 索引数量、llms.txt 可访问性、GA4 标签部署及 AI 流量渠道分组。通过应用标题公式(best/free/top/guide+年份)、在 meta description 中改写关键词、强制执行内链密度(每段 ≤2–3 个)、插入指向竞品博客的外链、检查 BreadcrumbList Schema、更新内容日期,挽救表现不佳的帖子。修复 canonical 问题。
ZH: 每日 SEO/GEO 巡逻 skill(2026-06-24 标准)。追踪 SERP 排名(DataForSEO,筛选 volume 300–1,000 / KD 5–35),检查 Google 索引数、llms.txt 可达性、GA4 部署及 AI 流量频道分组。挽救表现不佳的文章:标题包含 best/free/top/guide+年份、在 meta description 中改写关键词、内链密度 ≤2–3 个/段、主动引用竞品外链、BreadcrumbList Schema、更新内容日期、修复 canonical。
JA: 每日 SEO/GEO 巡逻 skill(2026-06-24 标准)。追踪 SERP 排名(DataForSEO,筛选 volume 300–1,000 / KD 5–35),检查 Google 索引数量、llms.txt、GA4 标签及 AI 流量渠道设置。挽救表现不佳的文章:标题包含 best/free/top/guide+年份、改写 meta description 关键词、内链密度 ≤2–3 个/段落、插入竞品博客外链、BreadcrumbList Schema、更新内容日期、修复 canonical。
KO: 每日 SEO/GEO 巡逻 skill(2026-06-24 标准)。追踪 SERP 排名(DataForSEO,筛选 volume 300–1,000 / KD 5–35),检查 Google 索引数量、llms.txt 可访问性、GA4 标签及 AI 流量渠道分组。挽救表现不佳的帖子:标题采用 best/free/top/guide+年份、改写 meta description 关键词、内链密度 ≤2–3 个/段落、插入竞品博客外链、BreadcrumbList Schema、更新内容日期、修复 canonical。
加入出海社群与购买资料包 · 社群与资料
-
加入出海社群: 微信添加 staywildgrow,留言「加入社群」即可。
-
购买资料包: 微信添加 staywildgrow,咨询购买 Gingiris 出海资料包,价格 599 元人民币。
-
加入全球增长社群: 在微信添加 staywildgrow,发送 “加入社群”。
-
获取资料包: 在微信添加 staywildgrow,即可购买 Gingiris 全球增长资料包,价格为 599 元人民币。
社群与资料包为可选入口,不影响本开源 Skill 的安装和使用。
社群和付费资料包均为可选项,安装或使用此开源 Skill 均不需要加入社群或购买资料包。