Dictionary compression is a lossless data compression algorithm that replaces repeated sequences of data with compact references to a dynamically built dictionary of previously seen sequences. Pioneered by the LZ77 and LZW algorithms, it operates on the principle that redundancy in data (like repeated words or code patterns) can be encoded more efficiently as pointers. This technique is fundamental to formats like ZIP, GIF, and is conceptually analogous to how an agent might compress a long conversation history by referencing prior statements.
