zkJSON v2 Benchmark
Spec
Generate Pattened JSON
Generate Random JSON
zkJSON
MsgPack
CBOR
BSON
JSON
Encoded Data
x Times Smaller than MsgPack
+Bytes Bigger than zkJSON
MessagePack is a self-contained JSON encoding algorithm that produces the smallest encoded data sizes today.
zkJSON beats MessagePack by far in compression rate on pattened JSON, sometimes resulting in more than 20x smaller sizes.
zkJSON beats MessagePack in 90% of cases with completely randomized JSON, and almost ties in the rest of the cases.
CBOR produces slightly bigger sizes than MessagePack, BSON produces even bigger sizes than the original JSON.