New npm package for automatic recovery of broken streaming markdown
Remend launches as a standalone npm library that automatically detects and completes unterminated Markdown syntax during AI token streaming, preventing broken rendering in any application.
is a new standalone package that brings intelligent incomplete Markdown handling to any application.Remend Previously part of 's Markdown termination logic, Remend is now a standalone library () you can use in any application.Streamdownnpm i remend AI models stream Markdown token-by-token, which often produces incomplete syntax that breaks rendering. For example: Without correction, these patterns fail to render, leak raw Markdown, or disrupt layout: Remend automatically detects and completes unterminated Markdown blocks, ensuring clean, stable output during streaming. As the stream continues and the actual closing markers arrive, the content seamlessly updates, giving users a polished experience even mid-stream.
It works with any Markdown renderer as a pre-processor. For example: Remend powers the markdown rendering in Streamdown and has been battle-tested in production AI applications. It includes intelligent rules to avoid false positives and handles complex edge cases like: To get started, either use it through or install it standalone with:Streamdown Read more Why it matters Unclosed fences Half-finished bold/italic markers Unterminated links or lists Mathematical…