Repository navigation
core: expose exact token-local tokenizer bytes - #532
Merged
Merged
Conversation
Owner
Closed
BlivionIaG
pushed a commit
to BlivionIaG/TensorFold
that referenced
this pull request
Oct 20, 2026
Thanks @akol1. # Conflicts: # CHANGELOG.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What this changes
Adds allocator-owned exact bytes for token-local Hugging Face decoder chains. ByteLevel and ByteFallback preserve incomplete UTF-8; context-sensitive chains return null. Ordinary text decoding is unchanged. Public ownership/limitations and the changelog are documented.
Receipt
Base:
zig-flashnextatf8fe17d(1.0.2). Zig 0.17.0, Linux x86_64, CPU-only; no checkpoint or GPU used.zig test zig/src/core/tokenizer/tokenizer.zig -lc: 13 passed, 0 failed.zig test zig/src/core/tokenizer/steps.zig -lc: 7 passed, 0 failed.zig build test native -Dversion=1.0.2 -j2: completed successfully, without nvcc or kernel assets.loadTokenizer:tokenBytesretainedC3/A9, and their concatenation equaled full UTF-8 decoding.--versionreported1.0.2.python3 tools/zig/lean_check.py: base and candidate each report 782 files, 512 inherited findings, exit 1. Normalized finding identities/multiplicities are identical: zero added findings.Initial compiler attempts exhausted temporary-filesystem quota; redirected temporary/cache/output storage resolved that environmental failure. Machine-local paths are omitted.
Not run: Metal, GPU/model serving, draft/plain, cache-resume, concurrent-stream equality or performance measurements. This API-only change does not enable forced-tool serving or claim backend support, model qualification or speed.
Checklist