You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
vlm: don't fail the whole page on malformed DocLang from the model (#153)
The VLM pipeline routes non-DocTags model output through the DocLang XML
reader, which is a strict parser: a model that leaves a <heading>/<text>
unclosed produces markup it rejects with `expected 'heading' tag, not
'doclang'`, and that error propagated all the way out — dropping the entire
normal_4pages fixture from the #153 corpus run ("rust side failed").
The DocTags path never hard-fails on hostile model output (#152: best-effort
document out); the DocLang fallback now matches it. parse_doclang_fragments
tries the strict reader first (well-formed DocLang keeps its heading levels
and table structure) and, on a parse error, salvages the fragments through
the tolerant DocTags parser, which degrades broken/unknown tags to text and
never errors. Two regression tests cover both branches.
Refs #153
Signed-off-by: artiz <artem.kustikov@gmail.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01EY5KAiquN4YpVf2PXEQkVT
0 commit comments