@azure/ai-language-text 1.1.0-alpha.20230411.2 → 1.1.0-alpha.20230508.3

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/README.md CHANGED
@@ -42,8 +42,6 @@ Please see the [Migration Guide](https://github.com/azure/azure-sdk-for-js/blob/
42
42
  * [Abstractive Summarization](https://github.com/azure/azure-sdk-for-js/blob/main/sdk/cognitivelanguage/ai-language-text/Samples.md#abstractive-summarization):
43
43
  To get started, submit a request for access [here](https://aka.ms/applyforgatedsummarizationfeatures).
44
44
  * [Script Detection](https://github.com/azure/azure-sdk-for-js/blob/main/sdk/cognitivelanguage/ai-language-text/Samples.md#language-detection)
45
- * [Automatic Language Detection](https://github.com/azure/azure-sdk-for-js/blob/main/sdk/cognitivelanguage/ai-language-text/Samples.md#automatic-language-detection)
46
- * [Entity Resolutions](https://github.com/azure/azure-sdk-for-js/blob/main/sdk/cognitivelanguage/ai-language-text/Samples.md#entity-resolutions)
47
45
  * [Specifying healthcare document type for better FHIR results](https://github.com/azure/azure-sdk-for-js/blob/main/sdk/cognitivelanguage/ai-language-text/Samples.md#healthcare-analysis)
48
46
 
49
47
 
package/dist/index.js CHANGED
@@ -3343,17 +3343,7 @@ const HealthcareAction = {
3343
3343
  type: {
3344
3344
  name: "Composite",
3345
3345
  className: "HealthcareAction",
3346
- modelProperties: Object.assign(Object.assign({}, ActionPrebuilt.type.modelProperties), { fhirVersion: {
3347
- serializedName: "fhirVersion",
3348
- type: {
3349
- name: "String"
3350
- }
3351
- }, documentType: {
3352
- serializedName: "documentType",
3353
- type: {
3354
- name: "String"
3355
- }
3356
- }, stringIndexType: {
3346
+ modelProperties: Object.assign(Object.assign({}, ActionPrebuilt.type.modelProperties), { stringIndexType: {
3357
3347
  defaultValue: "Utf16CodeUnit",
3358
3348
  serializedName: "stringIndexType",
3359
3349
  type: {
@@ -3956,9 +3946,9 @@ function toHealthcareResult(docIds, results) {
3956
3946
  }
3957
3947
  return transformDocumentResults(docIds, results, {
3958
3948
  processSuccess: (_a) => {
3959
- var { entities, relations, detectedLanguage } = _a, rest = tslib.__rest(_a, ["entities", "relations", "detectedLanguage"]);
3949
+ var { entities, relations } = _a, rest = tslib.__rest(_a, ["entities", "relations"]);
3960
3950
  const newEntities = entities.map(makeHealthcareEntity);
3961
- return Object.assign(Object.assign({ entities: newEntities, entityRelations: relations.map(makeHealthcareRelation(newEntities)) }, (detectedLanguage ? { detectedLanguage: { iso6391Name: detectedLanguage } } : {})), rest);
3951
+ return Object.assign({ entities: newEntities, entityRelations: relations.map(makeHealthcareRelation(newEntities)) }, rest);
3962
3952
  },
3963
3953
  });
3964
3954
  }
@@ -4062,7 +4052,7 @@ function transformAnalyzeBatchResults(docIds, response = [], errors = []) {
4062
4052
  }
4063
4053
  const { results } = actionData;
4064
4054
  const { modelVersion, statistics } = results;
4065
- return Object.assign(Object.assign(Object.assign({ kind, results: transformDocumentResults(docIds, results), completedOn }, (actionName ? { actionName } : {})), (statistics ? { statistics } : {})), { modelVersion });
4055
+ return Object.assign(Object.assign(Object.assign({ kind: "ExtractiveSummarization", results: transformDocumentResults(docIds, results), completedOn }, (actionName ? { actionName } : {})), (statistics ? { statistics } : {})), { modelVersion });
4066
4056
  }
4067
4057
  case "AbstractiveSummarizationLROResults": {
4068
4058
  const kind = "AbstractiveSummarization";
@@ -4071,7 +4061,7 @@ function transformAnalyzeBatchResults(docIds, response = [], errors = []) {
4071
4061
  }
4072
4062
  const { results } = actionData;
4073
4063
  const { modelVersion, statistics } = results;
4074
- return Object.assign(Object.assign(Object.assign({ kind, results: transformDocumentResults(docIds, results), completedOn }, (actionName ? { actionName } : {})), (statistics ? { statistics } : {})), { modelVersion });
4064
+ return Object.assign(Object.assign(Object.assign({ kind: "AbstractiveSummarization", results: transformDocumentResults(docIds, results), completedOn }, (actionName ? { actionName } : {})), (statistics ? { statistics } : {})), { modelVersion });
4075
4065
  }
4076
4066
  default: {
4077
4067
  throw new Error(`Unsupported results kind: ${resultKind}`);
@@ -5297,7 +5287,7 @@ exports.KnownPiiEntityCategory = void 0;
5297
5287
  KnownPiiEntityCategory["Default"] = "Default";
5298
5288
  })(exports.KnownPiiEntityCategory || (exports.KnownPiiEntityCategory = {}));
5299
5289
  /** Known values of {@link ResolutionKind} that the service accepts. */
5300
- exports.KnownResolutionKind = void 0;
5290
+ var KnownResolutionKind;
5301
5291
  (function (KnownResolutionKind) {
5302
5292
  /** BooleanResolution */
5303
5293
  KnownResolutionKind["BooleanResolution"] = "BooleanResolution";
@@ -5329,7 +5319,7 @@ exports.KnownResolutionKind = void 0;
5329
5319
  KnownResolutionKind["NumericRangeResolution"] = "NumericRangeResolution";
5330
5320
  /** TemporalSpanResolution */
5331
5321
  KnownResolutionKind["TemporalSpanResolution"] = "TemporalSpanResolution";
5332
- })(exports.KnownResolutionKind || (exports.KnownResolutionKind = {}));
5322
+ })(KnownResolutionKind || (KnownResolutionKind = {}));
5333
5323
  /** Known values of {@link WarningCode} that the service accepts. */
5334
5324
  var KnownWarningCode;
5335
5325
  (function (KnownWarningCode) {
@@ -5350,28 +5340,6 @@ var KnownFhirVersion;
5350
5340
  /** Four01 */
5351
5341
  KnownFhirVersion["Four01"] = "4.0.1";
5352
5342
  })(KnownFhirVersion || (KnownFhirVersion = {}));
5353
- /** Known values of {@link HealthcareDocumentType} that the service accepts. */
5354
- exports.KnownHealthcareDocumentType = void 0;
5355
- (function (KnownHealthcareDocumentType) {
5356
- /** None */
5357
- KnownHealthcareDocumentType["None"] = "None";
5358
- /** ClinicalTrial */
5359
- KnownHealthcareDocumentType["ClinicalTrial"] = "ClinicalTrial";
5360
- /** DischargeSummary */
5361
- KnownHealthcareDocumentType["DischargeSummary"] = "DischargeSummary";
5362
- /** ProgressNote */
5363
- KnownHealthcareDocumentType["ProgressNote"] = "ProgressNote";
5364
- /** HistoryAndPhysical */
5365
- KnownHealthcareDocumentType["HistoryAndPhysical"] = "HistoryAndPhysical";
5366
- /** Consult */
5367
- KnownHealthcareDocumentType["Consult"] = "Consult";
5368
- /** Imaging */
5369
- KnownHealthcareDocumentType["Imaging"] = "Imaging";
5370
- /** Pathology */
5371
- KnownHealthcareDocumentType["Pathology"] = "Pathology";
5372
- /** ProcedureNote */
5373
- KnownHealthcareDocumentType["ProcedureNote"] = "ProcedureNote";
5374
- })(exports.KnownHealthcareDocumentType || (exports.KnownHealthcareDocumentType = {}));
5375
5343
  /** Known values of {@link HealthcareEntityCategory} that the service accepts. */
5376
5344
  exports.KnownHealthcareEntityCategory = void 0;
5377
5345
  (function (KnownHealthcareEntityCategory) {
@@ -5869,14 +5837,6 @@ const AnalyzeBatchActionNames = {
5869
5837
  CustomSingleLabelClassification: "CustomSingleLabelClassification",
5870
5838
  CustomMultiLabelClassification: "CustomMultiLabelClassification",
5871
5839
  };
5872
- /**
5873
- * Known values of the {@link HealthcareAction.fhirVersion} parameter.
5874
- */
5875
- exports.KnownFhirVersion = void 0;
5876
- (function (KnownFhirVersion) {
5877
- /** 4.0.1 */
5878
- KnownFhirVersion["4.0.1"] = "4.0.1";
5879
- })(exports.KnownFhirVersion || (exports.KnownFhirVersion = {}));
5880
5840
  /**
5881
5841
  * Enum of possible error codes of a {@link TextAnalysisError}.
5882
5842
  */