Sub topic 9
Keep Every Claim Traceable to the Source
This chapter assumes you can write prompts for a chat model, you know the core message and key claims of your source asset (covered earlier), and you can read short Python functions. The code is optional but useful.
A repurposed draft is only as trustworthy as its weakest claim. A model that rewrites a white paper into a LinkedIn post can drift in small ways. It may round 41% up to "nearly half", add a customer name that sounds plausible, or turn "may reduce" into "reduces". This chapter gives you a working model of how those errors happen and a set of checks that catch most of them before a human reviews the draft.
Why fidelity fails
A language model produces text that fits the prompt and its own training. It does not look up each sentence in your source. When the format asks for a punchy hook or a persuasive call to action, the model fills gaps with whatever sounds right. Four failure modes account for most problems:
- Invented specifics. Numbers, names, dates, or quotes that are not in the source.
- Strengthened claims. Hedged language becomes certain ("can help" becomes "will").
- Lost qualifiers. Conditions, sample sizes, or time frames are dropped, so a true claim becomes a misleading one.
- Blended knowledge. The model adds a true-sounding fact from its training data that your source never made.
Each failure is more likely when the format spec asks for something the source cannot supply. A "three statistics" bullet list drawn from an article with one statistic invites invention. Fix the spec before you fix the prompt.
Layer 1: constrain the prompt
The first defense is the instruction itself. The prompt from the earlier chapter already includes the key lines:
from dataclasses import dataclass
@dataclass
class FormatSpec:
name: str
max_words: int
structure: str
FORMATS = [
FormatSpec("linkedin_post", 200, "Hook line, three short paragraphs, one closing question"),
FormatSpec("email_newsletter", 250, "Subject line, two-sentence intro, three bullets, one call to action"),
FormatSpec("video_script_60s", 150, "Hook in the first 5 seconds, three beats, spoken call to action"),
]
def build_prompt(source: str, core_message: str, voice: str, spec: FormatSpec) -> str:
return (
f"Rewrite the source material as a {spec.name}.\n"
f"Core message: {core_message}\n"
f"Brand voice: {voice}\n"
f"Length: at most {spec.max_words} words.\n"
f"Structure: {spec.structure}.\n"
"Use only facts, numbers, and claims that appear in the source. "
"If something is not in the source, leave it out.\n\n"
f"<source>\n{source}\n</source>"
)Three details matter here:
- The source is wrapped in
<source>tags. This separates the material from the instructions, so the model treats it as data. - The "leave it out" sentence gives the model a permitted alternative to inventing. Without it, a model asked for three bullets will produce three bullets.
- The structure line limits the count of slots, not the content. If your source supports only two claims, change the spec to ask for "up to three bullets".
A prompt cannot guarantee fidelity. It lowers the error rate, and the later layers catch what remains.
Layer 2: keep a claim list
In the earlier chapter you extracted the core message and key claims. Turn that into a numbered list and put it in the prompt, so the model can point to claims by ID.
Key claims from the source:
C1. 41% of surveyed teams reduced reporting time after adopting templates (survey of 212 teams).
C2. The effect was largest for teams with fewer than 20 people.
C3. The study did not measure revenue impact.Note that C3 is a limit. Including what the source does not claim helps prevent overreach, because the model sees the boundary.
Then ask the model to attach the IDs it used. You can do this through structured output, which makes the draft machine-readable:
{
"draft": "Teams that adopt reporting templates ...",
"claims_used": ["C1", "C2"],
"added_information": []
}The added_information field gives the model a place to declare anything it brought in from outside the claim list. A non-empty value is a flag for the reviewer. Self-reports are not reliable on their own, because a model can claim it used only C1 and C2 while paraphrasing something else. Treat them as a cheap first signal and verify with the checks below.
Layer 3: automatic checks
Automatic checks are narrow but fast. The most useful one finds numbers in the draft that are absent from the source, since invented statistics are the most damaging error and the easiest to detect.
import re
def numbers_in(text: str) -> set[str]:
return set(re.findall(r"\d+(?:[.,]\d+)*%?", text))
def unsupported_numbers(source: str, draft: str) -> list[str]:
return sorted(numbers_in(draft) - numbers_in(source))Run it on a draft that says "Teams cut reporting time by 41% and saved 15 hours a week" against a source that mentions only 41%. The function returns ['15'], and the reviewer looks at that sentence first.
What this check misses
Know the limits so you do not over-trust it:
- Formatting differences. If the source says "41 percent" and the draft says "41%", the strings
41and41%differ, and the check reports a false positive. Normalize both sides if your sources mix styles. - Spelled-out numbers. "Forty-one" and "three out of four" are invisible to the regex.
- Derived numbers. A draft that says "nearly half" for 41% passes, because no digits are involved. A draft that says "82%" for a doubled 41% fails, which is correct, but a legitimate sum or ratio also fails and needs a human to confirm it.
- Wrong attachment. The draft may use 41% and 212 correctly, but swap what they describe. The check sees both numbers in the source and passes it.
- Non-numeric inventions. Names, products, and quotes are not covered.
You can extend the same idea to proper nouns by extracting capitalized words and comparing them to the source. Expect more false positives, because sentence-initial words and brand names for your own company also match. Use it as a prompt for review, not a verdict.
Quote checking
If a draft contains quotation marks, the quoted text should appear in the source word for word. This is a stricter test than the number check and is easy to automate:
import re
def unsupported_quotes(source: str, draft: str) -> list[str]:
quotes = re.findall(r"[\"“]([^\"”]{12,})[\"”]", draft)
normalized_source = " ".join(source.split()).lower()
return [q for q in quotes if " ".join(q.split()).lower() not in normalized_source]The 12-character minimum skips short scare quotes around single words. A paraphrased quote returns as unsupported, which is the behavior you want: a paraphrase should not sit inside quotation marks.
Layer 4: a second-pass audit
For high-stakes assets, add a second model call that acts as a checker. Give it the source and the draft, and ask for a sentence-by-sentence verdict. The checker works better when the task is narrow and the output format is fixed:
For each sentence in the draft, return one of:
SUPPORTED (quote the supporting source sentence),
UNSUPPORTED (no source sentence backs it),
STRONGER (the source says something weaker).Requiring a quoted source sentence for SUPPORTED matters. It makes the checker show its evidence, and you can then run the exact-match test above on its quotes. A checker that cannot produce a real quote has not found support.
This pass costs another model call per draft and still makes mistakes, so it reduces review work without removing it.
Putting the layers together
The pipeline function attaches the automatic results to each draft and marks everything as needing review:
def call_model(prompt: str) -> str:
raise NotImplementedError("Replace with your model provider's client call")
def repurpose(source: str, core_message: str, voice: str, formats: list[FormatSpec]) -> dict:
results = {}
for spec in formats:
draft = call_model(build_prompt(source, core_message, voice, spec))
results[spec.name] = {
"draft": draft,
"word_count": len(draft.split()),
"unsupported_numbers": unsupported_numbers(source, draft),
"status": "needs_review",
}
return resultsEvery draft starts as needs_review. No check in this chapter promotes a draft to approved. That decision belongs to a person, which is the subject of the next chapter.
Choosing how much checking to do
Match the effort to the risk of the claim and the channel.
| Situation | Suggested checks |
|---|---|
| Internal draft, low stakes | Constrained prompt, number check |
| Public social post with statistics | Add claim IDs, quote check, human review of flagged lines |
| Regulated or legal content (health, finance) | All layers, plus review of every sentence by a qualified person |
| Customer quotes and testimonials | Exact quote check, written permission on file |
Longer formats need more attention than short ones. A 150-word script has few places to hide an error, while a 1,500-word article spreads small shifts across many paragraphs.
Common errors in practice
- Putting the claim list only in the review step. The model should see it when it writes, not just when you check.
- Asking for more than the source holds. Specs with fixed counts ("five tips") cause padding. Use "up to".
- Trusting
claims_usedat face value. Verify it against the draft. - Treating a clean automatic check as approval. A draft can pass every script and still say something misleading.
- Fixing the draft by hand and skipping the cause. If the same invented claim shows up in three formats, the spec or the source summary is the problem. Correct it there.
Exercise
A draft says "Teams using templates cut reporting time by 41% and saved 15 hours a week." The source mentions 41% and 212 teams but never mentions 15 hours. What does unsupported_numbers return, and name one error in the same draft that this function could not catch.
Show answer
It returns ['15'], because 15 appears in the draft but not in the source. It could not catch a strengthened claim, for example if the source said "41% of teams reduced reporting time" and the draft implied that all teams cut time by 41%. It also could not catch a swapped attachment, such as using 212 as a percentage, since both numbers appear in the source.
Exercise
Your spec asks for "five statistics" in a newsletter, but the source contains two. Which layer should you change first, and why?
Show answer
Change the format spec, for example to "up to three bullets, using only statistics from the source". A fixed count the source cannot supply pushes the model to invent the missing items, and no prompt wording or later check addresses that cause as directly.