[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"detail-sidebar-cat-1-en-105":3,"doc-detail-572585-en":53,"doc-seo-572585-105":75},{"code":4,"msg":5,"data":6},0,"success",[7,14,19,24,29,34,39,44,49],{"id":8,"doc_module":9,"doc_module_name":10,"category_name":11,"show_sort_weight":12,"slug":13},11,1,"Template","Presentations",90,"presentations",{"id":15,"doc_module":9,"doc_module_name":10,"category_name":16,"show_sort_weight":17,"slug":18},12,"Resumes",80,"resumes",{"id":20,"doc_module":9,"doc_module_name":10,"category_name":21,"show_sort_weight":22,"slug":23},14,"Invoices",70,"invoices",{"id":25,"doc_module":9,"doc_module_name":10,"category_name":26,"show_sort_weight":27,"slug":28},15,"Posters",60,"posters",{"id":30,"doc_module":9,"doc_module_name":10,"category_name":31,"show_sort_weight":32,"slug":33},16,"Social Media",50,"social-media",{"id":35,"doc_module":9,"doc_module_name":10,"category_name":36,"show_sort_weight":37,"slug":38},17,"Forms",40,"forms",{"id":40,"doc_module":9,"doc_module_name":10,"category_name":41,"show_sort_weight":42,"slug":43},18,"Letters",30,"letters",{"id":45,"doc_module":9,"doc_module_name":10,"category_name":46,"show_sort_weight":47,"slug":48},21,"Paper Templates",5,"papers-templates",{"id":50,"doc_module":9,"doc_module_name":10,"category_name":51,"show_sort_weight":4,"slug":52},158,"General","general-158",{"code":4,"msg":5,"data":54},{"doc_id":55,"user_id":56,"nickname":57,"user_avatar":58,"doc_module":9,"category_id":8,"category_name":11,"doc_title":59,"doc_description":60,"doc_content":61,"file_id":62,"file_url":63,"file_type":64,"file_size":65,"view_count":66,"is_deleted":4,"is_public":9,"is_downloadable":9,"audit_status":9,"page_count":67,"language":68,"language_code":69,"site_id":70,"html_lang":69,"table_of_contents":71,"faqs":72,"seo_title":73,"seo_description":60,"update_tm":74,"read_time":20},572585,962090893057,"PakDamar76","https://ap-avatar.wpscdn.com/davatar_155a257f0dc6eb9ab79c44ca47cae57d","LatentMD - Benchmarking Markdown Boundary Failures in LLM-Generated Text","Large language models increasingly generate Markdown consumed by renderers, agents, code extractors, and downstream pipelines. Existing evaluations often mix content quality with format adherence, leaving Markdown fence-boundary failures insufficiently measured. LatentMD introduces a benchmark and evaluation protocol to diagnose CommonMark-level fence-boundary failures, separating content correctness from boundary correctness. It contains 4,179 prompts and a CLI scoring tool. Across 9 LLMs and about 37,600 generations, boundary failures are widespread, with notable content-correct but boundary-broken outputs and delimiter-collision-driven causes.","LatentMD: Benchmarking Markdown Boundary  \nFailures in LLM-Generated Text ∗  \nSungjune Lee  \nSeoul National University [casthood@snu.ac.kr](casthood@snu.ac.kr)  \nMyungjoo Kang†  \nSeoul National University [mkang@snu.ac.kr](mkang@snu.ac.kr)  \narXiv : 2609 .06993v2 [cs .SE] 1 1 Sep 2026  \nAbstract  \nLarge language models (LLMs) increasingly generate Markdown that is consumed by renderers, agents, code extractors, and structured downstream pipelines. Yet existing evaluations often conflate content quality with format adherence, leaving Markdown boundary failures under-measured. We introduce LatentMD, a benchmark and evaluation protocol for diagnosing CommonMark-level fence-boundary failures in LLM-generated Markdown. LatentMD separates content correctness from boundary correctness, enabling detection of outputs that are content-correct but boundary-broken. The benchmark contains 4 , 179 prompts and a CLI for scoring arbitrary model outputs. Across 9 LLMs and roughly 37 ,600 generations, we find that Markdown boundary failures are widespread: 38.0% of valid maingrid outputs are content-correct but boundary-broken, with substantial boundary breakage under unspecified prompts and in a small human-authored validation set. Ablations show that failures are driven primarily by same-family symmetricdelimiter collisions rather than nesting alone, are only partially mitigated by prompt hints, and generalize to Python triple-quote docstrings while JSON remains robust as an asymmetric-delimiter control. LatentMD provides a reproducible diagnostic target for parser-sensitive LLM evaluation.  \n1 Introduction  \nLLM Markdown output is increasingly read by automated tools, not just human eyes—chat UIs render it on screen, agentic systems parse it to decide actions, and search-and-extraction systems pull code blocks out of it for reuse [20] . These tools rely on the implicit assumption that the output’s structure is correct; when the structure breaks, the tools break with it.  \nThis breaks regularly in the wild. A user asks a chat model to write a Markdown tutorial about Python generators with two code examples; the model wraps its reply in a fenced block tagged markdown and embeds the two Python examples as inner fenced blocks. In many chat UIs and developer tools, this output visibly breaks: the inner fences close the outer wrapper at the first length match, and the trailing content leaks outside the intended block as raw text or stripped fence characters. In other cases the breakage is invisible at render time but still corrupts any tool that reads the document’s spec-level structure.  \nThis is not a contrived test case: the same fence-boundary failure has been filed across major LLMand developer tools, including OpenAI ChatKit, Google Gemini CLI, Microsoft VS Code, and open-source agentic projects [19, 11, 16, 2, 6, 17] . These incidents show that nested-fence breakage is a recurring deployment failure rather than a benchmark artefact.  \n∗ Code and scoring tool: [https://anonymous.4open.science/r/LatentMD-code-B51D](https://anonymous.4open.science/r/LatentMD-code-B51D).†  \nCorresponding author.  \nPreprint.  \nYet existing LLM-output benchmarks do not measure this failure. They score content correctness and surface format adherence [24, 5, 8, 27, 14], but none isolate whether the model can correctly track nested fence boundaries. A generation that is content-correct but boundary-broken would therefore be scored as passing by these benchmarks. The same output would still corrupt any specstrict downstream parser or renderer. We close this gap with LatentMD, a 4, 179-prompt rule-based benchmark that adds an explicit Boundary axis orthogonal to Content. This isolates a content-correct but boundary-broken failure mode, the latent failure. It supports paired causal and trend claims that aggregate-only benchmarks cannot.  \nContributions. We make the following contributions. (a) Benchmark. We introduce LatentMD, the first systematic benchmark of LLM Mar","cbCaisx4pSlYY7ei","https://ap.wps.com/l/cbCaisx4pSlYY7ei","pdf",655857,3,41,"English","en",105,"# Introduction\n# Background & Related Work","[{\"question\":\"What problem does LatentMD target in LLM-generated Markdown?\",\"answer\":\"LatentMD targets CommonMark-level fence-boundary failures in LLM-generated Markdown, especially cases where nested fences break tool- and parser-sensitive structure.\"},{\"question\":\"How does LatentMD separate content correctness from boundary correctness?\",\"answer\":\"LatentMD uses a benchmark framework that adds a Boundary axis orthogonal to Content, allowing detection of outputs that are content-correct but boundary-broken.\"},{\"question\":\"What causes do the authors find for Markdown boundary failures?\",\"answer\":\"Ablations indicate failures are driven mainly by same-family symmetric-delimiter collisions rather than nesting alone, only partially mitigated by prompt hints, and reflected in Python while JSON is more robust.\"}]","LatentMD - Benchmarking Markdown Boundary Failures in LLM-Generated Text | PDF",1791928244,{"code":4,"msg":76,"data":77},"ok",{"site_id":70,"language":69,"slug":78,"title":59,"keywords":79,"description":60,"schema_data":80,"social_meta":135,"head_meta":137,"extra_data":139,"updated_unix":140},"latentmd-benchmarking-markdown-boundary-failures-in-llm-generated-text","",{"@graph":81,"@context":134},[82,97,117],{"@type":83,"itemListElement":84},"BreadcrumbList",[85,89,92,94],{"item":86,"name":87,"@type":88,"position":9},"https://docshare.wps.com","Home","ListItem",{"item":90,"name":10,"@type":88,"position":91},"https://docshare.wps.com/template/",2,{"item":93,"name":11,"@type":88,"position":66},"https://docshare.wps.com/template/presentations/",{"item":95,"name":59,"@type":88,"position":96},"https://docshare.wps.com/template/latentmd-benchmarking-markdown-boundary-failures-in-llm-generated-text/572585/",4,{"url":95,"name":59,"@type":98,"image":99,"author":104,"headline":59,"publisher":106,"fileFormat":109,"inLanguage":69,"description":60,"dateModified":110,"datePublished":111,"encodingFormat":109,"isAccessibleForFree":112,"interactionStatistic":113},"DigitalDocument",{"url":100,"@type":101,"width":102,"height":103},"https://docshare.wps.com/thumbnails/latentmd-benchmarking-markdown-boundary-failures-in-llm-generated-text/572585.png","ImageObject",442,249,{"name":57,"@type":105},"Person",{"url":86,"name":107,"@type":108},"DocShare","Organization","application/pdf","2026-10-19","2026-10-13",true,{"@type":114,"interactionType":115,"userInteractionCount":66},"InteractionCounter",{"@type":116},"ViewAction",{"@type":118,"mainEntity":119},"FAQPage",[120,126,130],{"name":121,"@type":122,"acceptedAnswer":123},"What problem does LatentMD target in LLM-generated Markdown?","Question",{"text":124,"@type":125},"LatentMD targets CommonMark-level fence-boundary failures in LLM-generated Markdown, especially cases where nested fences break tool- and parser-sensitive structure.","Answer",{"name":127,"@type":122,"acceptedAnswer":128},"How does LatentMD separate content correctness from boundary correctness?",{"text":129,"@type":125},"LatentMD uses a benchmark framework that adds a Boundary axis orthogonal to Content, allowing detection of outputs that are content-correct but boundary-broken.",{"name":131,"@type":122,"acceptedAnswer":132},"What causes do the authors find for Markdown boundary failures?",{"text":133,"@type":125},"Ablations indicate failures are driven mainly by same-family symmetric-delimiter collisions rather than nesting alone, only partially mitigated by prompt hints, and reflected in Python while JSON is more robust.","https://schema.org",{"og:url":95,"og:type":136,"og:title":59,"og:site_name":107,"og:description":60},"article",{"robots":138,"canonical":95},"index,follow",{"doc_id":55,"site_id":70},1792438355]