betto_lexical
Lexical text utilities (tokenizer, stemmer, stopwords) for Dart and Flutter.
0.1.0-dev.2
bettongia/lexical
What this package is like to depend on
Last release 1 months ago
06 Jul 2026
Too new to tell
only 2 dated releases
Unknown
no stable releases
Nothing withdrawn
no release was ever pulled
2 months old
2 releases · first in 2026
2 releases in the last 12 months
see the full history below
Release timeline
2 releases · Jun 2026 to Jul 2026Releases
latest 2-
0.1.0-dev.206 Jul 2026 pre-releaseRelease notes
Open source →Stemmer previously wired up only English, throwing ArgumentError for
every other locale, even though the underlying snowball_stemmer
dependency already implements 28 languages. Extend the factory to map
all of them (excluding the genericportervariant, not a distinct
language). Each new mapping was verified against the actual stemmer
output for a representative inflected word per language, not just
type-checked.Also bump the betto_icu dependency to 0.1.0-dev.2 and re-export its
new OffsetTokenizer/TokenSpan types, needed by kmdb's vault chunker
for position-aware tokenisation.Co-Authored-By: Claude Sonnet 5 [email protected]
Release notes
Open source →Stemming
Stemmernow supports 28 languages, up from just English: Arabic, Armenian, Basque, Catalan, Danish, Dutch, English, Finnish, French, German, Greek, Hindi, Hungarian, Indonesian, Irish, Italian, Lithuanian, Nepali, Norwegian, Portuguese, Romanian, Russian, Serbian, Spanish, Swedish, Tamil, Turkish, and Yiddish — every languagepackage:snowball_stemmerimplements (excluding its genericportervariant, an alternate English algorithm rather than a distinct language). Unsupported language codes still throwArgumentError, as before.
Tokenization
- Re-exports
OffsetTokenizerandTokenSpanfrombetto_icu(now pinned to^0.1.0-dev.2) — aTokenizerthat also reports each token's character offsets in the source text. Implemented byIcuTokenizerandRegExpTokenizer.
-
0.1.0-dev.117 Jun 2026 pre-releaseRelease notes
Open source →Initial development release.
Tokenization
createDefaultTokenizer()returns the best tokenizer for the current platform at compile time — no runtimePlatformchecks.IcuTokenizer— UAX #29 word segmentation via the system ICU library (native: macOS, Linux, Windows, Android, iOS).BrowserTokenizer— word segmentation viaIntl.Segmenter(web).RegExpTokenizer— lightweight Latin-script tokenizer in pure Dart, available on all platforms.
Stemming
Stemmer— Snowball-based stemmer. Construct with aLocaleand callstem(word)to reduce tokens to their base form. English (en) supported.
Stop words
getStopWords(Locale)— returns aStopwordsenum value containing the stop-word set for the given locale. ThrowsArgumentErrorfor unsupported language codes.- 58 languages sourced from stopwords-iso.