# OpenSearch 3.0 : unknown setting \[index.knn.space\_type\] please check that any required plugins are installed, or check the breaking changes documentation for removed settings

**URL:** <https://forum.opensearch.org/t/opensearch-3-0-unknown-setting-index-knn-space-type-please-check-that-any-required-plugins-are-installed-or-check-the-breaking-changes-documentation-for-removed-settings/24319>\
**Category:** k-NN\
**Created:** [May 9, 2025, 2:19pm UTC](https://forum.opensearch.org/t/opensearch-3-0-unknown-setting-index-knn-space-type-please-check-that-any-required-plugins-are-installed-or-check-the-breaking-changes-documentation-for-removed-settings/24319 "2025-05-09T14:19:19Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![sans\_india85](https://avatars.discourse-cdn.com/v4/letter/s/c77e96/32.png) [@sans\_india85](https://forum.opensearch.org/u/sans_india85)\
**Post date:** [May 9, 2025, 2:19pm UTC](https://forum.opensearch.org/t/opensearch-3-0-unknown-setting-index-knn-space-type-please-check-that-any-required-plugins-are-installed-or-check-the-breaking-changes-documentation-for-removed-settings/24319/1 "2025-05-09T14:19:20Z")

</div>

**Versions** (relevant - OpenSearch/Dashboard/Server OS/Browser):  
C:\opensearch-3.0.0-windows-x64\opensearch-3.0.0

**Describe the issue** :  
[RAG chatbot with a conversational flow agent - OpenSearch Documentation](https://docs.opensearch.org/docs/latest/tutorials/gen-ai/chatbots/rag-conversational-agent/#step-13-create-a-vector-index) \<–On creation of Create a vector index specifying the ingest pipeline as a default pipeline.  
curl -XPUT “[http://localhost:9200/test\_population\_data](http://localhost:9200/test_population_data)” -H ‘Content-Type: application/json’ -d’  
{  
“mappings”: {  
“properties”: {  
“population\_description”: {  
“type”: “text”  
},  
“population\_description\_embedding”: {  
“type”: “knn\_vector”,  
“dimension”: 384  
}  
}  
},  
“settings”: {  
“index”: {  
“knn.space\_type”: “cosinesimil”,  
“default\_pipeline”: “test\_population\_data\_pipeline”,  
“knn”: “true”  
}  
}  
}  
’  
It gives the below error  
{  
“error”: {  
“root\_cause”: [  
{  
“type”: “settings\_exception”,  
“reason”: “unknown setting [index.knn.space\_type] please check that any required plugins are installed, or check the breaking changes documentation for removed settings”  
}  
],  
“type”: “settings\_exception”,  
“reason”: “unknown setting [index.knn.space\_type] please check that any required plugins are installed, or check the breaking changes documentation for removed settings”  
},  
“status”: 400  
}

When I run below command, the plugin opensearch-knn is already present.  
PS C:\opensearch-3.0.0-windows-x64\opensearch-3.0.0\bin\> .\opensearch-plugin list  
opensearch-alerting  
opensearch-anomaly-detection  
opensearch-asynchronous-search  
opensearch-cross-cluster-replication  
opensearch-custom-codecs  
opensearch-flow-framework  
opensearch-geospatial  
opensearch-index-management  
opensearch-job-scheduler  
opensearch-knn  
opensearch-ltr  
opensearch-ml  
opensearch-neural-search  
opensearch-notifications  
opensearch-notifications-core  
opensearch-observability  
opensearch-reports-scheduler  
opensearch-security  
opensearch-security-analytics  
opensearch-skills  
opensearch-sql  
opensearch-system-templates  
query-insights

How to fix the error?

---

<div class="post-metadata">

**Author:** ![navtat](https://avatars.discourse-cdn.com/v4/letter/n/f4b2a3/32.png) [@navtat](https://forum.opensearch.org/u/navtat)\
**Post date:** [May 9, 2025, 6:18pm UTC](https://forum.opensearch.org/t/opensearch-3-0-unknown-setting-index-knn-space-type-please-check-that-any-required-plugins-are-installed-or-check-the-breaking-changes-documentation-for-removed-settings/24319/2 "2025-05-09T18:18:13Z")

</div>

@sans_india85 yes, that’s an expected behavior. You cannot specify the space\_type using an index setting. We need to specify it in the index mapping like shown below:

```auto
“population_description_embedding”: {
“type”: “knn_vector”,
“dimension”: 384,
"space_type": "cosinesimil"
}

```

---

<div class="post-metadata">

**Author:** ![sans\_india85](https://avatars.discourse-cdn.com/v4/letter/s/c77e96/32.png) [@sans\_india85](https://forum.opensearch.org/u/sans_india85)\
**Post date:** [May 12, 2025, 12:00pm UTC](https://forum.opensearch.org/t/opensearch-3-0-unknown-setting-index-knn-space-type-please-check-that-any-required-plugins-are-installed-or-check-the-breaking-changes-documentation-for-removed-settings/24319/3 "2025-05-12T12:00:44Z")

</div>

Thanks for your input.

[https://localhost:9200/test\_population\_data](https://localhost:9200/test_population_data)

Mapper Parsing Exception as seen in the screenshot.

 ![image](https://us1.discourse-cdn.com/flex019/uploads/mauve_hedgehog/original/2X/2/24d677b3d86c5dacaec05d3f0b1da54ae2a96f7e.png)

* * *

To resolve this, you can try removing the `knn.space_type` parameter. By default, `knn_vector` fields use the cosine similarity measure. Here is the corrected mapping:POST [https://localhost:9200/test\_population\_data](https://localhost:9200/test_population_data)  
{  
“mappings”: {  
“properties”: {  
“population\_description”: {  
“type”: “text”  
},  
“population\_description\_embedding”: {  
“type”: “knn\_vector”,  
“dimension”: 384  
}  
}  
},  
“settings”: {  
“index”: {  
“default\_pipeline”: “test\_population\_data\_pipeline”,  
“knn”: true  
}  
}  
}

---

<div class="post-metadata">

**Author:** ![navtat](https://avatars.discourse-cdn.com/v4/letter/n/f4b2a3/32.png) [@navtat](https://forum.opensearch.org/u/navtat)\
**Post date:** [May 12, 2025, 4:57pm UTC](https://forum.opensearch.org/t/opensearch-3-0-unknown-setting-index-knn-space-type-please-check-that-any-required-plugins-are-installed-or-check-the-breaking-changes-documentation-for-removed-settings/24319/4 "2025-05-12T16:57:20Z")

</div>

@sans_india85 instead of `space_type` you are trying to use `knn.space_type`, that’s the reason you are running into `mapper_parsing_exception`. Check the example I shared in my previous comment. Also, the default value of `space_type` is `l2` not `cosinesimil`.

---

<div class="post-metadata">

**Author:** ![dalip](https://avatars.discourse-cdn.com/v4/letter/d/b19c9b/32.png) [@dalip](https://forum.opensearch.org/u/dalip)\
**Post date:** [May 13, 2025, 3:43pm UTC](https://forum.opensearch.org/t/opensearch-3-0-unknown-setting-index-knn-space-type-please-check-that-any-required-plugins-are-installed-or-check-the-breaking-changes-documentation-for-removed-settings/24319/5 "2025-05-13T15:43:57Z")

</div>

Hi Thanks, for the update can we do like this? :

 ![image](https://us1.discourse-cdn.com/flex019/uploads/mauve_hedgehog/original/2X/6/6fd8c66d68d1881382ff451c110b37b5c0795460.png)

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex019/uploads/mauve_hedgehog/original/2X/3/33547ea01a5b12dcca2958411d3edd97ae2ea8c1.png) [@system](https://forum.opensearch.org/u/system)\
**Post date:** [July 12, 2025, 3:44pm UTC](https://forum.opensearch.org/t/opensearch-3-0-unknown-setting-index-knn-space-type-please-check-that-any-required-plugins-are-installed-or-check-the-breaking-changes-documentation-for-removed-settings/24319/6 "2025-07-12T15:44:50Z")

</div>

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