Skip to content

[LLM] Implement Pipeline 2 on-device text enrichment engine - #9

Merged
menny merged 1 commit into
pipeline-1-preprocessorfrom
pipeline-2-enricher
Oct 16, 2026
Merged

menny merged 1 commit into
pipeline-1-preprocessorfrom
pipeline-2-enricher

Conversation

@menny

@menny menny commented Oct 16, 2026

Copy link
Copy Markdown
Member

Summary

Implements Pipeline 2 (On-Device Runtime Text Ingestion) and associated linguistic algorithms as specified in docs/INGESTION.md and docs/DATA.md:

  • ReaderEnricher: Fast, single-pass on-device text enrichment engine using BreakIterator word segmentation. Produces interactive TokenSpan objects while preserving exact string offsets.
  • CliticDeconstructor: Pronoun surgery deconstructing verbs with attached enclitic object pronouns (single and compound like diciéndomelo -> diciendo + me + lo), restoring stress accents (á, é, í, ó, ú).
  • NumberConverter: Deterministic Spanish number to words converter for integers 0..999,999 with gender agreement and apocope (un, veintiún).
  • Enrichment Models & Provider: Data models for TokenSpan, CliticBreakdown, DictionaryEntry, FalseCognateEntry, and the WordLookupProvider interface.
  • Pure-JVM Unit Tests: Comprehensive test suites for all components (CliticDeconstructorTest, NumberConverterTest, ReaderEnricherTest).

Stacked on top of #7 (pipeline-1-preprocessor).

- Add ReaderEnricher for single-pass Unicode-aware token segmentation and interactive TokenSpan enrichment.
- Add CliticDeconstructor implementing clitic pronoun surgery (accent restoration and compound pronoun breakdown).
- Add NumberConverter for deterministic Spanish number conversion (0..999,999) with gender agreement and apocope.
- Add EnrichmentModels defining TokenSpan, CliticBreakdown, DictionaryEntry, FalseCognateEntry, and WordLookupProvider.
- Add comprehensive test suites for CliticDeconstructor, NumberConverter, and ReaderEnricher.
@menny
menny added this pull request to stack #8 October 16, 2026 02:06
@menny
menny merged commit abb6a51 into main Oct 16, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant