Sub topic 14
Preventing Problems with Better Prompts and Source Material
This chapter assumes you have read the earlier chapters on claim extraction, fact verification, bias testing, brand rubrics, and the audit log. It also assumes you have written prompts for a generative AI tool. The Python example needs only basic Python.
The earlier chapters catch problems after a draft exists. This chapter moves the work earlier. If the same problem shows up in your rejection log week after week, the cheapest fix is usually to change what the model is given, not to keep catching the problem at review.
What upstream controls can and cannot do
An upstream control is anything you change before the model writes: the prompt, the source material, the examples, the output format, or the brief. These controls lower the rate of problems. They do not remove the need for review.
A model that is told to use only the supplied facts can still misread a fact, blend two of them, or add a plausible detail from its training data. Treat upstream controls as a way to make review faster and failures rarer. Keep the review step.
| Approach | What it does | Weakness |
|---|---|---|
| Review only | Catches problems in finished drafts | Reviewers repeat the same fixes on every draft |
| Upstream controls only | Reduces how often problems appear | Nothing catches the failures that remain |
| Both, linked by the rejection log | Review finds the problems, upstream changes prevent them | Needs someone to own the log and the prompt changes |
Start from the rejection log
Your audit log from the previous chapter is the input to this one. Group rejected drafts by cause, then pick the causes that recur. A typical grouping looks like this:
- Invented statistics or customer numbers.
- Features described that the product does not have.
- Superlatives and guarantees that legal rejects.
- Tone that is too casual or too formal for the channel.
- Audience assumptions, such as assuming a buyer's age or family status.
Each cause points to a different upstream fix. Invented numbers point to the source material. Tone points to the prompt and its examples. Audience assumptions point to the brief. Fix the most frequent cause first, and change one thing at a time so you can tell whether the change worked.
Control 1: Give the model a fact pack
A fact pack is a short, approved list of statements the model may use as facts. Each statement has an ID, the wording you will stand behind, and the source and date it was checked against. The pack replaces the model's memory of your product with material you have already verified.
A good fact pack has these properties:
- Small. Include only what this piece of copy needs. A 40-page product document invites the model to pick the wrong detail.
- Written as claims, not marketing. "The Plus plan costs $12 per user per month, billed annually" is usable. "Affordable pricing for everyone" is not.
- Dated. Prices, features, and availability change. A "checked on" date tells the next person when to re-verify.
- Explicit about limits. Include what the product does not do and which regions or plans are excluded. Models fill silence with the most common feature in the category.
- Owned. One named person updates the pack when the product changes.
Because every fact in the pack was already verified, the fact check for a draft becomes a comparison of the draft against the pack. Anything in the draft that is not in the pack is, by definition, a new claim and goes to full verification.
Control 2: Write prompts that constrain claims
Most prompts say what to write. Prompts that prevent problems also say what to do when the material is missing. The instructions below address the failure patterns from the earlier chapters.
- Restrict the source. "State product facts only from the FACTS list. If a fact you need is not listed, write [NEEDS FACT: description] instead of guessing."
- Require tags. "After every sentence that contains a fact, add the ID of the supporting fact, such as [F2]." Tags make the draft checkable in seconds.
- Ban the risky forms. "Do not write statistics, percentages, customer quotes, awards, rankings, or comparisons with named competitors unless they appear in FACTS."
- Say what a quote is. Models invent testimonials readily. Provide real approved quotes in the pack, or forbid quotes altogether.
- Allow refusal. A model that is told it may leave a gap will leave one more often than a model that is told to produce a finished paragraph.
Do not rely on a single sentence such as "Be accurate." It gives the model nothing to act on. Specific instructions tied to specific failure patterns work better because you can test them: run the prompt on ten briefs and count how many drafts still contain untagged numbers.
Control 3: Put brand and audience rules in the prompt
Your brand rubric already turns the style guide into questions. Reuse those questions as instructions. If the rubric asks "Is the copy in plain, direct language with no jargon?", the prompt should say "Use plain, direct language. Avoid jargon." Matching the wording of the prompt to the rubric means the model is being steered toward the same criteria the reviewer will score.
Add two more things:
- One or two approved examples. A short sample of on-brand copy for the same channel shows tone better than a paragraph of description. Choose examples that pass your rubric, and change them periodically so the model does not copy their structure.
- A bias-aware brief. State the audience by need and situation, not by assumed identity. "Small business owners who need to send invoices faster" gives the model something to write about. "Women entrepreneurs" invites stereotyped framing. Also instruct the model not to infer age, gender, family status, or income from the audience description.
Your swap test from the bias chapter still applies. Prompts that include the same constraints for every audience group make the outputs more comparable, so differences between groups are easier to see.
A worked example: build the prompt and run a tag check
The script below builds a prompt from a fact pack and a brief, then runs two cheap checks on a draft. It finds tags that point to facts not in the pack, and sentences that contain digits but no tag. Like the earlier pre-check script, it flags things for a human to look at and does not verify truth.
import re
FACT_PACK = {
"F1": "The Plus plan costs $12 per user per month, billed annually. "
"(Pricing page, checked 2026-11-02)",
"F2": "Plus includes shared project boards and CSV export. "
"(Feature list, checked 2026-11-02)",
"F3": "Plus does not include single sign-on. "
"(Feature list, checked 2026-11-02)",
}
VOICE_RULES = [
"Use plain, direct language. Avoid jargon.",
"Do not use guarantees or superlatives such as best, fastest, or risk-free.",
"Do not infer the reader's age, gender, family status, or income.",
]
def build_prompt(brief, facts, voice_rules):
fact_lines = "\n".join(f"[{fid}] {text}" for fid, text in facts.items())
rule_lines = "\n".join(f"- {rule}" for rule in voice_rules)
return (
"Write marketing copy for the brief below.\n\n"
f"BRIEF:\n{brief}\n\n"
f"FACTS (the only product facts you may state):\n{fact_lines}\n\n"
"RULES:\n"
"- After every sentence that states a fact, add its ID, for example [F1].\n"
"- Do not write statistics, quotes, awards, rankings, or competitor "
"comparisons unless they appear in FACTS.\n"
"- If you need a fact that is not listed, write [NEEDS FACT: description].\n"
f"{rule_lines}\n"
)
def unknown_tags(draft, facts):
"""Return fact IDs cited in the draft that are not in the fact pack."""
return sorted(set(re.findall(r"\[(F\d+)\]", draft)) - set(facts))
def untagged_numbers(draft):
"""Return sentences that contain a digit but cite no fact ID."""
sentences = re.split(r"(?<=[.!?])\s+", draft.strip())
return [s for s in sentences if re.search(r"\d", s) and not re.search(r"\[F\d+\]", s)]
brief = "Two sentences for a landing page aimed at small teams that need shared task tracking."
print(build_prompt(brief, FACT_PACK, VOICE_RULES))
draft = (
"The Plus plan costs $12 per user per month [F1]. "
"Teams save 40% of their time. "
"Export your boards to Excel [F9]."
)
print("Unknown tags:", unknown_tags(draft, FACT_PACK))
print("Untagged numbers:", untagged_numbers(draft))For this draft, the script reports F9 as an unknown tag and "Teams save 40% of their time." as an untagged number. The first sentence passes both checks. A reviewer would still open the pricing page to confirm F1, but the pack was verified once and does not need re-verifying per draft.
The feedback loop
The diagram shows how the rejection log feeds changes upstream and back into review.
Run the loop on a schedule, such as monthly, and keep a short change note for each edit: what you changed, which log entries motivated it, and what you expect to improve. After the change, compare the rejection rate for that cause over the next batch of drafts. If the rate does not drop, revert the change or try a different one.
Common mistakes
- Overstuffed fact packs. Dumping the whole product manual into the prompt makes tagging unreliable and invites wrong picks.
- Stale packs. A pack that is not updated after a price change makes the model produce confident, tagged, wrong copy. Put review dates in the pack and assign an owner.
- Prompt creep. Adding a new rule after every rejection produces a long prompt where rules conflict. Prune rules that no longer match recurring causes.
- Treating tags as proof. See the warning above.
- Changing several things at once. You cannot tell which change helped.
- Skipping the limits. Without "does not include single sign-on", a model may assume the feature exists.
Exercise
Your rejection log for the last month shows 14 rejected drafts. Nine were rejected for invented percentages, three for a tone that was too casual, and two for describing a feature the product lacks. Which upstream change do you make first, and how do you measure whether it worked?
Show answer
Address the invented percentages first, because they are the most frequent cause. Add a rule to the prompt that bans statistics unless they appear in the fact pack, require fact-ID tags on every sentence with a fact, and add any real, verified statistics to the pack with sources and dates. Change only this, then run the next batch of drafts and count how many are rejected for invented numbers, optionally using a script that flags digit-containing sentences with no tag. Compare that count with the 9 of 14 baseline. If it does not fall, revise or revert the change.
Exercise
A draft sentence reads "Plus supports single sign-on for secure teams [F2]." The fact pack contains F2 (shared boards and CSV export) and F3 (Plus does not include single sign-on). Does the tag check pass, and does the draft pass review?
Show answer
The tag check passes, because F2 exists in the pack and the sentence has a tag. The draft fails review. The sentence contradicts F3 and is not supported by F2. This shows why tags only make a draft faster to check and why the reviewer must compare each tagged sentence with the fact it cites. The fix is to remove the sentence and keep the explicit limit in the pack so the prompt and the reviewer both see it.