As you know, Zcash memos are capped at 512 bytes. This limit makes it hard to fit longer messages or structured data. I’ve been working on a small project called BPEzip, and I think it could be useful for people who need to send more information in memos.
BPEzip is a compression algorithm based on Byte Pair Encoding (BPE), tuned specifically for short texts. Unlike general-purpose compressors, it works well on small inputs and guarantees that compressed data is never much larger than the original (worst case is +1 byte overhead). I also added an integer codec for compact encoding of number sequences.
Compression ratio depends on the input data of course, but messages in most common world languages compress to about 40–70% of their original size.
If you’re curious, you can try it here:
https://github.com/Tomas-M/bpezip
It is written in javascript, but the compression/decompression part can be easily ported to any language. The training is more complicated, but there is already pre-trained dataset so you can use it right away.
Feel free to use it in any of your projects, and let me know please if you have questions or comments.