Sure. The only reason image generators aren't deterministic is that you inject randomness. Set the same random seed, get the same image. Download Stable Diffusion XL and run it locally and try it.
There are models that can be run in both directions. Take a source image and generate a token stream prompt for it. That's your compressed image. Now run it forward to decompress.
CPU intensive but massive compression ratios can be achieved... like orders of magnitude better than jpeg.
It's lossy compression, so we're not violating fundamental mathematical limits. Those bounds apply to lossless compression.