Engineering Markdown Output Validation

Validate Markdown Structure

Heading scan against the skeleton: missing sections, broken order, absent title — the README that shipped without its Examples.

Overview

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.

Workflow

  1. Paste skeleton and document

    The expected sections in order; the generated markdown raw — heading scan does the rest.

  2. Read the missing-section fails

    Installation and Examples are the sections users need most — and the ones models drop first.

  3. Repair into the same document

    The repair prompt adds what's missing and keeps every surviving section verbatim.

Why This Works

  • A heading scan beats eyeballing for documents over a screen long
  • Order checking catches restructuring that presence checks miss
  • Severity weighting puts dropped sections above cosmetic issues

Best for

  • Doc generation pipelines with fixed skeletons
  • Repos generating READMEs at scale
  • Anyone whose generated docs "look complete"

Not for

  • Defining the document skeleton — that's the Markdown Output Builder
  • Reviewing the prose quality — structure validation, not editing

Use cases

  • Checking generated READMEs kept all five sections
  • Verifying docs pages before they merge
  • Catching the dropped section a reviewer would miss

Tip: Save time by exploring related resources and tools that integrate with this workflow.

Explore all resources