PromptisePromptise
Why PromptiseUse casesRoadmapDocs
GitHubGet started
Promptise - AI Framework LogoPromptise

The foundation layer for agentic intelligence. Build, secure and operate autonomous AI systems with Promptise Foundry.

pip install promptise

[01] Foundry

  • MCPcast
  • The Promptise Agent
  • Reasoning Engine
  • MCP
  • Agent Runtime
  • Prompt Engineering
  • Execution Engine
  • Agent Identity

[02] Resources

  • Documentation
  • GitHub
  • Guides
  • Learning Paths
  • Questions

[03] Company

  • About
  • Terms of Service
  • Privacy Policy
  • Cookie Policy
  • Subprocessors

© 2026 Promptise by Manser Ventures. All rights reserved.

Open source · Python

← Guides> Prompt Engineering

Why LLMs Get Niche Facts Wrong: Popularity and Training Data

Why LLMs know popular facts but invent niche ones: accuracy tracks how often a fact appears in training data. When to retrieve instead. Real example.

Level
Intermediate
Reading time
5 min
Published
Sep 20, 2025
Last updated
Oct 18, 2026
By
Promptise Team
  • LLM Mental Models
  • How LLMs Work
  • Hallucinations
  • RAG (Retrieval-Augmented Generation)
Contents · 6 sections↓
  1. 01Why do LLMs get niche facts wrong?
  2. 02Why it's true
  3. 03Example: famous and obscure scientists
  4. 04What it changes in practice
  5. 05Frequently asked questions
  6. 06Next steps

An LLM learned what it knows from what many people wrote. A fact stated on thousands of pages is learned well; a fact stated on a handful is learned poorly, and the model gives both in the same confident tone. This essay, part of the Mental Models learning path, explains the research on popularity and accuracy, how to predict which questions are risky, and what to do about the long tail. It includes a real example where the famous answers are right and the obscure ones are invented.

[01]

Why do LLMs get niche facts wrong?

A model's accuracy on a factual question tracks how often the facts behind it appear in its training data. Popular facts appear across thousands of documents and are learned reliably. Long-tail facts, such as minor people, small companies, exact dates and your own internal data, appear rarely or never, so the model fills the gap with something plausible. Nothing in the answer tells you which case you are in. For long-tail questions, give the model the source.

Key takeaways:

  • Ask "how many pages say this?" That estimate predicts reliability better than how confident the answer sounds.

  • Coarse facts outlive fine ones. Years and countries survive; days, places and numbers drift.

  • Retrieval fixes the tail. Supplying the source matters far more for obscure facts than for popular ones.

  • Your company's data is the extreme tail: zero training documents.


[02]

Why it's true

Large Language Models Struggle to Learn Long-Tail Knowledge (Kandpal et al., ICML 2023) counted, for each question in benchmarks such as TriviaQA, how many pretraining documents mention the entities involved. Accuracy rose with that count, with both correlational and causal evidence, across model sizes up to 176B parameters. Bigger models did better on rare facts, but the authors estimated that scale alone would need many orders of magnitude to close the gap, and that retrieval reduces the dependence on pretraining frequency.

When Not to Trust Language Models (Mallen et al., ACL 2023) built PopQA, 14k questions about entities of varying popularity. Models struggled with less popular entities, and scaling did not meaningfully improve memorization of the tail. Retrieval-augmented models beat much larger unaided models, while unaided models stayed competitive on popular entities. The authors proposed adaptive retrieval: retrieve only when the question is about something unpopular.

The crowd metaphor is accurate in one more way: the model has no index of its sources. It can't tell you "only three pages said this" because it doesn't store pages; it stores what the pages had in common.


[03]

Example: famous and obscure scientists

Text
1
2
3
4
5
6
7
8
9
Give the full date of birth (day, month, year) and place of birth of each of these physicists/chemists. One line each, no commentary:
Marie Curie
Lise Meitner
Hertha Sponer
Marietta Blau
Harriet Brooks
Erika Cremer
Clara Immerwahr
Hilde Levi
Output
Marie Curie — 7 November 1867, Warsaw, Congress Poland (then Russian Empire)
Lise Meitner — 7 November 1878, Vienna, Austria-Hungary
Hertha Sponer — 23 September 1895, Neisse (now Nysa), Prussian Silesia, German Empire
Marietta Blau — 28 July 1894, Vienna, Austria-Hungary
Harriet Brooks — 2 January 1876,  Port Hope, Ontario, Canada
Erika Cremer — 23 June 1900, Berlin, German Empire
Clara Immerwahr — 21 June 1870, Polkendorf (now part of Świebodzin), Province of Brandenburg, Prussia
Hilde Levi — 7 November 1909, Copenhagen, Denmark

Checked against Wikidata: Curie and Meitner, the two famous names, are right. Every birth year is right. But Sponer was born on 1 September, Blau on 29 April, Brooks on 2 July in Exeter, Ontario, Cremer on 20 May in Munich, and Levi on 9 May in Frankfurt. Levi got the same "7 November" as the two famous lines above her. Immerwahr's date is right, her birthplace description wrong.

A prompt that allows uncertainty helps only partly:

Text
… If you are not confident of the exact day and month, give only what you are sure of (for example just the year) and mark the line 'CHECK'. Leaving out a detail is better than guessing it.
Output
…
Hertha Sponer — 5 July 1895, Neunkirchen, Saarland, German Empire. CHECK …
Marietta Blau — 28 July 1894, Vienna, Austria-Hungary.
…
Erika Cremer — 23 January 1900, Erlangen, Kingdom of Bavaria, German Empire.
…

It flagged four lines, but still gave exact dates instead of just years, and left two wrong lines unflagged. Sponer's birthplace changed between runs, from the correct Neisse to Neunkirchen. Results vary by model; the pattern of right-on-popular, wrong-on-rare is the stable part.

From facts many pages state to facts no page states: popular facts like Curie's and Meitner's birth dates came back right, so answer directly; long-tail facts came back with the year right and the day wrong, and your own data has zero training documents, so retrieve the source. Years survive; days, places and numbers drift.
FigureThe fewer pages state a fact, the less reliably the model knows it, and the more you should retrieve the source

[04]

What it changes in practice

  • Estimate popularity before you trust. Would this fact appear on many independent pages? Famous people, mainstream APIs and textbook science, probably. Minor figures, niche libraries, recent releases, prices and anything about your organization, no.

  • Retrieve for the tail. Paste the source, connect search or a database, or give the model a lookup tool. Adaptive retrieval is a fine default: answer popular questions directly, ground everything else.

  • Use disagreement as a signal. When repeated samples disagree on a detail, as Sponer's birthplace did, the model is guessing. Verify that detail or drop it.


[05]

Frequently asked questions

How do LLMs learn facts?

They learn statistical patterns from training text. A fact repeated across many documents becomes a strong pattern; one mentioned rarely leaves a weak one. There's no separate fact database inside the model, which is why rare facts degrade into plausible guesses.

Does a bigger model fix long-tail errors?

It helps a little. Both Kandpal et al. and Mallen et al. found that scale improves popular facts much more than rare ones. Retrieval augmentation was the more effective fix for the tail.

Can I ask the model how sure it is?

You can, and it helps somewhat, but the model's self-reported confidence is not well matched to its accuracy on rare facts. Checking agreement across samples, or verifying against a source, is more reliable.

What counts as long-tail knowledge?

Facts that appear in few documents: lesser-known people and places, exact dates and figures, small projects, recent events after the training cutoff, and private data such as your policies, customers and code.


[06]

Next steps

  • LLMs as lossy compression: why exact wording fails even for popular sources.

  • LLM hallucinations: why they happen: quick checks for any answer.

  • Grounding LLM answers: give the model the right context.

  • Agentic RAG in Python: let an agent decide when to retrieve.

  • Verification loops: sample-agreement checks such as SelfCheckGPT.

  • Mental Models: How to Think with LLMs: the full learning path.

Contents

  1. 01Why do LLMs get niche facts wrong?
  2. 02Why it's true
  3. 03Example: famous and obscure scientists
  4. 04What it changes in practice
  5. 05Frequently asked questions
  6. 06Next steps

Learning paths

Want more structure? Paths put guides in order, like a short course.

See the paths →

> Read next

Related guides

  • // 01Beginner · 4 minWhy Can't LLMs Count Letters? Tokens and ProbabilityWhy LLMs miscount letters, reverse strings wrong and miss word limits: tokenization, sampling, real failures, and why exact work belongs in your code.
  • // 02Beginner · 5 minAre LLMs Stochastic Parrots? What the Term Gets RightAre LLMs stochastic parrots? What Bender et al. meant, what next-token prediction implies, where the term falls short, and the habit it should give you.
  • // 03Intermediate · 4 minLLMs as Lossy Compression: Why They Can't Quote ExactlyWhy an LLM is a lossy compression of its training data: it keeps gist and loses exact wording, quotes and URLs. What to ask it for, with a real example.
  • // 04Intermediate · 5 minWhy LLMs Fail Modified Puzzles: Pattern-Matching BiasWhy LLMs answer the famous version of a changed puzzle: training-data priors, research on counterfactual tasks, a real failure and how to prompt around it.
  • // 05Intermediate · 4 minAI Code Hallucinations: Why Plausible Output Fools YouWhy LLM code looks right but fails: plausibility vs correctness, hallucinated packages, a real regex that broke, and how to verify output by running it.
  • // 06Intermediate · 5 minHow LLMs Generate Text: Next-Token Probabilities ExplainedHow LLMs generate text one token at a time: probabilities, temperature, top-p, and why early words commit the rest. Real example of a verdict-first error.

Keep going.

Browse every guide by topic and level, or follow a learning path that puts them in order.

All guidesLearning paths