Skip to content

Commit 3f0a562

Browse files
authored
Merge pull request #263528 from HeidiSteen/heidist-jan
[azure search] January refresh #5
2 parents d19e007 + 80f24b2 commit 3f0a562

21 files changed

+162
-154
lines changed

articles/search/TOC.yml

Lines changed: 28 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,12 @@
1313
href: search-faq-frequently-asked-questions.yml
1414
- name: Quickstarts
1515
items:
16+
- name: Vector search
17+
href: search-get-started-vector.md
1618
- name: Full text search
1719
href: search-get-started-text.md
1820
- name: Semantic ranking
1921
href: search-get-started-semantic.md
20-
- name: Vector search
21-
href: search-get-started-vector.md
2222
- name: Portal
2323
items:
2424
- name: Create an index
@@ -232,14 +232,6 @@
232232
href: search-how-to-create-search-index.md
233233
- name: Create an index alias
234234
href: search-how-to-alias.md
235-
- name: Create a vector index
236-
href: vector-search-how-to-create-index.md
237-
- name: Configure a vectorizer (vectors)
238-
href: vector-search-how-to-configure-vectorizer.md
239-
- name: Chunk documents (vectors)
240-
href: vector-search-how-to-chunk-documents.md
241-
- name: Generate embeddings (vectors)
242-
href: vector-search-how-to-generate-embeddings.md
243235
- name: Load an index
244236
href: search-how-to-load-search-index.md
245237
- name: Index large data sets
@@ -254,6 +246,17 @@
254246
href: search-howto-complex-data-types.md
255247
- name: Model relational data
256248
href: index-sql-relational-data.md
249+
- name: Vector stores
250+
items:
251+
- name: Create a vector index
252+
href: vector-search-how-to-create-index.md
253+
- name: Configure a vectorizer (vectors)
254+
href: vector-search-how-to-configure-vectorizer.md
255+
- name: Chunk documents (vectors)
256+
href: vector-search-how-to-chunk-documents.md
257+
- name: Generate embeddings (vectors)
258+
href: vector-search-how-to-generate-embeddings.md
259+
257260
- name: Analyzers
258261
items:
259262
- name: Add a language analyzer
@@ -366,19 +369,19 @@
366369
href: cognitive-search-custom-skill-scale.md
367370
- name: Example - Bing Entity Search
368371
href: cognitive-search-create-custom-skill-example.md
369-
- name: Knowledge store
370-
items:
371-
- name: Create using REST
372-
href: knowledge-store-create-rest.md
373-
- name: Shaping data
374-
href: knowledge-store-projection-shape.md
375-
- name: Define projections
376-
href: knowledge-store-projections-examples.md
377-
- name: Projection example
378-
href: knowledge-store-projection-example-long.md
379-
- name: Connect with Power BI
380-
href: knowledge-store-connect-power-bi.md
381-
- name: Queries
372+
- name: Knowledge stores
373+
items:
374+
- name: Create using REST
375+
href: knowledge-store-create-rest.md
376+
- name: Shaping data
377+
href: knowledge-store-projection-shape.md
378+
- name: Define projections
379+
href: knowledge-store-projections-examples.md
380+
- name: Projection example
381+
href: knowledge-store-projection-example-long.md
382+
- name: Connect with Power BI
383+
href: knowledge-store-connect-power-bi.md
384+
- name: Queries (text and vector)
382385
items:
383386
- name: Full text query
384387
href: search-query-create.md
@@ -438,7 +441,7 @@
438441
href: performance-benchmarks.md
439442
- name: Tips for better performance
440443
href: search-performance-tips.md
441-
- name: Monitoring Azure AI Search
444+
- name: Monitor Azure AI Search
442445
href: monitor-azure-cognitive-search.md
443446
- name: Visualize resource logs
444447
href: search-monitor-logs-powerbi.md
@@ -617,7 +620,7 @@
617620
href: cognitive-search-skill-sentiment-v3.md
618621
- name: Text Translation
619622
href: cognitive-search-skill-text-translation.md
620-
- name: Azure AI Search utility skills (non-billable)
623+
- name: Azure AI Search utility skills (nonbillable)
621624
items:
622625
- name: Conditional
623626
href: cognitive-search-skill-conditional.md

articles/search/cognitive-search-concept-annotations-syntax.md

Lines changed: 17 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,45 +1,44 @@
11
---
2-
title: Reference inputs and outputs in skillsets
2+
title: Reference enriched nodes during skillset execution
33
titleSuffix: Azure AI Search
44
description: Explains the annotation syntax and how to reference inputs and outputs of a skillset in an AI enrichment pipeline in Azure AI Search.
55
author: HeidiSteen
66
ms.author: heidist
77
ms.service: cognitive-search
88
ms.custom:
99
- ignite-2023
10-
ms.topic: conceptual
11-
ms.date: 09/16/2022
10+
ms.topic: how-to
11+
ms.date: 01/18/2024
1212
---
13-
# Reference an annotation in an Azure AI Search skillset
1413

15-
In this article, you'll learn how to reference *annotations* (or an enrichment node) in skill definitions, using examples to illustrate various scenarios.
14+
# Reference a path to enriched nodes using context and source properties an Azure AI Search skillset
1615

17-
Skills read inputs and write outputs to nodes in an [enriched document](cognitive-search-working-with-skillsets.md#enrichment-tree) tree, building the tree as the enrichments progress. Any node can be referenced in an input for further downstream enrichment, or mapped to an output field in an index. This article introduces the syntax and provides examples for specifying a path to a node. For the full syntax, see [Skill context and input annotation language language](cognitive-search-skill-annotation-language.md).
16+
During skillset execution, the engine builds an in-memory [enrichment tree](cognitive-search-working-with-skillsets.md#enrichment-tree) that captures each enrichment, such as recognized entities or translated text. In this article, learn how to reference an enrichment node in the enrichment tree so that you can pass output to downstream skills or specify an output field mapping for a search index field.
1817

19-
Paths to an annotation are specified in the "context" and "source" properties of a skillset, and in [output field mappings](cognitive-search-output-field-mapping.md) in an indexer. Here's an example of what paths might look like in a skillset:
20-
21-
:::image type="content" source="media/cognitive-search-annotations-syntax/content-source-annotation-path.png" alt-text="Screenshot of a skillset definition with context and source elements highlighted.":::
22-
23-
The example in the screenshot illustrates the path for an item in an Azure Cosmos DB collection.
24-
25-
+ "context" path is `/document/HotelId` because the collection is partitioned into documents by the `/HotelId` field.
26-
27-
+ "source" path is `/document/Description` because the skill is a translation skill, and the field that you'll want the skill to translate is the `Description` field in each document.
18+
This article uses examples to illustrate various scenarios. For the full syntax, see [Skill context and input annotation language language](cognitive-search-skill-annotation-language.md).
2819

2920
## Background concepts
3021

3122
Before reviewing the syntax, let's revisit a few important concepts to better understand the examples provided later in this article.
3223

3324
| Term | Description |
3425
|------|-------------|
35-
| "enriched document" | An enriched document is an internal structure that collects skill output as it's created and it holds all annotations related to a document. Think of an enriched document as a tree of annotations. Generally, an annotation created from a previous annotation becomes its child. </p>Enriched documents only exist for the duration of skillset execution. Once content is mapped to the search index, the enriched document is no longer needed. Although you don't interact with enriched documents directly, it's useful to have a mental model of the documents when creating a skillset. |
36-
| "annotation" | Within an enriched document, a node that is created and populated by a skill, such as "text" and "layoutText" in the OCR skill, is called an annotation. An enriched document is populated with both annotations and unchanged field values or metadata copied from the source. |
26+
| "enriched document" | An enriched document is an in-memory structure that collects skill output as it's created and it holds all enrichments related to a document. Think of an enriched document as a tree. Generally, the tree starts at the root document level, and each new enrichment is created from a previous as its child. |
27+
| "node" | Within an enriched document, a node (sometimes referred to as an "annotation") is created and populated by a skill, such as "text" and "layoutText" in the OCR skill. An enriched document is populated with both enrichments and original source field values or metadata copied from the source. |
3728
| "context" | The scope of enrichment, which is either the entire document, a portion of a document, or if you're working with images, the extracted images from a document. By default, the enrichment context is at the `"/document"` level, scoped to individual documents contained in the data source. When a skill runs, the outputs of that skill become [properties of the defined context](#example-2). |
3829

3930
## Paths for different scenarios
4031

4132
Paths are specified in the "context" and "source" properties of a skillset, and in the [output field mappings](cognitive-search-output-field-mapping.md) in an indexer.
4233

34+
:::image type="content" source="media/cognitive-search-annotations-syntax/content-source-annotation-path.png" alt-text="Screenshot of a skillset definition with context and source elements highlighted.":::
35+
36+
The example in the screenshot illustrates the path for an item in an Azure Cosmos DB collection.
37+
38+
+ `context` path is `/document/HotelId` because the collection is partitioned into documents by the `/HotelId` field.
39+
40+
+ `source` path is `/document/Description` because the skill is a translation skill, and the field that you'll want the skill to translate is the `Description` field in each document.
41+
4342
All paths start with `/document`. An enriched document is created in the "document cracking" stage of indexer execution, when the indexer opens a document or reads in a row from the data source. Initially, the only node in an enriched document is the [root node (`/document`)](cognitive-search-skill-annotation-language.md#document-root), and it's the node from which all other enrichments occur.
4443

4544
The following list includes several common examples:
@@ -57,7 +56,7 @@ Examples in the remainder of this article are based on the "content" field gener
5756

5857
## Example 1: Simple annotation reference
5958

60-
In Azure Blob Storage, suppose you have a variety of files containing references to people's names that you want to extract using entity recognition. In the skill definition below, `"/document/content"` is the textual representation of the entire document, and "people" is an extraction of full names for entities identified as persons.
59+
In Azure Blob Storage, suppose you have a variety of files containing references to people's names that you want to extract using entity recognition. In the following skill definition, `"/document/content"` is the textual representation of the entire document, and "people" is an extraction of full names for entities identified as persons.
6160

6261
Because the default context is `"/document"`, the list of people can now be referenced as `"/document/people"`. In this specific case `"/document/people"` is an annotation, which could now be mapped to a field in an index, or used in another skill in the same skillset.
6362

articles/search/cognitive-search-how-to-debug-skillset.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ Enriched documents are internal, but a debug session gives you access to the con
117117

118118
If the field mappings are correct, check individual skills for configuration and content. If a skill fails to produce output, it might be missing a property or parameter, which can be determined through error and validation messages.
119119

120-
Other issues, such as an invalid context or input expression, can be harder to resolve because the error will tell you what is wrong, but not how to fix it. For help with context and input syntax, see [Reference annotations in an Azure AI Search skillset](cognitive-search-concept-annotations-syntax.md#background-concepts). For help with individual messages, see [Troubleshooting common indexer errors and warnings](cognitive-search-common-errors-warnings.md).
120+
Other issues, such as an invalid context or input expression, can be harder to resolve because the error will tell you what is wrong, but not how to fix it. For help with context and input syntax, see [Reference enrichments in an Azure AI Search skillset](cognitive-search-concept-annotations-syntax.md#background-concepts). For help with individual messages, see [Troubleshooting common indexer errors and warnings](cognitive-search-common-errors-warnings.md).
121121

122122
The following steps show you how to get information about a skill.
123123

@@ -203,7 +203,7 @@ You can edit the skill definition in the portal.
203203

204204
### Test your code
205205

206-
At this point, new requests from your debug session should now be sent to your local Azure Function. You can use breakpoints in your Visual Studio code to debug your code or run step by step.
206+
At this point, new requests from your debug session should now be sent to your local Azure Function. You can use breakpoints in your Visual Studio Code to debug your code or run step by step.
207207

208208
## Next steps
209209

articles/search/cognitive-search-output-field-mapping.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ Output field mappings are added to the `outputFieldMappings` array in an indexer
5858

5959
| Property | Description |
6060
|----------|-------------|
61-
| sourceFieldName | Required. Specifies a path to enriched content. An example might be `/document/content`. See [Reference annotations in an Azure AI Search skillset](cognitive-search-concept-annotations-syntax.md) for path syntax and examples. |
61+
| sourceFieldName | Required. Specifies a path to enriched content. An example might be `/document/content`. See [Reference enrichments in an Azure AI Search skillset](cognitive-search-concept-annotations-syntax.md) for path syntax and examples. |
6262
| targetFieldName | Optional. Specifies the search field that receives the enriched content. Target fields must be top-level simple fields or collections. It can't be a path to a subfield in a complex type. If you want to retrieve specific nodes in a complex structure, you can [flatten individual nodes](#flattening-information-from-complex-types) in memory, and then send the output to a string collection in your index. |
6363
| mappingFunction | Optional. Adds extra processing provided by [mapping functions](search-indexer-field-mappings.md#mappingFunctions) supported by indexers. In the case of enrichment nodes, encoding and decoding are the most commonly used functions. |
6464

articles/search/cognitive-search-skill-annotation-language.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -269,4 +269,4 @@ Parentheses can be used to change or disambiguate evaluation order.
269269

270270
## See also
271271
+ [Create a skillset in Azure AI Search](cognitive-search-defining-skillset.md)
272-
+ [Reference annotations in an Azure AI Search skillset](cognitive-search-concept-annotations-syntax.md)
272+
+ [Reference enrichments in an Azure AI Search skillset](cognitive-search-concept-annotations-syntax.md)

articles/search/cognitive-search-working-with-skillsets.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ Skills can execute independently and in parallel, or sequentially if you feed th
6464

6565
+ Skill #2 is a [Sentiment Detection skill](cognitive-search-skill-sentiment.md) accepts "pages" as input, and produces a new field called "Sentiment" as output that contains the results of sentiment analysis.
6666

67-
Notice how the output of the first skill ("pages") is used in sentiment analysis, where "/document/reviews_text/pages/*" is both the context and input. For more information about path formulation, see [How to reference annotations](cognitive-search-concept-annotations-syntax.md).
67+
Notice how the output of the first skill ("pages") is used in sentiment analysis, where "/document/reviews_text/pages/*" is both the context and input. For more information about path formulation, see [How to reference enrichments](cognitive-search-concept-annotations-syntax.md).
6868

6969
```json
7070
{
@@ -222,7 +222,7 @@ The enrichment tree now has a new node placed under the context of the skill. Th
222222

223223
![enrichment tree after skill #1](media/cognitive-search-working-with-skillsets/enrichment-tree-skill1.png "Enrichment tree after skill #1 executes")
224224

225-
To access any of the enrichments added to a node by a skill, the full path for the enrichment is needed. For example, if you want to use the text from the ```pages``` node as an input to another skill, you'll need to specify it as ```"/document/reviews_text/pages/*"```. For more information about paths, see [Reference annotations](cognitive-search-concept-annotations-syntax.md).
225+
To access any of the enrichments added to a node by a skill, the full path for the enrichment is needed. For example, if you want to use the text from the ```pages``` node as an input to another skill, you'll need to specify it as ```"/document/reviews_text/pages/*"```. For more information about paths, see [Reference enrichments](cognitive-search-concept-annotations-syntax.md).
226226

227227
### Skill #2 Language detection
228228

0 commit comments

Comments
 (0)