Free concept playground · no account

Pack the Brain

Pack the AI's memory before it forgets your question.

Pack the Brain

AvailableFree
Context window:3,300 / 4,096 tok (overflow)
  • System prompt300 tok · prio 95 · 69% attn
  • The question200 tok · prio 100 · 42% attn
  • Retrieved doc A1,400 tok · prio 60 · 42% attn
  • Retrieved doc B (has the answer)1,400 tok · prio 55 · 69% attn
  • Retrieved doc C1,400 tok · prio 50 · evicted
  • Chat history1,600 tok · prio 40 · evicted

✓ The answer doc gets 69% attention — the model can use it.

Context rot you can watcha fuller window remembers less

You packed 3,300 of 4,096 tokens (81% full), evicting 2 block(s). The answer-bearing doc ends up with 69% attentionenough to use.

A bigger context window isn’t a bigger memory. Attention thins toward the middle of a stuffed window (“lost in the middle”) and degrades as it fills. Put the fact that matters near an edge, keep the window lean, and evict on purpose — don’t just dump everything in and hope.

Was this playground useful?

Pack the brain

Drag content blocks — system prompt, chat history, retrieved docs, the question — into a fixed context window sized to a real model. Overflow the window and the lowest-priority blocks get evicted; even for what stays, an attention heat-strip shows the middle of a stuffed window going cold. Then watch a buried answer get the wrong response. Runs entirely in your browser (0 uploads, works offline).

How to use it

  1. Pick a context window size and choose which blocks to include (checkbox) and their order (↑/↓).
  2. Watch the fill bar and the attention heat-strip — brighter means more attention, dim means the model barely reads it.
  3. Read the verdict: whether the answer-bearing doc gets enough attention to be used — or was evicted or lost in the middle.

What this clears up (the fundamentals)

  • A bigger window isn't a bigger memory — attention doesn't spread evenly. Models attend most to the start and end of the context and least to the middle ("lost in the middle").
  • Context rot is real — as a window fills, attention degrades across the board. A fact that would be used in a lean prompt gets ignored in a stuffed one.
  • Eviction is a priority decision — when content overflows, something gets dropped. If you don't decide what, the system drops it for you — sometimes the answer.
  • Placement matters — the same retrieved doc helps at an edge and gets ignored in the middle. Where you put a fact is part of the prompt.

Where it's used

An AI-engineering literacy tool — the fastest way to feel why "just paste everything into the giant context window" produces worse answers, not better. It's a miatz build-lab concept playable; learn to build it yourself.

FAQ

What is "lost in the middle"?

An observed behaviour where language models retrieve information reliably from the beginning and end of their context but poorly from the middle. Bury the relevant fact in the middle of a long prompt and the model often ignores it.

What is context rot?

The general degradation of attention and answer quality as a context window fills up. More tokens dilute the model's focus, so relevant content gets less effective attention than it would in a shorter prompt.

How is attention estimated here?

With a U-shaped position curve (high at the edges, low in the middle) multiplied by a fill penalty that grows as the window approaches full. It's a teaching approximation of the real, measured effect.

Is anything uploaded?

No. The packing and attention math run entirely in your browser — nothing is transmitted or stored. Turn off your Wi-Fi and it still works.

Limits

A teaching model with fixed blocks and an approximated attention curve — real models vary in how strongly they show these effects, and good retrieval/re-ranking mitigates them. Use it to build the "lean, ordered context" instinct, then measure on your own prompts.

Related

Part of the Demystify Playgrounds. Explore the rest from the Playgrounds home.

Bookmark this page (Ctrl+D, or ⌘D on Mac) — it works offline the next time you need it.

Ninety playgrounds. Zero setup.

Every concept here is playable free, no account — and inside the program you learn to rebuild the machinery yourself.