I am new to Azure AI search, I want to get an attribute chunk index from this skillset to know at which index in the document the chunk is located. the content of pages after he split would looks like this
{'values': [{'recordId': '0', 'data': {'text': 'sample data 1 '}}, {'recordId': '1', 'data': {'text': 'sample data 1'}}, {'recordId': '2', 'data': {'text': 'sample data 3'}}
How to copy the recordId value as a field.
{
"name": "testing-phase-1-docs-skillset",
"description": "Skillset to chunk documents and generate embeddings",
"skills": [
{
"@odata.type": "#Microsoft.Skills.Text.SplitSkill",
"name": "#3",
"description": "Split skill to chunk documents",
"context": "/document",
"inputs": [
{
"name": "text",
"source": "/document/content",
"inputs": []
}
],
"outputs": [
{
"name": "textItems",
"targetName": "pages"
}
],
"defaultLanguageCode": "en",
"textSplitMode": "pages",
"maximumPageLength": 2000,
"pageOverlapLength": 500,
"unit": "characters"
}
],
"@odata.etag": "\"0x8DD029DA50735BD\"",
"indexProjections": {
"selectors": [
{
"targetIndexName": "testing-phase-1-docs-index",
"parentKeyFieldName": "parent_id",
"sourceContext": "/document/pages/*",
"mappings": [
{
"name": "content",
"source": "/document/pages/*"
}, // want to add a recordId here
{
"name": "metadata_title",
"source": "/document/metadata_title"
}
]
}
],
"parameters": {
"projectionMode": "skipIndexingParentDocuments"
}
}
}

SplitSkillitself doesn't exposerecordIddirectly, try to add it as a custom field by creating a projection which extractsrecordIdin the final index configuration.