On Oct 30, 2009, at 5:49 AM, Joel Halbert wrote:
Hi,
Without using a proximity search i.e. "cheese sandwich"~5
What's the best way of up-scoring results in which the search terms
are
closer to each other?
I'm not aware of any query technique to score based on proximity that
doesn't, itself, use proximity information.
I suppose you could precompute the proximity associations by indexing
n-grams (in this case, called Lucene calls them shingles), such that
there is a single token in your index containing cheese_sandwich
(effectively)
BTW, what's your concern about using a Phrase Query? What requirement
do you have that would prevent that particular query? Or is there
something in the way it is implemented that doesn't work for your
needs (assuming your example here is for discussion purposes)
E.g. so if I search for:
content:cheese content:sandwich
How do you ensure that a document with content:
"Toasted Cheese Sandwich"
scores higher then:
"Cheese and Potato, Tuna sandwich"
Joel
---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscr...@lucene.apache.org
For additional commands, e-mail: java-user-h...@lucene.apache.org
--------------------------
Grant Ingersoll
http://www.lucidimagination.com/
Search the Lucene ecosystem (Lucene/Solr/Nutch/Mahout/Tika/Droids)
using Solr/Lucene:
http://www.lucidimagination.com/search
---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscr...@lucene.apache.org
For additional commands, e-mail: java-user-h...@lucene.apache.org