Closed (works as designed)
Project:
Apache Solr Search
Version:
6.x-1.x-dev
Component:
More Like This
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
26 Jan 2009 at 10:09 UTC
Updated:
6 Apr 2010 at 01:38 UTC
Under "Advanced configuration" on the "More Like This" new block configuration page (admin/settings/apachesolr_mlt/configure_block), it doesn't make sense (to me) to have the default value of the "Minimum document frequency" field be 1. It seems to me, you need to have at least two documents containing the field in question before you can compare the open node to anything other than itself.
This patch changes the default, pre-fill from 1 to 2.
| Comment | File | Size | Author |
|---|---|---|---|
| apachesolr-mindocs.patch | 984 bytes | horncologne |
Comments
Comment #1
mikejoconnor commentedThe mindf is actually the minimum number of times the word appears in the document, not the minimum number of documents the word is in. Poor naming.
I think it's best to leave it at one, with the idea that you may only use a keyword once in a document, yet it is still relevant. I would like other opinions on these settings, I haven't had a chance to test them.
Comment #2
pwolanin commentedlet's leave as is in the absence of compelling argument for change.
Comment #3
horncologne commentedThanks for the clarification, Mike. If the functionality is as you say, then I see that 1 is fine.
The name, however, led me to the wrong conclusion. I will continue to suggest a patch that makes this clear.
- jam.
Comment #4
horncologne commentedNow I am confused, Mike!
This is line 214-224 of apachsolr_mlt.module:
You seem to be describing the functionality of mintf rather than mindf - can you please make sure that we are talking about the same thing?
Seems to me like the minimum mintf == 1 is perfectly good as a default.
But if the minimum mindf == 1 that means (correct me if I am wrong) that the given term must appear in at least one node/document for it to be used for comparison. Since the node being displayed has that term, the worst case scenario would be apachesolr_mlt comparing the content to itself ... right? That's why I think this should be two as a default/minimum. A term must appear in at least one *other* document as well or this is meaningless.
- jam.
Comment #5
pwolanin commenteddocs:
http://wiki.apache.org/solr/MoreLikeThis
http://wiki.apache.org/solr/MoreLikeThisHandler
Comment #6
horncologne commentedGood stuff! Now that I have RTFM'd ...
... I still don't see how it makes any sense to compare a word that appears in only one doc. That comparison must be with itself, right?
If a word appears in two documents, then you have something to compare and similar content to recommend.
/me clarifies: The world won't end over this one, I just think it makes sense one way and it probably works just fine another way, too ... I'll let go at this point.
Cheers,
- jam.
Comment #7
pwolanin commentedI'd agree that making mindf 2 is possibly more sensible, but having at 1 does have an effect. The mlt handler is, I believe, doing a kind of term vector distance calculation, so if the term occurs only in one document it will increase the relative distance of that document from all other documents.
Comment #8
pwolanin commented