LuceneSearcher.from_prebuilt_index returns empty contents #1250
-
Hi there, I'm using one of the pre-built indexes via Do the prebuilt indexes store the full document contents? If so, is there any way to access them without decoding the Thanks! |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
In this case, you get If you want an index with Hope this helps! |
Beta Was this translation helpful? Give feedback.
raw
stores the raw document in its original format,contents
stores the "parsed" document. So, for example,raw
might give the original HTML doc, andcontents
provides what's actually indexed after tag cleanup. Thus, you're always able to reconstructcontents
formraw
(i.e., just re-parse the document), but not vice versa. For this reason, we only storeraw
in the prebuilt indexes.In this case, you get
contents
fromraw
by parsing out the JSON and pulling out the right field.If you want an index with
contents
but notraw
, you'll have to build a fresh index yourself.Hope this helps!