While LLMs have been used for… a lot, it seems like this use might be one where it’s not only reliable but it appears to outperform existing methods of image compression. Being able to cram more data into less space tends to lead to interesting developments, so I will be keeping my eye on this.

What do you guys think? Seem like it’s deserving of less hype than I’m giving it? What kind of security holes do you think this could open?

  • @kevincox@lemmy.ml
    link
    fedilink
    31 year ago

    I think this is a legitimate use case. It shouldn’t have any security vulnerabilities beyond regular compression-related vulnerabilities.

    The core to compression is prediction. Most compression algorithms work sort of like this:

    1. Guess what the data is going to be.
    2. Encode the difference from the guess.

    If your guess is good it doesn’t take much data to encode the difference. So the data stream is smaller.

    AI image generation can be used to guess the data quite effectively, and it can use context that is hard to encode in classic algorithms (such as what a car looks like). This is basically the next step of shared dictionary compression (like what makes Brotli quite effective) where instead of building a dictionary as a simple Huffman table you compress the dictionary into the model weights. Since the model can do a pretty good job at creating “Image of a girl with brown hair looking right” you “just” need to encode the difference.

    IIUC neither PNG or FLAC use pre-shared data, so sending a massive set of neural weights can be an advantage (and presumably you only need to send these weights occasionally).

    • brie
      link
      fedilink
      1
      edit-2
      1 year ago

      An example of a compression algorithm that does support tuning parameters before hand is zstd.

      Even if something isn’t in a pre-shared dataset, I wonder if a sufficiently advanced LLM might be able to do well at compressing predictable but non-repeating data, such as “abc, bcd, cde, […]”.