Data poisoning: tampered training, fine-tuning, and retrieval sources

How poisoned examples in training sets, fine-tuning data, or a retrieval corpus change model behavior, which sources are easiest to tamper with, and how provenance, review, and evaluation sets catch it.

Lesson 45 of 69 · 11 min read · practice only with authorization

Diagram

Where poisoned data can enter

Follow the path. One example at a time.

Step 1 of 4

Collection

Scraped pages, user feedback, and shared datasets are open to editing by outsiders.

Illustration: Collection
# Collection
# Scraped pages, user feedback, and shared datasets are
# open to editing by outsiders.

The example on the open step is one illustration, or the fix you can paste into an application you own.

What this page is made of

3 pieces. Each one says what fails, who is affected, what you would notice, and what you change.

  1. Open collection

    What fails
    Anything scraped or crowdsourced can be shaped by whoever controls the source.
    Who is affected
    Users of the model trained on it.
    What you would notice
    Datasets without a source list or hashes.
    What you change
    Record provenance and hashes for every source.
  2. Feedback loops

    What fails
    Thumbs-up data and user corrections fed back into training can be gamed.
    Who is affected
    All users, as behavior drifts.
    What you would notice
    Feedback used for training without rate limits or review.
    What you change
    Review samples and weight trusted reviewers.
  3. Retrieval corpora

    What fails
    For RAG, editing a source document changes answers immediately.
    Who is affected
    Anyone trusting the assistant’s policy answers.
    What you would notice
    Recent edits to high-traffic pages by new accounts.
    What you change
    Restrict who can edit authoritative sources and show citations.

Evaluation as a tripwire

A fixed, access-controlled evaluation set measured on every release catches many shifts. Include prompts about policies and safety-relevant behavior, and alert on changes even when overall accuracy improves.

Check yourself

Recognition and the fix. Nothing here is a procedure.

1 / 3

Which source can change a RAG assistant’s answers immediately?

Sibling techniques

Pages at the same depth, plus a lab and a glossary card for this one.

This page stands on its own. The lab and the glossary card are the next reading.

Practice

  1. LabControl benchA failure is described. Choose the control that changes the outcome.

Glossary

  1. CardData poisoningTraining or fine-tune data is altered so the model behaves wrongly later.