seo-drift
The seo-drift command compares two SEO performance snapshots from Google Search Console, GSC AI Performance reports, rank trackers, or AEO probes and classifies changes as growth, decline, reshuffle, stable, new, or lost. Use it to analyze metric movements across weeks, algorithm updates, content refreshes, or site migrations, with outputs including gainers and losers analysis, quality gates validation, and (for GSC AI) citation drift cross-reference against audit results.
mkdir -p ~/.claude/commands && curl -fsSL https://raw.githubusercontent.com/indranilbanerjee/digital-marketing-pro/HEAD/commands/seo-drift.md -o ~/.claude/commands/seo-drift.mdseo-drift.md
# SEO Drift
> If you see unfamiliar placeholders or need to check which data sources are connected, see [CONNECTORS.md](../CONNECTORS.md).
Takes two snapshots of SEO performance data — separated by weeks, a Core Update, a content refresh, or an algorithm change — and produces a structured drift report. Works with classic GSC exports, the new GSC AI Performance Report (3 Jun 2026), rank-tracker exports, and `aeo-audit` probe results. Routes to `skills/seo-drift/SKILL.md`.
## Trigger
User runs `/digital-marketing-pro:seo-drift` or asks for:
- "Compare this month vs last month"
- "What changed since the Core Update?"
- "Track AI Mode citation drift"
- "Before/after for the content refresh"
- "Site migration impact audit"
## Inputs
1. **Baseline CSV** — older snapshot
2. **Current CSV** — newer snapshot
3. **Source type** — auto-detected via columns (GSC / GSC AI / rank tracker / AEO probe). Both snapshots must be from same source.
4. **Noise threshold** (optional) — default 5%, below which moves are classified `stable`. YMYL industries should use 10% to filter out Quality Rater Guidelines volatility.
## Process
1. Load brand context
2. Place baseline + current CSV exports into the dated output folder
3. Run `scripts/seo_drift.py` to compute per-row deltas + classifications
4. Validate the four quality gates (date_range_distinct / sample_size / metric_compatibility / no_lookup_collisions)
5. Narrative analysis of top 10 gainers (cause hypotheses → amplification candidates)
6. Triage matrix for top 10 losers (`is_yMYL × had_recent_change × Core_Update_window` → action)
7. If source is GSC AI Performance Report: cross-reference AI Mode citation losses with `/digital-marketing-pro:aeo-audit`
8. Classification distribution analysis (high reshuffle = AI Mode intent reweighting)
9. Write `PLAN.md` to `${CLAUDE_PLUGIN_DATA}/{brand}/seo/seo-drift/{date}/`
## Output
Numbered intermediate files under `${CLAUDE_PLUGIN_DATA}/{brand}/seo/seo-drift/{YYYY-MM-DD}/`:
- `00-input.md`, `01-baseline.csv`, `02-current.csv`
- `03-drift-run.json` (raw script output), `04-quality-scorecard.md`
- `05-biggest-gainers.md`, `05-biggest-losers.md`
- `06-ai-mode-shift.md` (only when source is GSC AI Performance Report)
- `07-classification-distribution.md`
- `PLAN.md` (the deliverable)
## After the drift
Branch by finding:
- **High decline (>40% of rows)**: "Likely Core Update or competitor catch-up. Run `/digital-marketing-pro:seo-audit` for diagnosis."
- **High reshuffle (>20% of rows)**: "Likely intent shift (AI Mode reweighting). Run `/digital-marketing-pro:aeo-geo` to align with new intent patterns."
- **High growth (>30% of rows)**: "Find amplification opportunities. Run `/digital-marketing-pro:content-engine` to brief follow-ups."
- **High new (>15% of rows)**: "New SERP coverage — track and validate intent fit."
For the full skill spec including classification rules, position-delta inversion, and Core Update timing guidance, see [skills/seo-drift/SKILL.md](../skills/seo-drift/SKILL.md).Design a statistically rigorous A/B or multivariate test plan — If/Then/Because hypothesis, control and variant specs, required sample size per variant (absolute vs relative MDE via sample-size-calculator.py), test duration, guardrail metrics, stopping rules, and go/no-go decision criteria. Triggers on \"/digital-marketing-pro:ab-test-plan\", \"set up an A/B test\", \"how long should my test run\", \"calculate sample size for an experiment\", \"is this test result significant\". Reads the brand profile and past campaign-tracker results to avoid re-testing validated hypotheses; finished tests are evaluated with significance-tester.py by the cro-specialist agent.
Generate 3-5 ad copy variations per platform — headlines, descriptions, and CTAs formatted to Google, Meta, LinkedIn, TikTok, X, and Pinterest specs — each scored 1-10 with policy-compliance flags, A/B testing groupings, and a message-match check against the landing page. Triggers on \"/digital-marketing-pro:ad-creative\", \"write ad copy for Meta\", \"give me RSA headline variations\", \"we need LinkedIn ad copy\", \"draft TikTok ad creative\". Reads the brand profile, guidelines, and compliance rules; routes video ad scripts to /digital-marketing-pro:video-script and gates AI-generated visuals for EU campaigns through /digital-marketing-pro:c2pa-metadata and /digital-marketing-pro:check.
Walk through adding a custom MCP server integration to the plugin — searches npm for an existing MCP package (or scaffolds a custom server from the plugin's guide), generates the exact .mcp.json entry, sets up environment-variable credentials, tests connectivity, and documents the tools the new server exposes. Triggers on \"/digital-marketing-pro:add-integration\", \"connect Ahrefs to the plugin\", \"add a new MCP server\", \"integrate our internal API\", \"hook up Stripe data\". Reads the brand profile and agency credential profiles at ~/.claude-marketing/credentials/ to map client-specific keys; custom builds follow skills/context-engine/custom-mcp-guide.md.
Audit how a brand appears across the 6 canonical AI answer surfaces — ChatGPT, Perplexity, Google AI Mode, AI Overviews, Gemini, Copilot — probing 10-25 queries into a numbered output bundle with per-platform visibility scorecards, citation-accuracy checks, a competitor matrix, content gaps, and an optimization playbook behind a four-gate quality scorecard. Triggers on \"/digital-marketing-pro:aeo-audit\", \"does ChatGPT know about our brand\", \"check our AI search visibility\", \"how does Perplexity describe us\", \"are we showing up in AI Overviews\". Reads the brand profile; reconciles probes against GSC actuals via /digital-marketing-pro:gsc-ai-performance and defines the AI-visibility scoring standard reused by geo-monitor and share-of-voice.
Strategy module for Answer Engine / Generative Engine Optimization — audits AI visibility, restructures content for citation, runs entity-consistency checks across Knowledge Graph, Wikidata, Wikipedia, Crunchbase, and LinkedIn, and produces JSON-LD schema specs, monitoring frameworks, and a 90-day LLM content strategy. Triggers on \"/digital-marketing-pro:aeo-geo\", \"how do we get cited by AI\", \"optimize for AI Overviews\", \"fix our entity consistency\", \"do we need llms.txt\". Reads the brand profile, compliance rules, and industry benchmarks; its measurement counterpart is /digital-marketing-pro:aeo-audit, with GSC actuals via /digital-marketing-pro:gsc-ai-performance.
Generate a portfolio-level dashboard across ALL client brands — per-client RAG health scores, campaign activity, budget pacing, aggregate KPIs, team utilization, pending approvals, upcoming deadlines, and an alerts panel — built for agency standups and weekly reviews. Triggers on \"/digital-marketing-pro:agency-dashboard\", \"how are all our clients doing\", \"portfolio health check\", \"budget pacing across accounts\", \"which accounts are at risk\". Enumerates every brand under ~/.claude-marketing/brands/ and pulls data via campaign-tracker.py, execution-tracker.py, and team-manager.py; drill into a single client with /digital-marketing-pro:performance-report or /digital-marketing-pro:client-report.
Invoke when the user needs to manage multiple client brands, view portfolio-level dashboards, generate client reports, manage SOPs, switch credential profiles, assign team tasks, configure regions, or generate executive summaries. Triggers on requests involving multi-client management, agency workflows, client onboarding, or portfolio oversight.
Invoke when the user needs help with marketing measurement, KPI definition, dashboard design, attribution reporting, performance analysis, competitive benchmarking, or translating data into marketing decisions. Triggers on requests involving metrics, reporting, analytics setup, or data interpretation.