Question for SynonymQuery

2022-12-27 Thread Anh Dũng Bùi
Hi Lucene users, I recently came across SynonymQuery and found out that it only supports single-term synonyms (since it accepts a list of Term which will be considered as synonyms). We have some multi-term synonyms like "internet device" <-> "wifi router" or "dns" <-> "domain name service". Am I r

Re: Loading WFST to Memory Mapped File in Lucene

2022-12-27 Thread Dawid Weiss
Please feel free to provide a pull request that adds the ability to load the FST off heap to WFSTCompletionLookup. I think it's an oversight and it'd be a good addition. Dawid On Tue, Dec 27, 2022 at 10:35 AM marcos rebelo wrote: > > I have the same impression, even if I'm using the MMapDirector

Re: Loading WFST to Memory Mapped File in Lucene

2022-12-27 Thread marcos rebelo
I have the same impression, even if I'm using the MMapDirectory. The data is on heap. For my use case, it's a huge waste of memory :( 90% of my data could be correctly organised and kept in disk. Thanks for the support Best regards Marcos Rebelo On Tue, 27 Dec 2022, 09:11 Dawid Weiss, wrote:

Re: Loading WFST to Memory Mapped File in Lucene

2022-12-27 Thread Dawid Weiss
Looking at the code briefly, I think WFSTCompletionLookup uses on heap store for the fst. You'd have to load it with off heap fst store instead: https://github.com/apache/lucene/blob/1b9d98d6ec079e950bdd37137082f81400d3bc2e/lucene/core/src/java/org/apache/lucene/util/fst/OffHeapFSTStore.java but