Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[AI.TextTranslation] Disambiguate example titles #24323

Merged
merged 3 commits into from
Jun 6, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"title": "Find Sentence Boundaries",
"title": "Find Sentence Boundaries with minimum properties",
"operationId": "FindSentenceBoundaries",
"parameters": {
"api-version": "3.0",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"title": "Gets the set of languages currently supported by other operations of the Translator.",
"title": "Gets the set of languages currently supported by other operations of the Translator with minimum properties.",
"operationId": "GetLanguages",
"parameters": {
"api-version": "3.0"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"title": "Lookup Dictionary Entries",
"title": "Lookup Dictionary Entries with minimum properties",
"operationId": "LookupDictionaryEntries",
"parameters": {
"from": "en",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"title": "Lookup Dictionary Examples",
"title": "Lookup Dictionary Examples with minimum properties",
"operationId": "LookupDictionaryExamples",
"parameters": {
"from": "en",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
"cs"
],
"from": "en",
"textType": "plain",
"textType": "Plain",
"category": "custom",
"profanityAction": "NoAction",
"profanityMarker": "Asterisk",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"title": "Translate Text",
"title": "Translate Text with minimum properties",
"operationId": "Translate",
"parameters": {
"to": [
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"title": "Transliterate Text",
"title": "Transliterate Text with minimum properties",
"operationId": "Transliterate",
"parameters": {
"language": "zh-Hans",
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
{
"title": "Find Sentence Boundaries",
"operationId": "FindSentenceBoundaries",
"parameters": {
"X-ClientTraceId": "svun",
"language": "en",
"script": "Latn",
"api-version": "3.0",
"requestBody": [
{
"text": "How are you? I am fine. What did you do today?"
}
]
},
"responses": {
"200": {
"body": [
{
"sentLen": [
13,
11,
22
]
}
]
}
}
}
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"title": "Find Sentence Boundaries",
"title": "Find Sentence Boundaries with minimum properties",
"operationId": "FindSentenceBoundaries",
"parameters": {
"api-version": "3.0",
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,80 @@
{
"title": "Gets the set of languages currently supported by other operations of the Translator.",
"operationId": "GetLanguages",
"parameters": {
"X-ClientTraceId": "kayfnugjec",
"scope": "translation,transliteration,dictionary",
"Accept-Language": "en",
"If-None-Match": "fpnhruttllvc",
"api-version": "3.0"
},
"responses": {
"200": {
"body": {
"translation": {
"en": {
"name": "English",
"nativeName": "English",
"dir": "ltr"
},
"es": {
"name": "Spanish",
"nativeName": "Español",
"dir": "ltr"
}
},
"transliteration": {
"ar": {
"name": "Arabic",
"nativeName": "العربية",
"scripts": [
{
"code": "Arab",
"name": "Arabic",
"nativeName": "العربية",
"dir": "rtl",
"toScripts": [
{
"code": "Latn",
"name": "Latin",
"nativeName": "اللاتينية",
"dir": "ltr"
}
]
},
{
"code": "Latn",
"name": "Latin",
"nativeName": "اللاتينية",
"dir": "ltr",
"toScripts": [
{
"code": "Arab",
"name": "Arabic",
"nativeName": "العربية",
"dir": "rtl"
}
]
}
]
}
},
"dictionary": {
"cs": {
"name": "Czech",
"nativeName": "Čeština",
"dir": "ltr",
"translations": [
{
"name": "English",
"nativeName": "English",
"dir": "ltr",
"code": "en"
}
]
}
}
}
}
}
}
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"title": "Gets the set of languages currently supported by other operations of the Translator.",
"title": "Gets the set of languages currently supported by other operations of the Translator with minimum properties.",
"operationId": "GetLanguages",
"parameters": {
"api-version": "3.0"
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,87 @@
{
"title": "Lookup Dictionary Entries",
"operationId": "LookupDictionaryEntries",
"parameters": {
"X-ClientTraceId": "yqst",
"from": "en",
"to": "es",
"api-version": "3.0",
"requestBody": [
{
"text": "fly"
}
]
},
"responses": {
"200": {
"body": [
{
"normalizedSource": "fly",
"displaySource": "fly",
"translations": [
{
"normalizedTarget": "volar",
"displayTarget": "volar",
"posTag": "VERB",
"confidence": 0.4081,
"prefixWord": "",
"backTranslations": [
{
"normalizedText": "fly",
"displayText": "fly",
"numExamples": 15,
"frequencyCount": 4637
},
{
"normalizedText": "flying",
"displayText": "flying",
"numExamples": 15,
"frequencyCount": 1365
},
{
"normalizedText": "blow",
"displayText": "blow",
"numExamples": 15,
"frequencyCount": 503
},
{
"normalizedText": "flight",
"displayText": "flight",
"numExamples": 15,
"frequencyCount": 135
}
]
},
{
"normalizedTarget": "mosca",
"displayTarget": "mosca",
"posTag": "NOUN",
"confidence": 0.2668,
"prefixWord": "",
"backTranslations": [
{
"normalizedText": "fly",
"displayText": "fly",
"numExamples": 15,
"frequencyCount": 1697
},
{
"normalizedText": "flyweight",
"displayText": "flyweight",
"numExamples": 0,
"frequencyCount": 48
},
{
"normalizedText": "flies",
"displayText": "flies",
"numExamples": 9,
"frequencyCount": 34
}
]
}
]
}
]
}
}
}
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"title": "Lookup Dictionary Entries",
"title": "Lookup Dictionary Entries with minimum properties",
"operationId": "LookupDictionaryEntries",
"parameters": {
"from": "en",
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
{
"title": "Lookup Dictionary Examples",
"operationId": "LookupDictionaryExamples",
"parameters": {
"X-ClientTraceId": "vykwwekvcncclrmsyjhbok",
"from": "en",
"to": "es",
"api-version": "3.0",
"requestBody": [
{
"text": "fly",
"translation": "volar"
}
]
},
"responses": {
"200": {
"body": [
{
"normalizedSource": "fly",
"normalizedTarget": "volar",
"examples": [
{
"sourcePrefix": "They need machines to ",
"sourceTerm": "fly",
"sourceSuffix": ".",
"targetPrefix": "Necesitan máquinas para ",
"targetTerm": "volar",
"targetSuffix": "."
},
{
"sourcePrefix": "That should really ",
"sourceTerm": "fly",
"sourceSuffix": ".",
"targetPrefix": "Eso realmente debe ",
"targetTerm": "volar",
"targetSuffix": "."
}
]
}
]
}
}
}
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"title": "Lookup Dictionary Examples",
"title": "Lookup Dictionary Examples with minimum properties",
"operationId": "LookupDictionaryExamples",
"parameters": {
"from": "en",
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
{
"title": "Translate Text",
"operationId": "Translate",
"parameters": {
"X-ClientTraceId": "ndbkaatzsnoetqkiehappoza",
"to": [
"cs"
],
"from": "en",
"textType": "Plain",
"category": "custom",
"profanityAction": "NoAction",
"profanityMarker": "Asterisk",
"includeAlignment": true,
"includeSentenceLength": true,
"suggestedFrom": "en",
"fromScript": "Latn",
"toScript": "Latn",
"allowFallback": true,
"api-version": "3.0",
"requestBody": [
{
"text": "This is a test."
}
]
},
"responses": {
"200": {
"body": [
{
"detectedLanguage": {
"language": "en",
"score": 1.0
},
"translations": [
{
"to": "cs",
"text": "Tohle je test.",
"transliteration": {
"text": "Tohle je test.",
"script": "Latn"
},
"alignment": {
"proj": "okrxvzsagjgzrrv"
},
"sentLen": {
"srcSentLen": [
30
],
"transSentLen": [
24
]
}
}
],
"sourceText": {
"text": "This is a test"
}
}
]
}
}
}
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"title": "Translate Text",
"title": "Translate Text with minimum properties",
"operationId": "Translate",
"parameters": {
"to": [
Expand Down
Loading