HackerPapers

arXiv:2604.03336cs.LG

NativeTernary: A Self-Delimiting Binary Encoding with Unary Run-Length Hierarchy Markers for Ternary Neural Network Weights, Structured Data, and General Computing Infrastructure

Maharshi Savdhariya

Early discovery. Linked by one identifiable commenter. This paper is outside the main ranking; a mention is not an endorsement.

Abstract

BitNet b1.58 (Ma et al., 2024) demonstrates that large language models can operate entirely on ternary weights {-1, 0, +1}, yet no native binary wire format exists for such models. NativeTernary closes this gap. Benchmarked against GGUF on the real BitNet b1.58 2B4T architecture (24 layers, ~170 tensors, 2B parameters): NativeTernary encodes ternary weights at exactly 2.000 bits per weight -- 1.31x smaller than GGUF Q2_K and 4.0x smaller than GGUF int8 -- while reducing boundary and framing overhead by 460x (91 bytes vs ~42KB of GGUF tensor headers). Encode throughput: 47--69 MB/s. Decode throughput: 35--45 MB/s on commodity hardware. The decoder is a 10-line stateless state machine resilient to bitstream corruption.

arXiv comments
v2: benchmark results added. Real BitNet b1.58 2B4T architecture analysis: NativeTernary framing overhead 460x smaller than GGUF tensor headers (91 bytes vs 42KB). 1.31x smaller than GGUF Q2_K. C implementation: https://github.com/sm45118/nativeternary
Journal reference
DOI
Subjects
cs.LGMachine Learning eess.SPSignal Processing

On Hacker News

Linked by 1 identifiable commenter in 1 comment across 1 thread, from Aug 2026 to Aug 2026.

Comments linking this paper, per year.

Discussed in comments1 thread

    • This article (comparing the x86 AVX-512F instruction VPTERNLOGD to Amiga's Blitter) is not the end of the discussion for this instruction, it's actually the beginning... See, VPTERNLOGD is a ternary bitwise instruction. In theory, that means that it could (in theory, temporarily…

      peter_d_shermanView on HNParent context

Submitted to Hacker News

Connected through shared HN threads, not inferred similarity or a recommendation.