When a program creates a Lucene document, it can tell Lucene whether to save the field value or not. See, for example, the stored
argument in the StringField constructor. If the value is not stored, it can be found, but the original bytes of the value are not stored in the index, because they are not required and are not used by the search.
A typical template with, say, http://www.elasticsearch.org/ is to store the original JSON in one field and not store the actually indexed fields. Thus, the application working with the extracted data can use its own data format and it is not necessary to know about Lucene and its flat key document.
source share