Verace Bytewise
A vocabulary-free byte encoder and decoder that maps text, code, audio and images to one continuous vector per input, stored as a .sheaf file.
- Raw input bytes: Text, code, audio or images, with no vocabulary
- Pooled vector: One vector per input, stored in a .sheaf file
- Mean pooling to one vector: Averages the concept solitons into one vector
Overview
Verace Bytewise is the lab's byte-level alternative to subword tokenizers such as Tiktoken, OpenAI's tokenizer, and the BPE and SentencePiece methods developed by other parties; the lab's papers and code call this work UATS. It addresses one question: can raw bytes of text, source code, audio or images be turned into continuous vectors without any vocabulary table, compressed to a single vector per input, and decoded back to the exact original bytes? The design specification describes this single vector in category-theoretic language as a global sheaf section . In the code it is a mean-pooled feature vector.
The design specification, Sheaf Byte Protocol SBP v1.0, defines three tiers. A convolutional encoder compresses the byte stream into a shorter sequence of concept vectors, called concept solitons, at a default compression ratio of 8. A pooling step, sheafize, reduces that sequence to one vector of width . A transposed convolutional decoder expands a vector back into 256-way byte logits. A second decoder, the Desheafizer, adds a harmonic expansion stage and a UTF-8 projection. Adapters feed images, audio and legacy token IDs into the same pooling step, and a binary .sheaf format stores the result.
The research implementation comprises the core translator, the separate decoder, the multimodal adapters, a token-ID bridge, a command-line tool, a benchmark script and two unit test suites. The test suite checks output shapes for every modality, the .sheaf save and load cycle, and that the decoded text has the same byte length as the input. It does not check that the decoded content matches the input. The system's overview document claims 32x to 1024x compression and 8.7x faster translation than Tiktoken, at over 10.5 MB/s against 1.2 MB/s. No recorded run supports these figures, and the benchmark script estimates BPE token counts from word counts instead of running a tokenizer.
Verace Bytewise is an implemented, unit-tested prototype with untrained weights. No training run and no measured reconstruction accuracy are recorded. Exact byte reconstruction, which both the design specification and the overview document claim, is not demonstrated. A .sheaf file stores only the pooled vector, the byte length, the concept length and , so the claimed bijection between bytes and sections is a design claim. The design names a deterministic finite automaton for UTF-8 validity, but the code implements none. The reported cocycle defect involves no gluing computation. Speed and compression figures remain unmeasured claims.
Status
Prototype. The encoder, decoders, adapters, file format and command-line tool are implemented with shape-level unit tests, but no training run, no reconstruction measurement and no recorded benchmark result exist.
Simulator
A row of tokens is read two ways at once: the newest token looks back at every earlier one, and every token is also written into one memory of fixed size that fades.
- looking back: one arc for every earlier token
- fixed memory: how much of each token it still holds
- newest token at the right
- Looking back, this token
- 23 comparisons
- Looking back, whole sequence
- 276 comparisons
- State kept: looking back / fixed
- 24 tokens / 1 state
- Fixed memory: a token is half faded after
- 4.3 tokens
Lengthen the sequence: the arcs multiply, the fixed memory stays one state. Lower the decay and it forgets sooner.
This simulator is an illustration of the principle, with made-up numbers. It does not run the lab's code or show the lab's data, and nothing in it is a measurement.
Architecture
Wavelet byte encoder
A convolutional network,
WaveletEncoder, that embeds each byte and downsamples the byte sequence into a shorter sequence of concept vectors. The code calls its output concept solitons.Sheafization pooling step
The
sheafizemethod ofToposTranslatormean-pools the concept sequence into one vector of shape (1, 1, ). The design specification calls this vector the global sheaf section.Deconvolution byte decoder
DeconvDecoderupsamples a sequence of vectors with transposed convolutions and maps each position to logits over the 256 byte values.Universal Topos Sheaf Decoder
A separate three-stage decoder,
UniversalToposDecoder, also called the Desheafizer. It expands one vector into a sequence, deconvolves it into byte logits and projects the result to valid UTF-8.Multimodal adapters
MultiModalSheafTranslatorprojects image patches and audio frames into the encoder's feature width so that the same pooling step produces one vector for every modality.Legacy tokenizer bridge
LegacyTokenizerBridgeembeds integer token IDs from an existing tokenizer and pools them into one vector, for comparison and interoperability.Sheaf file format and CLI
A binary .sheaf format with the magic header SHF1, written and read by
save_sheafandload_sheaf. A command-line tool,cli.py, has encode, decode and info subcommands.
Implementation
Mechanisms as they are implemented in the source code, with the constants the code uses.
- Padded convolutional byte encoding
- Input bytes are zero-padded to a multiple of
compression_ratio(default 8). An empty input returnstorch.zeros((1, 1, d_model)). The encoder appliesnn.Embedding(256, d_model // 4), then a Conv1d with kernel_size=3, stride=2, padding=1 to channels with SiLU, then a Conv1d with kernel size and stridecompression_ratio // 2to channels. - Mean pooling to one vector
- The concept sequence is reduced to a single vector . Every modality, including token IDs from the legacy bridge, passes through this same averaging step.
- Transposed convolution decoder with argmax
DeconvDecoderapplies ConvTranspose1d(, ) with kernel size and stridecompression_ratio // 2and SiLU, then ConvTranspose1d(, ) with kernel_size=3, stride=2, padding=1, output_padding=1 and SiLU, thenLinear(d_model // 4, 256, bias=False). Each output byte is the argmax over the 256 logits, anddecode_from_solitonstruncates the result to the original length.- Cocycle defect as a shift norm
- The reported
cech_cocycle_defectis , the L2 norm of the pooled vector minus a copy of itself shifted cyclically by one feature position. It compares no overlapping parts of the input and performs no gluing. - Harmonic stalk expansion
StalkLocalizationFunctorrepeats the input vectortarget_concept_lengthtimes and samples evenly on . For tomax_harmonics(default 8) it adds , where the weights are random parameters scaled by . LayerNorm follows.- UTF-8 projection by discarding
project_valid_utf8takes the argmax over 256 byte logits, skips byte value 0, decodes the bytes with errors='ignore' and re-encodes them as UTF-8. Validity comes from dropping invalid sequences. The class nameUTF8TopologicalAutomatonsuggests a state machine, but none is implemented.UniversalToposDecoderdefaults to .- Sheaf binary layout
save_sheafpacks a 16-byte header with struct format "4sIII": magic b"SHF1", original byte length, concept length andd_model. The pooled vector follows as raw float32 bytes.load_sheafasserts the magic and reshapes the payload to (1, 1, ). Nothing else about the input is stored.- Image and audio patch projection
- Images of shape [1, 3, H, W] pass through
nn.Conv2d(3, d_model, kernel_size=16, stride=16)and are flattened to patches. Audio of shape [1, 1, T] passes throughnn.Conv1d(1, d_model, kernel_size=160, stride=160). Both share a LayerNorm and are then mean-pooled bysheafize. - Heuristic benchmark counts
benchmark_translator.pyestimates BPE token counts as twice the whitespace word count for Hindi, Arabic and Chinese, and as the word count otherwise. Latency is averaged over 100 calls oftranslate_to_sheafon a sentence repeated 50 times. Throughput is characters divided by average time, divided by .
Results
From the lab's own experiments and records. They have not been independently replicated.
Performance claims are not backed by recorded runs
The system's overview document states zero vocabulary, compression of 32x to 1024x and 8.7x faster translation, at over 10.5 MB/s against 1.2 MB/s for Tiktoken. No recorded run supports these figures, and the benchmark script estimates BPE counts from word counts instead of running a tokenizer.
Exact reconstruction is not tested
The text roundtrip test in the test suite asserts only that the decoded byte length equals the input byte length. It does not compare decoded content with the input, and the decoder weights are untrained.
The file format stores only one pooled vector
The lab's reading of the code shows that a .sheaf file holds a 16-byte header and one float32 vector of width . The bijection between byte streams and sections that the design specification claims is therefore not realised.
UTF-8 automaton exists only in the design
The design specification describes a deterministic finite automaton that guarantees valid UTF-8 output. The code instead decodes with errors ignored and drops invalid bytes and zero bytes.
Tests check shapes and serialisation only
The test suites check output shapes for text, image, audio and token-ID inputs, the .sheaf save and load cycle, and a deconvolver output of shape (1, 128, 256) for 16 input vectors. No test run is recorded.
Concepts
- Subword tokenization
- Methods such as BPE, SentencePiece and Tiktoken split text into units drawn from a fixed vocabulary of IDs. The design specification argues that this causes spelling blindness, fragmented numbers and unequal token costs across languages.
- Vocabulary-free byte modelling
- Operating directly on the 256 possible byte values, so that no out-of-vocabulary input can occur and no lookup table is needed. Verace Bytewise embeds bytes with a 256-row embedding.
- Concept solitons
- The system's name for the downsampled sequence of continuous vectors produced by the byte encoder. Each vector covers a fixed number of input bytes set by the compression ratio.
- Global sheaf section
- In sheaf theory, a global section is a consistent assignment glued together from local data. The design specification uses the term for the single vector that represents a whole input. In the code this vector is a mean of the concept vectors.
- Cech cocycle defect
- In the design, a measure of how badly local pieces fail to agree when glued. The code reports a different quantity: the norm of the pooled vector minus its own one-position cyclic shift.
- Stalk localization
- The first stage of the Desheafizer. It turns one vector back into a sequence by repetition plus small sinusoidal offsets, as an inverse of pooling.
- UTF-8 byte closure
- The requirement that decoded output is a valid UTF-8 byte sequence. The design specification assigns this to a deterministic finite automaton. The code achieves it by discarding invalid bytes.
- One vector per task
- The design target that any input, of any length or modality, is represented by a sequence of length 1. On this basis the system's overview document claims compression of 32x to 1024x.
- Claimed comparison with Tiktoken
- The system's overview document claims zero vocabulary against 100,277 IDs, exact spelling and arithmetic, and 8.7x faster translation than Tiktoken. These are the lab's stated claims, not recorded measurements.
About this page
Written from the lab's own documents and source code. Figures and results are the lab's measurements as it recorded them at the time, and have not been independently replicated.
Published under the PolyForm Noncommercial License 1.0.0: free for noncommercial use.