lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "David Parks" <davidpark...@yahoo.com>
Subject RE: MoreLikeThis supporting multiple document IDs as input?
Date Wed, 26 Dec 2012 11:46:25 GMT
Someone else suggested this query: q=id:[10000001 OR 10000002], where the numbers represent
multiple IDs, but if I get it, you're saying that these ultimate get turned into just one
document and we get similar documents to just that one. 

MoreLikeThese sounds promising. Is this in one of the development builds, or is it just and
addon I need to install? I haven't done much customization of Solr yet.

Thanks!
Dave


-----Original Message-----
From: Roman Chyla [mailto:roman.chyla@gmail.com] 
Sent: Wednesday, December 26, 2012 3:57 PM
To: solr-user@lucene.apache.org
Subject: Re: MoreLikeThis supporting multiple document IDs as input?

Jay Luker has written MoreLikeThese which is probably what you want. You may give it a try,
though I am not sure if it works with Solr4.0 at this point (we didn't port it yet)

https://github.com/romanchyla/montysolr/blob/MLT/contrib/adsabs/src/java/org/apache/solr/handler/MoreLikeTheseHandler.java

roman

On Wed, Dec 26, 2012 at 12:06 AM, Jack Krupansky <jack@basetechnology.com>wrote:

> MLT has both a request handler and a search component.
>
> The MLT handler returns similar documents only for the first document 
> that the query matches.
>
> The MLT search component returns similar documents for each of the 
> documents in the search results, but processes each search result base 
> document one at a time and keeps its similar documents segregated by 
> each of the base documents.
>
> It sounds like you wanted to merge the base search results and then 
> find documents similar to that merged super-document. Is that what you 
> were really seeking, as opposed to what the MLT component does? 
> Unfortunately, you can't do that with the components as they are.
>
> You would have to manually merge the values from the base documents 
> and then you could POST that text back to the MLT handler and find 
> similar documents using the posted text rather than a query. Kind of 
> messy, but in theory that should work.
>
> -- Jack Krupansky
>
> -----Original Message----- From: David Parks
> Sent: Tuesday, December 25, 2012 5:04 AM
> To: solr-user@lucene.apache.org
> Subject: MoreLikeThis supporting multiple document IDs as input?
>
>
> I'm unclear on this point from the documentation. Is it possible to 
> give Solr X # of document IDs and tell it that I want documents 
> similar to those X documents?
>
> Example:
>
>  - The user is browsing 5 different articles
>  - I send Solr the IDs of these 5 articles so I can present the user 
> other similar articles
>
> I see this example for sending it 1 document ID:
> http://localhost:8080/solr/**select/?qt=mlt&q=id:[document<http://loca
> lhost:8080/solr/select/?qt=mlt&q=id:[document>
> id]&mlt.fl=[field1],[field2],[**field3]&fl=id&rows=10
>
> But can I send it 2+ document IDs as the query?
>


Mime
View raw message