Repository navigation
tools: add Indian-script fixtures to tokenizer parity - #1988
Conversation
|
Thanks @currencycaver29. An independent review of this PR and #1989 on current main (d38bba3): The two PRs:
Applying it: both apply cleanly on main d38bba3. The author line is a real GitHub identity The expected ids come from the reference tokenizer, not our own output. The tool stores no ids. The fixture is what the body says. It holds 1,122 code points across Devanagari, Bengali, Arabic, Malayalam, Changes
Small point: the body's note about the tool stopping at the first unsupported tokenizer is a fair separate PR. Device run: none. Both runs above are CPU only. I'll close #1989 in favour of this one. |
|
Hi @currencycaver29, thanks again for the Indian-script fixtures. Two small things from our review are still open:
If it's easier, we can add the notice line when we land it. The two runs are the part we'd need from you. |
8f43d55 to
5987715
Compare
|
Thanks @currencycaver29 for the Indian-script fixtures. We've added the notice on your branch and will run the two parity checks ourselves, so nothing more is needed from you.
Before landing we'll post the pass counts of the two parity runs here: the default
|
5987715 to
9646458
Compare
|
Thanks @currencycaver29. We rebased this onto today's main, keeping your commits under your name. In Please pull before you push again (
|
|
/atc exchange 75702b255672b310039fd7e47b866c2510072dd77128ccfea5010aae304c9020 |
The parity corpus covered Indic scripts with one Devanagari phrase. Add one IN22-Gen sentence (AI4Bharat, CC BY 4.0) in all 22 scheduled Indian languages, canonical-composition exclusions in both forms (Devanagari qa, Bengali rra/yya, Gurmukhi khha, Oriya rra) and ZWJ/ZWNJ conjuncts, each as written, NFC and NFD.
The fixture's sentence is IN22-Gen's (AI4Bharat), CC BY 4.0. Co-authored-by: Divij Karanam <[email protected]>
9646458 to
5e1c650
Compare
|
Thank you @currencycaver29. This is merged into main with your commits under your own name, so you're listed as a TensorFold contributor. It ships in the next release, credited to you in the changelog and the release notes. |
|
Thanks @currencycaver29! This is in TensorFold 1.2.10, out now: https://github.com/ashhart/TensorFold/releases/tag/v1.2.10
|
What this changes
The tokenizer parity corpus covered Indic scripts with a single Devanagari phrase. This adds one IN22-Gen sentence in all 22 scheduled Indian languages, the canonical-composition exclusions in both forms (Devanagari qa, Bengali rra/yya, Gurmukhi khha, Oriya rra) and ZWJ/ZWNJ conjuncts, each as written, NFC and NFD. Test fixtures only; no engine change.
atc overlap --json: not run (ATC not installed in my environment); the diff touches onlytools/zig/tokenizer_parity.py.Checks on this head
python3 tools/zig/lean_check.py: not run.zig build-exe zig/src/core/tokenizer/check.zig -O ReleaseSafe), thenpython3 tools/zig/tokenizer_parity.py --no-synthetic --tokenizer NAME=PATHfor each tokenizer below. All pass on this head:Receipt
n/a: a fixture change to a development tool; it cannot reach inference.
tokenizers0.23.3.Notes
unicode_data.zig: all 940 pairs agree with Python's NFC, and the Indic exclusions are correctly absent.tokenizer_parity.pystops at the first tokenizer the checker does not support (for exampleUnsupportedPreTokenizerfor IndicBERT v2,UnsupportedRegexfor BLOOM,UnsupportedNormalizerfor XLM-R and mBERT) instead of reporting it and continuing. I can send that as a separate pull request if useful.Checklist