Skip to content

Commit 8c7ac20

Browse files
authored
Merge pull request #90290 from Careyjmac/master
[Azure Search] Add error descriptions for skill invalid language input, skill timeout
2 parents e69ee13 + 24ff8b5 commit 8c7ac20

File tree

1 file changed

+58
-0
lines changed

1 file changed

+58
-0
lines changed

articles/search/cognitive-search-common-errors-warnings.md

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,64 @@ Indexer read the document from the data source, but there was an issue convertin
4949
| Could not apply field mapping to a field | Could not apply mapping function `'functionName'` to field `'fieldName'`. Array cannot be null. Parameter name: bytes | Double check the [field mappings](search-indexer-field-mappings.md) defined on the indexer, and compare with the data of the specified field of the failed document. It may be necessary to modify the field mappings or the document data. |
5050
| Could not read field value | Could not read the value of column `'fieldName'` at index `'fieldIndex'`. A transport-level error has occurred when receiving results from the server. (provider: TCP Provider, error: 0 - An existing connection was forcibly closed by the remote host.) | These errors are typically due to unexpected connectivity issues with the data source's underlying service. Try running the document through your indexer again later. |
5151

52+
### Skill input 'languageCode' has the following language codes 'X,Y,Z', at least one of which is invalid.
53+
One or more of the values passed into the optional `languageCode` input of a downstream skill is not supported. This can occur if you are passing the output of the [LanguageDetectionSkill](cognitive-search-skill-language-detection.md) to subsequent skills, and the output consists of more languages than are supported in those downstream skills.
54+
55+
If you know that your data set is all in one language, you should remove the [LanguageDetectionSkill](cognitive-search-skill-language-detection.md) and the `languageCode` skill input and use the `defaultLanguageCode` skill parameter for that skill instead, assuming the language is supported for that skill.
56+
57+
If you know that your data set contains multiple languages and thus you need the [LanguageDetectionSkill](cognitive-search-skill-language-detection.md) and `languageCode` input, consider adding a [ConditionalSkill](cognitive-search-skill-conditional.md) to filter out the text with languages that are not supported before passing in the text to the downstream skill. Here is an example of what this might look like for the EntityRecognitionSkill:
58+
59+
```json
60+
{
61+
"@odata.type": "#Microsoft.Skills.Util.ConditionalSkill",
62+
"context": "/document",
63+
"inputs": [
64+
{ "name": "condition", "source": "= $(/document/language) == 'de' || $(/document/language) == 'en' || $(/document/language) == 'es' || $(/document/language) == 'fr' || $(/document/language) == 'it'" },
65+
{ "name": "whenTrue", "source": "/document/content" },
66+
{ "name": "whenFalse", "source": "= null" }
67+
],
68+
"outputs": [ { "name": "output", "targetName": "supportedByEntityRecognitionSkill" } ]
69+
}
70+
```
71+
72+
Here are some references for the currently supported languages for each of the skills that may produce this error message:
73+
* [Text Analytics Supported Languages](https://docs.microsoft.com/azure/cognitive-services/text-analytics/text-analytics-supported-languages) (for the [KeyPhraseExtractionSkill](cognitive-search-skill-keyphrases.md), [EntityRecognitionSkill](cognitive-search-skill-entity-recognition.md), and [SentimentSkill](cognitive-search-skill-sentiment.md))
74+
* [Translator Supported Languages](https://docs.microsoft.com/azure/cognitive-services/translator/language-support) (for the [Text TranslationSkill](cognitive-search-skill-text-translation.md))
75+
* [Text SplitSkill](cognitive-search-skill-textsplit.md) Supported Languages: `da, de, en, es, fi, fr, it, ko, pt`
76+
77+
### Skill did not execute within the time limit
78+
There are two cases under which you may encounter this error message, each of which should be treated differently. Please follow the instructions below depending on what skill returned this error for you.
79+
80+
#### Built-in Cognitive Service skills
81+
Many of the built-in cognitive skills, such as language detection, entity recognition, or OCR, are backed by a Cognitive Service API endpoint. Sometimes there are transient issues with these endpoints and a request will time out. For transient issues, there is no remedy except to wait and try again. As a mitigation, consider setting your indexer to [run on a schedule](search-howto-schedule-indexers.md). Scheduled indexing picks up where it left off. Assuming transient issues are resolved, indexing and cognitive skill processing should be able to continue on the next scheduled run.
82+
83+
#### Custom skills
84+
If you encounter a timeout error with a custom skill you have created, there are a couple of things you can try. First, review your custom skill and ensure that it is not getting stuck in an infinite loop and that it is returning a result consistently. Once you have confirmed that is the case, determine what the execution time of your skill is. If you didn't explicitly set a `timeout` value on your custom skill definition, then the default `timeout` is 30 seconds. If 30 seconds is not long enough for your skill to execute, you may specify a higher `timeout` value on your custom skill definition. Here is an example of a custom skill definition where the timeout is set to 90 seconds:
85+
86+
```json
87+
{
88+
"@odata.type": "#Microsoft.Skills.Custom.WebApiSkill",
89+
"uri": "<your custom skill uri>",
90+
"batchSize": 1,
91+
"timeout": "PT90S",
92+
"context": "/document",
93+
"inputs": [
94+
{
95+
"name": "input",
96+
"source": "/document/content"
97+
}
98+
],
99+
"outputs": [
100+
{
101+
"name": "output",
102+
"targetName": "output"
103+
}
104+
]
105+
}
106+
```
107+
108+
The maximum value that you can set for the `timeout` parameter is 230 seconds. If your custom skill is unable to execute consistently within 230 seconds, you may consider reducing the `batchSize` of your custom skill so that it will have fewer documents to process within a single execution. If you have already set your `batchSize` to 1, you will need to rewrite the skill to be able to execute in under 230 seconds or otherwise split it into multiple custom skills so that the execution time for any single custom skill is a maximum of 230 seconds. Review the [custom skill documentation](cognitive-search-custom-skill-web-api.md) for more information.
109+
52110
## Warnings
53111
Warnings do not stop indexing, but they do indicate conditions that could result in unexpected outcomes. Whether you take action or not depends on the data and your scenario.
54112

0 commit comments

Comments
 (0)