Hi All, I am using MoreLikeThis.java in lucene to expand the query with related terms. It works fine and I could retrieve the relevant documents to the query but I couldn’t know how to extract the related terms to the query for the index.
my task is: For example query is "bank" related terms can be "money", "credit" and so on that appeares frequntly with "bank" in the index. what I should write in the main even I get the interesting terms to my query? i tried BooleanQuery result = (BooleanQuery) mlt.like(docNum); result.add(query, BooleanClause.Occur.MUST_NOT); System.out.println(result.getClauses().toString()); but it doesnt help any idea