11 ms·
LLM-Deflate: Extracting LLMs into Datasets
- dvh 1y agoRemember those programming books that were like "1000+1 tips for C++", making those with llms would be trivial now.
- gdiamos 1y agoWhat open source code do you use to pull synthetic data from LLMs?
- chmod775 1y agoI wonder how many cycles of train->extract->train->extract->... you can do before most of your output will be hallucinations.
- gdiamos 1y agoIt would be an expensive experiment to perform. I wonder how you could do it more efficiently?
- apwell23 1y ago> This compression is lossy Is compression really lossy? What is an example of lost knowledge?
- sqeaky 1y agoThink about all the times in llm gets it wrong, the fact that would have helped to get it right is something that was lost. I suppose this isn't proof it's lossy just maybe we don't know how to get the data out. Or look at it another way LLMs or just text prediction machines, whatever information doesn't help them predict the next token or conflicts with the likelihood of the next token is something that gets dropped. Or look at it another way these things are often trained on the many terabytes of the internet yet even a 200 billion parameter network is 100 or 200 GB in size. So something is missing, and that is a way better compression ratio then the best known algorithms for lossless compression. Or we can look at it another way, these things were never built to be lossless compression systems. We can know by looking at how these things are implemented that they don't retain everything they're trained on, they extract a bunch of statistics.
- visarga 1y agoI think extraction from the model itself is a bad idea. But extraction from external sources, such as the deep research reports LLMs generate, or solving problems where we have validation of correctness is a good idea. The model is not validating its outputs by simply doing another inference, but consults external sources or gets feedback from code execution. Humans in chat rooms could also provide lots of learning signal, especially when actions are judged against the outcomes they cause down the line, using hindsight. So in short what works is a model + a way to know its good outputs from bad ones.
- deleted 1y ago[deleted]
- kiicia 1y agoit's exactly the same as JPEG images being lossy, while you can see image as a whole (and it is enough for 99% of people), you are obviously missing some details and the more you rely on those details (professional photography, scientific data) the more obvious it is (to the point of image being useless in some cases) same with LLMs, we are currently testing how far we can go before we seeing obvious issues
- apwell23 1y agowhats an example of loss?
- aewens 1y agoLossy compression vs lossless compression is the difference of whether you can get a 1:1 copy of the original data if you compress and then decompress it. A simple example of this is if you have 4 bits of data and have a compression algorithm that turns it into 2 bits of data. If your dataset only contains 0000, 0011, 1100, and 1111; then this can technically be considered lossless compression because we can always reconstruct the exact original data (e.g. 0011 compresses to 01 and can decompress back to 0011, 1100 compresses to 10 and can decompress back to 1100, etc). However, if our dataset later included 1101 and got compressed to 10, this is now “lossy” because it would decompress to 1100, that last bit was “lost”. An LLM is lossy compression because it lacks the capacity to 1:1 replicate all its input data 100% of the time. It can get quite close in some cases, sure, but it is not perfect every time. So it is considered “lossy”.
- fxj 1y agoHow good can you recreate an image that is described by words? Obviously not bit by bit and pixel by pixel. You get something that resembles the original but not an exact copy.
- apwell23 1y agoyou can create original exactly with right prompt
- esafak 1y agohttps://en.wikipedia.org/wiki/Lossy_compression https://en.wikipedia.org/wiki/Lossy_compression
- fxj 1y agoIt is at least as lossy as jpeg compression. Details get lost and artifacts are generated.
- shawntan 1y agoNot sure if you mean in general, but I'll answer both branches of the question. In general: Depending on the method of compression, you can have lossy or non-lossy compression. Using 7zip on a bunch of text files can lossless-ly compress that data. Briefly, you calculate the statistics of the data you want to compress (the dictionary), and then make the commonly re-occuring chunks describable with fewer bits (encoding). The compressed file basically contains the dictionary and the encoding. For LLMs: There are ways to use an LLM (or any statistical model of text) to compress text data. But the techniques use similar settings as the above, with a dictionary and an encoding, with the LLM taking the function of a dictionary. When "extracting" data from the dictionary alone, you're basically sampling from the dictionary distribution. Quantitatively, the "loss" in "lossy" being described is literally the number of bits used for the encoding. I wrote a brief description here of techniques from an undergrad CS course that can be used: https://blog.wtf.sg/posts/2023-06-05-yes-its-just-doing-compression.-no-its-not-the-diss-you-think-it-is./ https://blog.wtf.sg/posts/2023-06-05-yes-its-just-doing-comp...
- gdiamos 1y agoLLMs have finite entropy (it is related to their training loss) and training typically doesn’t store the residuals. Some compression methods use LLMs internally and also store the residuals, making them lossless.
- gmerc 1y agoThe law of thermodynamics would require it to be lossy
- omneity 1y agoMy gripe with an approach like this is the lack of any grounding to these generated topics. Hallucination accumulates like error in this case so every generation that is conditioned by a previous one (the recursive "hierarchical topic exploration" in TFA). I suspect most of the "leafs" are unusable.
- fxj 1y agoThe question is: Is it like jpeg compression where the errors do not accumulate but the image comverges to a self inverse compressed image or does the data set converge to a single point which is meaningless?
- rapatel0 1y agoThe transformation function in jpeg (DCT) is generally well defined math. While lossy, most of the information is reprocudable. An LLM is layers and layers of non-linear transformations. It's hard to say exactly how information is accumulated. You can inspect activations from tokens but it's really not clear how to define what the function is exactly doing. Therefore error is poorly understood.
- ashf023 1y agoJPEG is similar actually. The DCT is invertible, but the result of the DCT is quantized, which is where some of the compression happens (DCT -> quantization -> IDCT), so the end to end process is not truly invertible. Maybe an analogy to the non-linearities in between the linear steps in deep learning
- gdiamos 1y agoI think it would be interesting to deflate out to a huge dataset and see where this happens. Certainly it will occur as the generated data exceeds the original, eg after 1-10T tokens. I think you could also do this faster by moving down the tree in a depth first manner. Typically I use this for knowledge transfer, style transfer, catastrophic forgetting mitigation, etc and so I don’t go very far. I usually manually review the data samples before using it.
- imranq 1y agoThe claims in this paper don't make sense. There is no proof that anything has been decompressed
- dragonwriter 1y ago“Decompression” is a metaphor, not a fact claim to be proved; it is a description of an approach to generating a dataset from an LLM where most of the potential utility is still fairly explicitly speculative, a jumping off point for further work.
- gmerc 1y agoNope http://arxiv.org/abs/2509.11208 http://arxiv.org/abs/2509.11208
- gmerc 1y agoAbout that http://arxiv.org/abs/2509.11208 http://arxiv.org/abs/2509.11208
- moktonar 1y agoWouldn’t this method be good if applied on humans in job interviews?
- fxj 1y agohow long would it take to do a complete memory dump of your brain by voice stream? days? months? years? this is more like writing one's autobiography.
- gdiamos 1y agoThere are some fun early theoretical ML papers on this topic. They prove that it is possible to fully clone a brain based on this method. I think one could theoretically estimate how many queries you would need to make to do it. The worst case is proportional to the number of parameters of the model, i.e. at least 10^15 for a human. At one minute per spoken sample, that comes out to about 2 billion years to clone one human. I suspect it is not practical without advancements in neural link to increase the bandwidth by billions of times. I personally like playing around with empirical methods like this blog post to understand the practical efficiency of our learning algorithms like back prop on transformers. I also try not to invest too much effort into this topic given the ethical issues.
- moktonar 1y agoI was thinking about selective knowledge exploration to see if the candidate is fit for the offered position. No need to dump everything
- dragonwriter 1y ago> Wouldn’t this method be good if applied on humans in job interviews? Uhm, no? I mean, some firms do abuse job interviews to pump candidates for usable information, and some have gotten a notable bad reputation for that which impacts their funnel of candidates, but from the article: “Generating comprehensive datasets requires thousands of model calls per topic”—you aren’t going to get a candidate to hang around for that...
- 1y ago
- benob 1y agoMy understanding was that the Alpaca data was a distillation from text-davinci-003
- fxj 1y agoLearning == Compression of information. It can be a description by a shorter bit length. Think Shannon Entropy and the measure of information content. The information is still in the weights but it is reorganized and the reconstructed sentences (or lists of tokens) will not provide the same exact bits but the information is still there.
- shawntan 1y agoThe compression is lossy.