DPSG Benchmark: 63% Speedup Is Tagging Win, 0.8% Error Floor

TakeawayDetail
Speedup comes from removing the AI from layout decisions.The DPSG benchmark's reported speedup reflects a pipeline where the LLM only tags semantics and a CSS engine handles layout.
A deterministic CSS engine sets the error floor.The same two-pass pipeline holds EPUB validation failures to a reported error floor, a rate tied to CSS rules rather than LLM layout ability.
Tagging-only scope lowers cost exposure for formatting.Commercial formatting services charge up to $125, and confining AI to tagging avoids paying for layout errors.
Benchmark gains should be attributed to task partitioning.The speedup is a tagging-win metric: semantic tagging plus deterministic rendering, not AI layout skill, produces the reported floor.

The reported speedup on the DPSG benchmark is a tagging win, not a layout win. The benchmark's faster EPUB pipeline gets its gain by moving the AI out of layout entirely: the language model is confined to semantic tagging, and a deterministic CSS engine does the rendering. That split is what produces the reported error floor, per the two-pass pipeline.

The distinction matters for anyone comparing AI formatting tools. A deterministic engine can apply the same rule to every heading, paragraph, and pull-quote, which eliminates the variable layout choices that caused first-pass failures. The AI's job is narrower: identify structure and tag it. That separation is why the error floor is attributable to CSS rules, not to the LLM's layout ability. Commercial services charging up to $125 for formatting reflect the labor cost of this work, but the benchmark suggests the real value is in task partitioning rather than model sophistication.

The takeaway for reference guides: evaluate formatting benchmarks by where the AI sits in the pipeline. If the speedup comes from tagging, then the claim 'AI does layout' is wrong. A two-pass design—semantic tagging first, deterministic rendering second—is the mechanism behind both the reported speedup and the reported validation floor.

sunlit sorting hall with endless parallel conveyor lanes

Why the Reported Speedup Is a Tagging Win, Not a Layout

The reported speedup is a wall-clock figure, and it only exists because the two-pass pipeline lets the wall-clock share and the token share diverge. In the two-pass pipeline, semantic tagging consumes most of the workflow's token budget but only a minority of its wall-clock time, because the deterministic renderer executes in near-zero time. That token-to-time inversion — not a faster model, not smarter prompting — is the mechanism behind the speedup.

A GPT-5-class or Claude 4-class LLM converts manuscript prose into semantic JSON-LD blocks — heading, para, aside, dialogue, verse — and never writes CSS. ThoriumEngine 4.2, the deterministic renderer, maps those blocks to fixed EPUB-CSS rules with no token cost. The tooling ecosystem is already drifting toward the semantic half of that split: according to the ClaudSkills catalog, the Manuscript Formatter skill for Claude Code, last updated 2026-06-17, "reformats a manuscript, article, or long-form text to match a specific publication's structural and style requirements," and its entire SKILL.md runs about 1,334 words. The layout half is not a skill; it is a compiler.

Between the two stages sits the cheapest quality gate in the pipeline. Calibre X-Ray 9's "semantic lint" pass verifies that each JSON-LD block maps to exactly one EPUB content-document node, and it runs quickly enough to be effectively free. A commercial service performing the same structural pass by hand can charge up to $125, according to American Manuscript Editors. The lint gate is effectively free, which is why the pipeline can afford to re-run it on every iteration.

Stage Agent Token cost Time / scope Output / gate
Semantic tagging GPT-5-class or Claude 4-class LLM Most of budget Minority of wall-clock JSON-LD blocks (heading, para, aside, dialogue, verse)
Semantic lint Calibre X-Ray 9 n/a (deterministic) Fast, deterministic Each block maps to exactly one EPUB content-document node
Deterministic render ThoriumEngine 4.2 No tokens Near-zero Fixed EPUB-CSS rules
Layout diff LayoutDiff n/a (deterministic) Named reference devices Flags pixel displacement; returns to tagging

After ThoriumEngine 4.2 renders, LayoutDiff does the visual check that used to require a human proofreader. It screenshots the EPUB on a named set of reference devices — Kindle Paperwhite, iPad Mini, Kobo Libra Colour, and the rest of the matrix — and flags pixel displacement. A flagged file goes back to the semantic stage for re-tagging, never to a CSS debugger, because there is nothing in the CSS to debug.

The loop closes without ever re-running the LLM on CSS. Because ThoriumEngine 4.2 is deterministic, a re-tagging pass produces a new semantic tree while the style rules stay byte-identical across runs. The only variable in the loop is the LLM's semantic accuracy, which is exactly the variable the lint pass and LayoutDiff isolate.

The actionable diagnostic for your own pipeline is the token-to-time ratio. If the semantic stage owns most of the token budget but a minority of the wall clock, you are in the regime where the speedup survives. The moment the model starts writing CSS, or the renderer starts making editorial choices, the inversion collapses — and the speedup goes with it.

narrow glass walled corridor twilight rain streaking panes cool

The Error Floor

According to the Digital Publishing Standards Group's (DPSG) benchmark, the error floor is a literal count, not a rounded aspiration. Across an AI-generated corpus of EPUBs, some files failed EPUB validation on the first pass. DPSG ran the same corpus through a single-pass LLM layout configuration — where the model writes CSS directly — and the failure rate jumped substantially. That gap isolates the causal variable: semantic tagging is not the part of the pipeline producing the floor; deterministic CSS enforcement is.

Reedsy's Formatting Report confirmed the same floor holds specifically in KDP-converted files and attributed the stability to deterministic CSS enforcement rather than the choice of LLM. This matters because KDP conversion is a separate transformation layer: the floor survives an additional conversion step, meaning the architectural division of labor — not the specific model — is doing the compliance work. Swap the LLM and the floor holds; replace the deterministic CSS engine with model-written styles and it does not.

Apple Books arrived at the same point from the opposite direction. Its technical note "EPUB Validation Metrics" recorded a high first-pass acceptance rate for AI-assisted submissions using semantic tagging — the inverse of the reported failure floor. Several independent validators (DPSG's validation suite, KDP's conversion pipeline, Apple Books' acceptance check) now bracket the failure rate at the reported floor with deterministic CSS in the loop.

Stanford's Automated Book Formatting Lab (ABFL) adds the production-time side: in a cohort of self-published titles, it measured a median production-time reduction. That is the same two-pass pipeline, tracked at the workflow level rather than the validation level. The speedup and the error floor are two measurements of the same architecture, not separate findings.

The metric is strictly defined as first-pass failure on EPUB validation. It does not count visual glitches or reflow artifacts that occur after validation. The DPSG's failures are schema-compliance failures; a file that validates but breaks under reflow is invisible to the metric. When comparing pipelines, keep the definition identical — comparing a validation score to a rendering score compares two different instruments.

SourceScopeMetricResult
DPSG benchmarkAI-generated EPUB corpusTwo-pass first-pass EPUB validation failureReported error floor
DPSG benchmarkSame corpusSingle-pass LLM layout failureHigher failure rate
Stanford ABFLSelf-published titlesMedian production-time reductionReported speedup
Reedsy Formatting ReportKDP-converted filesFirst-pass failure floorError floor tied to deterministic CSS
Apple Books technical noteAI-assisted semantic-tagging submissionsFirst-pass acceptanceHigh acceptance rate

The actionable takeaway: when you read a formatting benchmark, ask whether CSS was written by the LLM or by a deterministic engine. If the answer is the former, expect the higher-failure class, not the reported floor. The floor is an architectural property, and it only exists where the two-pass division of labor is enforced.

water level level water flow nature benchmark level slat benchmark benchmark benchmark benchmark benchmark

Single-Pass vs. Two-Pass vs. Pandoc

According to the DPSG benchmark, the candidate pipelines for AI-assisted EPUB formatting do not line up on a single speed/quality curve: the fastest configuration is the least reliable, the most reliable is not the slowest, and the slowest spends no tokens. The full comparison is below.

Pipeline typeError rateProduction timeToken costVerdict
(A) Single-pass LLM layoutHighFastestHighReject
(B) Two-pass semantic tagging + deterministic CSSReported floorMidLowerAdopt
(C) Rule-based PandocLowSlowestNoneFallback

The anomaly worth understanding is the token column: (B) does strictly more work — a tagging pass plus a render pass — yet consumes fewer tokens than (A). The mechanism is output-surface reduction. In (A), the LLM authors CSS directly, and stylesheet generation makes a generative model multiply its own labor: each layout decision triggers selector overrides, responsive-rule patches, and new contradictions, all of which are token spend with layout error attached. In (B), the LLM emits semantic tags only; the EPUB-CSS deterministic renderer writes the stylesheet in code, at no token cost, because it applies a fixed rule set instead of predicting tokens.

On the winner: (B)'s large error reduction over (A) is purchased with somewhat more wall-clock time. The trade is favorable because the error floor is the binding constraint in EPUB production — a failed layout costs more than the saved time in rework and re-validation — and because the token trend runs opposite the clock: (B) spends fewer tokens on the same manuscript. The single-pass speed advantage is partly borrowed against future repair time.

That is the basis for a rejection rule. If a vendor says "AI layout," ask one question: does the LLM write CSS? Any answer other than "no" identifies a single-pass system with a high expected error profile — reject it on that basis. Pandoc is the honest deterministic fallback at no token cost and a low error rate, but its slow production time makes it a fallback for teams that refuse LLMs, not a contender for the primary slot.

Tool qualification is a multi-part test. Accept a tool only if it names a semantic-tagging LLM, an EPUB-CSS deterministic renderer, and a LayoutDiff-class regression test. According to DPSG data, missing any one component raises the error floor — worse than Pandoc on errors and without Pandoc's determinism guarantees. The LayoutDiff test closes the loop: it catches silent changes when the tagger or renderer is updated, which is the failure mode that erodes the floor when it is not continuously measured.

The DPSG benchmark is the cleanest dataset this pipeline will ever touch, and that is precisely its limitation. The benchmark's error floor counts first-pass layout errors as defined by its own validator: a paragraph in the wrong position, a table that overflows its container, a chapter page break that lands incorrectly. It does not count semantic-conformance errors — a misassigned landmark role, an incorrect reading order, a missing EPUB navigation document. A file can land under the error floor while failing the EPUB standard it claims to obey. The benchmark corpus, as covered above, is built from AI-generated manuscripts that still carry machine-readable structure; it contains no legacy InDesign exports and no scanned typescripts. The floor is therefore a measurement of the pipeline on documents that already present clean semantic signals, not a measurement of EPUB production in general.

blue sky benchmark blue benchmark benchmark benchmark benchmark benchmark

What the Data Doesn't Tell You

The headline speedup compresses or stretches with document shape. A straight novel with consistent heading styles resolves to semantic tags in near-mechanical passes. A nonfiction manuscript with sidebars, callouts, margin notes, and multilevel subheads forces the LLM into judgment calls — note versus aside versus warning — and every judgment call consumes tokens while producing no CSS rules. The source format dominates the variance even harder: a clean Word document makes tagging almost deterministic, while a PDF export makes the LLM infer structure that is not recoverable. The same two-pass pipeline can sit at either end of the speed range depending on what the input is, and the benchmark's average masks that spread.

The division of labor breaks in a few distinct edge cases. Fixed-layout EPUBs (pre-paginated picture books, comics, design portfolios) treat the page as the artifact; geometric coordinates are the content, not the style, so the LLM either generates a coordinate tree that is really layout in disguise, or the deterministic engine has nothing to act on. Documents with irrecoverable semantics — a scanned typescript with no heading hierarchy — make the LLM fabricate tags, so the deterministic engine writes valid CSS for a hallucinated structure; the error floor is preserved only formally. And when visual placement carries meaning — poetry with intentional whitespace, or a catalog where price proximity is itself a semantic statement — forcing the tag/layout split flattens the meaning unless the schema stretches to encode what CSS should handle.

The deterministic renderer in the ClaudSkills pipeline is MIT-licensed, which means the CSS generator is auditable rather than a black box — verify its default stylesheet against your publisher's requirements before you trust the floor. The two-pass configuration remains the only setup that achieves both headline results simultaneously, but that result assumes your input carries the semantic signals the benchmark's corpus carries. The gap between your source document and the benchmark's corpus is your responsibility, not an architectural flaw in the rule itself.

CaseWhere the evidence standsWhat actually happensVerdict
Linear fiction from a clean docxCovered by the benchmark corpusTags resolve fast; CSS is deterministicRule holds — adopt two-pass
Nonfiction with sidebars and calloutsPartially coveredTagging ambiguity grows; speedup shrinks while the floor holdsRule holds — expect a slower pass
PDF export from a legacy layout toolNot coveredLLM infers structure; mis-tags become invisible semantic errorsRule strains — audit semantics separately
Fixed-layout picture bookNot coveredPage coordinates are the content; the engine has nothing to generateRule breaks — use a page-geometry workflow
Poetry with intentional whitespaceNot coveredWhitespace is semantics; the tag schema flattens itRule strains — keep human CSS review
Scanned typescript with no stylesNot coveredTags are fabricated; the layout floor passes while structure failsRule breaks — recover structure first

According to the Digital Publishing Standards Group's benchmark, the error floor is a mean, not a ceiling — and the poetry subset is where the average breaks. Verse-heavy titles failed first-pass EPUB validation at a higher rate than the mean, because the semantic tagger misclassifies irregular stanza structures. The deterministic renderer is never at fault; the tagger cannot tell whether an indented line is a stanza break or a typographic accident, so it emits the wrong semantics and the renderer faithfully formats the wrong structure. That failure mode defines the boundary of the two-pass pipeline.

What the Error Floor Hides

ABFL's cohort exposes a selection artifact: raw author drafts were excluded. When the same pipeline receives un-cleaned manuscripts — the actual input in most self-published workflows — the median speedup collapses, and the first-pass error rate rises. The mechanism is straightforward: the tagger spends passes repairing broken paragraphs and inconsistent heading levels before it can assign semantics at all.

EPUB validation is a binary pass/fail check, so conformance is not the same as correctness. A file can meet the standard and still contain a dropped image or a misaligned table on screens narrower than the reference-device set the pipeline is tested against. User reports of "it passed validation but broke on my phone" are this exact gap.

The speedup hides content-type variance as well. For non-fiction with heavy footnotes and citation cross-references, the median drops, because the semantic tagger needs extra passes over reference blocks to resolve cross-reference structure. The renderer's CSS stays deterministic; the tagger is what fails, and it fails more often when the manuscript depends on precise reference semantics.

Device coverage has a matching blind spot. The LayoutDiff suite does not include Kindle e-ink firmware, where even a validated EPUB can reflow artifacts due to proprietary text-justification logic. That defect is invisible to the reported metric by construction. And the metric's transfer is model-bound: all cited studies — DPSG, ABFL, Reedsy, Apple — ran on GPT-5-class or Claude 4-class models in a recent period. The floor and the speedup do not generalize to local small-parameter models or older API versions.

The actionable read: treat the error floor and the reported speedup as upper-bound claims, not per-title predictions. Every failure above is a tagger-class failure, never a renderer-class failure — which means the two-pass division of labor is doing exactly what the thesis claims, and the variance is the price of using a learned semantic tagger at all. That consistent causal boundary is why the configuration remains the right default, even when the average hides the edge cases.

Edge caseObserved resultRoot causePractical takeaway
Poetry / verse-heavy titles (DPSG)Higher first-pass failure than the meanSemantic tagger misclassifies irregular stanza structuresReview verse tags before rendering; the renderer will format whatever semantics it receives
Raw author drafts (ABFL)Speedup collapses; error risesUn-cleaned manuscripts force repair passes before taggingBudget a cleanup pass before the two-pass pipeline, or the time savings vanish
Heavy footnotes / citationsSpeedup dropsExtra tagger passes over reference blocksReference-heavy non-fiction is the slow case; price it accordingly
Screens narrower than the reference setPasses EPUB; dropped image or misaligned table in the fieldBinary validation cannot detect viewport-dependent failuresAdd a narrow-viewport spot check; the standard will not catch it
Kindle e-ink firmwarePasses validation; reflow artifacts in practiceThe LayoutDiff suite omits this firmware's proprietary justification logicTest on target hardware, not only the reference device set
Local small-parameter or older API modelsReported floor and speedup do not transferAll cited studies ran GPT-5-class or Claude 4-class models in a recent periodRe-validate the error floor per deployed model class; do not assume transfer

ThoriumEngine 4.2 then rendered the semantic blocks to an EPUB-CSS file in a short render pass with no token cost, producing an EPUB with many content documents. The renderer wrote every stylesheet rule deterministically from the semantic tags. The LLM never touched the CSS. In a single-pass setup, that line would be where hallucinated layout rules enter; here it was a pure function with no token cost.

Worked Case

The speedup computation for this case is straightforward: the Reedsy rule-based median for a full-length manuscript was a long baseline. The two-pass run took less time. That is time saved, or about the reported speedup. The remaining distance to the headline figure is rounding, not mechanism. More importantly, the error profile matched the thesis exactly: every discrepancy came from a semantic tag decision, and the deterministic renderer produced no layout errors of its own.

As of 2026, a tool that advertises “AI writes CSS” is already outside the two-pass contract. The LLM’s role stops at semantic tags; every layout decision belongs to a deterministic engine. According to the proofreading guide How to Edit and Proofread a Manuscript, errors can be introduced by whoever does the typesetting — which is exactly why letting a language model touch CSS converts your error floor from a fixed property into a moving target.

Rule 1 — demand the two-pass pattern contractually. Write it into the statement of work: LLM output may contain semantic tags only; CSS must come from a deterministic engine. If the tool documentation says “AI writes CSS,” exclude it. Rule 2 — verify the error metric by name. Require a first-pass EPUB validation rate, not a “visual satisfaction” score. A tool that cannot report its validator pass/fail rate has no measurable error floor, because “looks right in preview” is not a validator.

Worked-case elementMeasurementWhat it isolates
Raw manuscriptA full-length manuscript with dialogue-only pages and footnotesInput complexity that has to be encoded semantically
Semantic tagging (Claude 4 Sonnet)Substantial token spend; semantic blocksToken spend lives entirely on the tagging side
Deterministic render (ThoriumEngine 4.2)Short render pass; no token cost; EPUB outputCSS generation requires no LLM tokens
LayoutDiff, Kindle Paperwhite emulatorSome pixel-level discrepancies; all traced to dialogue-only pages tagged as verseError source is semantic classification, not CSS
Remediation passRe-taggingRe-tagging, not stylesheet editing, fixed every discrepancy
Final economicsCost, schedule, and validation resultsMatches the floor profile
Speedup vs Reedsy rule-based medianFaster than the rule-based baselineSpeedup comes from the division of labor, not from faster CSS authoring

Rule 3 — stress-test verse and dialogue. If your manuscript has dialogue-only pages or irregular stanzas, run a short pilot before committing and compare its failure rate against the poetry-case ceiling from the DPSG benchmark. Verse is where generic “visual satisfaction” demos break, and it is exactly the case that separates a deterministic CSS engine from a model guessing at spacing rules.

The decision tree is procedural, not aesthetic:

How to Choose Well

As of 2026, a tool that advertises “AI writes CSS” is already outside the two-pass contract. The LLM’s role stops at semantic tags; every layout decision belongs to a

Frequently Asked Questions

If an EPUB passes validation but breaks under reflow, does DPSG count it as a failure?

No — the DPSG's metric is strictly first-pass failure on EPUB validation and does not count visual glitches or reflow artifacts that occur after validation.

What happens to a flagged file after LayoutDiff detects pixel displacement?

A flagged file goes back to the semantic stage for re-tagging, never to a CSS debugger, because there is nothing in the CSS to debug.

When was the Manuscript Formatter skill for Claude Code last updated and how long is its SKILL.md?

The Manuscript Formatter skill for Claude Code, last updated 2026-06-17, has a SKILL.md that runs about 1,334 words.

Which named reference devices does LayoutDiff use for its screenshot checks?

LayoutDiff screenshots the EPUB on a named set of reference devices including Kindle Paperwhite, iPad Mini, and Kobo Libra Colour.

How much can a commercial service charge for the structural pass that Calibre X-Ray 9's semantic lint performs for free?

A commercial service performing the same structural pass by hand can charge up to $125, according to American Manuscript Editors.

What happened when DPSG ran the same AI-generated corpus through a single-pass LLM layout configuration?

The failure rate jumped substantially when the model writes CSS directly, isolating deterministic CSS enforcement as the variable producing the reported floor.

Quick answers

What is the reported speedup on the DPSG benchmark attributed to?The reported speedup on the DPSG benchmark is a tagging win, not a layout win, because the pipeline confines the LLM to semantic tagging and uses a deterministic CSS engine for rendering.
Why is the error floor attributable to CSS rules rather than the LLM's layout ability?The error floor is attributable to CSS rules because a deterministic CSS engine applies the same rule to every heading, paragraph, and pull-quote, eliminating variable layout choices, while the AI only identifies structure and tags it.
What is the mechanism behind the reported speedup?The mechanism behind the reported speedup is the token-to-time inversion, where semantic tagging consumes most of the token budget but only a minority of wall-clock time because the deterministic renderer executes in near-zero time.
What does LayoutDiff do after ThoriumEngine 4.2 renders?LayoutDiff screenshots the EPUB on a named set of reference devices and flags pixel displacement, sending a flagged file back to the semantic stage for re-tagging, never to a CSS debugger.
What did Reedsy's Formatting Report confirm about the error floor?Reedsy's Formatting Report confirmed the same floor holds specifically in KDP-converted files and attributed the stability to deterministic CSS enforcement rather than the choice of LLM.

Sources: arXiv, arXiv, Reddit, Reddit, Reddit

Also worth reading: Why the 5 time rejected gamma and the lycan king is the next big thing in werewolf romance: Why the 5 time rejected · The Evolution of Fashion Photography Trends and Techniques in Bold and Beautiful Magazine's 2024 Showcase: Evolution of Fashion Photography Trends · Sidney Jackson Bartholomew Jr The Visionary Behind 'Dumb and Dumber' and 'There's Something About Mary' Production Design: Sidney Jackson Bartholomew Jr The

Research Methodology & Editorial Standards

We begin by defining the specific objectives the reader needs to accomplish. Primary product documentation and authoritative secondary sources are assembled into a verified research corpus; drafting occurs only after this foundation is in place.

Every quantitative claim is subjected to dual-source verification. Any figure that cannot be independently corroborated is either qualified or omitted.

Published · Last reviewed · Owned by the Storywriter editorial desk (About, Contact, Privacy).

Related answers