# Improving search results for misspelled queries with ELSER semantic search

**URL:** <https://discuss.elastic.co/t/improving-search-results-for-misspelled-queries-with-elser-semantic-search/370935>\
**Category:** Elasticsearch\
**Created:** [November 22, 2024, 8:27am UTC](https://discuss.elastic.co/t/improving-search-results-for-misspelled-queries-with-elser-semantic-search/370935 "2024-11-22T08:27:41Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Sarah2](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/sarah2/32/137582_2.png) [@Sarah2](https://discuss.elastic.co/u/Sarah2)\
**Post date:** [November 22, 2024, 8:27am UTC](https://discuss.elastic.co/t/improving-search-results-for-misspelled-queries-with-elser-semantic-search/370935/1 "2024-11-22T08:27:41Z")

</div>

Using Elastic Search 8.11 and ELSER model to perform semantic search on multiple fields. I have not included any lexical search match in combination as using only embeddings field with text expansion is giving good results but its not handling misspelled queries well.

Using search query as follows:

```auto
GET search-exp/_search?filter_path=took,hits.hits._id,hits.hits._score,hits.hits._source,hits.total
{
  "query": {
    "bool": {
      "should": [
        {
          "text_expansion": {
            "metadata_attributes_embedding": {
              "model_text": <search-query>,
              "model_id": ".elser_model_2_linux-x86_64"
            }
          }
        },
        {
          "text_expansion": {
            "description_embedding": {
              "model_text":<search-query>,
              "model_id": ".elser_model_2_linux-x86_64"
            }
          }
        },
        {
          "text_expansion": {
            "notes_embedding": {
              "model_text": <search-query>,
              "model_id": ".elser_model_2_linux-x86_64"
            }
          }
        }
      ],
      "minimum_should_match": 1
    }
  },
  "min_score": 0,
  "from": 0,
  "size": 20
}

```

I tried adding linear combination with fields from which embedding is generated and include it with fuzziness: "AUTO" but its hampering with good search results I am getting with only text expansion queries.

Any recommendations for this?

Thanks in advance.

---

<div class="post-metadata">

**Author:** ![Jacques\_du\_Plessis](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jacques_du_plessis/32/35413_2.png) [@Jacques\_du\_Plessis](https://discuss.elastic.co/u/Jacques_du_Plessis)\
**Post date:** [December 29, 2024, 6:33pm UTC](https://discuss.elastic.co/t/improving-search-results-for-misspelled-queries-with-elser-semantic-search/370935/2 "2024-12-29T18:33:35Z")

</div>

Did you manage to figure it out? I have the exact same issue?
