> You can add the "indent=true" parameter to the request to get a tidier
> output. Firefox usually ignores tabs when showing XML, so I'd suggest to
> choose "View page source" in that case.
>
The page source looks so much better. :) thanks!

> The documentation seems to suggest to have stored=true for the fields
>> though, not sure why.
>>
>
> Maybe someone else can give more details here, but as I understand, if you
> store the term vectors, then MLT will use that information to compute
> similarity. If you don't store the term vectors, but you store the content,
> then MLT will iterate over the content of the field (more precisely, the
> first mlt.maxntp tokens) and generate the term vectors. In that case, the
> document is analyzed again, so it's a slower approach. If you don't store
> any of them, then you get no results :)
>

This makes sense. Just curious to know how much more space the term
vectors will take.
My 'text'(a product's description) can be very long, it can be 2K's
long paragraphs.
Is it crazy to create term vectors out of it?

Elaine

> On Fri, Jul 8, 2011 at 11:08 AM, Elaine Li <elaine.bing...@gmail.com> wrote:
>
>> Guan and Koji, thank you both!
>>
>> After I changed to termVectors = true, it returns the results as expected.
>> I flipped the stored=true|false for two fields: text and category_text
>> and compared the results and don't see any difference. The
>> documentation seems to suggest to have stored=true for the fields
>> though, not sure why.
>>
>> The debugOn=true triggered debug message is a little difficult to read
>> visually with everything in a big long string. After I turn on the
>> wt=json, it becomes slight better with some spaces. Is there a
>> hierarchical display of the debug message separated into multiple
>> lines with indents so it is easier to digest?
>>
>> Elaine
>>
>> On Thu, Jul 7, 2011 at 8:48 PM, Koji Sekiguchi <k...@r.email.ne.jp> wrote:
>> > Plus, debugQuery=on would help you when using MLT after 3.1:
>> >
>> > https://issues.apache.org/jira/browse/SOLR-860
>> >
>> > koji
>> > --
>> > http://www.rondhuit.com/en/
>> >
>> > (11/07/08 6:55), Juan Grande wrote:
>> >>
>> >> Hi Elaine,
>> >>
>> >> The first thing that comes to my mind is that neither the content nor
>> the
>> >> term vectors of "text" and "category_text" fields are being stored.
>> Check
>> >> the name of the parameter used to store the term vectors, which actually
>> >> is
>> >> "termVectors" and not "term_vectored" (see
>> >> http://wiki.apache.org/solr/SchemaXml#Expert_field_options).
>> >>
>> >> Try changing that and tell us if it worked!
>> >>
>> >> Regards,
>> >>
>> >> *Juan*
>> >>
>> >>
>> >>
>> >> On Thu, Jul 7, 2011 at 4:44 PM, Elaine Li<elaine.bing...@gmail.com>
>> >>  wrote:
>> >>
>> >>> Hi Folks,
>> >>>
>> >>> This is my configuration for mlt in solrconfig.xml
>> >>> <requestHandler name="/mlt"
>> >>> class="org.apache.solr.handler.MoreLikeThisHandler">
>> >>>    <lst name="defaults">
>> >>>      <str name="mlt.fl">name,text,category_text</str>
>> >>>      <int name="mlt.mintf">2</int>
>> >>>      <int name="mlt.mindf">1</int>
>> >>>      <int name="mlt.minwl">3</int>
>> >>>      <int name="mlt.maxwl">1000</int>
>> >>>      <int name="mlt.maxqt">50</int>
>> >>>      <int name="mlt.maxntp">5000</int>
>> >>>      <bool name="mlt.boost">true</bool>
>> >>>      <str name="mlt.qf">name,text,category_text</str>
>> >>>      <str name="mlt.interestingTerms"></str>
>> >>>    </lst>
>> >>> </requestHandler>
>> >>>
>> >>> I also defined the three fields to have term_vectored attribute in
>> >>> schema.xml
>> >>> <field name="name" type="text_nostem" indexed="true" stored="true"
>> >>> term_vectored="true"/>
>> >>> <field name="text" type="text_nostem" indexed="true" stored="false"
>> >>> multiValued="true" term_vectored="true"/>
>> >>> <field name="category_text" type="text_strip_id" indexed="true"
>> >>> stored="false" multiValued="true" term_vectored="true"/>
>> >>>
>> >>> When i submit the query
>> >>> "http://localhost:8983/solr/mlt?q=id:69134&mlt.count=10";, the return
>> >>> only contains one document with id=69134.
>> >>>
>> >>> Does anyone know or can guess what I missed? Thanks.
>> >>>
>> >>> Elaine
>> >>>
>> >>
>> >
>> >
>> >
>>
>

Reply via email to