/xuanran-seo-blog-writer:fact-check-and-citationfrom xuanran-seo-blog-writer
Fetches cited URLs and verifies statistical claims appear on page. Uses Crossref for academic claims, Tavily for industry. Replaces fabricated/unsourced stats and generates APA 7 references block.
Ships in xuanran-seo-blog-writer. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
The single most important anti-hallucination step. Without it, LLM-fabricated statistics make it to publication. With it, every cited fact is real and verifiable. Without exception.
section-drafter completes (Stage: humanizer-complete OR section-drafted)assembly (final draft.md assembly)repair-orchestrator when any C01 (fabricated citation) veto fires/factcheck workspace/{task_id}/draft.mdworkspace/{task_id}/sections/*.json — each has claims[] arrayworkspace/{task_id}/research.json — Tier-1 source candidates already discoveredreferences/apa-citation-rules.mdScan the draft for every claim that includes a number, percentage, dollar amount, or named source. Build claims list:
| Field | Description |
|---|---|
| claim_text | The exact sentence or phrase containing the statistic |
| value | The numeric value (e.g., "42%", "$1.2M", "3x") |
| attribution | Named source if present (e.g., "HubSpot", "Gartner 2025") |
| url | Cited URL if present (markdown link or parenthetical) |
| location | Heading or line number where the claim appears |
# Internal — fact-checker is the agent that does the actual verification work
Invoke agents/fact-checker.md with:
sections_dir = workspace/{task}/sections/mode = "fact-check"max_refs = 10 (or 15 for case-study / data-research formats)The fact-checker has the tool whitelist: Read, Write, WebFetch, Bash.
For each claim with needs_source=true:
Crossref lookup (academic preference, free, fast)
python -m scripts.fetch.crossref_lookup "{hint_query}" --rows 5 --apa
If hit + DOI → step 4.
Link resolver check on DOI URL
python -m scripts.validate.link_resolver "https://doi.org/{doi}"
If 200 OK → USE IT.
Tavily advanced fallback (for industry, news, recent statistics)
python -m scripts.fetch.tavily_search "{hint_query}" --depth advanced
For top-3 results → run link_resolver. First passing → USE IT.
If nothing resolves → mark claim as deleted. Surface to writer to rewrite the paragraph without the unsupportable claim.
| Score | Status | Criteria |
|---|---|---|
| 1.0 | VERIFIED | Exact number found on cited page in matching context |
| 0.7-0.9 | PARAPHRASE | Similar data with different wording, rounding, or timeframe |
| 0.3-0.6 | WEAK | Source page covers topic but specific stat not visible |
| 0.0 | NOT FOUND | Cited page does not contain the claimed data anywhere |
| N/A | UNVERIFIED | No source URL provided for the claim |
Scoring guidance:
Fully cited (highest confidence):
[Number]% [claim] ([Source], [Year]) — parenthetical citation[claim] [Number]% ... [markdown link to source] — inline linkAccording to [Source], [Number]... — attribution leadUncited statistics (flag for sourcing):
[Number]% of [noun phrase] — standalone percentage[Number]x more/less/higher/lower — multiplier claims$[Number] [claim] — dollar figures without attributionWeak signals (check context before extracting):
Output workspace/{task_id}/citations.json per schemas/citations.schema.json, AND
workspace/{task_id}/fact-check.json per schemas/fact-check.schema.json — its verdict
is EXACTLY one of CLEAN | CLEAN_WITH_NOTES | FIX_REQUIRED | BLOCK_PUBLISH (any other
string fails closed at the orchestrator gate and pre_publish_gate; CLEAN_WITH_NOTES is
the canonical "issues found and fixed in place" verdict — 2026-08-02,
scripts/pipeline/fc_verdict.py).
Canonical top-level key is citations (matches wp_publisher._load_citation_entries
canonical reader path). Legacy/alternate keys also accepted by the publisher:
refs, references, items, or bare top-level list — but new emitters
should write citations for clarity and forward-compat.
URL-resolution recording (v3.38.3, mandatory): a ref that is REAL but
bot-walled (Taylor & Francis / MDPI / ASTM return HEAD 403 to script UAs) gets
url_verified: true + resolved_status: "bot-403" (the STRING — never the bare
int 403, which reads as a broken ref and fires the C01 fabricated-citation
veto) + a resolution_note naming how it was verified (Crossref masthead /
browser UA). url_verified: true is authoritative for the C01 scorer. A ref you
could not verify anywhere gets url_verified: false. Full contract:
agents/fact-checker.md §"URL resolution recording".
{
"task_id": "abc123",
"citations": [
{
"id": 1,
"apa_7": "Smith, J. (2024). Title of work. Publisher. https://doi.org/10.1234/xyz",
"url": "https://doi.org/10.1234/xyz",
"url_verified": true,
"tier": 1,
"type": "peer_reviewed",
"verified_via": "crossref",
"claim_markers_resolved": ["c1_3", "c2_5"]
}
],
"in_text_replacements": [
{"marker": "[claim:c1_3]", "replace_with": "(Smith, 2024)"},
{"marker": "[claim:c4_exp]", "replace_with": ""}
],
"deleted_claims": [{"id": "c2_4", "reason": "no_resolvable_source"}],
"verification_summary": {
"total_claims": 18,
"verified": 12,
"paraphrase": 3,
"weak": 1,
"not_found": 0,
"unverified": 0,
"deleted": 2
}
}
python -m scripts.validate.apa_format_validator workspace/{task}/citations.json
Verifies all entries match APA 7 format. Failure → fact-checker agent retries.
LLMs are prone to invent plausible-sounding citations. We block this physically by:
link_resolver.py HEAD check.gov / .edu URLs (Tier 1)data-research / case-study formats: up to 15Three required elements for every numeric claim that survives verification:
Without all three, the claim is not citation-ready for AI engines.
After successful citations.json:
recommended_next_skill: assembly (script, no LLM)key_findings: {"refs_resolved": 8, "deleted_claims": ["c2_4"], "unverified_count": 0}If significant deletions (>3 claims deleted):
completion_status: "DONE_WITH_CONCERNS"section-drafter retry for the specific paragraphs that lost their supportIf all citations fail:
completion_status: "BLOCKED"repair-orchestrator (research quality issue, not fact-check failure)If C01 veto triggers (fabricated citation detected):
Typical article with 15 unique claims:
agents/fact-checker.md — the agent doing verification workscripts/fetch/crossref_lookup.pyscripts/fetch/tavily_search.pyscripts/validate/link_resolver.pyscripts/validate/apa_format_validator.pyreferences/apa-citation-rules.mdreferences/seo/citation-capsules-princeton.md — FLOW Evidence Triple full specWhat SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub xuanranl/loamwright-seo-skill --plugin xuanran-seo-blog-writer75 skills in this plugin
/ai-overview-recovery4-phase recovery when Google AI Overview drops an article. Measure damage → diagnose skip reason → rewrite → T+7/14/28 monitor. Triggered by drift-detector AIO loss alert OR /aio-recovery command./ai-visibility-trackerActive probe of ChatGPT/PPLX/Claude/Gemini to check if our article is cited. Compares to projects/{slug}/geo-baseline.json. Triggered by /ai-visibility command or daily/weekly schedule./batch-articleRun /article end-to-end for a list of keywords. Each keyword goes through the FULL pipeline (research → plan → build → optimize → publish → monitor baseline). Use for agency-scale operations — drop 10-500 keywords, get 10-500 published articles. Resumable across sessions.Other plugins' skills for the same job