Skip to content

v0.4.0

Compare
Choose a tag to compare
@Dan-wanna-M Dan-wanna-M released this 10 Sep 04:28
· 57 commits to master since this release

Summary

  • faster Formatter compilation
  • Refactors to make internal implementation and public API cleaner
  • Native support for basic json schema(all type keyword constraints and recursion)
  • Basic support for substring extraction

What's changed

  • Removed grammar_generators package completely.
    • JsonExtractor class is moved to formats.json package.
  • FormatterBuilder.schema() is removed.
  • Added FormatterBuilder.json() which is simpler to use than FormatterBuilder.schema().
  • RegexExtractor is moved from extractor to formats.regex
  • kbnf_representation is renamed to kbnf_reference and nonterminal is renamed to kbnf_definition for clarity in Extractor.
  • NonterminalExtractor is added to better illustrate the differences in interfaces&implementation between LiteralExtractor and other extractors.
  • LiteralExtractor is private now,
  • Bug fix: JsonExtractor will no longer produce None when parsing json where some keys/values contain { or }.
  • Make Formatron compatible with the newest vllm==0.6.0 and exllamav2==0.2.1.
  • Faster constrained decoding with exllamav2 integration thanks to @turboderp 's optimizations in his exllamav2 library.
  • Faster kbnf.Vocabulary creation by @turboderp in #10
  • Update docs, benchmarks and comments accordingly.

Full Changelog: v0.3.4...v0.4.0