[Paper Review] Self-Index Based on LZ77
This paper presents the first practical self-index based on the Lempel-Ziv 1977 (LZ77) compression format, designed specifically for highly repetitive text collections such as genomic databases, software repositories, and versioned documents. It achieves space usage of 2.6 to 4.0 times the size of LZ77-compressed text, outperforms the best existing self-index (RLCSA) in space by up to 6.6 times, and supports fast random access and pattern search at rates of 1–2 million characters per second and 10–50 microseconds per occurrence.
We introduce the first self-index based on the Lempel-Ziv 1977 compression format (LZ77). It is particularly competitive for highly repetitive text collections such as sequence databases of genomes of related species, software repositories, versioned document collections, and temporal text databases. Such collections are extremely compressible but classical self-indexes fail to capture that source of compressibility. Our self-index takes in practice a few times the space of the text compressed with LZ77 (as little as 2.6 times), extracts 1--2 million characters of the text per second, and finds patterns at a rate of 10--50 microseconds per occurrence. It is smaller (up to one half) than the best current self-index for repetitive collections, and faster in many cases.
Motivation & Objective
- To address the limitation of existing self-indexes in capturing repetitiveness in highly repetitive text collections such as genome databases, software repositories, and versioned documents.
- To design a self-index that leverages the superior compressibility of LZ77 over k-th order entropy and run-length models, which current self-indexes fail to exploit fully.
- To overcome the challenge of building a functional self-index without requiring the original text in plain form, a key obstacle in prior LZ77-based indexing approaches.
- To achieve practical performance in space, construction time, and query speed, making LZ77-based self-indexing viable for real-world applications.
Proposed method
- The self-index is built on a variant of LZ77 parsing called LZ-End, which enables efficient random access and reduces space overhead while preserving compression efficiency.
- It uses a suffix array and reverse suffix array data structures, augmented with compressed representations to support fast pattern location and text extraction.
- The index employs binary search on implicit or explicit ID arrays and reverse ID arrays to reduce space usage while maintaining logarithmic-time access to positions in the text.
- It introduces a new compressed data structure for the 'prevLess' operation, which efficiently finds the previous smaller element in a sequence, improving space and time efficiency.
- The index supports both LZ77 and LZ-End parsings, with five space-time trade-off variants, from most to least space-consuming.
- Construction uses compressed data structures and techniques from compressed suffix arrays and FM-indexes, adapted to the LZ77 parsing model.
Experimental results
Research questions
- RQ1Can a self-index be built directly on LZ77-compressed text without requiring the original text in plain form, while supporting fast random access and pattern matching?
- RQ2How does the space usage of an LZ77-based self-index compare to the state-of-the-art RLCSA index on highly repetitive collections?
- RQ3Can the index achieve both high compression and high performance in terms of extraction and search speed on real-world repetitive data?
- RQ4What are the most space-efficient configurations of the index, and how do they trade off with construction and query time?
Key findings
- The proposed LZ77 self-index uses at most 2|LZ| + o(|LZ|) bits of space, where |LZ| is the size of the LZ77-compressed text, making it highly space-efficient.
- The most space-efficient variant uses only 2.5 to 4.0 times the size of the p7zip-compressed LZ77 output, outperforming RLCSA with 512-sampling by up to 6.6 times in space usage.
- On the Einstein collection, the index uses 0.18% of the original text size (LZ-End 5), while RLCSA 512 uses 1.20%, demonstrating superior compression on highly repetitive data.
- Extraction performance reaches 1–2 million characters per second, outperforming RLCSA in most cases, and pattern location takes 10–50 microseconds per occurrence.
- The index is faster than RLCSA in many cases for pattern location, especially when the index is small, and maintains high performance even with minimal sampling.
- The design of the 'prevLess' data structure and the use of implicit ID arrays contribute to space efficiency and are potentially reusable in other compressed data structures.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.