A constrained screen needs an output contract before it needs more model prose. An Astra answer routed through CometAPI can be valid text and still hide the next action below a card, truncate an important caveat, or force horizontal scrolling. Define the fields, validate their bounds, and then inspect what the interface actually renders.
OpenAI’s Astra guidance describes detailed, formatted responses and recommends specifying the style and structure an application needs. CometAPI’s Astra article positions the model around professional artifacts and multistep work. Neither source establishes the layout below: it is an illustrative product contract, with proposed acceptance criteria, not a rendered or live gateway result.
A measurable word, paragraph, and field contract
For an English status card, use five required text fields: title, summary, status, next_action, and caveat. Reject extra fields at the application boundary. Define a word as a nonempty whitespace-separated token and count characters as Unicode code points. Those definitions make the following bounds testable, although neither count can predict line wrapping by itself.
| Layer | Proposed bound | Application behavior when exceeded |
|---|---|---|
Word: next_action |
2–4 words, at most 24 characters | Use the caller-owned label “Review details”; retain the proposed action in the details view. |
Paragraph: summary |
One paragraph, 1–2 sentences, at most 40 words and 240 characters | Withhold the generated summary from the compact card and show “Open details for the full explanation.” |
Field: title |
At most 8 words and 60 characters | Use “Update requires review”; show the full title in details. |
Field: status |
Exactly ok, warning, or error |
Treat any other value as an invalid response. |
Field: caveat |
At most 20 words and 120 characters; required and nonempty for warning/error | Keep the card in a warning state with “Details need review” if the caveat is missing or too long. |
These fallback strings belong to the application, so malformed output cannot supply its own replacement policy. Text bounds do not replace authorization checks for the action itself.
Three overflow fixtures
Use a 360 × 640 CSS-pixel viewport, 16-pixel side gutters, a 328-pixel card, and a 16-pixel system font with 24-pixel line height. Repeat at 200% text size with a 48-pixel line height. The proposed layout has no fixed card height: it allows vertical scrolling, wraps text, and never clamps the caveat. The action follows the caveat in document order.
- Long title. Set
titleto “Quarterly fulfillment exceptions requiring immediate customer follow-up across three regional teams”. This exceeds the word and character bounds. Expect “Update requires review” on the compact card, the complete title in details, and no horizontal scrollbar at either text size. - Dense paragraph. Set
summaryto “The import completed for the first batch, but several records need attention because their identifiers do not match the destination catalog and their requested dates fall outside the current fulfillment window, so inspect each mismatch before starting the next batch or notifying customers that every order is ready.” This exceeds 40 words. Expect the fixed summary fallback plus access to the complete original in details; the card must not silently cut the paragraph mid-sentence. - Error summary. Use
status: error,title: Import needs attention,summary: Three rows contain duplicate identifiers.,caveat: No records were imported. Review duplicate identifiers before retrying., andnext_action: Review details. The bounded text should remain readable at both sizes. If it extends below the viewport at 200%, scrolling must reveal the entire caveat before the action; no ellipsis or fixed-height clipping is acceptable.
Treat these as inputs and expected behavior to implement and inspect. No browser render or CometAPI trial is reported here. Verify the selected Astra route and returned field shape before enabling the card.
Reasoning effort is a separate experiment. My recommendation is to compare settings and retain the least demanding one that passes the content checks; this is not an OpenAI lowest-effort rule. The proposed layout acceptance goal remains the same across settings. If text fails the bounds or clips on screen, correct the parser, fallback, or layout and repeat the affected fixture before interpreting it as a model-quality problem.