---
name: seo-geo-audit
description: Audit a website for search and AI-answer visibility (Google, ChatGPT, Claude, Perplexity, Copilot), fix what is broken in its codebase, find long-tail keywords, and plan and draft the posts worth writing. Use when asked to improve SEO, GEO/AEO, AI visibility, rankings or a content plan.
---

# SEO + AI visibility agent

You are using the free API at https://canbotsseeme.pages.dev. It crawls and grades; you decide and edit. No key is needed. Every finding is graded Official / Observed / Speculative and cites its source (see https://canbotsseeme.pages.dev/api/method).

## 0. Set up
- Get the site URL. Check whether you are inside the site's codebase; if not, audit and plan but skip step 3.
- Read `.sightline/context.md` if it exists: business, goal, audience, competitors, key pages and a research log. If it is missing, infer what the business does from the site, confirm it with the user in one question, and create the file (sections: Business, Goal, Audience, Competitors, Key pages, Research log). Never front-load a long interview.
- If a Search Console MCP server or credentials are available, use them in step 5.
- Workflow skills (audit, content plan, project setup) install with: npx skills add ReluctantSkeptic/ai-visibility-audit

## 1. Audit
- GET https://canbotsseeme.pages.dev/api/audit?url=<site>&pages=3   (add &probe=1 to test firewalls with AI user agents, &indexnowKey=<key> to verify IndexNow)
- GET https://canbotsseeme.pages.dev/api/crawl?url=<site>&max=50   (site-wide: broken internal links, redirect chains, duplicates, orphan pages, JavaScript-only pages; up to ~45 s)
- GET https://canbotsseeme.pages.dev/api/links?url=<site>   (broken links on one page, including external)
The audit report has overall (0–100), stages, findings[] (id, stage, status, detail, why, fix, grade, cites), manual[], pages[].

## 2. Triage
- Research broadly, recommend selectively: lead with the one to three changes most likely to win qualified search traffic or stop a real loss. Access or indexing blockers jump the queue.
- "fail" first, then "warn". Eligible-stage fails are hard blockers: fix them before anything else.
- Skip status "myth" and "info". They are reported, never scored (llms.txt and schema-as-ranking-lever are documented non-factors).
- Show the user a short table: finding, one-line why, what you will change, and whether it needs them.

## 3. Fix in the codebase
- Detect the framework (package.json, next.config.*, astro.config.*, nuxt.config.*, wp-content, hugo.toml, plain HTML).
- For each finding, GET https://canbotsseeme.pages.dev/api/recipe/<finding-id>. If "agent": true, make the smallest correct change. If false, add it to a checklist for the user.
- One commit per stage, clear messages. Never invent facts, prices, dates or reviews.

## 4. Keywords and posts
GET https://canbotsseeme.pages.dev/api/keywords?url=<site>   (or &seed=<topic>, up to 3)
Returns suggestions (query, intent, format, longTail), clusters, and posts[] (title, format, target, supporting, coveredBy).
- Skip posts with coveredBy set; improve that page instead.
- Recommend the three best posts for this business; draft the first in the site's own content format once the user agrees.

### Writing rules (from the research)
- Title and H2s phrased as the questions people ask; pages whose headings match the sub-question are cited more often [05-industry-studies #14].
- The first ~200 characters under the H1 answer the main question: ChatGPT's quick mode judges title plus that snippet [02-openai #80].
- Lead each section with a standalone answer sentence, then detail. Use specific numbers, prices and dates [04-academic #1].
- Tables for comparisons, numbered lists for steps, everything visible without JavaScript or tabs.
- Show "Updated <date>", Article JSON-LD with datePublished/dateModified, add the post to the sitemap and feed.
- No hidden text, no instructions aimed at AI, no one-page-per-variant spam [01-google #10].

## 5. Search Console
With API access (scope webmasters.readonly), pull 90 days of query+page rows and the 90 days before:
- Striking distance: position 4–20 with meaningful impressions → strengthen that page for that query (title, an H2 with the query, a direct answer).
- CTR gaps: position under 6, CTR under half of typical (#1 ≈ 28%, #3 ≈ 11%, #5 ≈ 6.5%) → rewrite title and description.
- Cannibalization: one query split across pages → merge or differentiate, point internal links at the winner.
- Question queries ranking past 8 → an answer section or a new post each.
Without access, ask the user to upload a Performance export at https://canbotsseeme.pages.dev/app (Search Console tab).

## 6. AI answers (measurement, by hand or with your own web search)
GET https://canbotsseeme.pages.dev/api/prompts for ten research-backed prompts (fan-out discovery, source map, wrong facts, competitor named instead). Run them in the assistants the user cares about, several paraphrases each, and record which pages and third-party sources get cited.

## 7. Verify and report
Re-run step 1 after deploying. Append one line to the research log in `.sightline/context.md` ("<date> audit: <site>. Verdict: <conclusion>") so the next session does not redo it. Report the score change, what you fixed, the manual[] items only the owner can do (Search Console AI setting, Bing Webmaster Tools, WAF allowlist, Business Profile), and the content plan.
