AI engineering glossary · Prompt context engineering
What is output parser?
Output parser: Code that reads the raw text of a model reply and turns it into a usable structure, for instance pulling out JSON, a list or text between tags. Good parsers handle stray text around the answer and report clear errors.
Output parser: an example
A parser finds the text between <answer> and </answer> and converts '42' into the integer 42.
Related terms
More Prompt context engineering terms
- Output repair
- Parallel tool calls
- Plan-and-Solve prompting
- Position bias
- Presence penalty
- Program-aided language models
- Prompt
- Prompt caching
Where you learn it
Output parser is part of the AI Engineering Program, which teaches it with notes, a hands-on lab and an exam. The first lesson is free.