Structured extraction identifies specified facts in text and arranges them as attributes in a table. It is useful when information scattered across documents—such as internship applicants’ names, GPAs, and degrees—needs to be compared. section 4.3
A simple extraction workflow:
- Name the attributes to extract and provide the source text. section 4.3.1
- Specify an output format, including a placeholder for missing values. section 4.3.1
- Ask a language model for the results, then postprocess its text response into rows and fields. section 4.3.1 section 4.3.3
#1 Extract the following properties into a table: name,GPA,Degree #2 Text source: My name is Martin, I would love to do a summer internship at Banana! A bit about myself: I am currently working on a Bachelor of Computer Science at Stanford University, my current GPA is 4.0. #3 Mark the beginning of the table with <BeginTable> and the end with <EndTable>. Separate rows by newline symbols and separate fields by pipe symbols (|). Omit the table header and insert values in the attribute order from above. Use the placeholder <NA> if the value for an attribute is not available.
A reusable prompt specifies the attributes, source text, table delimiters, field order, and missing-value placeholder. section 4.3.1
From emails to an applicant table
For an email describing an applicant, extract the name, GPA, and degree. Repeating the process across emails produces a table for comparison; other examples extract birth cities and dates from biographies, using a placeholder when a fact is absent. section 4.3 section 4.3.5



