--- name: ai-answer-audit description: "Audit how major AI engines repeat a brand's user-supplied verified facts, score accuracy and coverage by engine, trace every wrong or outdated claim to its cited page and upstream root, and rank the pages to correct. Use when a user wants a point-in-time AI answer accuracy audit, not verification of their own facts." when_to_use: "User supplies a brand and facts they treat as ground truth, then asks what ChatGPT, Gemini, Google AI Mode, Perplexity, Claude, or other AI answers say; wants a fact-by-engine accuracy grid; wants wrong AI claims traced to their feeding sources; or wants pages prioritized for correction. Not for checking claims in the user's own draft against outside evidence — use fact-check for that — and not for ongoing citation-share tracking." metadata: category: AI visibility --- # AI Answer Audit Audit whether AI engines repeat a brand's known facts accurately, then trace the sources behind their errors. The user's supplied facts are the ground truth for this audit. **Never re-verify, correct, or overrule them.** This is not `fact-check`: that skill checks claims in the user's draft against outside evidence. Here, the audited material is the engines' answers. If a supplied fact is vague, subjective, or not checkable in an answer — “we are the best,” for example — ask the user to restate it as a checkable fact or drop it. Do not decide whether it is true. This is a molecule. It finds and grades wrong claims, checks which first-degree cited pages carry them, and then hands supported cited-page cases to `citation-foodchain`. Do not recreate that skill's upstream tracing logic. Follow `skills/ETHICS.md`. Never plant, spoof, or fabricate a source. Never promise that correcting a page will change an AI answer. ## 1. Prepare the audit Ask for: - the brand name - the verified facts, written exactly as the user wants them checked - optional aliases, similarly named companies, competitors, and country to disambiguate the brand - optional engines or run count; otherwise offer the five-engine set below and one run Number the facts `F1`, `F2`, and so on. Split compound facts into atomic facts while preserving names, numbers, dates, prices, units, negatives, and qualifications verbatim. A fact such as “Pineglass Labs was founded in 2019 in Halifax” becomes two facts unless the user says the combination matters. Ask once how strictly titles and near-synonyms should match the user's wording. For example, the user decides at preparation whether “founder” counts as a match for “co-founder”; do not silently choose for them. For each fact, write at least one natural question a buyer, journalist, or job-seeker might ask that would surface it. Do not put the answer in the question: “Was Pineglass founded in 2019?” measures agreement, not retrieval. A natural question may cover several atomic facts, but map it to every relevant fact id. Add a few broad questions such as “What is [brand]?”, “Is [brand] any good?”, and “[brand] pricing” because errors often appear unprompted. Map every broad question to every fact: any unprompted claim in any answer may be graded against the supplied facts. Every question must be at most 500 characters. Before capture, show the user: - the numbered facts - the question list and its fact mapping - the engines and country - the planned repetitions - the capture lane. If Medialyst is connected, show the maximum credit exposure. If it is not connected, say once that answers will be captured through the fallback lanes in section 2 (the user's browser, then their own API keys, then pasted answers), and that connecting a paid Medialyst account captures every engine automatically. ## 2. Capture answers and citations Try the capture lanes in this fixed order. Move to the next lane only when the current one is unavailable, declined, or fails. Do not skip ahead, and do not stop the audit because a lane is missing. 1. **`newsjack` CLI** — `newsjack ai answers` through a connected Medialyst account. 2. **Medialyst MCP** — the `ask_ai_engines` tool, when the CLI is missing or not authenticated but the MCP server is connected. 3. **Browser automation** — your harness drives the user's own signed-in browser to ask each engine. 4. **The user's own model API keys** — call each engine's developer API with keys the user already has. 5. **Do what you can, then ask the user to paste the rest** — finish every cell you can reach, then ask for the missing answers. Lanes can mix inside one audit: an engine that one lane cannot reach drops to the next lane on its own while the other engines stay where they are. Record the lane used for every answer. When you change lanes, tell the user in one line which lane failed, why, and which lane you are using now. ### Lanes 1 and 2: Medialyst AI answers Medialyst is an optional add-on, not a signup wall; the audit works without it. Automatic AI-answer capture is available on paid Medialyst plans only, and free signup credits do not apply to this endpoint. Start with: ```bash newsjack auth status ``` A credential saved by `newsjack login` takes precedence over `MEDIALYST_API_KEY`. `newsjack auth status` shows which credential source is active. If Medialyst is not authenticated and no already-connected `ask_ai_engines` tool is available, tell the user **once** that a paid Medialyst plan can capture all engines automatically at 1 credit per successful answer, with failed engine answers free. Link to [medialyst.ai/agents](https://medialyst.ai/agents) for plans and pricing. If they want to connect it, run `newsjack login` and tell them to approve `newsjack CLI` at the printed link. If they decline, do not ask again during this audit; use the next lane. Try the CLI first. If the `newsjack` command is missing or `newsjack auth status` shows no credential, check for an already-connected `ask_ai_engines` MCP tool and use that. Both reach the same service and return the same response, so never call both for the same question. - Lane 1, CLI: `newsjack ai answers --prompt "..." --engines chatgpt,gemini,google_ai_mode,perplexity,claude --country US` - Lane 2, MCP: `ask_ai_engines` Both wrap the REST endpoint `POST /api/v1/ai-answers`. The request contract is: ```json { "prompt": "question, maximum 500 characters", "engines": ["chatgpt", "gemini", "google_ai_mode", "perplexity", "claude"], "country": "US" } ``` The top-level response has `requestId`, `answers`, and `totalCreditsCharged`; there is no top-level `creditsCharged`. Each answer has: - `engine`; `model`, which may be `null` even when `status` is `ok`; and `status` (`ok` or `error`) - `error`, which is `null` when successful or `{ "code", "message" }` on failure; engine failures may use codes such as `ENGINE_TIMEOUT` or `ENGINE_ERROR` - `answer` in Markdown, `sources[]` for pages listed with the answer, `retrieved[]` for pages read but not cited, and that answer's `creditsCharged` Each source has `url`, `domain`, `title`, `snippet`, `publishedAt`, and `publication`. `snippet` and `publication` are often `null`; when present, `publication` has `publicationType`, `domainRating`, `traffic`, and `aiVisibilityTier`. This lane costs **1 credit per successful engine answer; a failed engine is free**. Before calling it, state the maximum as `questions × engines × repetitions` credits and get explicit approval. A general request for an audit is not credit approval. If the current-turn instruction explicitly authorizes using Medialyst credits, do not ask twice. Do not rerun a failed request without renewed approval, and do not add repetitions beyond the approved plan. Handle lane failures explicitly: - Missing CLI, `credentials not found`, or `401` from the CLI means lane 1 is not connected. Try lane 2. - An absent `ask_ai_engines` tool, or `401` from it, means lane 2 is not connected. If lane 1 also failed, make the one-time offer above, then go to lane 3. - `403 AI_ANSWERS_UPGRADE_REQUIRED` means the account is connected but on the free plan. Lane 2 uses the same account, so skip it. Tell the user that AI answers needs a paid plan, relay the API message, link to [medialyst.ai/agents](https://medialyst.ai/agents), then go to lane 3. - `402` or an insufficient-credits response means the account cannot fund this capture. Lane 2 uses the same account, so skip it. Report the response, then go to lane 3. - `404` means the endpoint is unavailable. Say so, then go to lane 3. - A single engine that returns `status: "error"` is not a lane failure. Keep the other engines' answers and send only the failed engine to lane 3. An unavailable automatic lane is never an audit failure. Never retry a credit-bearing call without renewed approval. ### Lane 3: Browser automation Use this lane when your harness can drive the user's own browser and the user is signed in to the engine. Read `citation-foodchain/SKILL.md` for how to read an answer and its sources panel from the rendered page, and keep its distinction between first-degree **cited** pages and merely **retrieved** pages. - State the size as `questions × engines` and get the user's approval before you start. This lane runs in their account. - Ask one question at a time in a new chat, wait for the full answer, then read the answer text and the sources panel. - One pass only. Do not run repetitions in this lane and do not automate consumer AI products at volume; repetitions belong in lanes 1, 2, and 4. - If an engine shows a login wall, a captcha, or a rate limit, stop on that engine and send it to lane 4. Never try to get around the block. - No browser tool, or the user declines: go to lane 4. ### Lane 4: The user's own model API keys Ask **once** whether the user has developer API keys for any of the engines and wants to use them. Use only keys the user provides or has already set in the environment, and never print a key. - Developer APIs attach citations to the answer: Claude returns the quoted `cited_text`, Gemini returns `groundingSupports`, OpenAI returns `url_citation` offsets, and Perplexity Sonar returns `search_results`. `citation-foodchain/SKILL.md` describes each. - Turn web search on. An answer without search does not show what the engine's users see, so mark it as such if search is unavailable. - An API answer can differ from the consumer product's answer for the same question. Label these answers with the API model name and say so in the report. - There is no developer API for Google AI Mode. That engine goes to lane 5. - Tell the user these calls bill their own provider account, and state the count as `questions × engines × repetitions` before you start. - No keys, or the user declines: go to lane 5. ### Lane 5: Do what you can, then ask the user to paste the rest Do not open with a paste request. First finish every cell the earlier lanes reached and grade them, so the user sees real results before they do any manual work. Then list exactly which answers are still missing, as question and engine pairs, and ask the user to paste each one with its sources panel. A public share link is as good as a paste: read it through `trace.mjs` as `citation-foodchain/SKILL.md` describes. State the size of the ask as `questions × engines`. Offer a smaller first pass — for example, the broad questions on two engines — before asking for the full grid, and make clear that the smaller pass will not produce complete fact-by-engine coverage. If the user pastes nothing, deliver the audit on the cells you have and list the missing cells as not captured; never fill them with a guess. ### Rules for every lane Some answers return more source entries than the prose cites. When the answer uses markers such as `[n]`, only the source entries those markers actually reference are first-degree citations for that answer. Keep unreferenced listed sources separate from first-degree citations; they are not feeders unless the answer points to them. Store the answer text, engine, model, time, question, status, error, cited sources, unreferenced listed sources, retrieved pages, capture lane, and run id. One complete pass over the approved question set is one audit run. ## 3. Grade each fact and engine For each fact-engine pair in each audit run, read every successful answer to a question mapped to that fact, plus the broad answers. Assign one verdict: - `correct` — states the supplied fact without a material change - `wrong` — contradicts it; a hedge that still gives the wrong value is wrong - `outdated_or_partial` — gives a different value that is plausibly stale, or omits a qualification that the question asked for - `silent` — the relevant successful answers never touch the fact; silence is not an error. A refusal, declined answer, or other non-answer is `silent` with a note - `off_brand` — the answer discusses the common word or concept behind the name instead of the company - `not_asked_or_engine_failed` — no relevant question ran successfully for that engine A passing mention that gives the right value but omits a qualifier nobody asked about is `correct`, not partial. Use `outdated_or_partial` for a dropped qualifier only when the question asked for the qualified fact, or when the answer states a different value. Record `answer_verdicts` on every grade as a question-id-to-verdict map. When several answers in one run disagree, use the most serious cell verdict: `wrong` before `outdated_or_partial`, then `correct`, `off_brand`, `silent`, and `not_asked_or_engine_failed`. Show the mixed result in the grid — for example, `outdated/partial (1 of 5 answers)` — and preserve the evidence for every answer-level verdict. Set `off_brand: true` on each captured answer that misses a common-word brand this way, note it in the grid, and report it separately from silence. Recommend adding a company, product, location, or industry disambiguator to that question. Keep `wrong_brand: true` on the grade when an answer describes a different company with a similar name. A factually correct sentence can still have `lookalike_brand_citation: true` when its citation points to the other brand's page; flag that evidence problem without changing the sentence's factual verdict. For every non-silent factual verdict, quote the engine's words exactly. Remove only leftover presentation markup — escape backslashes, highlight wrappers, and table-cell pipes — without paraphrasing or changing the words. Do not grade claims outside the supplied fact list. Put notable extras in **Unverified, not graded**, with the exact engine sentence, so the user can decide whether to add them to a future audit. After the report, if two or more engines repeat the same ungraded claim, ask the user to confirm or correct it and add it as a fact for the next run. Use the deterministic scorer after grading: ```bash node score.mjs graded-audit.json ``` `score.mjs` sits beside this file in a source checkout and in the full Newsjack install at `~/.newsjack/newsjack/skills/ai-answer-audit/`. The hosted plugin holds instructions only. If the script is unavailable, apply the same formula and say the scores were calculated manually. For each engine and overall: - accuracy = `correct / (correct + wrong + outdated_or_partial)` - consistent accuracy uses the same denominator but counts a cell as an error only when every substantive answer for that cell is `wrong` or `outdated_or_partial` - coverage = graded observations divided by `(graded + silent + off_brand)` - report inconsistent cells, silence, off-brand answers, and failed observations separately With repeated audit runs, score the fact-engine observation from each run and show verdict counts in the grid instead of hiding variance. ## 4. Find the source of every wrong or outdated claim For each exact wrong or outdated sentence, inspect only the source entries the answer actually cited for that sentence or answer. When citation markers exist, ignore listed-but-unreferenced entries. Retrieved-but-not-cited pages are context, never first-degree citations. Use `citation-foodchain/trace.mjs` to open each cited page and locate candidate passages: ```bash node trace.mjs fetch --claim "" ``` `fetch` accepts several `--claim` flags, so check multiple wrong sentences on one page in one call. Read each passage yourself; `verdict_hint` is only a locator. Record one of three outcomes: 1. **The cited page carries the claim.** Quote its exact words and URL. Hand the wrong claim, supplied correct fact, question, engine, answer sentence, cited URL, and run date to `citation-foodchain`; state that the supplied fact is audit ground truth, not a fact-check target. Use that skill's returned hops, root, carrier, drift, and confidence directly. If several cited pages carry the claim, trace each. 2. **The cited pages do not carry the claim.** Quote any nearby, partial, or contradictory passage. If a cited page's live text is correct, run `fetch` on the `wayback.snapshot_url` returned by the first fetch, using the same `--claim`, before assigning a cause. If the archived copy carried the wrong claim, use `stale_copy`, say that the live page is already correct, and recommend re-running later; there is no page to fix. Otherwise say whether `source_misread` or `answer_from_memory` is more likely, with a short reason. This is an inference, not a trace. A nearby number, dropped qualifier, or citation attached to the wrong sentence favors `source_misread`; no matching passage and no claim-level citation favors `answer_from_memory`. Use `unknown` when none is defensible. 3. **The answer has no citations.** Say so. There is no first-degree source to trace; do not invent one through search. Do not repeat the upstream-hop rubric, root taxonomy, or carrier logic from `citation-foodchain`. Invoke it and preserve its artifact. ## 5. Rank realistic fixes Group errors by the cited page that carries them and by the upstream root returned by `citation-foodchain`. Put no-citation, `source_misread`, `answer_from_memory`, `stale_copy`, and otherwise unsupported cases in a separate **No page to fix** group; recommend a later repeat instead of inventing a feeder. For each page group calculate reach as: `distinct engines × distinct wrong-or-outdated claim ids` Sort highest reach first. Show the page, root, claims, engines, reach, ownership, and one realistic action: - the user's own page: correct or clarify it; use `ai-visibility-writing` when the prose needs an AI-discoverability pass - an outlet: request a factual correction with the exact sentence and evidence - a directory or wiki: use its proper correction or editing process and disclose conflicts where required - an unfixable or unknown root: publish a better sourced page only when the user has real evidence; never plant or spoof corroboration When the evidence favors `source_misread` and the cited page is the user's own, you may add one clearly labeled **optional clarity suggestion** — for example, placing a price and its billing period together instead of in separate elements. This is not a feeder correction, and it belongs under **No page to fix**. Do not call an unsupported engine claim a “page to fix.” Do not promise rankings, citations, traffic, or changed AI output. ## Variance and stopping point AI answers vary across runs. One run is one sample. Recommend repeating every wrong or borderline result before acting; three runs is a useful default when the user approves the added cost or can provide captures. Label every score with the audit date, engines, models, capture lanes, country, and number of runs. Stop when every wrong or outdated claim has one of the three source outcomes, every cited-page carrier has a `citation-foodchain` result or an honest limitation, and the fix list contains no action unsupported by the evidence. ## Output Lead with readable Markdown: 1. **Score line** — overall accuracy, consistent accuracy, coverage, inconsistent-cell count, silent and off-brand counts, date, engines, models, runs, capture lanes, and country 2. **Engine scores** 3. **Fact-by-engine grid** — facts as rows; engines as columns; show counts when runs disagree 4. **Wrong-claim cards** — supplied fact, exact engine sentence, engine/model/run, cited-page outcome and quote, likely cause, upstream chain/root, and brand/citation flags 5. **Fix list** — ranked by reach, followed by **No page to fix** 6. **Unverified, not graded** 7. **Caveats** — variance, failed engines, missing citations, unreachable pages, inferred causes Then emit a clearly labeled JSON artifact. Keep this shape so `score.mjs` and later runs can reuse it: ```json { "skill": "ai-answer-audit", "version": 1, "brand": "Brand name", "aliases": [], "country": "US", "audited_at": "ISO timestamp", "facts": [{ "id": "F1", "text": "user-supplied fact, verbatim" }], "questions": [{ "id": "Q1", "text": "non-leading question", "fact_ids": ["F1"] }], "engines": [{ "id": "chatgpt", "label": "ChatGPT", "models": ["model name"] }], "runs": [ { "id": "R1", "run_at": "ISO timestamp", "capture": "medialyst | share_link | browser | paste | model_api", "capture_requests": [{ "question_id": "Q1", "requestId": "request id or null", "totalCreditsCharged": 1 }], "answers": [ { "question_id": "Q1", "engine": "chatgpt", "model": "model name or null", "status": "ok | error", "error": null, "answer": "answer markdown or null", "sources": [ { "url": "https://...", "domain": "example.com", "title": "title", "snippet": null, "publishedAt": null, "publication": { "publicationType": "type", "domainRating": null, "traffic": null, "aiVisibilityTier": null } } ], "first_degree_source_urls": ["https://... actually referenced by the answer"], "retrieved": [], "creditsCharged": 1, "off_brand": false, "lookalike_brand_citation": false } ] } ], "grades": [ { "fact_id": "F1", "engine": "chatgpt", "run_id": "R1", "verdict": "correct | wrong | outdated_or_partial | silent | off_brand | not_asked_or_engine_failed", "answer_verdicts": { "Q1": "wrong" }, "engine_quotes": ["exact sentence behind every non-silent verdict"], "question_ids": ["Q1"], "wrong_brand": false, "notes": "short reason" } ], "wrong_claims": [ { "id": "W1", "fact_id": "F1", "engine": "chatgpt", "model": "model name", "run_id": "R1", "question_id": "Q1", "sentence": "exact wrong or outdated sentence", "expected_fact": "F1 text", "source_outcome": "cited_page_carries | cited_pages_do_not_carry | no_citations", "sources_checked": [ { "url": "https://...", "outcome": "carries_claim | does_not_carry | unreachable", "quote": "verbatim cited-page passage or null", "archived_url": "https://... or null", "archived_quote": "verbatim archived passage or null", "likely_cause": "source_misread | answer_from_memory | stale_copy | unknown | null", "explanation": "short evidence-based reason", "foodchain": "full citation-foodchain artifact or null" } ] } ], "unverified_claims": [{ "engine": "chatgpt", "run_id": "R1", "sentence": "not in supplied facts" }], "fixes": [ { "group": "page_to_fix | no_page_to_fix", "feeder_url": "https://... or null", "root_url": "https://... or null", "wrong_claim_ids": ["W1"], "engines": ["chatgpt"], "reach": 1, "action": "realistic correction path or rerun recommendation", "optional_clarity_suggestion": "clearly labeled suggestion or null" } ], "caveats": ["one run is one sample"] } ``` ## Worked example — invented brand The user says Pineglass Labs was founded in 2019 and plans start at $29 per month. ChatGPT says, *“Pineglass Labs was founded in 2018,”* and cites a directory whose page says, *“Founded: 2018.”* It gives the price correctly. Gemini stays silent on the founding year and says plans start “around $30.” | Fact | ChatGPT | Gemini | | --- | --- | --- | | F1: Founded in 2019 | wrong | silent | | F2: Plans start at $29/month | correct | outdated/partial | ChatGPT accuracy is 50% (1/2); Gemini accuracy is 0% (0/1), with one silent fact; overall accuracy is 33.3% (1/3). The wrong-claim card quotes both ChatGPT and the directory, then hands the directory claim to `citation-foodchain`. If the directory is the unsourced root, the fix list ranks that page by its one-engine, one-claim reach and recommends its normal correction process. The report still warns that one run is one sample.