From a60a1f851b3875669fd51c6122602ed2e063d386 Mon Sep 17 00:00:00 2001 From: Mariana Rios Flores Date: Thu, 3 Dec 2020 16:24:28 -0800 Subject: [PATCH 1/3] first rounds: --- .../Azure.AI.FormRecognizer/src/AccountProperties.cs | 4 ++-- .../Azure.AI.FormRecognizer/src/CopyModelOperation.cs | 3 ++- .../src/CreateComposedModelOperation.cs | 7 +++++-- .../src/CreateCustomFormModelOperation.cs | 9 +++++---- .../src/CustomFormModelProperties.cs | 3 +++ .../Azure.AI.FormRecognizer/src/FieldBoundingBox.cs | 1 - .../Azure.AI.FormRecognizer/src/FieldValueType.cs | 2 +- .../Azure.AI.FormRecognizer/src/TrainingOperation.cs | 3 ++- 8 files changed, 20 insertions(+), 12 deletions(-) diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/AccountProperties.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/AccountProperties.cs index 3814ac927d78c..4ac90b7ca296e 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/AccountProperties.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/AccountProperties.cs @@ -6,7 +6,7 @@ namespace Azure.AI.FormRecognizer.Training { /// - /// Contains general information about a Cognitive Services Account, such as the number + /// Contains general information about the Form Recognizer resource, such as the number /// of models and account limits. /// public class AccountProperties @@ -29,7 +29,7 @@ internal AccountProperties(int customModelCount, int customModelLimit) } /// - /// The current count of trained custom models. + /// The current count of trained custom models in this subscription. /// public int CustomModelCount { get; } diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/CopyModelOperation.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/CopyModelOperation.cs index 694e4ed1a638e..e502a4de87345 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/CopyModelOperation.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/CopyModelOperation.cs @@ -78,7 +78,8 @@ public override CustomFormModelInfo Value public override bool HasValue => _value != null; /// - /// Initializes a new instance of the class. + /// Initializes a new instance of the class which + /// tracks the status of the long-running operation for copying a custom model into a target Form Recognizer resource. /// /// The ID of this operation. /// Model ID in the target Form Recognizer resource. diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/CreateComposedModelOperation.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/CreateComposedModelOperation.cs index 96c69dff455ad..2f3e1c096fc3a 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/CreateComposedModelOperation.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/CreateComposedModelOperation.cs @@ -6,7 +6,8 @@ namespace Azure.AI.FormRecognizer.Training { /// - /// Tracks the status of a long-running operation for training a model from a collection of custom forms. + /// Tracks the status of a long-running operation for creating a composed model from a + /// collection of existing trained models with labels. /// public class CreateComposedModelOperation : CreateCustomFormModelOperation { @@ -14,7 +15,9 @@ internal CreateComposedModelOperation(string location, FormRecognizerRestClient /// - /// Initializes a new instance of the class. + /// Initializes a new instance of the class which + /// tracks the status of a long-running operation for creating a composed model from a + /// collection of existing trained models with labels. /// /// The ID of this operation. /// The client used to check for completion. diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/CreateCustomFormModelOperation.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/CreateCustomFormModelOperation.cs index c1aa33ccc4b72..3bc0fba476f77 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/CreateCustomFormModelOperation.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/CreateCustomFormModelOperation.cs @@ -12,7 +12,7 @@ namespace Azure.AI.FormRecognizer.Training { /// - /// Tracks the status of a long-running operation for training a model from a collection of custom forms. + /// Tracks the status of a long-running operation for creating a custom model. /// public class CreateCustomFormModelOperation : Operation { @@ -73,7 +73,7 @@ public override CustomFormModel Value /// /// /// The last response returned from the server during the lifecycle of this instance. - /// An instance of sends requests to a server in UpdateStatusAsync, UpdateStatus, and other methods. + /// An instance of sends requests to a server in UpdateStatusAsync, UpdateStatus, and other methods. /// Responses from these requests can be accessed using GetRawResponse. /// public override Response GetRawResponse() => _response; @@ -116,7 +116,8 @@ internal CreateCustomFormModelOperation(string location, FormRecognizerRestClien } /// - /// Initializes a new instance of the class. + /// Initializes a new instance of the class which + /// tracks the status of a long-running operation for creating a custom model. /// /// The ID of this operation. /// The client used to check for completion. @@ -159,7 +160,7 @@ private async ValueTask UpdateStatusAsync(bool async, CancellationToke { if (!_hasCompleted) { - using DiagnosticScope scope = _diagnostics.CreateScope($"{nameof(TrainingOperation)}.{nameof(UpdateStatus)}"); + using DiagnosticScope scope = _diagnostics.CreateScope($"{nameof(CreateCustomFormModelOperation)}.{nameof(UpdateStatus)}"); scope.Start(); try diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/CustomFormModelProperties.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/CustomFormModelProperties.cs index 7d0278ba1ed24..653814000e3f4 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/CustomFormModelProperties.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/CustomFormModelProperties.cs @@ -5,6 +5,9 @@ namespace Azure.AI.FormRecognizer.Training { + /// + /// Properties of a model like for example if the model is a composed model. + /// [CodeGenModel("Attributes")] public partial class CustomFormModelProperties { diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FieldBoundingBox.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FieldBoundingBox.cs index 72ee051e8e39a..283c8e5a271da 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FieldBoundingBox.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FieldBoundingBox.cs @@ -5,7 +5,6 @@ using System.Collections.Generic; using System.Drawing; using System.Linq; -using Azure.Core; namespace Azure.AI.FormRecognizer.Models { diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FieldValueType.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FieldValueType.cs index c976754d830d4..d27f6fda93291 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FieldValueType.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FieldValueType.cs @@ -58,7 +58,7 @@ public enum FieldValueType Dictionary, /// - /// Used for type. + /// Used for Selection Mark type. /// SelectionMark } diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/TrainingOperation.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/TrainingOperation.cs index ba4fcbc1cc124..95fbc284fa324 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/TrainingOperation.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/TrainingOperation.cs @@ -13,7 +13,8 @@ public class TrainingOperation : CreateCustomFormModelOperation internal TrainingOperation(string location, FormRecognizerRestClient allOperations, ClientDiagnostics diagnostics) : base(location, allOperations, diagnostics) { } /// - /// Initializes a new instance of the class. + /// Initializes a new instance of the class which + /// tracks the status of a long-running operation for training a model from a collection of custom forms. /// /// The ID of this operation. /// The client used to check for completion. From 2dd2d9d631c3d045fa88507906fdb9c16bafa62b Mon Sep 17 00:00:00 2001 From: Mariana Rios Flores Date: Fri, 4 Dec 2020 12:29:39 -0800 Subject: [PATCH 2/3] improve docstring and cleanup some code --- .../src/FormElement.cs | 2 +- .../src/FormFieldOfT.cs | 3 +- .../Azure.AI.FormRecognizer/src/FormPage.cs | 7 ++- .../src/FormRecognizerClient.cs | 62 ++++++++++++------- .../src/FormRecognizerClientOptions.cs | 3 +- .../src/FormRecognizerModelFactory.cs | 6 +- .../src/FormSelectionMark.cs | 2 +- .../src/FormTableCell.cs | 2 +- .../src/FormTrainingClient.cs | 22 ++++--- .../src/RecognizeBusinessCardsOperation.cs | 4 +- .../src/RecognizeBusinessCardsOptions.cs | 10 ++- .../src/RecognizeContentOperation.cs | 3 +- .../src/RecognizeContentOptions.cs | 10 ++- .../src/RecognizeCustomFormsOperation.cs | 4 +- .../src/RecognizeCustomFormsOptions.cs | 10 ++- .../src/RecognizeInvoicesOperation.cs | 4 +- .../src/RecognizeInvoicesOptions.cs | 10 ++- .../src/RecognizeReceiptsOperation.cs | 4 +- .../src/RecognizeReceiptsOptions.cs | 10 ++- .../src/TrainingFileFilter.cs | 4 +- .../src/TrainingOptions.cs | 8 ++- .../tests/Models/OperationsMockTests.cs | 2 +- ...OutputModelsTrainedWithAndWithoutLabels.cs | 2 +- 23 files changed, 125 insertions(+), 69 deletions(-) diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormElement.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormElement.cs index e4106f087f31a..b89a5b4904d79 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormElement.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormElement.cs @@ -5,7 +5,7 @@ namespace Azure.AI.FormRecognizer.Models { /// /// Represents a form element recognized from the input document. Its text can be a line, - /// a word, the content of a table cell, etc. + /// a word, the content of a table cell, a selection mark, etc. /// public abstract class FormElement { diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormFieldOfT.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormFieldOfT.cs index 135acf87b55e1..c6313b161bcfa 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormFieldOfT.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormFieldOfT.cs @@ -12,7 +12,8 @@ public class FormField #pragma warning restore SA1649 // File name should match first type name { /// - /// Initializes a new instance of the class. + /// Initializes a new instance of the class which + /// represents a field recognized in the input form, where the field's value is of a known type. /// /// The weakly-typed field this instance is associated with. /// The strongly-typed value of this . diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormPage.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormPage.cs index cbf7c12c8215a..b49574c89a0ff 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormPage.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormPage.cs @@ -6,7 +6,8 @@ namespace Azure.AI.FormRecognizer.Models { /// - /// Represents a page recognized from the input document. Contains lines, words, tables and page metadata. + /// Represents a page recognized from the input document. Contains lines, words, tables, + /// selection marks, and page meta data. /// public class FormPage { @@ -41,7 +42,7 @@ internal FormPage(PageResult pageResult, IReadOnlyList readResults, /// The width of the image/PDF in pixels/inches, respectively. /// The height of the image/PDF in pixels/inches, respectively. /// The general orientation of the text in clockwise direction, measured in degrees between (-180, 180]. - /// The unit used by the width, height and properties. For images, the unit is "pixel". For PDF, the unit is "inch". + /// The unit used by the width, height and properties. For images, the unit is "pixel". For PDF, the unit is "inch". /// A list of recognized lines of text. /// A list of recognized tables contained in this page. /// A list of recognized selection marks contained in this page. @@ -79,7 +80,7 @@ internal FormPage(int pageNumber, float width, float height, float textAngle, Le /// /// The unit used by the width, height and properties. For images, the unit is - /// "pixel". For PDF, the unit is "inch". + /// "pixel". For PDF, the unit is "inch". /// public LengthUnit Unit { get; } diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormRecognizerClient.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormRecognizerClient.cs index 3486c10328817..dbe31a967539e 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormRecognizerClient.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormRecognizerClient.cs @@ -14,7 +14,7 @@ namespace Azure.AI.FormRecognizer /// /// The client to use to connect to the Form Recognizer Azure Cognitive Service to recognize /// information from forms and images and extract it into structured data. It provides the ability to analyze receipts, - /// to recognize form content, and to extract fields from custom forms with models trained on custom form types. + /// business cards, invoices, to recognize form content, and to extract fields from custom forms with models trained on custom form types. /// public class FormRecognizerClient { @@ -120,7 +120,8 @@ protected FormRecognizerClient() /// Recognizes layout elements from one or more passed-in forms. /// /// The stream containing one or more forms to recognize elements from. - /// A set of options available for configuring the recognize request. + /// A set of options available for configuring the recognize request. For example, specify the content type of the + /// form, the language of the form, and the custom page numbers in a multi-page document to analyze. /// A controlling the request lifetime. /// A to wait on this long-running operation. Its upon successful /// completion will contain layout elements extracted from the form. @@ -158,7 +159,8 @@ public virtual RecognizeContentOperation StartRecognizeContent(Stream form, Reco /// Recognizes layout elements from one or more passed-in forms. /// /// The stream containing one or more forms to recognize elements from. - /// A set of options available for configuring the recognize request. + /// A set of options available for configuring the recognize request. For example, specify the content type of the + /// form, the language of the form, and the custom page numbers in a multi-page document to analyze. /// A controlling the request lifetime. /// A to wait on this long-running operation. Its upon successful /// completion will contain layout elements extracted from the form. @@ -196,7 +198,8 @@ public virtual async Task StartRecognizeContentAsync( /// Recognizes layout elements from one or more passed-in forms. /// /// The absolute URI of the remote file to recognize elements from. - /// A set of options available for configuring the recognize request. + /// A set of options available for configuring the recognize request. For example, specify the content type of the + /// form, the language of the form, and the custom page numbers in a multi-page document to analyze. /// A controlling the request lifetime. /// A to wait on this long-running operation. Its upon successful /// completion will contain layout elements extracted from the form. @@ -232,7 +235,8 @@ public virtual RecognizeContentOperation StartRecognizeContentFromUri(Uri formUr /// Recognizes layout elements from one or more passed-in forms. /// /// The absolute URI of the remote file to recognize elements from. - /// A set of options available for configuring the recognize request. + /// A set of options available for configuring the recognize request. For example, specify the content type of the + /// form, the language of the form, and the custom page numbers in a multi-page document to analyze. /// A controlling the request lifetime. /// A to wait on this long-running operation. Its upon successful /// completion will contain layout elements extracted from the form. @@ -273,7 +277,8 @@ public virtual async Task StartRecognizeContentFromUr /// See for a list of available fields on a receipt. /// /// The stream containing the one or more receipts to recognize values from. - /// A set of options available for configuring the recognize request. + /// A set of options available for configuring the recognize request. For example, specify the content type of the + /// form, the locale of the form, or whether or not to include form elements. /// A controlling the request lifetime. /// A to wait on this long-running operation. Its upon successful /// completion will contain the extracted receipt. @@ -312,7 +317,8 @@ public virtual async Task StartRecognizeReceiptsAsyn /// See for a list of available fields on a receipt. /// /// The stream containing the one or more receipts to recognize values from. - /// A set of options available for configuring the recognize request. + /// A set of options available for configuring the recognize request. For example, specify the content type of the + /// form, the locale of the form, or whether or not to include form elements. /// A controlling the request lifetime. /// A to wait on this long-running operation. Its upon successful /// completion will contain the extracted receipt. @@ -351,7 +357,8 @@ public virtual RecognizeReceiptsOperation StartRecognizeReceipts(Stream receipt, /// See for a list of available fields on a receipt. /// /// The absolute URI of the remote file to recognize values from. - /// A set of options available for configuring the recognize request. + /// A set of options available for configuring the recognize request. For example, specify the content type of the + /// form, the locale of the form, or whether or not to include form elements. /// A controlling the request lifetime. /// A to wait on this long-running operation. Its upon successful /// completion will contain the extracted receipt. @@ -388,7 +395,8 @@ public virtual async Task StartRecognizeReceiptsFrom /// See for a list of available fields on a receipt. /// /// The absolute URI of the remote file to recognize values from. - /// A set of options available for configuring the recognize request. + /// A set of options available for configuring the recognize request. For example, specify the content type of the + /// form, the locale of the form, or whether or not to include form elements. /// A controlling the request lifetime. /// A to wait on this long-running operation. Its upon successful /// completion will contain the extracted receipt. @@ -429,7 +437,8 @@ public virtual RecognizeReceiptsOperation StartRecognizeReceiptsFromUri(Uri rece /// See for a list of available fields on a business card. /// /// The stream containing the one or more business cards to recognize values from. - /// A set of options available for configuring the recognize request. + /// A set of options available for configuring the recognize request. For example, specify the content type of the + /// form, the locale of the form, or whether or not to include form elements. /// A controlling the request lifetime. /// A to wait on this long-running operation. Its upon successful /// completion will contain the extracted business cards. @@ -468,7 +477,8 @@ public virtual async Task StartRecognizeBusines /// See for a list of available fields on a business card. /// /// The stream containing the one or more business cards to recognize values from. - /// A set of options available for configuring the recognize request. + /// A set of options available for configuring the recognize request. For example, specify the content type of the + /// form, the locale of the form, or whether or not to include form elements. /// A controlling the request lifetime. /// A to wait on this long-running operation. Its upon successful /// completion will contain the extracted business cards. @@ -507,7 +517,8 @@ public virtual RecognizeBusinessCardsOperation StartRecognizeBusinessCards(Strea /// See for a list of available fields on a business card. /// /// The absolute URI of the remote file to recognize values from. - /// A set of options available for configuring the recognize request. + /// A set of options available for configuring the recognize request. For example, specify the content type of the + /// form, the locale of the form, or whether or not to include form elements. /// A controlling the request lifetime. /// A to wait on this long-running operation. Its upon successful /// completion will contain the extracted business cards. @@ -544,7 +555,8 @@ public virtual async Task StartRecognizeBusines /// See for a list of available fields on a business card. /// /// The absolute URI of the remote file to recognize values from. - /// A set of options available for configuring the recognize request. + /// A set of options available for configuring the recognize request. For example, specify the content type of the + /// form, the locale of the form, or whether or not to include form elements. /// A controlling the request lifetime. /// A to wait on this long-running operation. Its upon successful /// completion will contain the extracted business cards. @@ -585,7 +597,8 @@ public virtual RecognizeBusinessCardsOperation StartRecognizeBusinessCardsFromUr /// See for a list of available fields on an invoice. /// /// The stream containing the one or more invoices to recognize values from. - /// A set of options available for configuring the recognize request. + /// A set of options available for configuring the recognize request. For example, specify the content type of the + /// form, the locale of the form, or whether or not to include form elements. /// A controlling the request lifetime. /// A to wait on this long-running operation. Its upon successful /// completion will contain the extracted invoices. @@ -624,7 +637,8 @@ public virtual async Task StartRecognizeInvoicesAsyn /// See for a list of available fields on an invoice. /// /// The stream containing the one or more invoices to recognize values from. - /// A set of options available for configuring the recognize request. + /// A set of options available for configuring the recognize request. For example, specify the content type of the + /// form, the locale of the form, or whether or not to include form elements. /// A controlling the request lifetime. /// A to wait on this long-running operation. Its upon successful /// completion will contain the extracted invoices. @@ -663,7 +677,8 @@ public virtual RecognizeInvoicesOperation StartRecognizeInvoices(Stream invoice, /// See for a list of available fields on an invoice. /// /// The absolute URI of the remote file to recognize values from. - /// A set of options available for configuring the recognize request. + /// A set of options available for configuring the recognize request. For example, specify the content type of the + /// form, the locale of the form, or whether or not to include form elements. /// A controlling the request lifetime. /// A to wait on this long-running operation. Its upon successful /// completion will contain the extracted invoices. @@ -700,7 +715,8 @@ public virtual async Task StartRecognizeInvoicesFrom /// See for a list of available fields on an invoice. /// /// The absolute URI of the remote file to recognize values from. - /// A set of options available for configuring the recognize request. + /// A set of options available for configuring the recognize request. For example, specify the content type of the + /// form, the locale of the form, or whether or not to include form elements. /// A controlling the request lifetime. /// A to wait on this long-running operation. Its upon successful /// completion will contain the extracted invoices. @@ -741,7 +757,8 @@ public virtual RecognizeInvoicesOperation StartRecognizeInvoicesFromUri(Uri invo /// /// The ID of the model to use for recognizing form values. /// The stream containing one or more forms to recognize elements from. - /// A set of options available for configuring the recognize request. + /// A set of options available for configuring the recognize request. For example, specify the content type of the + /// form, or whether or not to include form elements. /// A controlling the request lifetime. /// A to wait on this long-running operation. Its upon successful /// completion will contain recognized pages from the input document. @@ -777,7 +794,8 @@ public virtual RecognizeCustomFormsOperation StartRecognizeCustomForms(string mo /// /// The ID of the model to use for recognizing form values. /// The absolute URI of the remote file to recognize elements from. - /// A set of options available for configuring the recognize request. + /// A set of options available for configuring the recognize request. For example, specify the content type of the + /// form, or whether or not to include form elements. /// A controlling the request lifetime. /// A to wait on this long-running operation. Its upon successful /// completion will contain recognized pages from the input document. @@ -813,7 +831,8 @@ public virtual RecognizeCustomFormsOperation StartRecognizeCustomFormsFromUri(st /// /// The ID of the model to use for recognizing form values. /// The stream containing one or more forms to recognize elements from. - /// A set of options available for configuring the recognize request. + /// A set of options available for configuring the recognize request. For example, specify the content type of the + /// form, or whether or not to include form elements. /// A controlling the request lifetime. /// A to wait on this long-running operation. Its upon successful /// completion will contain recognized pages from the input document. @@ -849,7 +868,8 @@ public virtual async Task StartRecognizeCustomFor /// /// The ID of the model to use for recognizing form values. /// The absolute URI of the remote file to recognize elements from. - /// A set of options available for configuring the recognize request. + /// A set of options available for configuring the recognize request. For example, specify the content type of the + /// form, or whether or not to include form elements. /// A controlling the request lifetime. /// A to wait on this long-running operation. Its upon successful /// completion will contain recognized pages from the input document. diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormRecognizerClientOptions.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormRecognizerClientOptions.cs index 3dce9887279d3..e9052aaa6cef0 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormRecognizerClientOptions.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormRecognizerClientOptions.cs @@ -16,7 +16,8 @@ public class FormRecognizerClientOptions : ClientOptions internal const ServiceVersion LatestVersion = ServiceVersion.V2_0; /// - /// Initializes a new instance of the class. + /// Initializes a new instance of the class which allows + /// to configure the behavior of the or . /// /// The version of the service to send requests to. public FormRecognizerClientOptions(ServiceVersion version = LatestVersion) diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormRecognizerModelFactory.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormRecognizerModelFactory.cs index 35639d7af4c40..cb943b36586c0 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormRecognizerModelFactory.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormRecognizerModelFactory.cs @@ -11,7 +11,7 @@ namespace Azure.AI.FormRecognizer.Models { /// - /// A factory that builds Azure.AI.FormRecognizer model types for mocking. + /// A factory that builds Azure.AI.FormRecognizer model types used for mocking. /// public static class FormRecognizerModelFactory { @@ -287,7 +287,7 @@ public static FormLine FormLine(FieldBoundingBox boundingBox, int pageNumber, st /// The width of the image/PDF in pixels/inches, respectively. /// The height of the image/PDF in pixels/inches, respectively. /// The general orientation of the text in clockwise direction, measured in degrees between (-180, 180]. - /// The unit used by the width, height and properties. For images, the unit is "pixel". For PDF, the unit is "inch". + /// The unit used by the width, height and properties. For images, the unit is "pixel". For PDF, the unit is "inch". /// A list of recognized lines of text. /// A list of recognized tables contained in this page. /// A new instance for mocking. @@ -307,7 +307,7 @@ public static FormPage FormPage(int pageNumber, float width, float height, float /// The width of the image/PDF in pixels/inches, respectively. /// The height of the image/PDF in pixels/inches, respectively. /// The general orientation of the text in clockwise direction, measured in degrees between (-180, 180]. - /// The unit used by the width, height and properties. For images, the unit is "pixel". For PDF, the unit is "inch". + /// The unit used by the width, height and properties. For images, the unit is "pixel". For PDF, the unit is "inch". /// A list of recognized lines of text. /// A list of recognized tables contained in this page. /// A list of recognized selection marks contained in this page. diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormSelectionMark.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormSelectionMark.cs index b30074defe0c9..e8903aad96a78 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormSelectionMark.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormSelectionMark.cs @@ -28,7 +28,7 @@ internal FormSelectionMark(FieldBoundingBox boundingBox, int pageNumber, string public float Confidence { get; } /// - /// Selection mark state value. + /// Selection mark state value, like Selected or Unselected. /// public SelectionMarkState State { get; } } diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormTableCell.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormTableCell.cs index a2d99589fcc78..e8ec3edcd88fd 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormTableCell.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormTableCell.cs @@ -89,7 +89,7 @@ internal FormTableCell(FieldBoundingBox boundingBox, int pageNumber, string text /// /// When 'IncludeFieldElements' is set to true, a list of references to - /// the field elements constituting this cell is returned. An empty list otherwise. For calls to recognize content, this + /// the field elements constituting this cell is returned. An empty list otherwise. For calls to Recognize Content, this /// list is always populated. /// public IReadOnlyList FieldElements { get; } diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormTrainingClient.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormTrainingClient.cs index 15773d9dac5a7..8abfd6b6a7cfb 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormTrainingClient.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormTrainingClient.cs @@ -14,7 +14,7 @@ namespace Azure.AI.FormRecognizer.Training { /// /// The client to use to connect with the Form Recognizer Azure Cognitive Service to train models from - /// custom forms. It also supports listing and deleting trained models, as well as accessing account + /// custom forms. It also supports listing, copy, and deleting trained models, create composed models, and accessing account /// properties. /// public class FormTrainingClient @@ -110,9 +110,10 @@ public FormTrainingClient(Uri endpoint, TokenCredential credential, FormRecogniz /// /// An externally accessible Azure storage blob container Uri. /// For more information see . - /// If true, use a label file created in the <link-to-label-tool-doc> to provide training-time labels for training a model. If false, the model will be trained from forms only. + /// If true, corresponding labeled files must exist in the blob container. If false, the model will be trained from forms only. /// An optional, user-defined name to associate with the model. - /// A set of options available for configuring the training request. + /// A set of options available for configuring the training request. For example, set a filter to apply + /// to the documents in the source path for training. /// A controlling the request lifetime. /// /// A to wait on this long-running operation. Its Value upon successful @@ -152,9 +153,10 @@ public virtual TrainingOperation StartTraining(Uri trainingFilesUri, bool useTra /// /// An externally accessible Azure storage blob container Uri. /// For more information see . - /// If true, use a label file created in the <link-to-label-tool-doc> to provide training-time labels for training a model. If false, the model will be trained from forms only. + /// If true, corresponding labeled files must exist in the blob container. If false, the model will be trained from forms only. /// An optional, user-defined name to associate with the model. - /// A set of options available for configuring the training request. + /// A set of options available for configuring the training request. For example, set a filter to apply + /// to the documents in the source path for training. /// A controlling the request lifetime. /// /// A to wait on this long-running operation. Its Value upon successful @@ -195,8 +197,9 @@ public virtual async Task StartTrainingAsync(Uri trainingFile /// /// An externally accessible Azure storage blob container Uri. /// For more information see . - /// If true, use a label file created in the <link-to-label-tool-doc> to provide training-time labels for training a model. If false, the model will be trained from forms only. - /// A set of options available for configuring the training request. + /// If true, corresponding labeled files must exist in the blob container. If false, the model will be trained from forms only. + /// A set of options available for configuring the training request. For example, set a filter to apply + /// to the documents in the source path for training. /// A controlling the request lifetime. /// /// A to wait on this long-running operation. Its Value upon successful @@ -235,8 +238,9 @@ public virtual TrainingOperation StartTraining(Uri trainingFilesUri, bool useTra /// /// An externally accessible Azure storage blob container Uri. /// For more information see . - /// If true, use a label file created in the <link-to-label-tool-doc> to provide training-time labels for training a model. If false, the model will be trained from forms only. - /// A set of options available for configuring the training request. + /// If true, corresponding labeled files must exist in the blob container. If false, the model will be trained from forms only. + /// A set of options available for configuring the training request. For example, set a filter to apply + /// to the documents in the source path for training. /// A controlling the request lifetime. /// /// A to wait on this long-running operation. Its Value upon successful diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeBusinessCardsOperation.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeBusinessCardsOperation.cs index 430bdb83fbcb0..e3780596fbd60 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeBusinessCardsOperation.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeBusinessCardsOperation.cs @@ -2,7 +2,6 @@ // Licensed under the MIT License. using System; -using System.Collections.Generic; using System.Linq; using System.Threading; using System.Threading.Tasks; @@ -79,7 +78,8 @@ public override RecognizedFormCollection Value public override Response GetRawResponse() => _response; /// - /// Initializes a new instance of the class. + /// Initializes a new instance of the class which + /// tracks the status of a long-running operation for recognizing values from business cards. /// /// The ID of this operation. /// The client used to check for completion. diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeBusinessCardsOptions.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeBusinessCardsOptions.cs index 07b2bd2d4c158..bd23023687cab 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeBusinessCardsOptions.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeBusinessCardsOptions.cs @@ -4,13 +4,17 @@ namespace Azure.AI.FormRecognizer { /// - /// The set of options that can be specified when calling a recognize business cards method - /// to configure the behavior of the request. + /// The set of options that can be specified when calling a Recognize Business Cards method + /// to configure the behavior of the request. For example, specify the content type of the + /// form, the locale of the form, or whether or not to include form elements. /// public class RecognizeBusinessCardsOptions { /// - /// Initializes a new instance of the class. + /// Initializes a new instance of the class which + /// allows to set options that can be specified when calling a Recognize Business Cards method + /// to configure the behavior of the request. For example, specify the content type of the + /// form, the locale of the form, or whether or not to include form elements. /// public RecognizeBusinessCardsOptions() { diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeContentOperation.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeContentOperation.cs index cc2e3add0d1b4..ac2df54ffa269 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeContentOperation.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeContentOperation.cs @@ -70,7 +70,8 @@ public override FormPageCollection Value public override bool HasValue => _value != null; /// - /// Initializes a new instance of the class. + /// Initializes a new instance of the class which + /// tracks the status of a long-running operation for recognizing layout elements from forms. /// /// The ID of this operation. /// The client used to check for completion. diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeContentOptions.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeContentOptions.cs index d4ee72687d075..ca359ddd82373 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeContentOptions.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeContentOptions.cs @@ -6,13 +6,17 @@ namespace Azure.AI.FormRecognizer { /// - /// The set of options that can be specified when calling a recognize content method - /// to configure the behavior of the request. + /// The set of options that can be specified when calling a Recognize Content method + /// to configure the behavior of the request. For example, specify the content type of the + /// form, the language of the form, and the custom page numbers in a multi-page document to analyze. /// public class RecognizeContentOptions { /// - /// Initializes a new instance of the class. + /// Initializes a new instance of the class which + /// allows to set options that can be specified when calling a Recognize Content method + /// to configure the behavior of the request. For example, specify the content type of the + /// form, the language of the form, and the custom page numbers in a multi-page document to analyze. /// public RecognizeContentOptions() { diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeCustomFormsOperation.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeCustomFormsOperation.cs index 7c89345537cc4..c837228d362f2 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeCustomFormsOperation.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeCustomFormsOperation.cs @@ -137,7 +137,9 @@ internal RecognizeCustomFormsOperation(FormRecognizerRestClient operations, Clie } /// - /// Initializes a new instance of the class. + /// Initializes a new instance of the class which + /// tracks the status of a long-running operation for recognizing fields and other content from forms by using custom + /// trained models. /// /// The ID of this operation. /// The client used to check for completion. diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeCustomFormsOptions.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeCustomFormsOptions.cs index 14be8cce7be21..fa446aeca13fe 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeCustomFormsOptions.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeCustomFormsOptions.cs @@ -4,13 +4,17 @@ namespace Azure.AI.FormRecognizer { /// - /// The set of options that can be specified when calling a recognize custom forms method - /// to configure the behavior of the request. + /// The set of options that can be specified when calling a Recognize Custom Forms method + /// to configure the behavior of the request. For example, specify the content type of the + /// form, or whether or not to include form elements. /// public class RecognizeCustomFormsOptions { /// - /// Initializes a new instance of the class. + /// Initializes a new instance of the class which + /// allows to set options that can be specified when calling a Recognize Custom Forms method + /// to configure the behavior of the request. For example, specify the content type of the + /// form, or whether or not to include form elements. /// public RecognizeCustomFormsOptions() { diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeInvoicesOperation.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeInvoicesOperation.cs index e989fde348c28..4aea8bdbdda70 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeInvoicesOperation.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeInvoicesOperation.cs @@ -2,7 +2,6 @@ // Licensed under the MIT License. using System; -using System.Collections.Generic; using System.Linq; using System.Threading; using System.Threading.Tasks; @@ -79,7 +78,8 @@ public override RecognizedFormCollection Value public override Response GetRawResponse() => _response; /// - /// Initializes a new instance of the class. + /// Initializes a new instance of the class which + /// tracks the status of a long-running operation for recognizing values from invoices. /// /// The ID of this operation. /// The client used to check for completion. diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeInvoicesOptions.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeInvoicesOptions.cs index 2f3e610d14f5f..6e8f82682c5be 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeInvoicesOptions.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeInvoicesOptions.cs @@ -4,13 +4,17 @@ namespace Azure.AI.FormRecognizer { /// - /// The set of options that can be specified when calling a recognize invoices method - /// to configure the behavior of the request. + /// The set of options that can be specified when calling a Recognize Invoices method + /// to configure the behavior of the request. For example, specify the content type of the + /// form, the locale of the form, or whether or not to include form elements. /// public class RecognizeInvoicesOptions { /// - /// Initializes a new instance of the class. + /// Initializes a new instance of the class which + /// allows to set options that can be specified when calling a Recognize Invoices method + /// to configure the behavior of the request. For example, specify the content type of the + /// form, the locale of the form, or whether or not to include form elements. /// public RecognizeInvoicesOptions() { diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeReceiptsOperation.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeReceiptsOperation.cs index 00a186326a0ab..7fb2f53786b23 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeReceiptsOperation.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeReceiptsOperation.cs @@ -2,7 +2,6 @@ // Licensed under the MIT License. using System; -using System.Collections.Generic; using System.Linq; using System.Threading; using System.Threading.Tasks; @@ -79,7 +78,8 @@ public override RecognizedFormCollection Value public override Response GetRawResponse() => _response; /// - /// Initializes a new instance of the class. + /// Initializes a new instance of the class which + /// tracks the status of a long-running operation for recognizing values from receipts. /// /// The ID of this operation. /// The client used to check for completion. diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeReceiptsOptions.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeReceiptsOptions.cs index 3b455fc187686..9ed4294737cc4 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeReceiptsOptions.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeReceiptsOptions.cs @@ -4,13 +4,17 @@ namespace Azure.AI.FormRecognizer { /// - /// The set of options that can be specified when calling a recognize receipt method - /// to configure the behavior of the request. + /// The set of options that can be specified when calling a Recognize Receipts method + /// to configure the behavior of the request. For example, specify the content type of the + /// form, the locale of the form, or whether or not to include form elements. /// public class RecognizeReceiptsOptions { /// - /// Initializes a new instance of the class. + /// Initializes a new instance of the class which + /// allows to set options that can be specified when calling a Recognize Receipts method + /// to configure the behavior of the request. For example, specify the content type of the + /// form, the locale of the form, or whether or not to include form elements. /// public RecognizeReceiptsOptions() { diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/TrainingFileFilter.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/TrainingFileFilter.cs index 15a24a31f6202..537589ca32369 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/TrainingFileFilter.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/TrainingFileFilter.cs @@ -13,7 +13,9 @@ namespace Azure.AI.FormRecognizer.Training public partial class TrainingFileFilter { /// - /// Initializes a new instance of the class. + /// Initializes a new instance of the class which is + /// used by the to filter the documents by name in the + /// source path provided for training. /// public TrainingFileFilter() { diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/TrainingOptions.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/TrainingOptions.cs index 9b58512b6dbc7..765ff7a89f5a3 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/TrainingOptions.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/TrainingOptions.cs @@ -5,12 +5,16 @@ namespace Azure.AI.FormRecognizer.Training { /// /// The set of options that can be specified when calling the training method - /// to configure the behavior of the request. + /// to configure the behavior of the request. For example, set a filter to apply + /// to the documents in the source path for training. /// public class TrainingOptions { /// - /// Initializes a new instance of the class. + /// Initializes a new instance of the class which + /// allows to set options that can be specified when calling the training method + /// to configure the behavior of the request. For example, set a filter to apply + /// to the documents for training. /// public TrainingOptions() { diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/tests/Models/OperationsMockTests.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/tests/Models/OperationsMockTests.cs index 314ca4bc1acdd..bd8cdf4cea3c8 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/tests/Models/OperationsMockTests.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/tests/Models/OperationsMockTests.cs @@ -140,7 +140,7 @@ public async Task TrainingOperationCreatesDiagnosticScopeOnUpdate() await operation.UpdateStatusAsync(); - testListener.AssertScope($"{nameof(TrainingOperation)}.{nameof(TrainingOperation.UpdateStatus)}"); + testListener.AssertScope($"{nameof(CreateCustomFormModelOperation)}.{nameof(CreateCustomFormModelOperation.UpdateStatus)}"); } [Test] diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/tests/samples/Sample10_DifferentiateOutputModelsTrainedWithAndWithoutLabels.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/tests/samples/Sample10_DifferentiateOutputModelsTrainedWithAndWithoutLabels.cs index 21ee7b46d7734..8675753f0dc0e 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/tests/samples/Sample10_DifferentiateOutputModelsTrainedWithAndWithoutLabels.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/tests/samples/Sample10_DifferentiateOutputModelsTrainedWithAndWithoutLabels.cs @@ -20,7 +20,7 @@ public partial class FormRecognizerSamples : SamplesBase Date: Fri, 4 Dec 2020 16:27:57 -0800 Subject: [PATCH 3/3] PR feedback --- sdk/formrecognizer/Azure.AI.FormRecognizer/README.md | 2 +- .../Azure.AI.FormRecognizer/src/AccountProperties.cs | 6 +++--- .../src/CreateComposedModelOperation.cs | 4 ++-- .../Azure.AI.FormRecognizer/src/CustomFormModel.cs | 2 +- .../Azure.AI.FormRecognizer/src/CustomFormModelInfo.cs | 2 +- .../src/CustomFormModelProperties.cs | 2 +- .../Azure.AI.FormRecognizer/src/FieldValueType.cs | 2 +- .../Azure.AI.FormRecognizer/src/FormPage.cs | 6 +++--- .../src/FormRecognizerClient.cs | 10 +++++----- .../src/FormRecognizerModelFactory.cs | 6 +++--- .../Azure.AI.FormRecognizer/src/FormTrainingClient.cs | 4 ++-- .../src/RecognizeBusinessCardsOptions.cs | 3 ++- .../src/RecognizeContentOptions.cs | 4 ++-- .../src/RecognizeCustomFormsOptions.cs | 3 ++- .../src/RecognizeInvoicesOptions.cs | 3 ++- .../src/RecognizeReceiptsOptions.cs | 3 ++- 16 files changed, 33 insertions(+), 29 deletions(-) diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/README.md b/sdk/formrecognizer/Azure.AI.FormRecognizer/README.md index dc62609a8a39b..b5a5ccdf3514e 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/README.md +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/README.md @@ -116,7 +116,7 @@ var client = new FormRecognizerClient(new Uri(endpoint), new DefaultAzureCredent - Training custom models to recognize specific fields and values you specify by labeling your custom forms. A `CustomFormModel` is returned indicating the fields the model will extract, as well as the estimated accuracy for each field. - Managing models created in your account. - Copying a custom model from one Form Recognizer resource to another. -- Creating a composed model from a collection of existing trained models with labels. +- Creating a composed model from a collection of existing models trained with labels. See examples for [Train a Model](#train-a-model) and [Manage Custom Models](#manage-custom-models). diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/AccountProperties.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/AccountProperties.cs index 4ac90b7ca296e..eb294db08779b 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/AccountProperties.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/AccountProperties.cs @@ -21,7 +21,7 @@ internal AccountProperties(ModelsSummary summary) /// Initializes a new instance of the class. /// /// The current count of trained custom models. - /// The maximum number of models that can be trained for this subscription. + /// The maximum number of models that can be trained for this account. internal AccountProperties(int customModelCount, int customModelLimit) { CustomModelCount = customModelCount; @@ -29,12 +29,12 @@ internal AccountProperties(int customModelCount, int customModelLimit) } /// - /// The current count of trained custom models in this subscription. + /// The current count of trained custom models in this account. /// public int CustomModelCount { get; } /// - /// The maximum number of models that can be trained for this subscription. + /// The maximum number of models that can be trained for this account. /// public int CustomModelLimit { get; } } diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/CreateComposedModelOperation.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/CreateComposedModelOperation.cs index 2f3e1c096fc3a..8e6c0780ffbc5 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/CreateComposedModelOperation.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/CreateComposedModelOperation.cs @@ -7,7 +7,7 @@ namespace Azure.AI.FormRecognizer.Training { /// /// Tracks the status of a long-running operation for creating a composed model from a - /// collection of existing trained models with labels. + /// collection of existing models trained with labels. /// public class CreateComposedModelOperation : CreateCustomFormModelOperation { @@ -17,7 +17,7 @@ internal CreateComposedModelOperation(string location, FormRecognizerRestClient /// /// Initializes a new instance of the class which /// tracks the status of a long-running operation for creating a composed model from a - /// collection of existing trained models with labels. + /// collection of existing models trained with labels. /// /// The ID of this operation. /// The client used to check for completion. diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/CustomFormModel.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/CustomFormModel.cs index 252de9c21b7e0..db34a27d9b816 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/CustomFormModel.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/CustomFormModel.cs @@ -71,7 +71,7 @@ internal CustomFormModel( public string ModelName { get; } /// - /// Model properties, like for example, if a model is composed. + /// Properties of a model, such as whether the model is a composed model or not. /// [CodeGenMember("Attributes")] public CustomFormModelProperties Properties { get; } diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/CustomFormModelInfo.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/CustomFormModelInfo.cs index 01497aa083c77..e01b151bb76c6 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/CustomFormModelInfo.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/CustomFormModelInfo.cs @@ -40,7 +40,7 @@ internal CustomFormModelInfo(string modelId, CustomFormModelStatus status, DateT public string ModelName { get; } /// - /// Model properties, like for example, if a model is composed. + /// Properties of a model, such as whether the model is a composed model or not. /// [CodeGenMember("Attributes")] public CustomFormModelProperties Properties { get; } diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/CustomFormModelProperties.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/CustomFormModelProperties.cs index 653814000e3f4..040d9663aca13 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/CustomFormModelProperties.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/CustomFormModelProperties.cs @@ -6,7 +6,7 @@ namespace Azure.AI.FormRecognizer.Training { /// - /// Properties of a model like for example if the model is a composed model. + /// Properties of a model, such as whether the model is a composed model or not. /// [CodeGenModel("Attributes")] public partial class CustomFormModelProperties diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FieldValueType.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FieldValueType.cs index d27f6fda93291..4da111b9d0a9d 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FieldValueType.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FieldValueType.cs @@ -58,7 +58,7 @@ public enum FieldValueType Dictionary, /// - /// Used for Selection Mark type. + /// Used for type. /// SelectionMark } diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormPage.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormPage.cs index b49574c89a0ff..dc795032849ab 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormPage.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormPage.cs @@ -7,7 +7,7 @@ namespace Azure.AI.FormRecognizer.Models { /// /// Represents a page recognized from the input document. Contains lines, words, tables, - /// selection marks, and page meta data. + /// selection marks, and page metadata. /// public class FormPage { @@ -42,7 +42,7 @@ internal FormPage(PageResult pageResult, IReadOnlyList readResults, /// The width of the image/PDF in pixels/inches, respectively. /// The height of the image/PDF in pixels/inches, respectively. /// The general orientation of the text in clockwise direction, measured in degrees between (-180, 180]. - /// The unit used by the width, height and properties. For images, the unit is "pixel". For PDF, the unit is "inch". + /// The unit used by the width, height and properties. For images, the unit is pixel. For PDF, the unit is inch. /// A list of recognized lines of text. /// A list of recognized tables contained in this page. /// A list of recognized selection marks contained in this page. @@ -80,7 +80,7 @@ internal FormPage(int pageNumber, float width, float height, float textAngle, Le /// /// The unit used by the width, height and properties. For images, the unit is - /// "pixel". For PDF, the unit is "inch". + /// pixel. For PDF, the unit is inch. /// public LengthUnit Unit { get; } diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormRecognizerClient.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormRecognizerClient.cs index dbe31a967539e..c506dcd61670c 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormRecognizerClient.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormRecognizerClient.cs @@ -14,7 +14,7 @@ namespace Azure.AI.FormRecognizer /// /// The client to use to connect to the Form Recognizer Azure Cognitive Service to recognize /// information from forms and images and extract it into structured data. It provides the ability to analyze receipts, - /// business cards, invoices, to recognize form content, and to extract fields from custom forms with models trained on custom form types. + /// business cards, and invoices, to recognize form content, and to extract fields from custom forms with models trained on custom form types. /// public class FormRecognizerClient { @@ -121,7 +121,7 @@ protected FormRecognizerClient() /// /// The stream containing one or more forms to recognize elements from. /// A set of options available for configuring the recognize request. For example, specify the content type of the - /// form, the language of the form, and the custom page numbers in a multi-page document to analyze. + /// form, the language of the form, and which pages in a multi-page document to analyze. /// A controlling the request lifetime. /// A to wait on this long-running operation. Its upon successful /// completion will contain layout elements extracted from the form. @@ -160,7 +160,7 @@ public virtual RecognizeContentOperation StartRecognizeContent(Stream form, Reco /// /// The stream containing one or more forms to recognize elements from. /// A set of options available for configuring the recognize request. For example, specify the content type of the - /// form, the language of the form, and the custom page numbers in a multi-page document to analyze. + /// form, the language of the form, and which pages in a multi-page document to analyze. /// A controlling the request lifetime. /// A to wait on this long-running operation. Its upon successful /// completion will contain layout elements extracted from the form. @@ -199,7 +199,7 @@ public virtual async Task StartRecognizeContentAsync( /// /// The absolute URI of the remote file to recognize elements from. /// A set of options available for configuring the recognize request. For example, specify the content type of the - /// form, the language of the form, and the custom page numbers in a multi-page document to analyze. + /// form, the language of the form, and which pages in a multi-page document to analyze. /// A controlling the request lifetime. /// A to wait on this long-running operation. Its upon successful /// completion will contain layout elements extracted from the form. @@ -236,7 +236,7 @@ public virtual RecognizeContentOperation StartRecognizeContentFromUri(Uri formUr /// /// The absolute URI of the remote file to recognize elements from. /// A set of options available for configuring the recognize request. For example, specify the content type of the - /// form, the language of the form, and the custom page numbers in a multi-page document to analyze. + /// form, the language of the form, and which pages in a multi-page document to analyze. /// A controlling the request lifetime. /// A to wait on this long-running operation. Its upon successful /// completion will contain layout elements extracted from the form. diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormRecognizerModelFactory.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormRecognizerModelFactory.cs index cb943b36586c0..8d189e7866736 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormRecognizerModelFactory.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormRecognizerModelFactory.cs @@ -19,7 +19,7 @@ public static class FormRecognizerModelFactory /// Initializes a new instance of the class. /// /// The current count of trained custom models. - /// The maximum number of models that can be trained for this subscription. + /// The maximum number of models that can be trained for this account. /// A new instance for mocking. public static AccountProperties AccountProperties(int customModelCount, int customModelLimit) => new AccountProperties(customModelCount, customModelLimit); @@ -287,7 +287,7 @@ public static FormLine FormLine(FieldBoundingBox boundingBox, int pageNumber, st /// The width of the image/PDF in pixels/inches, respectively. /// The height of the image/PDF in pixels/inches, respectively. /// The general orientation of the text in clockwise direction, measured in degrees between (-180, 180]. - /// The unit used by the width, height and properties. For images, the unit is "pixel". For PDF, the unit is "inch". + /// The unit used by the width, height and properties. For images, the unit is pixel. For PDF, the unit is inch. /// A list of recognized lines of text. /// A list of recognized tables contained in this page. /// A new instance for mocking. @@ -307,7 +307,7 @@ public static FormPage FormPage(int pageNumber, float width, float height, float /// The width of the image/PDF in pixels/inches, respectively. /// The height of the image/PDF in pixels/inches, respectively. /// The general orientation of the text in clockwise direction, measured in degrees between (-180, 180]. - /// The unit used by the width, height and properties. For images, the unit is "pixel". For PDF, the unit is "inch". + /// The unit used by the width, height and properties. For images, the unit is pixel. For PDF, the unit is inch. /// A list of recognized lines of text. /// A list of recognized tables contained in this page. /// A list of recognized selection marks contained in this page. diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormTrainingClient.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormTrainingClient.cs index 8abfd6b6a7cfb..24f3809306aaa 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormTrainingClient.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/FormTrainingClient.cs @@ -14,7 +14,7 @@ namespace Azure.AI.FormRecognizer.Training { /// /// The client to use to connect with the Form Recognizer Azure Cognitive Service to train models from - /// custom forms. It also supports listing, copy, and deleting trained models, create composed models, and accessing account + /// custom forms. It also supports listing, copying, and deleting trained models, creating composed models, and accessing account /// properties. /// public class FormTrainingClient @@ -279,7 +279,7 @@ public virtual async Task StartTrainingAsync(Uri trainingFile #region Composed model /// - /// Creates a composed model from a collection of existing trained models with labels. + /// Creates a composed model from a collection of existing models trained with labels. /// /// List of model ids to use in the composed model. /// An optional, user-defined name to associate with the model. diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeBusinessCardsOptions.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeBusinessCardsOptions.cs index bd23023687cab..344362cd92c36 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeBusinessCardsOptions.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeBusinessCardsOptions.cs @@ -21,7 +21,8 @@ public RecognizeBusinessCardsOptions() } /// - /// Whether or not to include form elements such as lines and words in addition to form fields. + /// Whether or not to include all lines per page and field elements such as lines, words, + /// and selection marks for each form field. /// public bool IncludeFieldElements { get; set; } diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeContentOptions.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeContentOptions.cs index ca359ddd82373..8ff0abf132fd3 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeContentOptions.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeContentOptions.cs @@ -8,7 +8,7 @@ namespace Azure.AI.FormRecognizer /// /// The set of options that can be specified when calling a Recognize Content method /// to configure the behavior of the request. For example, specify the content type of the - /// form, the language of the form, and the custom page numbers in a multi-page document to analyze. + /// form, the language of the form, and which pages in a multi-page document to analyze. /// public class RecognizeContentOptions { @@ -16,7 +16,7 @@ public class RecognizeContentOptions /// Initializes a new instance of the class which /// allows to set options that can be specified when calling a Recognize Content method /// to configure the behavior of the request. For example, specify the content type of the - /// form, the language of the form, and the custom page numbers in a multi-page document to analyze. + /// form, the language of the form, and which pages in a multi-page document to analyze. /// public RecognizeContentOptions() { diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeCustomFormsOptions.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeCustomFormsOptions.cs index fa446aeca13fe..05ae6778b5261 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeCustomFormsOptions.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeCustomFormsOptions.cs @@ -21,7 +21,8 @@ public RecognizeCustomFormsOptions() } /// - /// Whether or not to include form elements such as lines and words in addition to form fields. + /// Whether or not to include all lines per page and field elements such as lines, words, + /// and selection marks for each form field. /// public bool IncludeFieldElements { get; set; } diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeInvoicesOptions.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeInvoicesOptions.cs index 6e8f82682c5be..50cedcc757128 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeInvoicesOptions.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeInvoicesOptions.cs @@ -21,7 +21,8 @@ public RecognizeInvoicesOptions() } /// - /// Whether or not to include form elements such as lines and words in addition to form fields. + /// Whether or not to include all lines per page and field elements such as lines, words, + /// and selection marks for each form field. /// public bool IncludeFieldElements { get; set; } diff --git a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeReceiptsOptions.cs b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeReceiptsOptions.cs index 9ed4294737cc4..9584ce54fd56a 100644 --- a/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeReceiptsOptions.cs +++ b/sdk/formrecognizer/Azure.AI.FormRecognizer/src/RecognizeReceiptsOptions.cs @@ -21,7 +21,8 @@ public RecognizeReceiptsOptions() } /// - /// Whether or not to include form elements such as lines and words in addition to form fields. + /// Whether or not to include all lines per page and field elements such as lines, words, + /// and selection marks for each form field. /// public bool IncludeFieldElements { get; set; }