OpenSearch Serverless - Unable to create index mappings with Nested type

0

Hello, I am using OpenSearch Serverless as a vector datastore. While creating index mappings, I am unable to use {"type": "nested"} when I do index sorting while creating the index. I get the following error : Error: TypeError("Unable to serialize {'nested', 'type'} (type: <class 'set'>)"))

When I removed index sorting, I was able to create the "nested" type in index mappings. Any guidance on how to create index mapping with sorting when using 'nested' type? Thanks! Here is my index schema for reference:

Index_body = {'mappings': {'properties': {'acl_tags': {'nested', 'type'}, 'content_type': {'type': 'keyword'}, 'dataset_id': {'type': 'keyword'}, 'item_id': {'type': 'keyword'}, 'metadata': {'nested', 'type'}, 'source_type': {'type': 'keyword'}}}, 'settings': {'index': {'number_of_shards': 1, 'sort.field': 'item_id', 'sort.order': 'asc'}}}

Deepali
posta 7 mesi fa104 visualizzazioni
Nessuna risposta

Accesso non effettuato. Accedi per postare una risposta.

Una buona risposta soddisfa chiaramente la domanda, fornisce un feedback costruttivo e incoraggia la crescita professionale del richiedente.

Linee guida per rispondere alle domande