Hi,
I want to write my own query expander. I may need to obtain the AST
(abstract syntax tree) of an already parsed query string, navigate to
certain parts of it (words) and make logical phrases of those words by
adding to the AST - where necessary.

And finally transfrom this AST to lucene query string (or query
objcet) then send to lucene searcher to get result.

This cannot be done to the string because the query logic cannot be
semantically altered. (e.g. AND, OR, paren's etc) so it must be parsed
first.

How can this be done with Lucene.Net or combine with other 3-party library?

Thanks for any tips.
Floyd

PS: example is user input a query string from front-end interface like
(A OR B) AND (C OR D)
I want my application rewrite this Query to
( A OR Y OR B OR T)  AND  (C OR Z OR D OR F)

The A B Y T C Z D F are CJK-words(term) with double-quota surround it.
Why I want to do this, Basically I want to do synonymous query but
lucene.net's synonymous seems have some problem in my test (Solr also)
especially processing CJK.

Reply via email to