Fix Invalid JSON from AI
The JSON won't parse and you can't see why. Deterministic cause-sniffing — trailing commas, single quotes, unclosed brackets — and the repair prompt that fixes it.
Heading scan against the skeleton: missing sections, broken order, absent title — the README that shipped without its Examples.
Generated documents erode structurally: a section gets dropped, another swaps position, and the document still looks fine at a glance. This setup validates a README against its five-section skeleton and catches the two most common drops — Installation and Examples, the sections readers actually came for. The heading scan is real markdown parsing of #/##/### lines with order checking; the repair prompt restores the missing sections without touching the ones that survived.
Paste skeleton and document
The expected sections in order; the generated markdown raw — heading scan does the rest.
Read the missing-section fails
Installation and Examples are the sections users need most — and the ones models drop first.
Repair into the same document
The repair prompt adds what's missing and keeps every surviving section verbatim.
The AI Output Validator does a real heading scan of the #/##/### lines and checks them against the expected skeleton in order — in the loaded example it flags "Missing section: Installation" and "Missing section: Examples," the two sections readers came for. Order checking also catches a section that swapped position. It surfaces structural gaps; it doesn't review the prose quality, and it can't guarantee catching every content problem.
Surviving sections stay untouched: the REPAIR TASK returns only the corrected markdown under the rules "Keep everything that was already correct unchanged" and "Fix only the problems listed above," so untouched sections travel verbatim while Installation and Examples get restored. You run that repair prompt in your own assistant; the validator produces it but doesn't regenerate the document itself.
The JSON won't parse and you can't see why. Deterministic cause-sniffing — trailing commas, single quotes, unclosed brackets — and the repair prompt that fixes it.
Paste the response, get the verdict: real JSON parsing, missing-field detection, and a repair prompt for everything found.
Grade agent output the same way every time — a rubric scoring correctness, grounding, safety, tone, and completeness, with a pass threshold instead of a gut call.
Stop getting 'Sure, here is the JSON…' — the output-contract pattern that forces models to return only parseable JSON: schema, example, and a strict rule block.
Free text in, named fields out. The extraction prompt pattern that turns any unstructured text into consistent, parseable records.
Billing, Technical, Account, How-To, Feature Request — ticket triage with definitions that decide the borderline cases for the model.
Paste an AI's output and validate it against the expected format — with a repair prompt for every failure found.
Turn source material and a target audience into clear docs, help, or knowledge-base content — gather the material, outline the piece, write it section by section, then check it for clarity and gaps.
Generate documentation that matches the code instead of drifting from it — have AI explain what the code really does, write it up as structured docs, then validate the format holds.
Your README works perfectly on the one machine where the tool was already installed. Everyone else hits a missing prerequisite in the first ninety seconds. Here's how to build a README from your real setup facts — and the clean-machine run that decides whether any of it is true.