# More\_like\_this documentation

**URL:** <https://discuss.elastic.co/t/more-like-this-documentation/114477>\
**Category:** Elasticsearch\
**Created:** [January 8, 2018, 9:21am UTC](https://discuss.elastic.co/t/more-like-this-documentation/114477 "2018-01-08T09:21:46Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![yehosef](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/yehosef/32/42175_2.png) [@yehosef](https://discuss.elastic.co/u/yehosef)\
**Post date:** [January 8, 2018, 9:21am UTC](https://discuss.elastic.co/t/more-like-this-documentation/114477/1 "2018-01-08T09:21:47Z")

</div>

I'm a little confused by the documentation at [https://www.elastic.co/guide/en/elasticsearch/reference/current/query-dsl-mlt-query.html](https://www.elastic.co/guide/en/elasticsearch/reference/current/query-dsl-mlt-query.html).

One issue is that I'm trying to do a query using other documents as reference for finding similar.

```
"like": [
          {"_id": "16083773"},
          {"_id": "16084243"}
        ],

```

This works (I still have issues with relevance, etc - but it works.) But in the docs it says that you can use an `ids` field but that doesn't seem to work. `like_text` also meets with a `[mlt] query does not support [like_text]`

I also cannot find an acceptable way to use the Query Formation Parameters (esp. `minimum_should_match`).

Are there some examples using the MLT query and these features?

---

<div class="post-metadata">

**Author:** ![yehosef](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/yehosef/32/42175_2.png) [@yehosef](https://discuss.elastic.co/u/yehosef)\
**Post date:** [January 8, 2018, 9:36am UTC](https://discuss.elastic.co/t/more-like-this-documentation/114477/2 "2018-01-08T09:36:09Z")

</div>

Seems like from [https://www.elastic.co/guide/en/elasticsearch/reference/2.4/query-dsl-mlt-query.html](https://www.elastic.co/guide/en/elasticsearch/reference/2.4/query-dsl-mlt-query.html)  
that the `ids` and `like_text` was depreciated. I guess just not removed from the docs.

Now my `minimum_should_match` is working (at the same level as the other Term Select Parameters. Not sure why it was't working before.

---

<div class="post-metadata">

**Author:** ![Mark\_Harwood](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/mark_harwood/32/10538_2.png) [@Mark\_Harwood](https://discuss.elastic.co/u/Mark_Harwood)\
**Post date:** [January 8, 2018, 10:39am UTC](https://discuss.elastic.co/t/more-like-this-documentation/114477/3 "2018-01-08T10:39:28Z")

</div>

I opened [an issue](https://github.com/elastic/elasticsearch/issues/28128) to flag the incorrect docs.  
It includes an example of how the old ids and like\_text functionality is achieved using the new unified `like` parameter

---

<div class="post-metadata">

**Author:** ![yehosef](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/yehosef/32/42175_2.png) [@yehosef](https://discuss.elastic.co/u/yehosef)\
**Post date:** [January 8, 2018, 2:37pm UTC](https://discuss.elastic.co/t/more-like-this-documentation/114477/4 "2018-01-08T14:37:44Z")

</div>

Thanks. But what also wasn't clear was that the MLT docs say the it uses the syntax of the Multi GET which allows for

```auto
GET /test/type/_mget
{
    "ids" : ["1", "2"]
}

```

And it doesn't seem that's supported, or if it is, I couldn't figure out how to use it. After reading of the MLT docs again, I noticed:

> The syntax to specify documents is _similar_ to the one used by the Multi GET API.

So I don't know if that mean the short `ids` syntax is supported (but I don't know how to use it) or not.

---

<div class="post-metadata">

**Author:** ![Mark\_Harwood](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/mark_harwood/32/10538_2.png) [@Mark\_Harwood](https://discuss.elastic.co/u/Mark_Harwood)\
**Post date:** [January 8, 2018, 2:42pm UTC](https://discuss.elastic.co/t/more-like-this-documentation/114477/5 "2018-01-08T14:42:06Z")

</div>

> [@yehosef](#):
>
> And it doesn't seem that's supported, or if it is, I couldn't figure out how to use it.

There's an example in the linked issue I shared

---

<div class="post-metadata">

**Author:** ![yehosef](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/yehosef/32/42175_2.png) [@yehosef](https://discuss.elastic.co/u/yehosef)\
**Post date:** [January 9, 2018, 8:25am UTC](https://discuss.elastic.co/t/more-like-this-documentation/114477/6 "2018-01-09T08:25:47Z")

</div>

The example in the issue is basically the same as that in the documentation.

I was pointing out that the MLT docs says that it (basically) uses the MultiGET syntax, one of which is `ids:["1","2"]`. But that syntax doesn't seem to work for the MLT. I'm not saying it's a bug.. just caused me some confusion especially since the `ids` syntax used to be supported for MLT.

Ideally, I would think either MLT should support short ids

```auto
"like": {
    "ids": ["1","2","3"]
}

```

or that there is an explicit reference that MLT supports the MultiGET syntax, **except** for short ids.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [February 6, 2018, 8:25am UTC](https://discuss.elastic.co/t/more-like-this-documentation/114477/7 "2018-02-06T08:25:52Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
