AI engineering glossary · Prompt context engineering
What is lost in the middle?
Lost in the middle: A documented pattern where models use information at the start and end of a long input better than information placed in the middle. It means where you place key facts in a long prompt can change answer accuracy.
Lost in the middle: an example
In a 20-document prompt, a model answers correctly when the relevant passage is first or last, but misses it in position 10.
Related terms
More Prompt context engineering terms
- Maieutic prompting
- Majority label bias
- Map-reduce summarisation
- Markdown formatting in prompts
- Max tokens
- Message roles
- Meta-prompting
- Multi-turn conversation
Where you learn it
Lost in the middle is part of the AI Engineering Program, which teaches it with notes, a hands-on lab and an exam. The first lesson is free.