Repository navigation
Preserve embedded NULs in native tokenizer input - #6157
Merged
Merged
Conversation
joelteply
force-pushed
the
codex/bigmama-tokenizer-bytes
branch
from
November 19, 2026 06:03
b99fba2 to
a659530
Compare
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.
BigMama recorded six failed embeddings in each of two 15-minute windows. Rust rejected an interior NUL at byte 7,135 while preparing a CString. llama_tokenize accepts a pointer and an explicit byte length. Pass the borrowed UTF-8 slice, check input and output bounds, and preserve the suffix.
The real Qwen embedding GGUF reproduced the offset, round-tripped all 7,152 bytes through 896 tokens, and produced a finite pooled embedding. The normal-vs-pooled vector comparison also passed. This change was deployed on BigMama before check-in. The 15-minute resident comparison ends at 05:49:11 UTC.
Stacked on #6156 for its feature-gated real-model test and pooled constructor. Retarget to canary after #6156 merges.