An output format tells a language model how to present its answer. A prompt can specify not just the task and input, but also the exact labels or layout the answer should use. Consistent answers are easier to process across many inputs. section 1.3.2 section 4.2.2
One label per review
To classify a movie review, include the review, ask whether its sentiment is positive or negative, and end with `Answer ("Positive"/"Negative"):`. Without that constraint, the model might reply with `P` or a full sentence instead. Using the same two labels makes it simpler to count the results. section 4.2.1 section 4.2.2
For information extraction, specify the shape of a whole result rather than a single label. A prompt can request named attributes in a fixed order, table boundary markers, newline-separated rows, pipe-separated fields, no header, and `<NA>` for missing values. Python code can generate that prompt for each input, then postprocess the model’s raw answer into structured output and save the results to a CSV file. section 4.3.2 section 4.3.4
#1 Extract the following properties into a table: [List of attributes] #2 Text source: [Email] #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.
The extraction prompt template shows where the attribute list and source text go, followed by the rules that make the answer parseable. section 4.3.2
Choose a format that matches the next step: a fixed label for counting classifications, or delimited fields for extracting records. State it explicitly in every prompt template rather than relying on the model to choose it. section 4.2.2 section 4.3.2









