Season 3 · Context Engineering · Episode 4

S3E4 The Extractor

Drop in a file, get its whole content back as clean text you can keep

What this lesson is about

A PDF is a picture of a document. A photograph of a worksheet is a picture of a picture of a document. Neither can be searched, quoted, fed to another tool, or pulled into the harness you have been building all season. The Extractor's whole job is to turn any of those back into plain text you can actually use. You give it a file or a link; it gives you clean markdown. That is the entire job, and it does nothing else on purpose.

What you'll be able to do

A little background

This episode closes the season's loop. Season 3 has been about building context for an AI to work from — first a file describing you, then rules for an agent, then the retrieval step that searches those files. The Extractor is what fills them. It is the difference between a folder of documents you own and a folder of documents an AI can read.

Extraction is accuracy work rather than reasoning work, so the way to judge it is not whether the output reads nicely. It is whether the output matches the original. Pick something off the page you can see with your own eyes — a figure in a table, a heading halfway down, the last line — and find it in what came back. If those match, the extraction held.

Once a document becomes text you can search, what becomes possible that was not possible before?

Key words

Extraction
Getting the content out of a file in a form you can search, quote and reuse.
Markdown
Plain text with light punctuation for structure. Readable by you, by any AI, and by any machine later.
OCR
Optical Character Recognition — reading letters out of an image, which is what happens to a photographed page.
Structure
Headings, lists and tables. A good extraction keeps them; a poor one flattens everything into prose.