@azure/ai-language-text 1.1.0-alpha.20240112.1 → 1.1.0-alpha.20240116.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.
package/dist/index.js CHANGED
@@ -3,6 +3,7 @@
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
5
  var coreAuth = require('@azure/core-auth');
6
+ var tslib = require('tslib');
6
7
  var coreTracing = require('@azure/core-tracing');
7
8
  var logger$1 = require('@azure/logger');
8
9
  var coreClient = require('@azure/core-client');
@@ -153,7 +154,7 @@ function convertToLanguageDetectionInput(inputs, countryHint) {
153
154
  * @internal
154
155
  */
155
156
  function getOperationOptions(options) {
156
- const { abortSignal, includeStatistics, onResponse, requestOptions, serializerOptions, tracingOptions, ...rest } = options;
157
+ const { abortSignal, includeStatistics, onResponse, requestOptions, serializerOptions, tracingOptions } = options, rest = tslib.__rest(options, ["abortSignal", "includeStatistics", "onResponse", "requestOptions", "serializerOptions", "tracingOptions"]);
157
158
  return {
158
159
  options: {
159
160
  abortSignal,
@@ -1676,23 +1677,19 @@ const AnalyzeTextEntityLinkingInput = {
1676
1677
  className: "AnalyzeTextEntityLinkingInput",
1677
1678
  uberParent: "AnalyzeAction",
1678
1679
  polymorphicDiscriminator: AnalyzeAction.type.polymorphicDiscriminator,
1679
- modelProperties: {
1680
- ...AnalyzeAction.type.modelProperties,
1681
- analysisInput: {
1680
+ modelProperties: Object.assign(Object.assign({}, AnalyzeAction.type.modelProperties), { analysisInput: {
1682
1681
  serializedName: "analysisInput",
1683
1682
  type: {
1684
1683
  name: "Composite",
1685
1684
  className: "MultiLanguageAnalysisInput"
1686
1685
  }
1687
- },
1688
- parameters: {
1686
+ }, parameters: {
1689
1687
  serializedName: "parameters",
1690
1688
  type: {
1691
1689
  name: "Composite",
1692
1690
  className: "EntityLinkingAction"
1693
1691
  }
1694
- }
1695
- }
1692
+ } })
1696
1693
  }
1697
1694
  };
1698
1695
  const AnalyzeTextEntityRecognitionInput = {
@@ -1702,23 +1699,19 @@ const AnalyzeTextEntityRecognitionInput = {
1702
1699
  className: "AnalyzeTextEntityRecognitionInput",
1703
1700
  uberParent: "AnalyzeAction",
1704
1701
  polymorphicDiscriminator: AnalyzeAction.type.polymorphicDiscriminator,
1705
- modelProperties: {
1706
- ...AnalyzeAction.type.modelProperties,
1707
- analysisInput: {
1702
+ modelProperties: Object.assign(Object.assign({}, AnalyzeAction.type.modelProperties), { analysisInput: {
1708
1703
  serializedName: "analysisInput",
1709
1704
  type: {
1710
1705
  name: "Composite",
1711
1706
  className: "MultiLanguageAnalysisInput"
1712
1707
  }
1713
- },
1714
- parameters: {
1708
+ }, parameters: {
1715
1709
  serializedName: "parameters",
1716
1710
  type: {
1717
1711
  name: "Composite",
1718
1712
  className: "EntityRecognitionAction"
1719
1713
  }
1720
- }
1721
- }
1714
+ } })
1722
1715
  }
1723
1716
  };
1724
1717
  const AnalyzeTextKeyPhraseExtractionInput = {
@@ -1728,23 +1721,19 @@ const AnalyzeTextKeyPhraseExtractionInput = {
1728
1721
  className: "AnalyzeTextKeyPhraseExtractionInput",
1729
1722
  uberParent: "AnalyzeAction",
1730
1723
  polymorphicDiscriminator: AnalyzeAction.type.polymorphicDiscriminator,
1731
- modelProperties: {
1732
- ...AnalyzeAction.type.modelProperties,
1733
- analysisInput: {
1724
+ modelProperties: Object.assign(Object.assign({}, AnalyzeAction.type.modelProperties), { analysisInput: {
1734
1725
  serializedName: "analysisInput",
1735
1726
  type: {
1736
1727
  name: "Composite",
1737
1728
  className: "MultiLanguageAnalysisInput"
1738
1729
  }
1739
- },
1740
- parameters: {
1730
+ }, parameters: {
1741
1731
  serializedName: "parameters",
1742
1732
  type: {
1743
1733
  name: "Composite",
1744
1734
  className: "KeyPhraseExtractionAction"
1745
1735
  }
1746
- }
1747
- }
1736
+ } })
1748
1737
  }
1749
1738
  };
1750
1739
  const AnalyzeTextPiiEntitiesRecognitionInput = {
@@ -1754,23 +1743,19 @@ const AnalyzeTextPiiEntitiesRecognitionInput = {
1754
1743
  className: "AnalyzeTextPiiEntitiesRecognitionInput",
1755
1744
  uberParent: "AnalyzeAction",
1756
1745
  polymorphicDiscriminator: AnalyzeAction.type.polymorphicDiscriminator,
1757
- modelProperties: {
1758
- ...AnalyzeAction.type.modelProperties,
1759
- analysisInput: {
1746
+ modelProperties: Object.assign(Object.assign({}, AnalyzeAction.type.modelProperties), { analysisInput: {
1760
1747
  serializedName: "analysisInput",
1761
1748
  type: {
1762
1749
  name: "Composite",
1763
1750
  className: "MultiLanguageAnalysisInput"
1764
1751
  }
1765
- },
1766
- parameters: {
1752
+ }, parameters: {
1767
1753
  serializedName: "parameters",
1768
1754
  type: {
1769
1755
  name: "Composite",
1770
1756
  className: "PiiEntityRecognitionAction"
1771
1757
  }
1772
- }
1773
- }
1758
+ } })
1774
1759
  }
1775
1760
  };
1776
1761
  const AnalyzeTextLanguageDetectionInput = {
@@ -1780,23 +1765,19 @@ const AnalyzeTextLanguageDetectionInput = {
1780
1765
  className: "AnalyzeTextLanguageDetectionInput",
1781
1766
  uberParent: "AnalyzeAction",
1782
1767
  polymorphicDiscriminator: AnalyzeAction.type.polymorphicDiscriminator,
1783
- modelProperties: {
1784
- ...AnalyzeAction.type.modelProperties,
1785
- analysisInput: {
1768
+ modelProperties: Object.assign(Object.assign({}, AnalyzeAction.type.modelProperties), { analysisInput: {
1786
1769
  serializedName: "analysisInput",
1787
1770
  type: {
1788
1771
  name: "Composite",
1789
1772
  className: "LanguageDetectionAnalysisInput"
1790
1773
  }
1791
- },
1792
- parameters: {
1774
+ }, parameters: {
1793
1775
  serializedName: "parameters",
1794
1776
  type: {
1795
1777
  name: "Composite",
1796
1778
  className: "LanguageDetectionAction"
1797
1779
  }
1798
- }
1799
- }
1780
+ } })
1800
1781
  }
1801
1782
  };
1802
1783
  const AnalyzeTextSentimentAnalysisInput = {
@@ -1806,23 +1787,19 @@ const AnalyzeTextSentimentAnalysisInput = {
1806
1787
  className: "AnalyzeTextSentimentAnalysisInput",
1807
1788
  uberParent: "AnalyzeAction",
1808
1789
  polymorphicDiscriminator: AnalyzeAction.type.polymorphicDiscriminator,
1809
- modelProperties: {
1810
- ...AnalyzeAction.type.modelProperties,
1811
- analysisInput: {
1790
+ modelProperties: Object.assign(Object.assign({}, AnalyzeAction.type.modelProperties), { analysisInput: {
1812
1791
  serializedName: "analysisInput",
1813
1792
  type: {
1814
1793
  name: "Composite",
1815
1794
  className: "MultiLanguageAnalysisInput"
1816
1795
  }
1817
- },
1818
- parameters: {
1796
+ }, parameters: {
1819
1797
  serializedName: "parameters",
1820
1798
  type: {
1821
1799
  name: "Composite",
1822
1800
  className: "SentimentAnalysisAction"
1823
1801
  }
1824
- }
1825
- }
1802
+ } })
1826
1803
  }
1827
1804
  };
1828
1805
  const SentimentTaskResult = {
@@ -1832,16 +1809,13 @@ const SentimentTaskResult = {
1832
1809
  className: "SentimentTaskResult",
1833
1810
  uberParent: "AnalyzeTextTaskResult",
1834
1811
  polymorphicDiscriminator: AnalyzeTextTaskResult.type.polymorphicDiscriminator,
1835
- modelProperties: {
1836
- ...AnalyzeTextTaskResult.type.modelProperties,
1837
- results: {
1812
+ modelProperties: Object.assign(Object.assign({}, AnalyzeTextTaskResult.type.modelProperties), { results: {
1838
1813
  serializedName: "results",
1839
1814
  type: {
1840
1815
  name: "Composite",
1841
1816
  className: "SentimentResponse"
1842
1817
  }
1843
- }
1844
- }
1818
+ } })
1845
1819
  }
1846
1820
  };
1847
1821
  const EntitiesTaskResult = {
@@ -1851,16 +1825,13 @@ const EntitiesTaskResult = {
1851
1825
  className: "EntitiesTaskResult",
1852
1826
  uberParent: "AnalyzeTextTaskResult",
1853
1827
  polymorphicDiscriminator: AnalyzeTextTaskResult.type.polymorphicDiscriminator,
1854
- modelProperties: {
1855
- ...AnalyzeTextTaskResult.type.modelProperties,
1856
- results: {
1828
+ modelProperties: Object.assign(Object.assign({}, AnalyzeTextTaskResult.type.modelProperties), { results: {
1857
1829
  serializedName: "results",
1858
1830
  type: {
1859
1831
  name: "Composite",
1860
1832
  className: "EntitiesResult"
1861
1833
  }
1862
- }
1863
- }
1834
+ } })
1864
1835
  }
1865
1836
  };
1866
1837
  const EntityLinkingTaskResult = {
@@ -1870,16 +1841,13 @@ const EntityLinkingTaskResult = {
1870
1841
  className: "EntityLinkingTaskResult",
1871
1842
  uberParent: "AnalyzeTextTaskResult",
1872
1843
  polymorphicDiscriminator: AnalyzeTextTaskResult.type.polymorphicDiscriminator,
1873
- modelProperties: {
1874
- ...AnalyzeTextTaskResult.type.modelProperties,
1875
- results: {
1844
+ modelProperties: Object.assign(Object.assign({}, AnalyzeTextTaskResult.type.modelProperties), { results: {
1876
1845
  serializedName: "results",
1877
1846
  type: {
1878
1847
  name: "Composite",
1879
1848
  className: "EntityLinkingResult"
1880
1849
  }
1881
- }
1882
- }
1850
+ } })
1883
1851
  }
1884
1852
  };
1885
1853
  const PiiTaskResult = {
@@ -1889,16 +1857,13 @@ const PiiTaskResult = {
1889
1857
  className: "PiiTaskResult",
1890
1858
  uberParent: "AnalyzeTextTaskResult",
1891
1859
  polymorphicDiscriminator: AnalyzeTextTaskResult.type.polymorphicDiscriminator,
1892
- modelProperties: {
1893
- ...AnalyzeTextTaskResult.type.modelProperties,
1894
- results: {
1860
+ modelProperties: Object.assign(Object.assign({}, AnalyzeTextTaskResult.type.modelProperties), { results: {
1895
1861
  serializedName: "results",
1896
1862
  type: {
1897
1863
  name: "Composite",
1898
1864
  className: "PiiResult"
1899
1865
  }
1900
- }
1901
- }
1866
+ } })
1902
1867
  }
1903
1868
  };
1904
1869
  const KeyPhraseTaskResult = {
@@ -1908,16 +1873,13 @@ const KeyPhraseTaskResult = {
1908
1873
  className: "KeyPhraseTaskResult",
1909
1874
  uberParent: "AnalyzeTextTaskResult",
1910
1875
  polymorphicDiscriminator: AnalyzeTextTaskResult.type.polymorphicDiscriminator,
1911
- modelProperties: {
1912
- ...AnalyzeTextTaskResult.type.modelProperties,
1913
- results: {
1876
+ modelProperties: Object.assign(Object.assign({}, AnalyzeTextTaskResult.type.modelProperties), { results: {
1914
1877
  serializedName: "results",
1915
1878
  type: {
1916
1879
  name: "Composite",
1917
1880
  className: "KeyPhraseResult"
1918
1881
  }
1919
- }
1920
- }
1882
+ } })
1921
1883
  }
1922
1884
  };
1923
1885
  const LanguageDetectionTaskResult = {
@@ -1927,16 +1889,13 @@ const LanguageDetectionTaskResult = {
1927
1889
  className: "LanguageDetectionTaskResult",
1928
1890
  uberParent: "AnalyzeTextTaskResult",
1929
1891
  polymorphicDiscriminator: AnalyzeTextTaskResult.type.polymorphicDiscriminator,
1930
- modelProperties: {
1931
- ...AnalyzeTextTaskResult.type.modelProperties,
1932
- results: {
1892
+ modelProperties: Object.assign(Object.assign({}, AnalyzeTextTaskResult.type.modelProperties), { results: {
1933
1893
  serializedName: "results",
1934
1894
  type: {
1935
1895
  name: "Composite",
1936
1896
  className: "LanguageDetectionResult"
1937
1897
  }
1938
- }
1939
- }
1898
+ } })
1940
1899
  }
1941
1900
  };
1942
1901
  const AnalyzeBatchAction = {
@@ -1949,16 +1908,13 @@ const AnalyzeBatchAction = {
1949
1908
  serializedName: "kind",
1950
1909
  clientName: "kind"
1951
1910
  },
1952
- modelProperties: {
1953
- ...BatchActionState.type.modelProperties,
1954
- kind: {
1911
+ modelProperties: Object.assign(Object.assign({}, BatchActionState.type.modelProperties), { kind: {
1955
1912
  serializedName: "kind",
1956
1913
  required: true,
1957
1914
  type: {
1958
1915
  name: "String"
1959
1916
  }
1960
- }
1961
- }
1917
+ } })
1962
1918
  }
1963
1919
  };
1964
1920
  const AnalyzeTextLROResult = {
@@ -1971,76 +1927,59 @@ const AnalyzeTextLROResult = {
1971
1927
  serializedName: "kind",
1972
1928
  clientName: "kind"
1973
1929
  },
1974
- modelProperties: {
1975
- ...TaskState.type.modelProperties,
1976
- ...BatchActionState.type.modelProperties,
1977
- kind: {
1930
+ modelProperties: Object.assign(Object.assign(Object.assign({}, TaskState.type.modelProperties), BatchActionState.type.modelProperties), { kind: {
1978
1931
  serializedName: "kind",
1979
1932
  required: true,
1980
1933
  type: {
1981
1934
  name: "String"
1982
1935
  }
1983
- }
1984
- }
1936
+ } })
1985
1937
  }
1986
1938
  };
1987
1939
  const AnalyzeTextJobState = {
1988
1940
  type: {
1989
1941
  name: "Composite",
1990
1942
  className: "AnalyzeTextJobState",
1991
- modelProperties: {
1992
- ...JobState.type.modelProperties,
1993
- ...TasksState.type.modelProperties,
1994
- ...AnalyzeTextJobStatistics.type.modelProperties
1995
- }
1943
+ modelProperties: Object.assign(Object.assign(Object.assign({}, JobState.type.modelProperties), TasksState.type.modelProperties), AnalyzeTextJobStatistics.type.modelProperties)
1996
1944
  }
1997
1945
  };
1998
1946
  const ActionPrebuilt = {
1999
1947
  type: {
2000
1948
  name: "Composite",
2001
1949
  className: "ActionPrebuilt",
2002
- modelProperties: {
2003
- ...ActionCommon.type.modelProperties,
2004
- modelVersion: {
1950
+ modelProperties: Object.assign(Object.assign({}, ActionCommon.type.modelProperties), { modelVersion: {
2005
1951
  defaultValue: "latest",
2006
1952
  serializedName: "modelVersion",
2007
1953
  type: {
2008
1954
  name: "String"
2009
1955
  }
2010
- }
2011
- }
1956
+ } })
2012
1957
  }
2013
1958
  };
2014
1959
  const ActionCustom = {
2015
1960
  type: {
2016
1961
  name: "Composite",
2017
1962
  className: "ActionCustom",
2018
- modelProperties: {
2019
- ...ActionCommon.type.modelProperties,
2020
- projectName: {
1963
+ modelProperties: Object.assign(Object.assign({}, ActionCommon.type.modelProperties), { projectName: {
2021
1964
  serializedName: "projectName",
2022
1965
  required: true,
2023
1966
  type: {
2024
1967
  name: "String"
2025
1968
  }
2026
- },
2027
- deploymentName: {
1969
+ }, deploymentName: {
2028
1970
  serializedName: "deploymentName",
2029
1971
  required: true,
2030
1972
  type: {
2031
1973
  name: "String"
2032
1974
  }
2033
- }
2034
- }
1975
+ } })
2035
1976
  }
2036
1977
  };
2037
1978
  const CustomEntitiesResult = {
2038
1979
  type: {
2039
1980
  name: "Composite",
2040
1981
  className: "CustomEntitiesResult",
2041
- modelProperties: {
2042
- ...CustomResult.type.modelProperties,
2043
- documents: {
1982
+ modelProperties: Object.assign(Object.assign({}, CustomResult.type.modelProperties), { documents: {
2044
1983
  serializedName: "documents",
2045
1984
  required: true,
2046
1985
  type: {
@@ -2052,17 +1991,14 @@ const CustomEntitiesResult = {
2052
1991
  }
2053
1992
  }
2054
1993
  }
2055
- }
2056
- }
1994
+ } })
2057
1995
  }
2058
1996
  };
2059
1997
  const CustomLabelClassificationResult = {
2060
1998
  type: {
2061
1999
  name: "Composite",
2062
2000
  className: "CustomLabelClassificationResult",
2063
- modelProperties: {
2064
- ...CustomResult.type.modelProperties,
2065
- documents: {
2001
+ modelProperties: Object.assign(Object.assign({}, CustomResult.type.modelProperties), { documents: {
2066
2002
  serializedName: "documents",
2067
2003
  required: true,
2068
2004
  type: {
@@ -2074,17 +2010,14 @@ const CustomLabelClassificationResult = {
2074
2010
  }
2075
2011
  }
2076
2012
  }
2077
- }
2078
- }
2013
+ } })
2079
2014
  }
2080
2015
  };
2081
2016
  const EntitiesDocumentResult = {
2082
2017
  type: {
2083
2018
  name: "Composite",
2084
2019
  className: "EntitiesDocumentResult",
2085
- modelProperties: {
2086
- ...DocumentResult.type.modelProperties,
2087
- entities: {
2020
+ modelProperties: Object.assign(Object.assign({}, DocumentResult.type.modelProperties), { entities: {
2088
2021
  serializedName: "entities",
2089
2022
  required: true,
2090
2023
  type: {
@@ -2096,17 +2029,14 @@ const EntitiesDocumentResult = {
2096
2029
  }
2097
2030
  }
2098
2031
  }
2099
- }
2100
- }
2032
+ } })
2101
2033
  }
2102
2034
  };
2103
2035
  const ClassificationDocumentResult = {
2104
2036
  type: {
2105
2037
  name: "Composite",
2106
2038
  className: "ClassificationDocumentResult",
2107
- modelProperties: {
2108
- ...DocumentResult.type.modelProperties,
2109
- classifications: {
2039
+ modelProperties: Object.assign(Object.assign({}, DocumentResult.type.modelProperties), { classifications: {
2110
2040
  serializedName: "class",
2111
2041
  required: true,
2112
2042
  type: {
@@ -2118,17 +2048,14 @@ const ClassificationDocumentResult = {
2118
2048
  }
2119
2049
  }
2120
2050
  }
2121
- }
2122
- }
2051
+ } })
2123
2052
  }
2124
2053
  };
2125
2054
  const HealthcareEntitiesDocumentResult = {
2126
2055
  type: {
2127
2056
  name: "Composite",
2128
2057
  className: "HealthcareEntitiesDocumentResult",
2129
- modelProperties: {
2130
- ...DocumentResult.type.modelProperties,
2131
- entities: {
2058
+ modelProperties: Object.assign(Object.assign({}, DocumentResult.type.modelProperties), { entities: {
2132
2059
  serializedName: "entities",
2133
2060
  required: true,
2134
2061
  type: {
@@ -2140,8 +2067,7 @@ const HealthcareEntitiesDocumentResult = {
2140
2067
  }
2141
2068
  }
2142
2069
  }
2143
- },
2144
- relations: {
2070
+ }, relations: {
2145
2071
  serializedName: "relations",
2146
2072
  required: true,
2147
2073
  type: {
@@ -2153,32 +2079,27 @@ const HealthcareEntitiesDocumentResult = {
2153
2079
  }
2154
2080
  }
2155
2081
  }
2156
- }
2157
- }
2082
+ } })
2158
2083
  }
2159
2084
  };
2160
2085
  const SentimentDocumentResult = {
2161
2086
  type: {
2162
2087
  name: "Composite",
2163
2088
  className: "SentimentDocumentResult",
2164
- modelProperties: {
2165
- ...DocumentResult.type.modelProperties,
2166
- sentiment: {
2089
+ modelProperties: Object.assign(Object.assign({}, DocumentResult.type.modelProperties), { sentiment: {
2167
2090
  serializedName: "sentiment",
2168
2091
  required: true,
2169
2092
  type: {
2170
2093
  name: "Enum",
2171
2094
  allowedValues: ["positive", "neutral", "negative", "mixed"]
2172
2095
  }
2173
- },
2174
- confidenceScores: {
2096
+ }, confidenceScores: {
2175
2097
  serializedName: "confidenceScores",
2176
2098
  type: {
2177
2099
  name: "Composite",
2178
2100
  className: "SentimentConfidenceScores"
2179
2101
  }
2180
- },
2181
- sentences: {
2102
+ }, sentences: {
2182
2103
  serializedName: "sentences",
2183
2104
  required: true,
2184
2105
  type: {
@@ -2190,17 +2111,14 @@ const SentimentDocumentResult = {
2190
2111
  }
2191
2112
  }
2192
2113
  }
2193
- }
2194
- }
2114
+ } })
2195
2115
  }
2196
2116
  };
2197
2117
  const LinkedEntitiesDocumentResult = {
2198
2118
  type: {
2199
2119
  name: "Composite",
2200
2120
  className: "LinkedEntitiesDocumentResult",
2201
- modelProperties: {
2202
- ...DocumentResult.type.modelProperties,
2203
- entities: {
2121
+ modelProperties: Object.assign(Object.assign({}, DocumentResult.type.modelProperties), { entities: {
2204
2122
  serializedName: "entities",
2205
2123
  required: true,
2206
2124
  type: {
@@ -2212,24 +2130,20 @@ const LinkedEntitiesDocumentResult = {
2212
2130
  }
2213
2131
  }
2214
2132
  }
2215
- }
2216
- }
2133
+ } })
2217
2134
  }
2218
2135
  };
2219
2136
  const PiiEntitiesDocumentResult = {
2220
2137
  type: {
2221
2138
  name: "Composite",
2222
2139
  className: "PiiEntitiesDocumentResult",
2223
- modelProperties: {
2224
- ...DocumentResult.type.modelProperties,
2225
- redactedText: {
2140
+ modelProperties: Object.assign(Object.assign({}, DocumentResult.type.modelProperties), { redactedText: {
2226
2141
  serializedName: "redactedText",
2227
2142
  required: true,
2228
2143
  type: {
2229
2144
  name: "String"
2230
2145
  }
2231
- },
2232
- entities: {
2146
+ }, entities: {
2233
2147
  serializedName: "entities",
2234
2148
  required: true,
2235
2149
  type: {
@@ -2241,17 +2155,14 @@ const PiiEntitiesDocumentResult = {
2241
2155
  }
2242
2156
  }
2243
2157
  }
2244
- }
2245
- }
2158
+ } })
2246
2159
  }
2247
2160
  };
2248
2161
  const ExtractedSummaryDocumentResult = {
2249
2162
  type: {
2250
2163
  name: "Composite",
2251
2164
  className: "ExtractedSummaryDocumentResult",
2252
- modelProperties: {
2253
- ...DocumentResult.type.modelProperties,
2254
- sentences: {
2165
+ modelProperties: Object.assign(Object.assign({}, DocumentResult.type.modelProperties), { sentences: {
2255
2166
  serializedName: "sentences",
2256
2167
  required: true,
2257
2168
  type: {
@@ -2263,17 +2174,14 @@ const ExtractedSummaryDocumentResult = {
2263
2174
  }
2264
2175
  }
2265
2176
  }
2266
- }
2267
- }
2177
+ } })
2268
2178
  }
2269
2179
  };
2270
2180
  const KeyPhrasesDocumentResult = {
2271
2181
  type: {
2272
2182
  name: "Composite",
2273
2183
  className: "KeyPhrasesDocumentResult",
2274
- modelProperties: {
2275
- ...DocumentResult.type.modelProperties,
2276
- keyPhrases: {
2184
+ modelProperties: Object.assign(Object.assign({}, DocumentResult.type.modelProperties), { keyPhrases: {
2277
2185
  serializedName: "keyPhrases",
2278
2186
  required: true,
2279
2187
  type: {
@@ -2284,33 +2192,27 @@ const KeyPhrasesDocumentResult = {
2284
2192
  }
2285
2193
  }
2286
2194
  }
2287
- }
2288
- }
2195
+ } })
2289
2196
  }
2290
2197
  };
2291
2198
  const LanguageDetectionDocumentResult = {
2292
2199
  type: {
2293
2200
  name: "Composite",
2294
2201
  className: "LanguageDetectionDocumentResult",
2295
- modelProperties: {
2296
- ...DocumentResult.type.modelProperties,
2297
- detectedLanguage: {
2202
+ modelProperties: Object.assign(Object.assign({}, DocumentResult.type.modelProperties), { detectedLanguage: {
2298
2203
  serializedName: "detectedLanguage",
2299
2204
  type: {
2300
2205
  name: "Composite",
2301
2206
  className: "DetectedLanguage"
2302
2207
  }
2303
- }
2304
- }
2208
+ } })
2305
2209
  }
2306
2210
  };
2307
2211
  const AbstractiveSummaryDocumentResult = {
2308
2212
  type: {
2309
2213
  name: "Composite",
2310
2214
  className: "AbstractiveSummaryDocumentResult",
2311
- modelProperties: {
2312
- ...DocumentResult.type.modelProperties,
2313
- summaries: {
2215
+ modelProperties: Object.assign(Object.assign({}, DocumentResult.type.modelProperties), { summaries: {
2314
2216
  serializedName: "summaries",
2315
2217
  required: true,
2316
2218
  type: {
@@ -2322,17 +2224,14 @@ const AbstractiveSummaryDocumentResult = {
2322
2224
  }
2323
2225
  }
2324
2226
  }
2325
- }
2326
- }
2227
+ } })
2327
2228
  }
2328
2229
  };
2329
2230
  const HealthcareResult = {
2330
2231
  type: {
2331
2232
  name: "Composite",
2332
2233
  className: "HealthcareResult",
2333
- modelProperties: {
2334
- ...PreBuiltResult.type.modelProperties,
2335
- documents: {
2234
+ modelProperties: Object.assign(Object.assign({}, PreBuiltResult.type.modelProperties), { documents: {
2336
2235
  serializedName: "documents",
2337
2236
  required: true,
2338
2237
  type: {
@@ -2344,17 +2243,14 @@ const HealthcareResult = {
2344
2243
  }
2345
2244
  }
2346
2245
  }
2347
- }
2348
- }
2246
+ } })
2349
2247
  }
2350
2248
  };
2351
2249
  const SentimentResponse = {
2352
2250
  type: {
2353
2251
  name: "Composite",
2354
2252
  className: "SentimentResponse",
2355
- modelProperties: {
2356
- ...PreBuiltResult.type.modelProperties,
2357
- documents: {
2253
+ modelProperties: Object.assign(Object.assign({}, PreBuiltResult.type.modelProperties), { documents: {
2358
2254
  serializedName: "documents",
2359
2255
  required: true,
2360
2256
  type: {
@@ -2366,17 +2262,14 @@ const SentimentResponse = {
2366
2262
  }
2367
2263
  }
2368
2264
  }
2369
- }
2370
- }
2265
+ } })
2371
2266
  }
2372
2267
  };
2373
2268
  const EntitiesResult = {
2374
2269
  type: {
2375
2270
  name: "Composite",
2376
2271
  className: "EntitiesResult",
2377
- modelProperties: {
2378
- ...PreBuiltResult.type.modelProperties,
2379
- documents: {
2272
+ modelProperties: Object.assign(Object.assign({}, PreBuiltResult.type.modelProperties), { documents: {
2380
2273
  serializedName: "documents",
2381
2274
  required: true,
2382
2275
  type: {
@@ -2388,17 +2281,14 @@ const EntitiesResult = {
2388
2281
  }
2389
2282
  }
2390
2283
  }
2391
- }
2392
- }
2284
+ } })
2393
2285
  }
2394
2286
  };
2395
2287
  const EntityLinkingResult = {
2396
2288
  type: {
2397
2289
  name: "Composite",
2398
2290
  className: "EntityLinkingResult",
2399
- modelProperties: {
2400
- ...PreBuiltResult.type.modelProperties,
2401
- documents: {
2291
+ modelProperties: Object.assign(Object.assign({}, PreBuiltResult.type.modelProperties), { documents: {
2402
2292
  serializedName: "documents",
2403
2293
  required: true,
2404
2294
  type: {
@@ -2410,17 +2300,14 @@ const EntityLinkingResult = {
2410
2300
  }
2411
2301
  }
2412
2302
  }
2413
- }
2414
- }
2303
+ } })
2415
2304
  }
2416
2305
  };
2417
2306
  const PiiResult = {
2418
2307
  type: {
2419
2308
  name: "Composite",
2420
2309
  className: "PiiResult",
2421
- modelProperties: {
2422
- ...PreBuiltResult.type.modelProperties,
2423
- documents: {
2310
+ modelProperties: Object.assign(Object.assign({}, PreBuiltResult.type.modelProperties), { documents: {
2424
2311
  serializedName: "documents",
2425
2312
  required: true,
2426
2313
  type: {
@@ -2432,17 +2319,14 @@ const PiiResult = {
2432
2319
  }
2433
2320
  }
2434
2321
  }
2435
- }
2436
- }
2322
+ } })
2437
2323
  }
2438
2324
  };
2439
2325
  const ExtractiveSummarizationResult = {
2440
2326
  type: {
2441
2327
  name: "Composite",
2442
2328
  className: "ExtractiveSummarizationResult",
2443
- modelProperties: {
2444
- ...PreBuiltResult.type.modelProperties,
2445
- documents: {
2329
+ modelProperties: Object.assign(Object.assign({}, PreBuiltResult.type.modelProperties), { documents: {
2446
2330
  serializedName: "documents",
2447
2331
  required: true,
2448
2332
  type: {
@@ -2454,17 +2338,14 @@ const ExtractiveSummarizationResult = {
2454
2338
  }
2455
2339
  }
2456
2340
  }
2457
- }
2458
- }
2341
+ } })
2459
2342
  }
2460
2343
  };
2461
2344
  const KeyPhraseResult = {
2462
2345
  type: {
2463
2346
  name: "Composite",
2464
2347
  className: "KeyPhraseResult",
2465
- modelProperties: {
2466
- ...PreBuiltResult.type.modelProperties,
2467
- documents: {
2348
+ modelProperties: Object.assign(Object.assign({}, PreBuiltResult.type.modelProperties), { documents: {
2468
2349
  serializedName: "documents",
2469
2350
  required: true,
2470
2351
  type: {
@@ -2476,17 +2357,14 @@ const KeyPhraseResult = {
2476
2357
  }
2477
2358
  }
2478
2359
  }
2479
- }
2480
- }
2360
+ } })
2481
2361
  }
2482
2362
  };
2483
2363
  const LanguageDetectionResult = {
2484
2364
  type: {
2485
2365
  name: "Composite",
2486
2366
  className: "LanguageDetectionResult",
2487
- modelProperties: {
2488
- ...PreBuiltResult.type.modelProperties,
2489
- documents: {
2367
+ modelProperties: Object.assign(Object.assign({}, PreBuiltResult.type.modelProperties), { documents: {
2490
2368
  serializedName: "documents",
2491
2369
  required: true,
2492
2370
  type: {
@@ -2498,28 +2376,21 @@ const LanguageDetectionResult = {
2498
2376
  }
2499
2377
  }
2500
2378
  }
2501
- }
2502
- }
2379
+ } })
2503
2380
  }
2504
2381
  };
2505
2382
  const AbstractiveSummarizationResult = {
2506
2383
  type: {
2507
2384
  name: "Composite",
2508
2385
  className: "AbstractiveSummarizationResult",
2509
- modelProperties: {
2510
- ...AbstractiveSummarizationResultBase.type.modelProperties,
2511
- ...PreBuiltResult.type.modelProperties
2512
- }
2386
+ modelProperties: Object.assign(Object.assign({}, AbstractiveSummarizationResultBase.type.modelProperties), PreBuiltResult.type.modelProperties)
2513
2387
  }
2514
2388
  };
2515
2389
  const AbstractiveSummarizationAction = {
2516
2390
  type: {
2517
2391
  name: "Composite",
2518
2392
  className: "AbstractiveSummarizationAction",
2519
- modelProperties: {
2520
- ...AbstractiveSummarizationTaskParametersBase.type.modelProperties,
2521
- ...ActionPrebuilt.type.modelProperties
2522
- }
2393
+ modelProperties: Object.assign(Object.assign({}, AbstractiveSummarizationTaskParametersBase.type.modelProperties), ActionPrebuilt.type.modelProperties)
2523
2394
  }
2524
2395
  };
2525
2396
  const CustomEntitiesLROTask = {
@@ -2529,16 +2400,13 @@ const CustomEntitiesLROTask = {
2529
2400
  className: "CustomEntitiesLROTask",
2530
2401
  uberParent: "AnalyzeBatchAction",
2531
2402
  polymorphicDiscriminator: AnalyzeBatchAction.type.polymorphicDiscriminator,
2532
- modelProperties: {
2533
- ...AnalyzeBatchAction.type.modelProperties,
2534
- parameters: {
2403
+ modelProperties: Object.assign(Object.assign({}, AnalyzeBatchAction.type.modelProperties), { parameters: {
2535
2404
  serializedName: "parameters",
2536
2405
  type: {
2537
2406
  name: "Composite",
2538
2407
  className: "CustomEntityRecognitionAction"
2539
2408
  }
2540
- }
2541
- }
2409
+ } })
2542
2410
  }
2543
2411
  };
2544
2412
  const CustomSingleLabelClassificationLROTask = {
@@ -2548,16 +2416,13 @@ const CustomSingleLabelClassificationLROTask = {
2548
2416
  className: "CustomSingleLabelClassificationLROTask",
2549
2417
  uberParent: "AnalyzeBatchAction",
2550
2418
  polymorphicDiscriminator: AnalyzeBatchAction.type.polymorphicDiscriminator,
2551
- modelProperties: {
2552
- ...AnalyzeBatchAction.type.modelProperties,
2553
- parameters: {
2419
+ modelProperties: Object.assign(Object.assign({}, AnalyzeBatchAction.type.modelProperties), { parameters: {
2554
2420
  serializedName: "parameters",
2555
2421
  type: {
2556
2422
  name: "Composite",
2557
2423
  className: "CustomSingleLabelClassificationAction"
2558
2424
  }
2559
- }
2560
- }
2425
+ } })
2561
2426
  }
2562
2427
  };
2563
2428
  const CustomMultiLabelClassificationLROTask = {
@@ -2567,16 +2432,13 @@ const CustomMultiLabelClassificationLROTask = {
2567
2432
  className: "CustomMultiLabelClassificationLROTask",
2568
2433
  uberParent: "AnalyzeBatchAction",
2569
2434
  polymorphicDiscriminator: AnalyzeBatchAction.type.polymorphicDiscriminator,
2570
- modelProperties: {
2571
- ...AnalyzeBatchAction.type.modelProperties,
2572
- parameters: {
2435
+ modelProperties: Object.assign(Object.assign({}, AnalyzeBatchAction.type.modelProperties), { parameters: {
2573
2436
  serializedName: "parameters",
2574
2437
  type: {
2575
2438
  name: "Composite",
2576
2439
  className: "CustomMultiLabelClassificationAction"
2577
2440
  }
2578
- }
2579
- }
2441
+ } })
2580
2442
  }
2581
2443
  };
2582
2444
  const HealthcareLROTask = {
@@ -2586,16 +2448,13 @@ const HealthcareLROTask = {
2586
2448
  className: "HealthcareLROTask",
2587
2449
  uberParent: "AnalyzeBatchAction",
2588
2450
  polymorphicDiscriminator: AnalyzeBatchAction.type.polymorphicDiscriminator,
2589
- modelProperties: {
2590
- ...AnalyzeBatchAction.type.modelProperties,
2591
- parameters: {
2451
+ modelProperties: Object.assign(Object.assign({}, AnalyzeBatchAction.type.modelProperties), { parameters: {
2592
2452
  serializedName: "parameters",
2593
2453
  type: {
2594
2454
  name: "Composite",
2595
2455
  className: "HealthcareAction"
2596
2456
  }
2597
- }
2598
- }
2457
+ } })
2599
2458
  }
2600
2459
  };
2601
2460
  const SentimentAnalysisLROTask = {
@@ -2605,16 +2464,13 @@ const SentimentAnalysisLROTask = {
2605
2464
  className: "SentimentAnalysisLROTask",
2606
2465
  uberParent: "AnalyzeBatchAction",
2607
2466
  polymorphicDiscriminator: AnalyzeBatchAction.type.polymorphicDiscriminator,
2608
- modelProperties: {
2609
- ...AnalyzeBatchAction.type.modelProperties,
2610
- parameters: {
2467
+ modelProperties: Object.assign(Object.assign({}, AnalyzeBatchAction.type.modelProperties), { parameters: {
2611
2468
  serializedName: "parameters",
2612
2469
  type: {
2613
2470
  name: "Composite",
2614
2471
  className: "SentimentAnalysisAction"
2615
2472
  }
2616
- }
2617
- }
2473
+ } })
2618
2474
  }
2619
2475
  };
2620
2476
  const EntitiesLROTask = {
@@ -2624,16 +2480,13 @@ const EntitiesLROTask = {
2624
2480
  className: "EntitiesLROTask",
2625
2481
  uberParent: "AnalyzeBatchAction",
2626
2482
  polymorphicDiscriminator: AnalyzeBatchAction.type.polymorphicDiscriminator,
2627
- modelProperties: {
2628
- ...AnalyzeBatchAction.type.modelProperties,
2629
- parameters: {
2483
+ modelProperties: Object.assign(Object.assign({}, AnalyzeBatchAction.type.modelProperties), { parameters: {
2630
2484
  serializedName: "parameters",
2631
2485
  type: {
2632
2486
  name: "Composite",
2633
2487
  className: "EntityRecognitionAction"
2634
2488
  }
2635
- }
2636
- }
2489
+ } })
2637
2490
  }
2638
2491
  };
2639
2492
  const EntityLinkingLROTask = {
@@ -2643,16 +2496,13 @@ const EntityLinkingLROTask = {
2643
2496
  className: "EntityLinkingLROTask",
2644
2497
  uberParent: "AnalyzeBatchAction",
2645
2498
  polymorphicDiscriminator: AnalyzeBatchAction.type.polymorphicDiscriminator,
2646
- modelProperties: {
2647
- ...AnalyzeBatchAction.type.modelProperties,
2648
- parameters: {
2499
+ modelProperties: Object.assign(Object.assign({}, AnalyzeBatchAction.type.modelProperties), { parameters: {
2649
2500
  serializedName: "parameters",
2650
2501
  type: {
2651
2502
  name: "Composite",
2652
2503
  className: "EntityLinkingAction"
2653
2504
  }
2654
- }
2655
- }
2505
+ } })
2656
2506
  }
2657
2507
  };
2658
2508
  const PiiLROTask = {
@@ -2662,16 +2512,13 @@ const PiiLROTask = {
2662
2512
  className: "PiiLROTask",
2663
2513
  uberParent: "AnalyzeBatchAction",
2664
2514
  polymorphicDiscriminator: AnalyzeBatchAction.type.polymorphicDiscriminator,
2665
- modelProperties: {
2666
- ...AnalyzeBatchAction.type.modelProperties,
2667
- parameters: {
2515
+ modelProperties: Object.assign(Object.assign({}, AnalyzeBatchAction.type.modelProperties), { parameters: {
2668
2516
  serializedName: "parameters",
2669
2517
  type: {
2670
2518
  name: "Composite",
2671
2519
  className: "PiiEntityRecognitionAction"
2672
2520
  }
2673
- }
2674
- }
2521
+ } })
2675
2522
  }
2676
2523
  };
2677
2524
  const ExtractiveSummarizationLROTask = {
@@ -2681,16 +2528,13 @@ const ExtractiveSummarizationLROTask = {
2681
2528
  className: "ExtractiveSummarizationLROTask",
2682
2529
  uberParent: "AnalyzeBatchAction",
2683
2530
  polymorphicDiscriminator: AnalyzeBatchAction.type.polymorphicDiscriminator,
2684
- modelProperties: {
2685
- ...AnalyzeBatchAction.type.modelProperties,
2686
- parameters: {
2531
+ modelProperties: Object.assign(Object.assign({}, AnalyzeBatchAction.type.modelProperties), { parameters: {
2687
2532
  serializedName: "parameters",
2688
2533
  type: {
2689
2534
  name: "Composite",
2690
2535
  className: "ExtractiveSummarizationAction"
2691
2536
  }
2692
- }
2693
- }
2537
+ } })
2694
2538
  }
2695
2539
  };
2696
2540
  const KeyPhraseLROTask = {
@@ -2700,16 +2544,13 @@ const KeyPhraseLROTask = {
2700
2544
  className: "KeyPhraseLROTask",
2701
2545
  uberParent: "AnalyzeBatchAction",
2702
2546
  polymorphicDiscriminator: AnalyzeBatchAction.type.polymorphicDiscriminator,
2703
- modelProperties: {
2704
- ...AnalyzeBatchAction.type.modelProperties,
2705
- parameters: {
2547
+ modelProperties: Object.assign(Object.assign({}, AnalyzeBatchAction.type.modelProperties), { parameters: {
2706
2548
  serializedName: "parameters",
2707
2549
  type: {
2708
2550
  name: "Composite",
2709
2551
  className: "KeyPhraseExtractionAction"
2710
2552
  }
2711
- }
2712
- }
2553
+ } })
2713
2554
  }
2714
2555
  };
2715
2556
  const AbstractiveSummarizationLROTask = {
@@ -2719,16 +2560,13 @@ const AbstractiveSummarizationLROTask = {
2719
2560
  className: "AbstractiveSummarizationLROTask",
2720
2561
  uberParent: "AnalyzeBatchAction",
2721
2562
  polymorphicDiscriminator: AnalyzeBatchAction.type.polymorphicDiscriminator,
2722
- modelProperties: {
2723
- ...AnalyzeBatchAction.type.modelProperties,
2724
- parameters: {
2563
+ modelProperties: Object.assign(Object.assign({}, AnalyzeBatchAction.type.modelProperties), { parameters: {
2725
2564
  serializedName: "parameters",
2726
2565
  type: {
2727
2566
  name: "Composite",
2728
2567
  className: "AbstractiveSummarizationAction"
2729
2568
  }
2730
- }
2731
- }
2569
+ } })
2732
2570
  }
2733
2571
  };
2734
2572
  const EntityRecognitionLROResult = {
@@ -2738,16 +2576,13 @@ const EntityRecognitionLROResult = {
2738
2576
  className: "EntityRecognitionLROResult",
2739
2577
  uberParent: "AnalyzeTextLROResult",
2740
2578
  polymorphicDiscriminator: AnalyzeTextLROResult.type.polymorphicDiscriminator,
2741
- modelProperties: {
2742
- ...AnalyzeTextLROResult.type.modelProperties,
2743
- results: {
2579
+ modelProperties: Object.assign(Object.assign({}, AnalyzeTextLROResult.type.modelProperties), { results: {
2744
2580
  serializedName: "results",
2745
2581
  type: {
2746
2582
  name: "Composite",
2747
2583
  className: "EntitiesResult"
2748
2584
  }
2749
- }
2750
- }
2585
+ } })
2751
2586
  }
2752
2587
  };
2753
2588
  const CustomEntityRecognitionLROResult = {
@@ -2757,16 +2592,13 @@ const CustomEntityRecognitionLROResult = {
2757
2592
  className: "CustomEntityRecognitionLROResult",
2758
2593
  uberParent: "AnalyzeTextLROResult",
2759
2594
  polymorphicDiscriminator: AnalyzeTextLROResult.type.polymorphicDiscriminator,
2760
- modelProperties: {
2761
- ...AnalyzeTextLROResult.type.modelProperties,
2762
- results: {
2595
+ modelProperties: Object.assign(Object.assign({}, AnalyzeTextLROResult.type.modelProperties), { results: {
2763
2596
  serializedName: "results",
2764
2597
  type: {
2765
2598
  name: "Composite",
2766
2599
  className: "CustomEntitiesResult"
2767
2600
  }
2768
- }
2769
- }
2601
+ } })
2770
2602
  }
2771
2603
  };
2772
2604
  const CustomSingleLabelClassificationLROResult = {
@@ -2776,16 +2608,13 @@ const CustomSingleLabelClassificationLROResult = {
2776
2608
  className: "CustomSingleLabelClassificationLROResult",
2777
2609
  uberParent: "AnalyzeTextLROResult",
2778
2610
  polymorphicDiscriminator: AnalyzeTextLROResult.type.polymorphicDiscriminator,
2779
- modelProperties: {
2780
- ...AnalyzeTextLROResult.type.modelProperties,
2781
- results: {
2611
+ modelProperties: Object.assign(Object.assign({}, AnalyzeTextLROResult.type.modelProperties), { results: {
2782
2612
  serializedName: "results",
2783
2613
  type: {
2784
2614
  name: "Composite",
2785
2615
  className: "CustomLabelClassificationResult"
2786
2616
  }
2787
- }
2788
- }
2617
+ } })
2789
2618
  }
2790
2619
  };
2791
2620
  const CustomMultiLabelClassificationLROResult = {
@@ -2795,16 +2624,13 @@ const CustomMultiLabelClassificationLROResult = {
2795
2624
  className: "CustomMultiLabelClassificationLROResult",
2796
2625
  uberParent: "AnalyzeTextLROResult",
2797
2626
  polymorphicDiscriminator: AnalyzeTextLROResult.type.polymorphicDiscriminator,
2798
- modelProperties: {
2799
- ...AnalyzeTextLROResult.type.modelProperties,
2800
- results: {
2627
+ modelProperties: Object.assign(Object.assign({}, AnalyzeTextLROResult.type.modelProperties), { results: {
2801
2628
  serializedName: "results",
2802
2629
  type: {
2803
2630
  name: "Composite",
2804
2631
  className: "CustomLabelClassificationResult"
2805
2632
  }
2806
- }
2807
- }
2633
+ } })
2808
2634
  }
2809
2635
  };
2810
2636
  const EntityLinkingLROResult = {
@@ -2814,16 +2640,13 @@ const EntityLinkingLROResult = {
2814
2640
  className: "EntityLinkingLROResult",
2815
2641
  uberParent: "AnalyzeTextLROResult",
2816
2642
  polymorphicDiscriminator: AnalyzeTextLROResult.type.polymorphicDiscriminator,
2817
- modelProperties: {
2818
- ...AnalyzeTextLROResult.type.modelProperties,
2819
- results: {
2643
+ modelProperties: Object.assign(Object.assign({}, AnalyzeTextLROResult.type.modelProperties), { results: {
2820
2644
  serializedName: "results",
2821
2645
  type: {
2822
2646
  name: "Composite",
2823
2647
  className: "EntityLinkingResult"
2824
2648
  }
2825
- }
2826
- }
2649
+ } })
2827
2650
  }
2828
2651
  };
2829
2652
  const PiiEntityRecognitionLROResult = {
@@ -2833,16 +2656,13 @@ const PiiEntityRecognitionLROResult = {
2833
2656
  className: "PiiEntityRecognitionLROResult",
2834
2657
  uberParent: "AnalyzeTextLROResult",
2835
2658
  polymorphicDiscriminator: AnalyzeTextLROResult.type.polymorphicDiscriminator,
2836
- modelProperties: {
2837
- ...AnalyzeTextLROResult.type.modelProperties,
2838
- results: {
2659
+ modelProperties: Object.assign(Object.assign({}, AnalyzeTextLROResult.type.modelProperties), { results: {
2839
2660
  serializedName: "results",
2840
2661
  type: {
2841
2662
  name: "Composite",
2842
2663
  className: "PiiResult"
2843
2664
  }
2844
- }
2845
- }
2665
+ } })
2846
2666
  }
2847
2667
  };
2848
2668
  const ExtractiveSummarizationLROResult = {
@@ -2852,16 +2672,13 @@ const ExtractiveSummarizationLROResult = {
2852
2672
  className: "ExtractiveSummarizationLROResult",
2853
2673
  uberParent: "AnalyzeTextLROResult",
2854
2674
  polymorphicDiscriminator: AnalyzeTextLROResult.type.polymorphicDiscriminator,
2855
- modelProperties: {
2856
- ...AnalyzeTextLROResult.type.modelProperties,
2857
- results: {
2675
+ modelProperties: Object.assign(Object.assign({}, AnalyzeTextLROResult.type.modelProperties), { results: {
2858
2676
  serializedName: "results",
2859
2677
  type: {
2860
2678
  name: "Composite",
2861
2679
  className: "ExtractiveSummarizationResult"
2862
2680
  }
2863
- }
2864
- }
2681
+ } })
2865
2682
  }
2866
2683
  };
2867
2684
  const HealthcareLROResult = {
@@ -2871,16 +2688,13 @@ const HealthcareLROResult = {
2871
2688
  className: "HealthcareLROResult",
2872
2689
  uberParent: "AnalyzeTextLROResult",
2873
2690
  polymorphicDiscriminator: AnalyzeTextLROResult.type.polymorphicDiscriminator,
2874
- modelProperties: {
2875
- ...AnalyzeTextLROResult.type.modelProperties,
2876
- results: {
2691
+ modelProperties: Object.assign(Object.assign({}, AnalyzeTextLROResult.type.modelProperties), { results: {
2877
2692
  serializedName: "results",
2878
2693
  type: {
2879
2694
  name: "Composite",
2880
2695
  className: "HealthcareResult"
2881
2696
  }
2882
- }
2883
- }
2697
+ } })
2884
2698
  }
2885
2699
  };
2886
2700
  const SentimentLROResult = {
@@ -2890,16 +2704,13 @@ const SentimentLROResult = {
2890
2704
  className: "SentimentLROResult",
2891
2705
  uberParent: "AnalyzeTextLROResult",
2892
2706
  polymorphicDiscriminator: AnalyzeTextLROResult.type.polymorphicDiscriminator,
2893
- modelProperties: {
2894
- ...AnalyzeTextLROResult.type.modelProperties,
2895
- results: {
2707
+ modelProperties: Object.assign(Object.assign({}, AnalyzeTextLROResult.type.modelProperties), { results: {
2896
2708
  serializedName: "results",
2897
2709
  type: {
2898
2710
  name: "Composite",
2899
2711
  className: "SentimentResponse"
2900
2712
  }
2901
- }
2902
- }
2713
+ } })
2903
2714
  }
2904
2715
  };
2905
2716
  const KeyPhraseExtractionLROResult = {
@@ -2909,16 +2720,13 @@ const KeyPhraseExtractionLROResult = {
2909
2720
  className: "KeyPhraseExtractionLROResult",
2910
2721
  uberParent: "AnalyzeTextLROResult",
2911
2722
  polymorphicDiscriminator: AnalyzeTextLROResult.type.polymorphicDiscriminator,
2912
- modelProperties: {
2913
- ...AnalyzeTextLROResult.type.modelProperties,
2914
- results: {
2723
+ modelProperties: Object.assign(Object.assign({}, AnalyzeTextLROResult.type.modelProperties), { results: {
2915
2724
  serializedName: "results",
2916
2725
  type: {
2917
2726
  name: "Composite",
2918
2727
  className: "KeyPhraseResult"
2919
2728
  }
2920
- }
2921
- }
2729
+ } })
2922
2730
  }
2923
2731
  };
2924
2732
  const AbstractiveSummarizationLROResult = {
@@ -2928,73 +2736,59 @@ const AbstractiveSummarizationLROResult = {
2928
2736
  className: "AbstractiveSummarizationLROResult",
2929
2737
  uberParent: "AnalyzeTextLROResult",
2930
2738
  polymorphicDiscriminator: AnalyzeTextLROResult.type.polymorphicDiscriminator,
2931
- modelProperties: {
2932
- ...AnalyzeTextLROResult.type.modelProperties,
2933
- results: {
2739
+ modelProperties: Object.assign(Object.assign({}, AnalyzeTextLROResult.type.modelProperties), { results: {
2934
2740
  serializedName: "results",
2935
2741
  type: {
2936
2742
  name: "Composite",
2937
2743
  className: "AbstractiveSummarizationResult"
2938
2744
  }
2939
- }
2940
- }
2745
+ } })
2941
2746
  }
2942
2747
  };
2943
2748
  const EntityLinkingAction = {
2944
2749
  type: {
2945
2750
  name: "Composite",
2946
2751
  className: "EntityLinkingAction",
2947
- modelProperties: {
2948
- ...ActionPrebuilt.type.modelProperties,
2949
- stringIndexType: {
2752
+ modelProperties: Object.assign(Object.assign({}, ActionPrebuilt.type.modelProperties), { stringIndexType: {
2950
2753
  defaultValue: "Utf16CodeUnit",
2951
2754
  serializedName: "stringIndexType",
2952
2755
  type: {
2953
2756
  name: "String"
2954
2757
  }
2955
- }
2956
- }
2758
+ } })
2957
2759
  }
2958
2760
  };
2959
2761
  const EntityRecognitionAction = {
2960
2762
  type: {
2961
2763
  name: "Composite",
2962
2764
  className: "EntityRecognitionAction",
2963
- modelProperties: {
2964
- ...ActionPrebuilt.type.modelProperties,
2965
- stringIndexType: {
2765
+ modelProperties: Object.assign(Object.assign({}, ActionPrebuilt.type.modelProperties), { stringIndexType: {
2966
2766
  defaultValue: "Utf16CodeUnit",
2967
2767
  serializedName: "stringIndexType",
2968
2768
  type: {
2969
2769
  name: "String"
2970
2770
  }
2971
- }
2972
- }
2771
+ } })
2973
2772
  }
2974
2773
  };
2975
2774
  const KeyPhraseExtractionAction = {
2976
2775
  type: {
2977
2776
  name: "Composite",
2978
2777
  className: "KeyPhraseExtractionAction",
2979
- modelProperties: {
2980
- ...ActionPrebuilt.type.modelProperties
2981
- }
2778
+ modelProperties: Object.assign({}, ActionPrebuilt.type.modelProperties)
2982
2779
  }
2983
2780
  };
2984
2781
  const PiiEntityRecognitionAction = {
2985
2782
  type: {
2986
2783
  name: "Composite",
2987
2784
  className: "PiiEntityRecognitionAction",
2988
- modelProperties: {
2989
- ...ActionPrebuilt.type.modelProperties,
2990
- domainFilter: {
2785
+ modelProperties: Object.assign(Object.assign({}, ActionPrebuilt.type.modelProperties), { domainFilter: {
2991
2786
  defaultValue: "none",
2992
2787
  serializedName: "domain",
2993
2788
  type: {
2994
2789
  name: "String"
2995
2790
  }
2996
- },
2997
- categoriesFilter: {
2791
+ }, categoriesFilter: {
2998
2792
  constraints: {
2999
2793
  UniqueItems: true
3000
2794
  },
@@ -3007,199 +2801,160 @@ const PiiEntityRecognitionAction = {
3007
2801
  }
3008
2802
  }
3009
2803
  }
3010
- },
3011
- stringIndexType: {
2804
+ }, stringIndexType: {
3012
2805
  defaultValue: "Utf16CodeUnit",
3013
2806
  serializedName: "stringIndexType",
3014
2807
  type: {
3015
2808
  name: "String"
3016
2809
  }
3017
- }
3018
- }
2810
+ } })
3019
2811
  }
3020
2812
  };
3021
2813
  const LanguageDetectionAction = {
3022
2814
  type: {
3023
2815
  name: "Composite",
3024
2816
  className: "LanguageDetectionAction",
3025
- modelProperties: {
3026
- ...ActionPrebuilt.type.modelProperties
3027
- }
2817
+ modelProperties: Object.assign({}, ActionPrebuilt.type.modelProperties)
3028
2818
  }
3029
2819
  };
3030
2820
  const SentimentAnalysisAction = {
3031
2821
  type: {
3032
2822
  name: "Composite",
3033
2823
  className: "SentimentAnalysisAction",
3034
- modelProperties: {
3035
- ...ActionPrebuilt.type.modelProperties,
3036
- includeOpinionMining: {
2824
+ modelProperties: Object.assign(Object.assign({}, ActionPrebuilt.type.modelProperties), { includeOpinionMining: {
3037
2825
  defaultValue: false,
3038
2826
  serializedName: "opinionMining",
3039
2827
  type: {
3040
2828
  name: "Boolean"
3041
2829
  }
3042
- },
3043
- stringIndexType: {
2830
+ }, stringIndexType: {
3044
2831
  defaultValue: "Utf16CodeUnit",
3045
2832
  serializedName: "stringIndexType",
3046
2833
  type: {
3047
2834
  name: "String"
3048
2835
  }
3049
- }
3050
- }
2836
+ } })
3051
2837
  }
3052
2838
  };
3053
2839
  const HealthcareAction = {
3054
2840
  type: {
3055
2841
  name: "Composite",
3056
2842
  className: "HealthcareAction",
3057
- modelProperties: {
3058
- ...ActionPrebuilt.type.modelProperties,
3059
- stringIndexType: {
2843
+ modelProperties: Object.assign(Object.assign({}, ActionPrebuilt.type.modelProperties), { stringIndexType: {
3060
2844
  defaultValue: "Utf16CodeUnit",
3061
2845
  serializedName: "stringIndexType",
3062
2846
  type: {
3063
2847
  name: "String"
3064
2848
  }
3065
- }
3066
- }
2849
+ } })
3067
2850
  }
3068
2851
  };
3069
2852
  const ExtractiveSummarizationAction = {
3070
2853
  type: {
3071
2854
  name: "Composite",
3072
2855
  className: "ExtractiveSummarizationAction",
3073
- modelProperties: {
3074
- ...ActionPrebuilt.type.modelProperties,
3075
- maxSentenceCount: {
2856
+ modelProperties: Object.assign(Object.assign({}, ActionPrebuilt.type.modelProperties), { maxSentenceCount: {
3076
2857
  defaultValue: 3,
3077
2858
  serializedName: "sentenceCount",
3078
2859
  type: {
3079
2860
  name: "Number"
3080
2861
  }
3081
- },
3082
- orderBy: {
2862
+ }, orderBy: {
3083
2863
  defaultValue: "Offset",
3084
2864
  serializedName: "sortBy",
3085
2865
  type: {
3086
2866
  name: "String"
3087
2867
  }
3088
- },
3089
- stringIndexType: {
2868
+ }, stringIndexType: {
3090
2869
  defaultValue: "Utf16CodeUnit",
3091
2870
  serializedName: "stringIndexType",
3092
2871
  type: {
3093
2872
  name: "String"
3094
2873
  }
3095
- }
3096
- }
2874
+ } })
3097
2875
  }
3098
2876
  };
3099
2877
  const CustomEntityRecognitionAction = {
3100
2878
  type: {
3101
2879
  name: "Composite",
3102
2880
  className: "CustomEntityRecognitionAction",
3103
- modelProperties: {
3104
- ...ActionCustom.type.modelProperties,
3105
- stringIndexType: {
2881
+ modelProperties: Object.assign(Object.assign({}, ActionCustom.type.modelProperties), { stringIndexType: {
3106
2882
  defaultValue: "Utf16CodeUnit",
3107
2883
  serializedName: "stringIndexType",
3108
2884
  type: {
3109
2885
  name: "String"
3110
2886
  }
3111
- }
3112
- }
2887
+ } })
3113
2888
  }
3114
2889
  };
3115
2890
  const CustomSingleLabelClassificationAction = {
3116
2891
  type: {
3117
2892
  name: "Composite",
3118
2893
  className: "CustomSingleLabelClassificationAction",
3119
- modelProperties: {
3120
- ...ActionCustom.type.modelProperties
3121
- }
2894
+ modelProperties: Object.assign({}, ActionCustom.type.modelProperties)
3122
2895
  }
3123
2896
  };
3124
2897
  const CustomMultiLabelClassificationAction = {
3125
2898
  type: {
3126
2899
  name: "Composite",
3127
2900
  className: "CustomMultiLabelClassificationAction",
3128
- modelProperties: {
3129
- ...ActionCustom.type.modelProperties
3130
- }
2901
+ modelProperties: Object.assign({}, ActionCustom.type.modelProperties)
3131
2902
  }
3132
2903
  };
3133
2904
  const CustomEntitiesResultDocumentsItem = {
3134
2905
  type: {
3135
2906
  name: "Composite",
3136
2907
  className: "CustomEntitiesResultDocumentsItem",
3137
- modelProperties: {
3138
- ...EntitiesDocumentResult.type.modelProperties
3139
- }
2908
+ modelProperties: Object.assign({}, EntitiesDocumentResult.type.modelProperties)
3140
2909
  }
3141
2910
  };
3142
2911
  const EntitiesResultDocumentsItem = {
3143
2912
  type: {
3144
2913
  name: "Composite",
3145
2914
  className: "EntitiesResultDocumentsItem",
3146
- modelProperties: {
3147
- ...EntitiesDocumentResult.type.modelProperties
3148
- }
2915
+ modelProperties: Object.assign({}, EntitiesDocumentResult.type.modelProperties)
3149
2916
  }
3150
2917
  };
3151
2918
  const CustomLabelClassificationResultDocumentsItem = {
3152
2919
  type: {
3153
2920
  name: "Composite",
3154
2921
  className: "CustomLabelClassificationResultDocumentsItem",
3155
- modelProperties: {
3156
- ...ClassificationDocumentResult.type.modelProperties
3157
- }
2922
+ modelProperties: Object.assign({}, ClassificationDocumentResult.type.modelProperties)
3158
2923
  }
3159
2924
  };
3160
2925
  const HealthcareResultDocumentsItem = {
3161
2926
  type: {
3162
2927
  name: "Composite",
3163
2928
  className: "HealthcareResultDocumentsItem",
3164
- modelProperties: {
3165
- ...HealthcareEntitiesDocumentResult.type.modelProperties
3166
- }
2929
+ modelProperties: Object.assign({}, HealthcareEntitiesDocumentResult.type.modelProperties)
3167
2930
  }
3168
2931
  };
3169
2932
  const SentimentResponseDocumentsItem = {
3170
2933
  type: {
3171
2934
  name: "Composite",
3172
2935
  className: "SentimentResponseDocumentsItem",
3173
- modelProperties: {
3174
- ...SentimentDocumentResult.type.modelProperties
3175
- }
2936
+ modelProperties: Object.assign({}, SentimentDocumentResult.type.modelProperties)
3176
2937
  }
3177
2938
  };
3178
2939
  const EntityLinkingResultDocumentsItem = {
3179
2940
  type: {
3180
2941
  name: "Composite",
3181
2942
  className: "EntityLinkingResultDocumentsItem",
3182
- modelProperties: {
3183
- ...LinkedEntitiesDocumentResult.type.modelProperties
3184
- }
2943
+ modelProperties: Object.assign({}, LinkedEntitiesDocumentResult.type.modelProperties)
3185
2944
  }
3186
2945
  };
3187
2946
  const PiiResultDocumentsItem = {
3188
2947
  type: {
3189
2948
  name: "Composite",
3190
2949
  className: "PiiResultDocumentsItem",
3191
- modelProperties: {
3192
- ...PiiEntitiesDocumentResult.type.modelProperties
3193
- }
2950
+ modelProperties: Object.assign({}, PiiEntitiesDocumentResult.type.modelProperties)
3194
2951
  }
3195
2952
  };
3196
2953
  const KeyPhraseResultDocumentsItem = {
3197
2954
  type: {
3198
2955
  name: "Composite",
3199
2956
  className: "KeyPhraseResultDocumentsItem",
3200
- modelProperties: {
3201
- ...KeyPhrasesDocumentResult.type.modelProperties
3202
- }
2957
+ modelProperties: Object.assign({}, KeyPhrasesDocumentResult.type.modelProperties)
3203
2958
  }
3204
2959
  };
3205
2960
  const GeneratedClientAnalyzeBatchHeaders = {
@@ -3513,9 +3268,7 @@ function toTextAnalysisError(errorModel) {
3513
3268
  if (errorModel.innererror !== undefined) {
3514
3269
  return toTextAnalysisError(errorModel.innererror);
3515
3270
  }
3516
- return {
3517
- ...errorModel,
3518
- };
3271
+ return Object.assign({}, errorModel);
3519
3272
  }
3520
3273
  function makeTextAnalysisErrorResult(id, error) {
3521
3274
  return {
@@ -3540,10 +3293,10 @@ function transformDocumentResults(ids, response, options) {
3540
3293
  }
3541
3294
  function toLanguageDetectionResult(docIds, results) {
3542
3295
  return transformDocumentResults(docIds, results, {
3543
- processSuccess: ({ detectedLanguage, ...rest }) => ({
3544
- primaryLanguage: detectedLanguage,
3545
- ...rest,
3546
- }),
3296
+ processSuccess: (_a) => {
3297
+ var { detectedLanguage } = _a, rest = tslib.__rest(_a, ["detectedLanguage"]);
3298
+ return (Object.assign({ primaryLanguage: detectedLanguage }, rest));
3299
+ },
3547
3300
  });
3548
3301
  }
3549
3302
  function toPiiEntityRecognitionResult(docIds, results) {
@@ -3551,10 +3304,10 @@ function toPiiEntityRecognitionResult(docIds, results) {
3551
3304
  }
3552
3305
  function toSentimentAnalysisResult(docIds, results) {
3553
3306
  return transformDocumentResults(docIds, results, {
3554
- processSuccess: ({ sentences, ...rest }) => ({
3555
- ...rest,
3556
- sentences: sentences.map((sentence) => convertGeneratedSentenceSentiment(sentence, sentences)),
3557
- }),
3307
+ processSuccess: (_a) => {
3308
+ var { sentences } = _a, rest = tslib.__rest(_a, ["sentences"]);
3309
+ return (Object.assign(Object.assign({}, rest), { sentences: sentences.map((sentence) => convertGeneratedSentenceSentiment(sentence, sentences)) }));
3310
+ },
3558
3311
  });
3559
3312
  }
3560
3313
  /**
@@ -3566,18 +3319,20 @@ function toSentimentAnalysisResult(docIds, results) {
3566
3319
  * @returns The user-friendly sentence sentiment object.
3567
3320
  * @internal
3568
3321
  */
3569
- function convertGeneratedSentenceSentiment({ targets, assessments: _, ...rest }, sentences) {
3570
- return {
3571
- ...rest,
3572
- opinions: targets?.map(
3322
+ function convertGeneratedSentenceSentiment(_a, sentences) {
3323
+ var _b;
3324
+ var { targets, assessments: _ } = _a, rest = tslib.__rest(_a, ["targets", "assessments"]);
3325
+ return Object.assign(Object.assign({}, rest), { opinions: (_b = targets === null || targets === void 0 ? void 0 : targets.map(
3573
3326
  // eslint-disable-next-line @typescript-eslint/no-shadow
3574
- ({ relations, ...rest }) => ({
3575
- target: rest,
3576
- assessments: relations
3577
- .filter((relation) => relation.relationType === "assessment")
3578
- .map((relation) => convertTargetRelationToAssessmentSentiment(relation, sentences)),
3579
- })) ?? [],
3580
- };
3327
+ (_a) => {
3328
+ var { relations } = _a, rest = tslib.__rest(_a, ["relations"]);
3329
+ return ({
3330
+ target: rest,
3331
+ assessments: relations
3332
+ .filter((relation) => relation.relationType === "assessment")
3333
+ .map((relation) => convertTargetRelationToAssessmentSentiment(relation, sentences)),
3334
+ });
3335
+ })) !== null && _b !== void 0 ? _b : [] });
3581
3336
  }
3582
3337
  /**
3583
3338
  * Converts a target relation object returned by the service to an assessment
@@ -3590,9 +3345,10 @@ function convertGeneratedSentenceSentiment({ targets, assessments: _, ...rest },
3590
3345
  * @internal
3591
3346
  */
3592
3347
  function convertTargetRelationToAssessmentSentiment(targetRelation, sentences) {
3348
+ var _a;
3593
3349
  const assessmentPtr = targetRelation.ref;
3594
3350
  const assessmentIndex = parseAssessmentIndex(assessmentPtr);
3595
- const assessment = sentences?.[assessmentIndex.sentence].assessments?.[assessmentIndex.assessment];
3351
+ const assessment = (_a = sentences === null || sentences === void 0 ? void 0 : sentences[assessmentIndex.sentence].assessments) === null || _a === void 0 ? void 0 : _a[assessmentIndex.assessment];
3596
3352
  if (assessment !== undefined) {
3597
3353
  return assessment;
3598
3354
  }
@@ -3651,11 +3407,12 @@ function appendReadableErrorMessage(currentMessage, innerMessage) {
3651
3407
  * @param error - the incoming error
3652
3408
  */
3653
3409
  function transformError(errorResponse) {
3410
+ var _a;
3654
3411
  const strongErrorResponse = errorResponse;
3655
3412
  if (!strongErrorResponse.response) {
3656
3413
  throw errorResponse;
3657
3414
  }
3658
- const topLevelError = strongErrorResponse.response.parsedBody?.error;
3415
+ const topLevelError = (_a = strongErrorResponse.response.parsedBody) === null || _a === void 0 ? void 0 : _a.error;
3659
3416
  if (!topLevelError)
3660
3417
  return errorResponse;
3661
3418
  let errorMessage = topLevelError.message;
@@ -3689,11 +3446,8 @@ async function throwError(p) {
3689
3446
  }
3690
3447
  function toHealthcareResult(docIds, results) {
3691
3448
  function makeHealthcareEntity(entity) {
3692
- const { dataSources, ...rest } = entity;
3693
- return {
3694
- dataSources: dataSources ?? [],
3695
- ...rest,
3696
- };
3449
+ const { dataSources } = entity, rest = tslib.__rest(entity, ["dataSources"]);
3450
+ return Object.assign({ dataSources: dataSources !== null && dataSources !== void 0 ? dataSources : [] }, rest);
3697
3451
  }
3698
3452
  function makeHealthcareRelation(entities) {
3699
3453
  return ({ entities: generatedEntities, relationType, confidenceScore, }) => ({
@@ -3706,13 +3460,10 @@ function toHealthcareResult(docIds, results) {
3706
3460
  });
3707
3461
  }
3708
3462
  return transformDocumentResults(docIds, results, {
3709
- processSuccess: ({ entities, relations, ...rest }) => {
3463
+ processSuccess: (_a) => {
3464
+ var { entities, relations } = _a, rest = tslib.__rest(_a, ["entities", "relations"]);
3710
3465
  const newEntities = entities.map(makeHealthcareEntity);
3711
- return {
3712
- entities: newEntities,
3713
- entityRelations: relations.map(makeHealthcareRelation(newEntities)),
3714
- ...rest,
3715
- };
3466
+ return Object.assign({ entities: newEntities, entityRelations: relations.map(makeHealthcareRelation(newEntities)) }, rest);
3716
3467
  },
3717
3468
  });
3718
3469
  }
@@ -3732,14 +3483,7 @@ function transformAnalyzeBatchResults(docIds, response = [], errors = []) {
3732
3483
  }
3733
3484
  const { results } = actionData;
3734
3485
  const { modelVersion, statistics } = results;
3735
- return {
3736
- kind,
3737
- results: toSentimentAnalysisResult(docIds, results),
3738
- completedOn,
3739
- ...(actionName ? { actionName } : {}),
3740
- ...(statistics ? { statistics } : {}),
3741
- modelVersion,
3742
- };
3486
+ return Object.assign(Object.assign(Object.assign({ kind, results: toSentimentAnalysisResult(docIds, results), completedOn }, (actionName ? { actionName } : {})), (statistics ? { statistics } : {})), { modelVersion });
3743
3487
  }
3744
3488
  case "EntityRecognitionLROResults": {
3745
3489
  const kind = "EntityRecognition";
@@ -3748,14 +3492,7 @@ function transformAnalyzeBatchResults(docIds, response = [], errors = []) {
3748
3492
  }
3749
3493
  const { results } = actionData;
3750
3494
  const { modelVersion, statistics } = results;
3751
- return {
3752
- kind: "EntityRecognition",
3753
- results: toEntityRecognitionResult(docIds, results),
3754
- completedOn,
3755
- ...(actionName ? { actionName } : {}),
3756
- ...(statistics ? { statistics } : {}),
3757
- modelVersion,
3758
- };
3495
+ return Object.assign(Object.assign(Object.assign({ kind: "EntityRecognition", results: toEntityRecognitionResult(docIds, results), completedOn }, (actionName ? { actionName } : {})), (statistics ? { statistics } : {})), { modelVersion });
3759
3496
  }
3760
3497
  case "PiiEntityRecognitionLROResults": {
3761
3498
  const kind = "PiiEntityRecognition";
@@ -3764,14 +3501,7 @@ function transformAnalyzeBatchResults(docIds, response = [], errors = []) {
3764
3501
  }
3765
3502
  const { results } = actionData;
3766
3503
  const { modelVersion, statistics } = results;
3767
- return {
3768
- kind,
3769
- results: toPiiEntityRecognitionResult(docIds, results),
3770
- completedOn,
3771
- ...(actionName ? { actionName } : {}),
3772
- ...(statistics ? { statistics } : {}),
3773
- modelVersion,
3774
- };
3504
+ return Object.assign(Object.assign(Object.assign({ kind, results: toPiiEntityRecognitionResult(docIds, results), completedOn }, (actionName ? { actionName } : {})), (statistics ? { statistics } : {})), { modelVersion });
3775
3505
  }
3776
3506
  case "KeyPhraseExtractionLROResults": {
3777
3507
  const kind = "KeyPhraseExtraction";
@@ -3780,14 +3510,7 @@ function transformAnalyzeBatchResults(docIds, response = [], errors = []) {
3780
3510
  }
3781
3511
  const { results } = actionData;
3782
3512
  const { modelVersion, statistics } = results;
3783
- return {
3784
- kind,
3785
- results: toKeyPhraseExtractionResult(docIds, results),
3786
- completedOn,
3787
- ...(actionName ? { actionName } : {}),
3788
- ...(statistics ? { statistics } : {}),
3789
- modelVersion,
3790
- };
3513
+ return Object.assign(Object.assign(Object.assign({ kind, results: toKeyPhraseExtractionResult(docIds, results), completedOn }, (actionName ? { actionName } : {})), (statistics ? { statistics } : {})), { modelVersion });
3791
3514
  }
3792
3515
  case "EntityLinkingLROResults": {
3793
3516
  const kind = "EntityLinking";
@@ -3796,14 +3519,7 @@ function transformAnalyzeBatchResults(docIds, response = [], errors = []) {
3796
3519
  }
3797
3520
  const { results } = actionData;
3798
3521
  const { modelVersion, statistics } = results;
3799
- return {
3800
- kind,
3801
- results: toEntityLinkingResult(docIds, results),
3802
- completedOn,
3803
- ...(actionName ? { actionName } : {}),
3804
- ...(statistics ? { statistics } : {}),
3805
- modelVersion,
3806
- };
3522
+ return Object.assign(Object.assign(Object.assign({ kind, results: toEntityLinkingResult(docIds, results), completedOn }, (actionName ? { actionName } : {})), (statistics ? { statistics } : {})), { modelVersion });
3807
3523
  }
3808
3524
  case "HealthcareLROResults": {
3809
3525
  const kind = "Healthcare";
@@ -3812,14 +3528,7 @@ function transformAnalyzeBatchResults(docIds, response = [], errors = []) {
3812
3528
  }
3813
3529
  const { results } = actionData;
3814
3530
  const { modelVersion, statistics } = results;
3815
- return {
3816
- kind,
3817
- results: toHealthcareResult(docIds, results),
3818
- completedOn,
3819
- ...(actionName ? { actionName } : {}),
3820
- ...(statistics ? { statistics } : {}),
3821
- modelVersion,
3822
- };
3531
+ return Object.assign(Object.assign(Object.assign({ kind, results: toHealthcareResult(docIds, results), completedOn }, (actionName ? { actionName } : {})), (statistics ? { statistics } : {})), { modelVersion });
3823
3532
  }
3824
3533
  case "CustomEntityRecognitionLROResults": {
3825
3534
  const kind = "CustomEntityRecognition";
@@ -3828,15 +3537,8 @@ function transformAnalyzeBatchResults(docIds, response = [], errors = []) {
3828
3537
  }
3829
3538
  const { results } = actionData;
3830
3539
  const { deploymentName, projectName, statistics } = results;
3831
- return {
3832
- kind,
3833
- results: transformDocumentResults(docIds, results),
3834
- completedOn,
3835
- ...(actionName ? { actionName } : {}),
3836
- ...(statistics ? { statistics } : {}),
3837
- deploymentName,
3838
- projectName,
3839
- };
3540
+ return Object.assign(Object.assign(Object.assign({ kind, results: transformDocumentResults(docIds, results), completedOn }, (actionName ? { actionName } : {})), (statistics ? { statistics } : {})), { deploymentName,
3541
+ projectName });
3840
3542
  }
3841
3543
  case "CustomSingleLabelClassificationLROResults": {
3842
3544
  const kind = "CustomSingleLabelClassification";
@@ -3845,15 +3547,8 @@ function transformAnalyzeBatchResults(docIds, response = [], errors = []) {
3845
3547
  }
3846
3548
  const { results } = actionData;
3847
3549
  const { deploymentName, projectName, statistics } = results;
3848
- return {
3849
- kind,
3850
- results: transformDocumentResults(docIds, results),
3851
- completedOn,
3852
- ...(actionName ? { actionName } : {}),
3853
- ...(statistics ? { statistics } : {}),
3854
- deploymentName,
3855
- projectName,
3856
- };
3550
+ return Object.assign(Object.assign(Object.assign({ kind, results: transformDocumentResults(docIds, results), completedOn }, (actionName ? { actionName } : {})), (statistics ? { statistics } : {})), { deploymentName,
3551
+ projectName });
3857
3552
  }
3858
3553
  case "CustomMultiLabelClassificationLROResults": {
3859
3554
  const kind = "CustomMultiLabelClassification";
@@ -3862,15 +3557,8 @@ function transformAnalyzeBatchResults(docIds, response = [], errors = []) {
3862
3557
  }
3863
3558
  const { results } = actionData;
3864
3559
  const { deploymentName, projectName, statistics } = results;
3865
- return {
3866
- kind,
3867
- results: transformDocumentResults(docIds, results),
3868
- completedOn,
3869
- ...(actionName ? { actionName } : {}),
3870
- ...(statistics ? { statistics } : {}),
3871
- deploymentName,
3872
- projectName,
3873
- };
3560
+ return Object.assign(Object.assign(Object.assign({ kind, results: transformDocumentResults(docIds, results), completedOn }, (actionName ? { actionName } : {})), (statistics ? { statistics } : {})), { deploymentName,
3561
+ projectName });
3874
3562
  }
3875
3563
  case "ExtractiveSummarizationLROResults": {
3876
3564
  const kind = "ExtractiveSummarization";
@@ -3879,14 +3567,7 @@ function transformAnalyzeBatchResults(docIds, response = [], errors = []) {
3879
3567
  }
3880
3568
  const { results } = actionData;
3881
3569
  const { modelVersion, statistics } = results;
3882
- return {
3883
- kind: "ExtractiveSummarization",
3884
- results: transformDocumentResults(docIds, results),
3885
- completedOn,
3886
- ...(actionName ? { actionName } : {}),
3887
- ...(statistics ? { statistics } : {}),
3888
- modelVersion,
3889
- };
3570
+ return Object.assign(Object.assign(Object.assign({ kind: "ExtractiveSummarization", results: transformDocumentResults(docIds, results), completedOn }, (actionName ? { actionName } : {})), (statistics ? { statistics } : {})), { modelVersion });
3890
3571
  }
3891
3572
  case "AbstractiveSummarizationLROResults": {
3892
3573
  const kind = "AbstractiveSummarization";
@@ -3895,14 +3576,7 @@ function transformAnalyzeBatchResults(docIds, response = [], errors = []) {
3895
3576
  }
3896
3577
  const { results } = actionData;
3897
3578
  const { modelVersion, statistics } = results;
3898
- return {
3899
- kind: "AbstractiveSummarization",
3900
- results: transformDocumentResults(docIds, results),
3901
- completedOn,
3902
- ...(actionName ? { actionName } : {}),
3903
- ...(statistics ? { statistics } : {}),
3904
- modelVersion,
3905
- };
3579
+ return Object.assign(Object.assign(Object.assign({ kind: "AbstractiveSummarization", results: transformDocumentResults(docIds, results), completedOn }, (actionName ? { actionName } : {})), (statistics ? { statistics } : {})), { modelVersion });
3906
3580
  }
3907
3581
  default: {
3908
3582
  throw new Error(`Unsupported results kind: ${resultKind}`);
@@ -3918,7 +3592,7 @@ function toIndexErrorMap(errors) {
3918
3592
  const errorMap = new Map();
3919
3593
  for (const error of errors) {
3920
3594
  const position = extractErrorPointerIndex(error);
3921
- const { target, ...errorWithoutTarget } = error;
3595
+ const errorWithoutTarget = tslib.__rest(error, ["target"]);
3922
3596
  errorMap.set(position, toTextAnalysisError(errorWithoutTarget));
3923
3597
  }
3924
3598
  return errorMap;
@@ -3981,13 +3655,11 @@ const jobStatusOperationSpec$1 = {
3981
3655
  serializer: serializer$2,
3982
3656
  };
3983
3657
  function addOnResponse(options, cb) {
3984
- return {
3985
- ...options,
3986
- onResponse: (rawResponse, response, error) => {
3658
+ return Object.assign(Object.assign({}, options), { onResponse: (rawResponse, response, error) => {
3659
+ var _a;
3987
3660
  cb(rawResponse, response, error);
3988
- options.onResponse?.(rawResponse, response, error);
3989
- },
3990
- };
3661
+ (_a = options.onResponse) === null || _a === void 0 ? void 0 : _a.call(options, rawResponse, response, error);
3662
+ } });
3991
3663
  }
3992
3664
  function logWarnHeader(rawResponse) {
3993
3665
  const warnHeader = rawResponse.headers.get("warn-text");
@@ -4011,11 +3683,8 @@ async function getRawResponse(getResponse, options) {
4011
3683
  }
4012
3684
  async function sendRequest(settings) {
4013
3685
  const { client, opOptions, path, spanStr, spec, tracing, httpMethod = "GET" } = settings;
4014
- return tracing.withSpan(spanStr, opOptions, async (finalOptions) => throwError(getRawResponse((options) => client.sendOperationRequest({ options }, {
4015
- ...spec,
4016
- path,
4017
- httpMethod,
4018
- }), finalOptions)));
3686
+ return tracing.withSpan(spanStr, opOptions, async (finalOptions) => throwError(getRawResponse((options) => client.sendOperationRequest({ options }, Object.assign(Object.assign({}, spec), { path,
3687
+ httpMethod })), finalOptions)));
4019
3688
  }
4020
3689
  /**
4021
3690
  * @internal
@@ -4045,10 +3714,7 @@ function createAnalyzeBatchLro(settings) {
4045
3714
  const { client, commonOptions, documents, initialRequestOptions, pollRequestOptions, tasks, tracing, } = settings;
4046
3715
  return {
4047
3716
  async sendInitialRequest() {
4048
- return tracing.withSpan(`${clientName}.beginAnalyzeBatch`, addOnResponse({
4049
- ...commonOptions,
4050
- ...initialRequestOptions,
4051
- }, logWarnHeader), async (finalOptions) => throwError(getRawResponse((paramOptions) => client.analyzeBatch({
3717
+ return tracing.withSpan(`${clientName}.beginAnalyzeBatch`, addOnResponse(Object.assign(Object.assign({}, commonOptions), initialRequestOptions), logWarnHeader), async (finalOptions) => throwError(getRawResponse((paramOptions) => client.analyzeBatch({
4052
3718
  tasks,
4053
3719
  analysisInput: {
4054
3720
  documents,
@@ -4058,7 +3724,7 @@ function createAnalyzeBatchLro(settings) {
4058
3724
  },
4059
3725
  sendPollRequest: createSendPollRequest({
4060
3726
  client,
4061
- options: { ...commonOptions, ...pollRequestOptions },
3727
+ options: Object.assign(Object.assign({}, commonOptions), pollRequestOptions),
4062
3728
  spanStr: `${clientName}.beginAnalyzeBatch`,
4063
3729
  tracing,
4064
3730
  }),
@@ -4110,7 +3776,7 @@ function processAnalyzeResult(options) {
4110
3776
  spanStr: `${clientName}.beginAnalyzeBatch`,
4111
3777
  // if `top` is set to `undefined`, the default value will not be sent
4112
3778
  // as part of the request.
4113
- opOptions: maxPageSize ? { ...opOptions, top: maxPageSize } : opOptions,
3779
+ opOptions: maxPageSize ? Object.assign(Object.assign({}, opOptions), { top: maxPageSize }) : opOptions,
4114
3780
  path: pageLink,
4115
3781
  tracing,
4116
3782
  });
@@ -4150,12 +3816,9 @@ function createUpdateAnalyzeState(docIds) {
4150
3816
  */
4151
3817
  function createPollerWithCancellation(settings) {
4152
3818
  const { client, options, poller, id, tracing } = settings;
4153
- return {
4154
- ...poller,
4155
- sendCancellationRequest: async () => {
3819
+ return Object.assign(Object.assign({}, poller), { sendCancellationRequest: async () => {
4156
3820
  await tracing.withSpan(`${clientName}.beginAnalyzeBatch`, options, async (finalOptions) => throwError(getRawResponse((paramOptions) => client.analyzeText.cancelJob(id, paramOptions), finalOptions)));
4157
- },
4158
- };
3821
+ } });
4159
3822
  }
4160
3823
 
4161
3824
  /*
@@ -4249,6 +3912,7 @@ class GeneratedClient extends coreClient__namespace.ServiceClient {
4249
3912
  * @param options The parameter options
4250
3913
  */
4251
3914
  constructor(endpoint, options) {
3915
+ var _a, _b;
4252
3916
  if (endpoint === undefined) {
4253
3917
  throw new Error("'endpoint' cannot be null");
4254
3918
  }
@@ -4263,14 +3927,9 @@ class GeneratedClient extends coreClient__namespace.ServiceClient {
4263
3927
  const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix
4264
3928
  ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}`
4265
3929
  : `${packageDetails}`;
4266
- const optionsWithDefaults = {
4267
- ...defaults,
4268
- ...options,
4269
- userAgentOptions: {
3930
+ const optionsWithDefaults = Object.assign(Object.assign(Object.assign({}, defaults), options), { userAgentOptions: {
4270
3931
  userAgentPrefix
4271
- },
4272
- endpoint: options.endpoint ?? options.baseUri ?? "{Endpoint}/language"
4273
- };
3932
+ }, endpoint: (_b = (_a = options.endpoint) !== null && _a !== void 0 ? _a : options.baseUri) !== null && _b !== void 0 ? _b : "{Endpoint}/language" });
4274
3933
  super(optionsWithDefaults);
4275
3934
  // Parameter assignments
4276
3935
  this.endpoint = endpoint;
@@ -4425,19 +4084,15 @@ function textAnalyticsAzureKeyCredentialPolicy(credential) {
4425
4084
  */
4426
4085
  class TextAnalysisClient {
4427
4086
  constructor(endpointUrl, credential, options = {}) {
4428
- const { defaultCountryHint = "us", defaultLanguage = "en", serviceVersion, ...pipelineOptions } = options;
4087
+ const { defaultCountryHint = "us", defaultLanguage = "en", serviceVersion } = options, pipelineOptions = tslib.__rest(options, ["defaultCountryHint", "defaultLanguage", "serviceVersion"]);
4429
4088
  this.defaultCountryHint = defaultCountryHint;
4430
4089
  this.defaultLanguage = defaultLanguage;
4431
- const internalPipelineOptions = {
4432
- ...pipelineOptions,
4433
- ...{
4434
- loggingOptions: {
4435
- logger: logger.info,
4436
- additionalAllowedHeaderNames: ["x-ms-correlation-request-id", "x-ms-request-id"],
4437
- },
4090
+ const internalPipelineOptions = Object.assign(Object.assign(Object.assign({}, pipelineOptions), {
4091
+ loggingOptions: {
4092
+ logger: logger.info,
4093
+ additionalAllowedHeaderNames: ["x-ms-correlation-request-id", "x-ms-request-id"],
4438
4094
  },
4439
- apiVersion: serviceVersion,
4440
- };
4095
+ }), { apiVersion: serviceVersion });
4441
4096
  this._client = new GeneratedClient(endpointUrl, internalPipelineOptions);
4442
4097
  const authPolicy = coreAuth.isTokenCredential(credential)
4443
4098
  ? coreRestPipeline.bearerTokenAuthenticationPolicy({ credential, scopes: DEFAULT_COGNITIVE_SCOPE })
@@ -4487,13 +4142,14 @@ class TextAnalysisClient {
4487
4142
  }
4488
4143
  // implementation
4489
4144
  async beginAnalyzeBatch(actions, documents, languageOrOptions, options = {}) {
4145
+ var _a;
4490
4146
  let realOptions;
4491
4147
  let realInputs;
4492
4148
  if (!Array.isArray(documents) || documents.length === 0) {
4493
4149
  throw new Error("'documents' must be a non-empty array");
4494
4150
  }
4495
4151
  if (isStringArray(documents)) {
4496
- const languageCode = languageOrOptions ?? this.defaultLanguage;
4152
+ const languageCode = (_a = languageOrOptions) !== null && _a !== void 0 ? _a : this.defaultLanguage;
4497
4153
  realInputs = convertToTextDocumentInput(documents, languageCode);
4498
4154
  realOptions = options;
4499
4155
  }
@@ -4501,12 +4157,15 @@ class TextAnalysisClient {
4501
4157
  realInputs = documents;
4502
4158
  realOptions = languageOrOptions;
4503
4159
  }
4504
- const realActions = actions.map(({ kind, actionName, ...rest }) => ({
4505
- kind,
4506
- actionName,
4507
- parameters: rest,
4508
- }));
4509
- const { includeStatistics, updateIntervalInMs, displayName, ...rest } = realOptions;
4160
+ const realActions = actions.map((_a) => {
4161
+ var { kind, actionName } = _a, rest = tslib.__rest(_a, ["kind", "actionName"]);
4162
+ return ({
4163
+ kind,
4164
+ actionName,
4165
+ parameters: rest,
4166
+ });
4167
+ });
4168
+ const { includeStatistics, updateIntervalInMs, displayName } = realOptions, rest = tslib.__rest(realOptions, ["includeStatistics", "updateIntervalInMs", "displayName"]);
4510
4169
  const lro = createAnalyzeBatchLro({
4511
4170
  client: this._client,
4512
4171
  commonOptions: rest,
@@ -4524,7 +4183,7 @@ class TextAnalysisClient {
4524
4183
  client: this._client,
4525
4184
  tracing: this._tracing,
4526
4185
  docIds,
4527
- opOptions: { ...rest, includeStatistics },
4186
+ opOptions: Object.assign(Object.assign({}, rest), { includeStatistics }),
4528
4187
  state,
4529
4188
  }),
4530
4189
  updateState: createUpdateAnalyzeState(docIds),
@@ -4544,11 +4203,11 @@ class TextAnalysisClient {
4544
4203
  }
4545
4204
  // implementation
4546
4205
  async restoreAnalyzeBatchPoller(serializedState, options = {}) {
4547
- const { includeStatistics, updateIntervalInMs, ...rest } = options;
4206
+ const { includeStatistics, updateIntervalInMs } = options, rest = tslib.__rest(options, ["includeStatistics", "updateIntervalInMs"]);
4548
4207
  const docIds = getDocIDsFromState(serializedState);
4549
4208
  const lro = createCreateAnalyzeBatchPollerLro({
4550
4209
  client: this._client,
4551
- options: { ...rest, includeStatistics },
4210
+ options: Object.assign(Object.assign({}, rest), { includeStatistics }),
4552
4211
  tracing: this._tracing,
4553
4212
  });
4554
4213
  const state = { continuationToken: "" };
@@ -4559,7 +4218,7 @@ class TextAnalysisClient {
4559
4218
  client: this._client,
4560
4219
  tracing: this._tracing,
4561
4220
  docIds,
4562
- opOptions: { ...rest, includeStatistics },
4221
+ opOptions: Object.assign(Object.assign({}, rest), { includeStatistics }),
4563
4222
  state,
4564
4223
  }),
4565
4224
  updateState: createUpdateAnalyzeState(),
@@ -5343,7 +5002,7 @@ const AnalyzeBatchActionNames = {
5343
5002
  /**
5344
5003
  * Enum of possible error codes of a {@link TextAnalysisError}.
5345
5004
  */
5346
- const KnownTextAnalysisErrorCode = { ...exports.KnownErrorCode, ...exports.KnownInnerErrorCode };
5005
+ const KnownTextAnalysisErrorCode = Object.assign(Object.assign({}, exports.KnownErrorCode), exports.KnownInnerErrorCode);
5347
5006
 
5348
5007
  Object.defineProperty(exports, "AzureKeyCredential", {
5349
5008
  enumerable: true,