# How to get right relevance in my eCommerce project

**URL:** https://discuss.elastic.co/t/how-to-get-right-relevance-in-my-ecommerce-project/173098
**Category:** Elasticsearch
**Created:** [March 20, 2019, 8:34am UTC](https://discuss.elastic.co/t/how-to-get-right-relevance-in-my-ecommerce-project/173098 "2019-03-20T08:34:27Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![bash\_script](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/bash_script/32/42213_2.png) [@bash\_script](https://discuss.elastic.co/u/bash_script)
#### Post date: [March 20, 2019, 8:34am UTC](https://discuss.elastic.co/t/how-to-get-right-relevance-in-my-ecommerce-project/173098/1 "2019-03-20T08:34:27Z")

</div>

Hey! I'm new in elasticsearch. In my eCommerce project, I have many various products. And when I want to search for a smartphone let's say iPhone 7 (iphone 7 red), I get results with cases for iPhone 7 (case for iphone 7 red). In my mapping, I use n\_gram tokenither with min\_gram = 1, and max\_gram = 3. What is the best way to say elastic find the best relevant results for my purpose?

---

<div class="post-metadata">

### Author: ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)
#### Post date: [March 20, 2019, 8:57am UTC](https://discuss.elastic.co/t/how-to-get-right-relevance-in-my-ecommerce-project/173098/2 "2019-03-20T08:57:08Z")

</div>

Could you provide a full recreation script as described in [About the Elasticsearch category](https://discuss.elastic.co/t/about-the-elasticsearch-category/21). It will help to better understand what you are doing. Please, try to keep the example as simple as possible.

A full reproduction script will help readers to understand, reproduce and if needed fix your problem. It will also most likely help to get a faster answer.

---

<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: [April 17, 2019, 9:09am UTC](https://discuss.elastic.co/t/how-to-get-right-relevance-in-my-ecommerce-project/173098/3 "2019-04-17T09:09:15Z")

</div>

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