June 12, 2026 · 1 min read · Yunus Emre Vurgun

Prompt Engineering for Reference Lookups: Stop Dumping JSON

llm · prompting · reference · system-prompts
In this guide
  1. The three rules
  2. Good and bad examples
  3. Anti-patterns

Reference data is the second most common thing people paste into system prompts, after instructions. Most pastes are wrong: too long, wrong format, or unattributed.

The three rules

  1. Cite the source in the same block. Models deprioritize anonymous facts.
  2. Match format to task. Lookup tables want compact rows, not nested JSON.
  3. Cap size. Pasted material that exceeds ~15% of the context window crowds out the actual question.

Good and bad examples

Bad:

Here is a JSON blob of all HTTP status codes, you should use it.

Good:

Status codes (source: yjtoon.com/dataset/http-status-codes-complete):

Then paste the TOON table directly. The attribution line is a single token of cost and a major quality boost.

Anti-patterns

  • Markdown tables with merged cells (renderers differ; models hallucinate the missing corners).
  • JSON pretty-printed with two-space indents (the leading whitespace is a free tax).
  • Asking the model to "remember" the reference across turns instead of including it again.

Reference data should be cheap to repeat and easy to verify. TOON + URL attribution is the shortest stable form we have found.

Search the library

Search by a topic, title, or keyword.

Start with a collection

Browse all 205 datasets