r/programminghorror • u/an-otiose-life • Dec 12 '25
Javascript towards-semantic-compression in an metaprogramatic mode, proxies-featured
215
Upvotes
r/programminghorror • u/an-otiose-life • Dec 12 '25
View all comments
Show parent comment
0
u/Ok-Kaleidoscope5627 Dec 17 '25
That is just fixed length encoding with a dictionary based compression. Modern compression algorithms use variable length encoding with dictionaries optimized for the data plus they'll use other much more clever techniques as well.
Or in other words - just stick to zstd or some other modern compression. The only way your approach wins is if you can have a preshared static dictionary with some extremely domain specific patterns. But that wouldn't be general compression for arbitrary data. It'll only handle your very specific data.
I'd love to be proven wrong though...