June 12, 2026 · 1 min read · Yunus Emre Vurgun
Prompt Engineering for Reference Lookups: Stop Dumping JSON
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
- Cite the source in the same block. Models deprioritize anonymous facts.
- Match format to task. Lookup tables want compact rows, not nested JSON.
- 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.