use case · basics · byte-level byT5 · WASM fp32 · ~84 MB

Byte-Level byT5 & IPA Articulatory Explorer

Unlike BPE or SentencePiece models, CharsiuG2P ships no vocabulary file at all. Every prompt <lang>: word is encoded straight from raw UTF-8 bytes (token_id = byte + 3, with add_special_tokens=False per upstream CharsiuG2P). Inspect the exact byte IDs entering the encoder across Latin, Greek, Cyrillic, Arabic, Devanagari, and Japanese Kana, dissect the predicted IPA into articulatory categories, and see how flipping only the <lang>: prefix shifts pronunciation across accents.

1 · Model status & cross-script inspector

Prepare CharsiuG2P above (or type below to inspect UTF-8 byte encoding immediately).

Query: <eng-us>: colonel

Waiting for CharsiuG2P inference…

Run the model above to see real IPA phonemes and decoder byte IDs.

ScriptLatin
UTF-8 bytes–
Phonemes–
Vowels / Cons.–
Syllables (est.)–
Latency–

2 · Raw UTF-8 bytes → byT5 token IDs (byte + 3)

Dashed tiles are the <lang>: prefix bytes; highlighted tiles are multi-byte UTF-8 characters (2 bytes for German ß, Cyrillic, Greek, Arabic; 3 bytes for Japanese Kana, Devanagari, Hangul, and Han). Per upstream CharsiuG2P, encoder inputs omit a trailing EOS (add_special_tokens=False), while the decoder emits EOS = 1 to stop.

3 · IPA articulatory breakdown

# IPA segment Category Phonetic features & notes
Run inference above to inspect every predicted IPA segment.

4 · Cross-accent & cross-language prefix lab

Keep the word bytes identical and swap ONLY the <lang>: prefix across eng-us, eng-uk, fra, and ger in four real ONNX forward passes.

5 · Show the real code

Lazy-hydrated directly from this route's live ES modules via lib/show-code.js.

Show the code: byT5 int64 tensor construction & model.generate()
Show the code: UTF-8 byte-to-token inspection (id = byte + 3)
Show the code: IPA affricate, diacritic & articulatory segmenter