@azure-rest/ai-translation-text 1.0.3-alpha.20251210.1 → 2.0.0-alpha.20251218.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (133) hide show
  1. package/CHANGELOG.md +9 -2
  2. package/README.md +26 -173
  3. package/dist/browser/clientDefinitions.d.ts +2 -20
  4. package/dist/browser/clientDefinitions.d.ts.map +1 -1
  5. package/dist/browser/clientDefinitions.js.map +1 -1
  6. package/dist/browser/customClient.js +2 -2
  7. package/dist/browser/customClient.js.map +1 -1
  8. package/dist/browser/index.d.ts +0 -1
  9. package/dist/browser/index.d.ts.map +1 -1
  10. package/dist/browser/index.js +0 -1
  11. package/dist/browser/index.js.map +1 -1
  12. package/dist/browser/isUnexpected.d.ts +1 -4
  13. package/dist/browser/isUnexpected.d.ts.map +1 -1
  14. package/dist/browser/isUnexpected.js +0 -3
  15. package/dist/browser/isUnexpected.js.map +1 -1
  16. package/dist/browser/models.d.ts +96 -7
  17. package/dist/browser/models.d.ts.map +1 -1
  18. package/dist/browser/models.js.map +1 -1
  19. package/dist/browser/outputModels.d.ts +31 -209
  20. package/dist/browser/outputModels.d.ts.map +1 -1
  21. package/dist/browser/outputModels.js.map +1 -1
  22. package/dist/browser/parameters.d.ts +4 -160
  23. package/dist/browser/parameters.d.ts.map +1 -1
  24. package/dist/browser/parameters.js.map +1 -1
  25. package/dist/browser/responses.d.ts +5 -62
  26. package/dist/browser/responses.d.ts.map +1 -1
  27. package/dist/browser/responses.js.map +1 -1
  28. package/dist/browser/textTranslationClient.d.ts.map +1 -1
  29. package/dist/browser/textTranslationClient.js +3 -3
  30. package/dist/browser/textTranslationClient.js.map +1 -1
  31. package/dist/commonjs/clientDefinitions.d.ts +2 -20
  32. package/dist/commonjs/clientDefinitions.d.ts.map +1 -1
  33. package/dist/commonjs/clientDefinitions.js.map +1 -1
  34. package/dist/commonjs/customClient.js +2 -2
  35. package/dist/commonjs/customClient.js.map +1 -1
  36. package/dist/commonjs/index.d.ts +0 -1
  37. package/dist/commonjs/index.d.ts.map +1 -1
  38. package/dist/commonjs/index.js +0 -1
  39. package/dist/commonjs/index.js.map +1 -1
  40. package/dist/commonjs/isUnexpected.d.ts +1 -4
  41. package/dist/commonjs/isUnexpected.d.ts.map +1 -1
  42. package/dist/commonjs/isUnexpected.js +0 -3
  43. package/dist/commonjs/isUnexpected.js.map +1 -1
  44. package/dist/commonjs/models.d.ts +96 -7
  45. package/dist/commonjs/models.d.ts.map +1 -1
  46. package/dist/commonjs/models.js.map +1 -1
  47. package/dist/commonjs/outputModels.d.ts +31 -209
  48. package/dist/commonjs/outputModels.d.ts.map +1 -1
  49. package/dist/commonjs/outputModels.js.map +1 -1
  50. package/dist/commonjs/parameters.d.ts +4 -160
  51. package/dist/commonjs/parameters.d.ts.map +1 -1
  52. package/dist/commonjs/parameters.js.map +1 -1
  53. package/dist/commonjs/responses.d.ts +5 -62
  54. package/dist/commonjs/responses.d.ts.map +1 -1
  55. package/dist/commonjs/responses.js.map +1 -1
  56. package/dist/commonjs/textTranslationClient.d.ts.map +1 -1
  57. package/dist/commonjs/textTranslationClient.js +3 -3
  58. package/dist/commonjs/textTranslationClient.js.map +1 -1
  59. package/dist/commonjs/tsdoc-metadata.json +1 -1
  60. package/dist/esm/clientDefinitions.d.ts +2 -20
  61. package/dist/esm/clientDefinitions.d.ts.map +1 -1
  62. package/dist/esm/clientDefinitions.js.map +1 -1
  63. package/dist/esm/customClient.js +2 -2
  64. package/dist/esm/customClient.js.map +1 -1
  65. package/dist/esm/index.d.ts +0 -1
  66. package/dist/esm/index.d.ts.map +1 -1
  67. package/dist/esm/index.js +0 -1
  68. package/dist/esm/index.js.map +1 -1
  69. package/dist/esm/isUnexpected.d.ts +1 -4
  70. package/dist/esm/isUnexpected.d.ts.map +1 -1
  71. package/dist/esm/isUnexpected.js +0 -3
  72. package/dist/esm/isUnexpected.js.map +1 -1
  73. package/dist/esm/models.d.ts +96 -7
  74. package/dist/esm/models.d.ts.map +1 -1
  75. package/dist/esm/models.js.map +1 -1
  76. package/dist/esm/outputModels.d.ts +31 -209
  77. package/dist/esm/outputModels.d.ts.map +1 -1
  78. package/dist/esm/outputModels.js.map +1 -1
  79. package/dist/esm/parameters.d.ts +4 -160
  80. package/dist/esm/parameters.d.ts.map +1 -1
  81. package/dist/esm/parameters.js.map +1 -1
  82. package/dist/esm/responses.d.ts +5 -62
  83. package/dist/esm/responses.d.ts.map +1 -1
  84. package/dist/esm/responses.js.map +1 -1
  85. package/dist/esm/textTranslationClient.d.ts.map +1 -1
  86. package/dist/esm/textTranslationClient.js +3 -3
  87. package/dist/esm/textTranslationClient.js.map +1 -1
  88. package/dist/react-native/clientDefinitions.d.ts +2 -20
  89. package/dist/react-native/clientDefinitions.d.ts.map +1 -1
  90. package/dist/react-native/clientDefinitions.js.map +1 -1
  91. package/dist/react-native/customClient.js +2 -2
  92. package/dist/react-native/customClient.js.map +1 -1
  93. package/dist/react-native/index.d.ts +0 -1
  94. package/dist/react-native/index.d.ts.map +1 -1
  95. package/dist/react-native/index.js +0 -1
  96. package/dist/react-native/index.js.map +1 -1
  97. package/dist/react-native/isUnexpected.d.ts +1 -4
  98. package/dist/react-native/isUnexpected.d.ts.map +1 -1
  99. package/dist/react-native/isUnexpected.js +0 -3
  100. package/dist/react-native/isUnexpected.js.map +1 -1
  101. package/dist/react-native/models.d.ts +96 -7
  102. package/dist/react-native/models.d.ts.map +1 -1
  103. package/dist/react-native/models.js.map +1 -1
  104. package/dist/react-native/outputModels.d.ts +31 -209
  105. package/dist/react-native/outputModels.d.ts.map +1 -1
  106. package/dist/react-native/outputModels.js.map +1 -1
  107. package/dist/react-native/parameters.d.ts +4 -160
  108. package/dist/react-native/parameters.d.ts.map +1 -1
  109. package/dist/react-native/parameters.js.map +1 -1
  110. package/dist/react-native/responses.d.ts +5 -62
  111. package/dist/react-native/responses.d.ts.map +1 -1
  112. package/dist/react-native/responses.js.map +1 -1
  113. package/dist/react-native/textTranslationClient.d.ts.map +1 -1
  114. package/dist/react-native/textTranslationClient.js +3 -3
  115. package/dist/react-native/textTranslationClient.js.map +1 -1
  116. package/package.json +2 -2
  117. package/review/ai-translation-text-node.api.md +66 -334
  118. package/dist/browser/serializeHelper.d.ts +0 -2
  119. package/dist/browser/serializeHelper.d.ts.map +0 -1
  120. package/dist/browser/serializeHelper.js +0 -13
  121. package/dist/browser/serializeHelper.js.map +0 -1
  122. package/dist/commonjs/serializeHelper.d.ts +0 -2
  123. package/dist/commonjs/serializeHelper.d.ts.map +0 -1
  124. package/dist/commonjs/serializeHelper.js +0 -16
  125. package/dist/commonjs/serializeHelper.js.map +0 -1
  126. package/dist/esm/serializeHelper.d.ts +0 -2
  127. package/dist/esm/serializeHelper.d.ts.map +0 -1
  128. package/dist/esm/serializeHelper.js +0 -13
  129. package/dist/esm/serializeHelper.js.map +0 -1
  130. package/dist/react-native/serializeHelper.d.ts +0 -2
  131. package/dist/react-native/serializeHelper.d.ts.map +0 -1
  132. package/dist/react-native/serializeHelper.js +0 -13
  133. package/dist/react-native/serializeHelper.js.map +0 -1
@@ -14,23 +14,6 @@ import type { RequestParameters } from '@azure-rest/core-client';
14
14
  import type { StreamableMethod } from '@azure-rest/core-client';
15
15
  import type { TokenCredential } from '@azure/core-auth';
16
16
 
17
- // @public
18
- export interface BackTranslationOutput {
19
- displayText: string;
20
- frequencyCount: number;
21
- normalizedText: string;
22
- numExamples: number;
23
- }
24
-
25
- // @public
26
- export interface BreakSentenceItemOutput {
27
- detectedLanguage?: DetectedLanguageOutput;
28
- sentLen: number[];
29
- }
30
-
31
- // @public (undocumented)
32
- export function buildMultiCollection(items: string[], parameterName: string): string;
33
-
34
17
  // @public
35
18
  function createClient(credential: TranslatorCredential | TranslatorTokenCredential | KeyCredential | TokenCredential, options?: ClientOptions): TextTranslationClient;
36
19
 
@@ -47,48 +30,9 @@ export interface DetectedLanguageOutput {
47
30
  score: number;
48
31
  }
49
32
 
50
- // @public
51
- export interface DictionaryExampleItemOutput {
52
- examples: Array<DictionaryExampleOutput>;
53
- normalizedSource: string;
54
- normalizedTarget: string;
55
- }
56
-
57
- // @public
58
- export interface DictionaryExampleOutput {
59
- sourcePrefix: string;
60
- sourceSuffix: string;
61
- sourceTerm: string;
62
- targetPrefix: string;
63
- targetSuffix: string;
64
- targetTerm: string;
65
- }
66
-
67
- // @public
68
- export interface DictionaryExampleTextItem extends InputTextItem {
69
- translation: string;
70
- }
71
-
72
- // @public
73
- export interface DictionaryLookupItemOutput {
74
- displaySource: string;
75
- normalizedSource: string;
76
- translations: Array<DictionaryTranslationOutput>;
77
- }
78
-
79
- // @public
80
- export interface DictionaryTranslationOutput {
81
- backTranslations: Array<BackTranslationOutput>;
82
- confidence: number;
83
- displayTarget: string;
84
- normalizedTarget: string;
85
- posTag: string;
86
- prefixWord: string;
87
- }
88
-
89
33
  // @public
90
34
  export interface ErrorDetailsOutput {
91
- code: number;
35
+ code: string;
92
36
  message: string;
93
37
  }
94
38
 
@@ -97,72 +41,6 @@ export interface ErrorResponseOutput {
97
41
  error: ErrorDetailsOutput;
98
42
  }
99
43
 
100
- // @public (undocumented)
101
- export interface FindSentenceBoundaries {
102
- post(options: FindSentenceBoundariesParameters): StreamableMethod<FindSentenceBoundaries200Response | FindSentenceBoundariesDefaultResponse>;
103
- }
104
-
105
- // @public (undocumented)
106
- export interface FindSentenceBoundaries200Headers {
107
- "x-requestid": string;
108
- }
109
-
110
- // @public
111
- export interface FindSentenceBoundaries200Response extends HttpResponse {
112
- // (undocumented)
113
- body: Array<BreakSentenceItemOutput>;
114
- // (undocumented)
115
- headers: RawHttpHeaders & FindSentenceBoundaries200Headers;
116
- // (undocumented)
117
- status: "200";
118
- }
119
-
120
- // @public (undocumented)
121
- export interface FindSentenceBoundariesBodyParam {
122
- body: Array<InputTextItem>;
123
- }
124
-
125
- // @public (undocumented)
126
- export interface FindSentenceBoundariesDefaultHeaders {
127
- "x-requestid": string;
128
- }
129
-
130
- // @public (undocumented)
131
- export interface FindSentenceBoundariesDefaultResponse extends HttpResponse {
132
- // (undocumented)
133
- body: ErrorResponseOutput;
134
- // (undocumented)
135
- headers: RawHttpHeaders & FindSentenceBoundariesDefaultHeaders;
136
- // (undocumented)
137
- status: string;
138
- }
139
-
140
- // @public (undocumented)
141
- export interface FindSentenceBoundariesHeaderParam {
142
- // (undocumented)
143
- headers?: RawHttpHeadersInput & FindSentenceBoundariesHeaders;
144
- }
145
-
146
- // @public (undocumented)
147
- export interface FindSentenceBoundariesHeaders {
148
- "X-ClientTraceId"?: string;
149
- }
150
-
151
- // @public (undocumented)
152
- export type FindSentenceBoundariesParameters = FindSentenceBoundariesQueryParam & FindSentenceBoundariesHeaderParam & FindSentenceBoundariesBodyParam & RequestParameters;
153
-
154
- // @public (undocumented)
155
- export interface FindSentenceBoundariesQueryParam {
156
- // (undocumented)
157
- queryParameters?: FindSentenceBoundariesQueryParamProperties;
158
- }
159
-
160
- // @public (undocumented)
161
- export interface FindSentenceBoundariesQueryParamProperties {
162
- language?: string;
163
- script?: string;
164
- }
165
-
166
44
  // @public (undocumented)
167
45
  export interface GetSupportedLanguages {
168
46
  get(options?: GetSupportedLanguagesParameters): StreamableMethod<GetSupportedLanguages200Response | GetSupportedLanguagesDefaultResponse>;
@@ -228,9 +106,9 @@ export interface GetSupportedLanguagesQueryParamProperties {
228
106
 
229
107
  // @public
230
108
  export interface GetSupportedLanguagesResultOutput {
231
- dictionary?: Record<string, SourceDictionaryLanguageOutput>;
232
- translation?: Record<string, TranslationLanguageOutput>;
233
- transliteration?: Record<string, TransliterationLanguageOutput>;
109
+ readonly models?: string[];
110
+ readonly translation?: Record<string, TranslationLanguageOutput>;
111
+ readonly transliteration?: Record<string, TransliterationLanguageOutput>;
234
112
  }
235
113
 
236
114
  // @public
@@ -247,15 +125,6 @@ export function isUnexpected(response: Translate200Response | TranslateDefaultRe
247
125
  // @public (undocumented)
248
126
  export function isUnexpected(response: Transliterate200Response | TransliterateDefaultResponse): response is TransliterateDefaultResponse;
249
127
 
250
- // @public (undocumented)
251
- export function isUnexpected(response: FindSentenceBoundaries200Response | FindSentenceBoundariesDefaultResponse): response is FindSentenceBoundariesDefaultResponse;
252
-
253
- // @public (undocumented)
254
- export function isUnexpected(response: LookupDictionaryEntries200Response | LookupDictionaryEntriesDefaultResponse): response is LookupDictionaryEntriesDefaultResponse;
255
-
256
- // @public (undocumented)
257
- export function isUnexpected(response: LookupDictionaryExamples200Response | LookupDictionaryExamplesDefaultResponse): response is LookupDictionaryExamplesDefaultResponse;
258
-
259
128
  // @public
260
129
  export type LanguageDirectionalityOutput = "ltr" | "rtl";
261
130
 
@@ -267,179 +136,23 @@ export interface LanguageScriptOutput {
267
136
  nativeName: string;
268
137
  }
269
138
 
270
- // @public (undocumented)
271
- export interface LookupDictionaryEntries {
272
- post(options: LookupDictionaryEntriesParameters): StreamableMethod<LookupDictionaryEntries200Response | LookupDictionaryEntriesDefaultResponse>;
273
- }
274
-
275
- // @public (undocumented)
276
- export interface LookupDictionaryEntries200Headers {
277
- "x-requestid": string;
278
- }
279
-
280
- // @public
281
- export interface LookupDictionaryEntries200Response extends HttpResponse {
282
- // (undocumented)
283
- body: Array<DictionaryLookupItemOutput>;
284
- // (undocumented)
285
- headers: RawHttpHeaders & LookupDictionaryEntries200Headers;
286
- // (undocumented)
287
- status: "200";
288
- }
289
-
290
- // @public (undocumented)
291
- export interface LookupDictionaryEntriesBodyParam {
292
- body: Array<InputTextItem>;
293
- }
294
-
295
- // @public (undocumented)
296
- export interface LookupDictionaryEntriesDefaultHeaders {
297
- "x-requestid": string;
298
- }
299
-
300
- // @public (undocumented)
301
- export interface LookupDictionaryEntriesDefaultResponse extends HttpResponse {
302
- // (undocumented)
303
- body: ErrorResponseOutput;
304
- // (undocumented)
305
- headers: RawHttpHeaders & LookupDictionaryEntriesDefaultHeaders;
306
- // (undocumented)
307
- status: string;
308
- }
309
-
310
- // @public (undocumented)
311
- export interface LookupDictionaryEntriesHeaderParam {
312
- // (undocumented)
313
- headers?: RawHttpHeadersInput & LookupDictionaryEntriesHeaders;
314
- }
315
-
316
- // @public (undocumented)
317
- export interface LookupDictionaryEntriesHeaders {
318
- "X-ClientTraceId"?: string;
319
- }
320
-
321
- // @public (undocumented)
322
- export type LookupDictionaryEntriesParameters = LookupDictionaryEntriesQueryParam & LookupDictionaryEntriesHeaderParam & LookupDictionaryEntriesBodyParam & RequestParameters;
323
-
324
- // @public (undocumented)
325
- export interface LookupDictionaryEntriesQueryParam {
326
- // (undocumented)
327
- queryParameters: LookupDictionaryEntriesQueryParamProperties;
328
- }
329
-
330
- // @public (undocumented)
331
- export interface LookupDictionaryEntriesQueryParamProperties {
332
- from: string;
333
- to: string;
334
- }
335
-
336
- // @public (undocumented)
337
- export interface LookupDictionaryExamples {
338
- post(options: LookupDictionaryExamplesParameters): StreamableMethod<LookupDictionaryExamples200Response | LookupDictionaryExamplesDefaultResponse>;
339
- }
340
-
341
- // @public (undocumented)
342
- export interface LookupDictionaryExamples200Headers {
343
- "x-requestid": string;
344
- }
345
-
346
- // @public
347
- export interface LookupDictionaryExamples200Response extends HttpResponse {
348
- // (undocumented)
349
- body: Array<DictionaryExampleItemOutput>;
350
- // (undocumented)
351
- headers: RawHttpHeaders & LookupDictionaryExamples200Headers;
352
- // (undocumented)
353
- status: "200";
354
- }
355
-
356
- // @public (undocumented)
357
- export interface LookupDictionaryExamplesBodyParam {
358
- body: Array<DictionaryExampleTextItem>;
359
- }
360
-
361
- // @public (undocumented)
362
- export interface LookupDictionaryExamplesDefaultHeaders {
363
- "x-requestid": string;
364
- }
365
-
366
- // @public (undocumented)
367
- export interface LookupDictionaryExamplesDefaultResponse extends HttpResponse {
368
- // (undocumented)
369
- body: ErrorResponseOutput;
370
- // (undocumented)
371
- headers: RawHttpHeaders & LookupDictionaryExamplesDefaultHeaders;
372
- // (undocumented)
373
- status: string;
374
- }
375
-
376
- // @public (undocumented)
377
- export interface LookupDictionaryExamplesHeaderParam {
378
- // (undocumented)
379
- headers?: RawHttpHeadersInput & LookupDictionaryExamplesHeaders;
380
- }
381
-
382
- // @public (undocumented)
383
- export interface LookupDictionaryExamplesHeaders {
384
- "X-ClientTraceId"?: string;
385
- }
386
-
387
- // @public (undocumented)
388
- export type LookupDictionaryExamplesParameters = LookupDictionaryExamplesQueryParam & LookupDictionaryExamplesHeaderParam & LookupDictionaryExamplesBodyParam & RequestParameters;
389
-
390
- // @public (undocumented)
391
- export interface LookupDictionaryExamplesQueryParam {
392
- // (undocumented)
393
- queryParameters: LookupDictionaryExamplesQueryParamProperties;
394
- }
395
-
396
- // @public (undocumented)
397
- export interface LookupDictionaryExamplesQueryParamProperties {
398
- from: string;
399
- to: string;
400
- }
401
-
402
139
  // @public
403
140
  export type ProfanityAction = "NoAction" | "Marked" | "Deleted";
404
141
 
405
142
  // @public
406
143
  export type ProfanityMarker = "Asterisk" | "Tag";
407
144
 
145
+ // @public
146
+ export interface ReferenceTextPair {
147
+ source: string;
148
+ target: string;
149
+ }
150
+
408
151
  // @public (undocumented)
409
152
  export interface Routes {
410
153
  (path: "/languages"): GetSupportedLanguages;
411
154
  (path: "/translate"): Translate;
412
155
  (path: "/transliterate"): Transliterate;
413
- (path: "/breaksentence"): FindSentenceBoundaries;
414
- (path: "/dictionary/lookup"): LookupDictionaryEntries;
415
- (path: "/dictionary/examples"): LookupDictionaryExamples;
416
- }
417
-
418
- // @public
419
- export interface SentenceBoundariesOutput {
420
- srcSentLen: number[];
421
- transSentLen: number[];
422
- }
423
-
424
- // @public
425
- export interface SourceDictionaryLanguageOutput {
426
- dir: LanguageDirectionalityOutput;
427
- name: string;
428
- nativeName: string;
429
- translations: Array<TargetDictionaryLanguageOutput>;
430
- }
431
-
432
- // @public
433
- export interface SourceTextOutput {
434
- text: string;
435
- }
436
-
437
- // @public
438
- export interface TargetDictionaryLanguageOutput {
439
- code: string;
440
- dir: LanguageDirectionalityOutput;
441
- name: string;
442
- nativeName: string;
443
156
  }
444
157
 
445
158
  // @public (undocumented)
@@ -465,16 +178,21 @@ export interface Translate200Headers {
465
178
  // @public
466
179
  export interface Translate200Response extends HttpResponse {
467
180
  // (undocumented)
468
- body: Array<TranslatedTextItemOutput>;
181
+ body: TranslationResultOutput;
469
182
  // (undocumented)
470
183
  headers: RawHttpHeaders & Translate200Headers;
471
184
  // (undocumented)
472
185
  status: "200";
473
186
  }
474
187
 
188
+ // @public
189
+ export interface TranslateBody {
190
+ inputs: Array<TranslateInputItem>;
191
+ }
192
+
475
193
  // @public (undocumented)
476
194
  export interface TranslateBodyParam {
477
- body: Array<InputTextItem>;
195
+ body: TranslateBody;
478
196
  }
479
197
 
480
198
  // @public (undocumented)
@@ -492,16 +210,10 @@ export interface TranslateDefaultResponse extends HttpResponse {
492
210
  status: string;
493
211
  }
494
212
 
495
- // @public
496
- export interface TranslatedTextAlignmentOutput {
497
- proj: string;
498
- }
499
-
500
213
  // @public
501
214
  export interface TranslatedTextItemOutput {
502
215
  detectedLanguage?: DetectedLanguageOutput;
503
- sourceText?: SourceTextOutput;
504
- translations: Array<TranslationTextOutput>;
216
+ readonly translations: Array<TranslationTextOutput>;
505
217
  }
506
218
 
507
219
  // @public (undocumented)
@@ -515,45 +227,55 @@ export interface TranslateHeaders {
515
227
  "X-ClientTraceId"?: string;
516
228
  }
517
229
 
518
- // @public (undocumented)
519
- export type TranslateParameters = TranslateQueryParam & TranslateHeaderParam & TranslateBodyParam & RequestParameters;
520
-
521
- // @public (undocumented)
522
- export interface TranslateQueryParam {
523
- // (undocumented)
524
- queryParameters: TranslateQueryParamProperties;
230
+ // @public
231
+ export interface TranslateInputItem {
232
+ language?: string;
233
+ script?: string;
234
+ targets: Array<TranslationTarget>;
235
+ text: string;
236
+ textType?: TextType;
525
237
  }
526
238
 
527
239
  // @public (undocumented)
528
- export interface TranslateQueryParamProperties {
529
- allowFallback?: boolean;
530
- category?: string;
531
- from?: string;
532
- fromScript?: string;
533
- includeAlignment?: boolean;
534
- includeSentenceLength?: boolean;
535
- profanityAction?: ProfanityAction;
536
- profanityMarker?: ProfanityMarker;
537
- suggestedFrom?: string;
538
- textType?: TextType;
539
- to: string;
540
- toScript?: string;
541
- }
240
+ export type TranslateParameters = TranslateHeaderParam & TranslateBodyParam & RequestParameters;
542
241
 
543
242
  // @public
544
243
  export interface TranslationLanguageOutput {
545
244
  dir: LanguageDirectionalityOutput;
245
+ readonly models: string[];
546
246
  name: string;
547
247
  nativeName: string;
548
248
  }
549
249
 
250
+ // @public
251
+ export interface TranslationResultOutput {
252
+ readonly value: Array<TranslatedTextItemOutput>;
253
+ }
254
+
255
+ // @public
256
+ export interface TranslationTarget {
257
+ adaptiveDatasetId?: string;
258
+ allowFallback?: boolean;
259
+ deploymentName?: string;
260
+ gender?: string;
261
+ grade?: string;
262
+ language: string;
263
+ profanityAction?: ProfanityAction;
264
+ profanityMarker?: ProfanityMarker;
265
+ referenceTextPairs?: Array<ReferenceTextPair>;
266
+ script?: string;
267
+ tone?: string;
268
+ }
269
+
550
270
  // @public
551
271
  export interface TranslationTextOutput {
552
- alignment?: TranslatedTextAlignmentOutput;
553
- sentLen?: SentenceBoundariesOutput;
272
+ instructionTokens?: number;
273
+ language: string;
274
+ responseTokens?: number;
275
+ sourceCharacters?: number;
276
+ sourceTokens?: number;
277
+ targetTokens?: number;
554
278
  text: string;
555
- to: string;
556
- transliteration?: TransliteratedTextOutput;
557
279
  }
558
280
 
559
281
  // @public (undocumented)
@@ -592,16 +314,21 @@ export interface Transliterate200Headers {
592
314
  // @public
593
315
  export interface Transliterate200Response extends HttpResponse {
594
316
  // (undocumented)
595
- body: Array<TransliteratedTextOutput>;
317
+ body: TransliterateResultOutput;
596
318
  // (undocumented)
597
319
  headers: RawHttpHeaders & Transliterate200Headers;
598
320
  // (undocumented)
599
321
  status: "200";
600
322
  }
601
323
 
324
+ // @public
325
+ export interface TransliterateBody {
326
+ inputs: Array<InputTextItem>;
327
+ }
328
+
602
329
  // @public (undocumented)
603
330
  export interface TransliterateBodyParam {
604
- body: Array<InputTextItem>;
331
+ body: TransliterateBody;
605
332
  }
606
333
 
607
334
  // @public (undocumented)
@@ -652,11 +379,16 @@ export interface TransliterateQueryParamProperties {
652
379
  toScript: string;
653
380
  }
654
381
 
382
+ // @public
383
+ export interface TransliterateResultOutput {
384
+ readonly value: Array<TransliteratedTextOutput>;
385
+ }
386
+
655
387
  // @public
656
388
  export interface TransliterationLanguageOutput {
657
389
  name: string;
658
390
  nativeName: string;
659
- scripts: Array<TransliterableScriptOutput>;
391
+ readonly scripts: Array<TransliterableScriptOutput>;
660
392
  }
661
393
 
662
394
  // (No @packageDocumentation comment for this package)
@@ -1,2 +0,0 @@
1
- export declare function buildMultiCollection(items: string[], parameterName: string): string;
2
- //# sourceMappingURL=serializeHelper.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"serializeHelper.d.ts","sourceRoot":"","sources":["../../src/serializeHelper.ts"],"names":[],"mappings":"AAGA,wBAAgB,oBAAoB,CAAC,KAAK,EAAE,MAAM,EAAE,EAAE,aAAa,EAAE,MAAM,GAAG,MAAM,CASnF"}
@@ -1,13 +0,0 @@
1
- // Copyright (c) Microsoft Corporation.
2
- // Licensed under the MIT License.
3
- export function buildMultiCollection(items, parameterName) {
4
- return items
5
- .map((item, index) => {
6
- if (index === 0) {
7
- return item;
8
- }
9
- return `${parameterName}=${item}`;
10
- })
11
- .join("&");
12
- }
13
- //# sourceMappingURL=serializeHelper.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"serializeHelper.js","sourceRoot":"","sources":["../../src/serializeHelper.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,MAAM,UAAU,oBAAoB,CAAC,KAAe,EAAE,aAAqB;IACzE,OAAO,KAAK;SACT,GAAG,CAAC,CAAC,IAAI,EAAE,KAAK,EAAE,EAAE;QACnB,IAAI,KAAK,KAAK,CAAC,EAAE,CAAC;YAChB,OAAO,IAAI,CAAC;QACd,CAAC;QACD,OAAO,GAAG,aAAa,IAAI,IAAI,EAAE,CAAC;IACpC,CAAC,CAAC;SACD,IAAI,CAAC,GAAG,CAAC,CAAC;AACf,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nexport function buildMultiCollection(items: string[], parameterName: string): string {\n return items\n .map((item, index) => {\n if (index === 0) {\n return item;\n }\n return `${parameterName}=${item}`;\n })\n .join(\"&\");\n}\n"]}
@@ -1,2 +0,0 @@
1
- export declare function buildMultiCollection(items: string[], parameterName: string): string;
2
- //# sourceMappingURL=serializeHelper.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"serializeHelper.d.ts","sourceRoot":"","sources":["../../src/serializeHelper.ts"],"names":[],"mappings":"AAGA,wBAAgB,oBAAoB,CAAC,KAAK,EAAE,MAAM,EAAE,EAAE,aAAa,EAAE,MAAM,GAAG,MAAM,CASnF"}
@@ -1,16 +0,0 @@
1
- "use strict";
2
- // Copyright (c) Microsoft Corporation.
3
- // Licensed under the MIT License.
4
- Object.defineProperty(exports, "__esModule", { value: true });
5
- exports.buildMultiCollection = buildMultiCollection;
6
- function buildMultiCollection(items, parameterName) {
7
- return items
8
- .map((item, index) => {
9
- if (index === 0) {
10
- return item;
11
- }
12
- return `${parameterName}=${item}`;
13
- })
14
- .join("&");
15
- }
16
- //# sourceMappingURL=serializeHelper.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"serializeHelper.js","sourceRoot":"","sources":["../../src/serializeHelper.ts"],"names":[],"mappings":";AAAA,uCAAuC;AACvC,kCAAkC;;AAElC,oDASC;AATD,SAAgB,oBAAoB,CAAC,KAAe,EAAE,aAAqB;IACzE,OAAO,KAAK;SACT,GAAG,CAAC,CAAC,IAAI,EAAE,KAAK,EAAE,EAAE;QACnB,IAAI,KAAK,KAAK,CAAC,EAAE,CAAC;YAChB,OAAO,IAAI,CAAC;QACd,CAAC;QACD,OAAO,GAAG,aAAa,IAAI,IAAI,EAAE,CAAC;IACpC,CAAC,CAAC;SACD,IAAI,CAAC,GAAG,CAAC,CAAC;AACf,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nexport function buildMultiCollection(items: string[], parameterName: string): string {\n return items\n .map((item, index) => {\n if (index === 0) {\n return item;\n }\n return `${parameterName}=${item}`;\n })\n .join(\"&\");\n}\n"]}
@@ -1,2 +0,0 @@
1
- export declare function buildMultiCollection(items: string[], parameterName: string): string;
2
- //# sourceMappingURL=serializeHelper.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"serializeHelper.d.ts","sourceRoot":"","sources":["../../src/serializeHelper.ts"],"names":[],"mappings":"AAGA,wBAAgB,oBAAoB,CAAC,KAAK,EAAE,MAAM,EAAE,EAAE,aAAa,EAAE,MAAM,GAAG,MAAM,CASnF"}
@@ -1,13 +0,0 @@
1
- // Copyright (c) Microsoft Corporation.
2
- // Licensed under the MIT License.
3
- export function buildMultiCollection(items, parameterName) {
4
- return items
5
- .map((item, index) => {
6
- if (index === 0) {
7
- return item;
8
- }
9
- return `${parameterName}=${item}`;
10
- })
11
- .join("&");
12
- }
13
- //# sourceMappingURL=serializeHelper.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"serializeHelper.js","sourceRoot":"","sources":["../../src/serializeHelper.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,MAAM,UAAU,oBAAoB,CAAC,KAAe,EAAE,aAAqB;IACzE,OAAO,KAAK;SACT,GAAG,CAAC,CAAC,IAAI,EAAE,KAAK,EAAE,EAAE;QACnB,IAAI,KAAK,KAAK,CAAC,EAAE,CAAC;YAChB,OAAO,IAAI,CAAC;QACd,CAAC;QACD,OAAO,GAAG,aAAa,IAAI,IAAI,EAAE,CAAC;IACpC,CAAC,CAAC;SACD,IAAI,CAAC,GAAG,CAAC,CAAC;AACf,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nexport function buildMultiCollection(items: string[], parameterName: string): string {\n return items\n .map((item, index) => {\n if (index === 0) {\n return item;\n }\n return `${parameterName}=${item}`;\n })\n .join(\"&\");\n}\n"]}
@@ -1,2 +0,0 @@
1
- export declare function buildMultiCollection(items: string[], parameterName: string): string;
2
- //# sourceMappingURL=serializeHelper.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"serializeHelper.d.ts","sourceRoot":"","sources":["../../src/serializeHelper.ts"],"names":[],"mappings":"AAGA,wBAAgB,oBAAoB,CAAC,KAAK,EAAE,MAAM,EAAE,EAAE,aAAa,EAAE,MAAM,GAAG,MAAM,CASnF"}
@@ -1,13 +0,0 @@
1
- // Copyright (c) Microsoft Corporation.
2
- // Licensed under the MIT License.
3
- export function buildMultiCollection(items, parameterName) {
4
- return items
5
- .map((item, index) => {
6
- if (index === 0) {
7
- return item;
8
- }
9
- return `${parameterName}=${item}`;
10
- })
11
- .join("&");
12
- }
13
- //# sourceMappingURL=serializeHelper.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"serializeHelper.js","sourceRoot":"","sources":["../../src/serializeHelper.ts"],"names":[],"mappings":"AAAA,uCAAuC;AACvC,kCAAkC;AAElC,MAAM,UAAU,oBAAoB,CAAC,KAAe,EAAE,aAAqB;IACzE,OAAO,KAAK;SACT,GAAG,CAAC,CAAC,IAAI,EAAE,KAAK,EAAE,EAAE;QACnB,IAAI,KAAK,KAAK,CAAC,EAAE,CAAC;YAChB,OAAO,IAAI,CAAC;QACd,CAAC;QACD,OAAO,GAAG,aAAa,IAAI,IAAI,EAAE,CAAC;IACpC,CAAC,CAAC;SACD,IAAI,CAAC,GAAG,CAAC,CAAC;AACf,CAAC","sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nexport function buildMultiCollection(items: string[], parameterName: string): string {\n return items\n .map((item, index) => {\n if (index === 0) {\n return item;\n }\n return `${parameterName}=${item}`;\n })\n .join(\"&\");\n}\n"]}