Apache Lucy’s indexes are made up of individual “segments”, each of which is is an independent inverted index. On the file system, each segment is a directory within the main index directory whose name starts with “seg_”: “seg_2”, “seg_5a”, etc.

Each Segment object keeps track of information about an index segment: its fields, document count, and so on. The Segment object itself writes one file, segmeta.json; besides storing info needed by Segment itself, the “segmeta” file serves as a central repository for metadata generated by other index components – relieving them of the burden of storing metadata themselves.