RE: documents with known relevancy

2010-07-16 Thread fiedzia
Jonathan Rochkind wrote: > > I've never used it, but I think this is the use case that the Solr feature > to use Lucene 'payloads' is meant for? > http://www.lucidimagination.com/blog/2009/08/05/getting-started-with-payloads/ > This is it, thanks for this link. -- View this message in conte

Re: documents with known relevancy

2010-07-16 Thread Dennis Gearon
--- On Fri, 7/16/10, Peter Karich wrote: > From: Peter Karich > Subject: Re: documents with known relevancy > To: solr-user@lucene.apache.org > Date: Friday, July 16, 2010, 12:25 PM > I didn't looked at payloads as > mentioned by Jonathan, but another > solution coul

Re: documents with known relevancy

2010-07-16 Thread Peter Karich
I didn't looked at payloads as mentioned by Jonathan, but another solution could be (similar to Dennis'): create a field 'tags' and then add the tag1 several times to it - depending on the weight. E.g. add it 10 times if the weight is 1.0 But add it only 2 times if the weight is 0.2 etc. Of cours

RE: documents with known relevancy

2010-07-16 Thread Jonathan Rochkind
> Exactly. The weight is a weight of a given tag for specific document, not > weight of the field as in weighted search. So one document may have tag1 > with weight of 0.1, and another may have the same tag1 with weight=0.8. I've never used it, but I think this is the use case that the Solr featur

Re: documents with known relevancy

2010-07-16 Thread fiedzia
Dennis Gearon wrote: > > Seems to me that you are doing externally to Solr what you could be doing > internally. If you had ONE field as and weighted those in your SOLR > query, that is how I am guessing it is usually done. > I guess i used confusing term for weight. The weight (value assigne

Re: documents with known relevancy

2010-07-16 Thread fiedzia
Dennis Gearon wrote: > > So does this mean that each document has a different weight for the same > tag? > Exactly. The weight is a weight of a given tag for specific document, not weight of the field as in weighted search. So one document may have tag1 with weight of 0.1, and another may have

Re: documents with known relevancy

2010-07-16 Thread Dennis Gearon
e: > From: fiedzia > Subject: Re: documents with known relevancy > To: solr-user@lucene.apache.org > Date: Friday, July 16, 2010, 8:06 AM > > > Peter Karich wrote: > > > > Hi, > > > > Why do you need the weight for the tags? > > > > The o

Re: documents with known relevancy

2010-07-16 Thread Dennis Gearon
Seems to me that you are doing externally to Solr what you could be doing internally. If you had ONE field as and weighted those in your SOLR query, that is how I am guessing it is usually done. Dennis Gearon Signature Warning EARTH has a Right To Life, otherwise we all die.

Re: documents with known relevancy

2010-07-16 Thread fiedzia
I came up with another idea, which seem to do what i want. Any comments about better solutions or improving efficiency are welcome: for each document create multivalue text field "tags" with all tags, and multiple dynamic fields for each tag containging value, so we have: { id: 123 tags: tag1

Re: documents with known relevancy

2010-07-16 Thread fiedzia
Peter Karich wrote: > > Hi, > > Why do you need the weight for the tags? > The only reason to include weights is to sort results by weights. So if there are multiple documents containing given tag, i want them to be sorted by weight. Also i would like to be able to seach by multiple tags at

Re: documents with known relevancy

2010-07-16 Thread Peter Karich
Hi, Why do you need the weight for the tags? you could index it this way: { id: 123 tag:'tag1' weight: 0.01 uniqueKey: combine(id, tag) } { id: 123 tag:'tag2' weight: 0.3 uniqueKey: combine(id, tag) } and specify the query-time boost with the help of the weight. Retri