html-entity-fix 0.1.0

Decode HTML entities (& < > " ' numeric refs) that LLMs sometimes emit in plain-text output. Zero deps.
Documentation
  • Coverage
  • 100%
    2 out of 2 items documented1 out of 2 items with examples
  • Size
  • Source code size: 18.98 kB This is the summed size of all the files inside the crates.io package for this release.
  • Documentation size: 245.22 kB This is the summed size of all files generated by rustdoc for all configured targets
  • Ø build duration
  • this release: 1m Average build duration of successful builds.
  • all releases: 1m Average build duration of successful builds in releases after 2024-10-23.
  • Links
  • Homepage
  • MukundaKatta/html-entity-fix
    0 0 0
  • crates.io
  • Dependencies
  • Versions
  • Owners
  • MukundaKatta

html-entity-fix

crates.io

Decode HTML entities (&, <, >, ", ', ', common typography) inside text that was supposed to be plain. Catches LLMs that over-correct out of an HTML context.

use html_entity_fix::fix;
assert_eq!(fix("AT&T"), "AT&T");
assert_eq!(fix("&lt;tag&gt;"), "<tag>");

Zero deps. MIT or Apache-2.0.