Skip to content

v1.0.4

Latest

Choose a tag to compare

@dimitree54 dimitree54 released this 10 Mar 07:36
· 84 commits to main since this release

Bug Fix

Fix: WordExtractor prompt/schema contract inconsistency (#2)

The Dutch extraction prompt instructed the LLM to extract phraseological constructions as single units, but PartOfSpeech had no phrase value. When the LLM returned word_type="phrase", Pydantic validation failed and the entire extraction raised APIError — breaking save-to-dictionary flows in production.

Changes

  • Added PHRASE = "phrase" to PartOfSpeech enum in core.models
  • Added phrase to the allowed types list in the NL extraction prompt
  • Added a few-shot example demonstrating phraseological unit extraction
  • Regenerated nl.json prompt asset
  • Added prompt-schema consistency tests to prevent future drift