Fields in more-like-this queries


(byuva) #1

I would like to find similar documents but just need the ids, not the
actual _source. Normally the "fields" parameter controls the fields
returned but with the MLT api it seems to control the fields on which
the MLT is applied (and seems to always return the _source).

-b


(Clinton Gormley) #2

On Mon, 2011-02-07 at 21:58 -0800, merrellb wrote:

I would like to find similar documents but just need the ids, not the
actual _source. Normally the "fields" parameter controls the fields
returned but with the MLT api it seems to control the fields on which
the MLT is applied (and seems to always return the _source).

MLT just gets converted into a normal search, which uses the "mlt" query
http://www.elasticsearch.org/guide/reference/query-dsl/mlt-query.html

If you use that yourself, then you get search's interface

clint


(system) #3