Repository navigation
Commit 0cea508
Validate Gemma4 GGUF tokenizer reconstruction (#651)
## Summary
- validate exact `gemma4` GGUF-native tokenizer reconstruction against
immutable artifact/source pins and llama.cpp
`8d9af256337d1a501250f9bbf4c0859a654bddd6`
- preserve `granite-embed-multi-311m` as deferred: its pinned
`modern-bert` artifact declares no pre and only exercises effective
fallback `gemma4`
- commit exact llama.cpp outputs plus deterministic Gemma4 qualification
inputs; network-free tests reconstruct through the current production
path and compare all 480 tokenization and detokenization outputs
- verify the pinned 6,309,288-byte archive SHA before decompression,
then strictly stream USTAR under a 48,025,600-byte ceiling with exact
regular-member names/count/sizes/hashes, duplicate rejection, zero
padding, and no PAX/GNU extensions or trailing data
- prove behavior and archive-policy drift fail through cleanup mutation
and adversarial archive regressions
- keep artifact revisions in evidence only and scope Gemma control-token
exceptions to `GEMMA4` validation
## Evidence
- Gemma4:
`unsloth/gemma-4-E2B-it-GGUF@0314792d7f1f7e229411f620751375812bb9faf2`,
`gemma-4-E2B-it-UD-IQ2_M.gguf`, 2,290,860,128 bytes, SHA-256
`3d95ada2a122c9c0b42803317239b64b262ac9226a307ff895b3d87eec0c2acd`;
480/480 native tokenize and detokenize cases match
- Granite fallback:
`SandLogicTechnologies/granite-embedding-311m-multilingual-r2-GGUF@f142535239859391fbef67aaf886d96500ad9fa8`,
240,602,528 bytes, SHA-256
`4cddb0ecb0ee45fcd1da37c007a608662568477a76ce5e12c14f7b34f002709e`;
480/480 fallback cases match without promoting the absent exact
identifier
## Validation
- full generator `--check` against pinned llama.cpp and immutable inputs
- focused tokenizer/oracle/docs/census: 124 passed
- adversarial archive coverage: compressed tamper/truncation,
extra/duplicate/missing members, oversize, bad hash, symlink, PAX
extension, decompression ceiling, and nonzero trailing data
- broad serial: 8,627 passed, 64 skipped, 12 deselected
- `lintrunner --output oneline --all-files`
- targeted mypy for all changed production/evidence/generator files
- iterative independent review; final review found no significant issues
---------
Signed-off-by: Justin Chu <[email protected]>
Co-authored-by: Copilot App <[email protected]>1 parent 20a29ed commit 0cea508
14 files changed
Lines changed: 2164 additions & 37 deletions
File tree
- docs/api
- scripts
- src/mobius/integrations/gguf
- tests
- data
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
| 2 | + | |
| 3 | + | |
Large diffs are not rendered by default.
0 commit comments