As title.
I used "import and vectorized data" to creat index and the index be automatically chunk.
Index schema like;
"value": [
{
"@search.score":
"chunk_id": "",
"chunk": "",
"title": "",
"image": ""
},
Referring to the official documentation, I used "/document/normalized_images/*/data" to retrieve the base64 data of the normalized images, and then processed it using a program to convert it into image files. However, my objective is to obtain the base64 data corresponding to each chunk. Therefore, I modified the skillset as follows, but it resulted in error messages:
"One or more index projection selectors are invalid. Details: There is no matching index field for input 'image' in index 'name'."
"indexProjections": {
"selectors": [
{
"targetIndexName": "name",
"parentKeyFieldName": "parent_id",
"sourceContext": "/document/pages/*",
"mappings": [
{
"name": "chunk",
"source": "/document/pages/*",
"sourceContext": null,
"inputs": []
},
{
"name": "vector",
"source": "/document/pages/*/vector",
"sourceContext": null,
"inputs": []
},
{
"name": "title",
"source": "/document/metadata_storage_name",
"sourceContext": null,
"inputs": []
},
{
"name": "image",
"sourceContext":"/document/pages/*",
"inputs": [
{
"source":"/document/normalized_images/*/pages/data",
"name":"imagedata"
}
]
}
]
}
]
I want to get the base64 data corresponding to each index chunk text. How can I adapt this approach or explore alternative solutions?
There's a mismatch between the index schema and the skillset configuration. The field named
"image"for storing image URLs, doesn't seem to be suitable for storing base64 data."imageData"As shown in below.Once you modify the above just update the skillset as below.
"image"field and store it in the"imageData"field.Update Indexer :