SEO Ops — a skill by Eric Siu.
Library skill — the default version is maintained in GitHub; edits you make live in your own clone.
# Version check (silent if up to date)
python3 telemetry/version_check.py 2>/dev/null || true
# Telemetry opt-in (first run only, then remembers your choice)
python3 telemetry/telemetry_init.py 2>/dev/null || true
Privacy: This skill logs usage locally to
~/.ai-marketing-skills/analytics/. Remote telemetry is opt-in only. No code, file paths, or repo content is ever collected. Seetelemetry/README.md.
AI-powered SEO operations: keyword intelligence, competitor gap analysis, GSC optimization, and trend detection.
content_attack_brief.py)Full keyword intelligence pipeline. Requires AHREFS_TOKEN and GSC auth.
# Run the full brief
python content_attack_brief.py
What it produces: - Topic fingerprint from your content library - BOFU money keywords ranked by Impact × Confidence - Trending keywords with sparkline visualizations - Competitor gap analysis (keywords they rank for, you don't) - Decaying page alerts (traffic drops >30%) - Execution pipeline (auto-create → semi-auto → team)
Output: Prints formatted report to stdout + saves JSON to OUTPUT_DIR/content-attack-brief-latest.json
gsc_client.py)Google Search Console API client. Works as CLI or importable library.
# CLI usage
python gsc_client.py --queries 50 --days 28
python gsc_client.py --striking # Striking distance keywords (pos 4-20)
python gsc_client.py --pages 100 --days 7
python gsc_client.py --trend # Daily click/impression trend
python gsc_client.py --devices # Mobile vs desktop split
python gsc_client.py --sites # List verified properties
python gsc_client.py --json --queries 25 # JSON output
# Library usage
from gsc_client import GSCClient
gsc = GSCClient()
rows = gsc.striking_distance(days=28, min_position=4, max_position=20)
for row in rows:
print(f"{row['keys'][0]}: pos {row['position']:.1f}, {row['impressions']} impressions")
gsc_auth.py)One-time OAuth setup for Google Search Console access.
python gsc_auth.py
# Opens browser → Google Sign-In → saves token locally
trend_scout.py)Multi-source trend detection. No API keys required for basic functionality.
python trend_scout.py
Sources: Google Trends RSS, Hacker News, Reddit, X/Twitter (needs BRAVE_API_KEY), YouTube outlier detection
Output: Prints summary + saves JSON to OUTPUT_DIR/flash-trends-latest.json and markdown report.
All scripts read from environment variables. Copy .env.example to .env and fill in your values.
Required:
- GSC_SITE_URL — your Google Search Console property URL
- GOOGLE_CLIENT_ID / GOOGLE_CLIENT_SECRET — for GSC OAuth
- YOUR_DOMAIN — your root domain
Optional:
- AHREFS_TOKEN — enables Ahrefs keyword data and competitor analysis
- COMPETITORS — comma-separated competitor domains
- BRAVE_API_KEY — enables X/Twitter trend scanning
- CONTENT_VERTICALS — comma-separated topics for trend relevance scoring
- TREND_SUBREDDITS — comma-separated subreddits to monitor
Keywords are scored on two axes:
Impact (0-10): Volume + CPC + Funnel Stage + Trend direction Confidence (0-10): Keyword Difficulty + Current ranking position + Topic authority
Priority = Impact × Confidence (max 100)
content_attack_brief.py for the full intelligence reportgsc_client.py --striking to monitor striking distance keywordstrend_scout.py to catch trending topics earlyCOMPETITORS listUse analytics readbacks before promoting any SEO, AEO, GEO, or content-refresh playbook change.
Inputs: - GSC clicks, impressions, CTR, average position, queries, pages - GA4 sessions, engaged sessions, conversions, assisted leads - Ahrefs rankings, backlinks, traffic estimates, keyword movement - ClickFlow opportunities where available - AI-search / answer-engine / GEO visibility where available - CMS/page change log
Judgment: - Compare baseline vs candidate windows. - Segment by page, query, topic, intent, and source. - Track confounders: seasonality, indexing lag, brand spikes, campaigns, tracking changes, and unrelated site edits.
Promotion rule:
- Promote the playbook patch only if the candidate beats baseline or exposes a repeatable signal.
- Otherwise mark it unproven, keep testing, or rollback.
Common readback windows: - Content refresh: 7, 14, 28, and 56 days - New content: 14, 28, 56, and 90 days - Technical SEO fix: daily for 7 days, then 28-day readback - AEO/GEO visibility: weekly, because answer engines are noisy gremlins with citations
Required readback fields: - change made - owner - page/query/topic affected - baseline window - candidate window - source systems pulled - primary and secondary metrics - caveats - decision: promote / keep testing / rollback / unproven - next playbook patch
pip install -r requirements.txt