Class AnomalyDetectorAsyncClient

java.lang.Object
com.azure.ai.anomalydetector.AnomalyDetectorAsyncClient

public final class AnomalyDetectorAsyncClient extends Object
Initializes a new instance of the asynchronous AnomalyDetectorClient type.
  • Method Details

    • detectUnivariateEntireSeriesWithResponse

      public Mono<com.azure.core.http.rest.Response<com.azure.core.util.BinaryData>> detectUnivariateEntireSeriesWithResponse(com.azure.core.util.BinaryData options, com.azure.core.http.rest.RequestOptions requestOptions)
      Detect anomalies for the entire series in batch.

      This operation generates a model with an entire series, each point is detected with the same model. With this method, points before and after a certain point are used to determine whether it is an anomaly. The entire detection can give user an overall status of the time series.

      Request Body Schema

      
       {
           series (Required): [
                (Required){
                   timestamp: OffsetDateTime (Optional)
                   value: double (Required)
               }
           ]
           granularity: String(yearly/monthly/weekly/daily/hourly/minutely/secondly/microsecond/none) (Optional)
           customInterval: Integer (Optional)
           period: Integer (Optional)
           maxAnomalyRatio: Double (Optional)
           sensitivity: Integer (Optional)
           imputeMode: String(auto/previous/linear/fixed/zero/notFill) (Optional)
           imputeFixedValue: Double (Optional)
       }
       

      Response Body Schema

      
       {
           period: int (Required)
           expectedValues (Required): [
               double (Required)
           ]
           upperMargins (Required): [
               double (Required)
           ]
           lowerMargins (Required): [
               double (Required)
           ]
           isAnomaly (Required): [
               boolean (Required)
           ]
           isNegativeAnomaly (Required): [
               boolean (Required)
           ]
           isPositiveAnomaly (Required): [
               boolean (Required)
           ]
           severity (Optional): [
               double (Optional)
           ]
       }
       
      Parameters:
      options - Method of univariate anomaly detection.
      requestOptions - The options to configure the HTTP request before HTTP client sends it.
      Returns:
      the response of entire anomaly detection along with Response on successful completion of Mono.
      Throws:
      com.azure.core.exception.HttpResponseException - thrown if the request is rejected by server.
      com.azure.core.exception.ClientAuthenticationException - thrown if the request is rejected by server on status code 401.
      com.azure.core.exception.ResourceNotFoundException - thrown if the request is rejected by server on status code 404.
      com.azure.core.exception.ResourceModifiedException - thrown if the request is rejected by server on status code 409.
    • detectUnivariateLastPointWithResponse

      public Mono<com.azure.core.http.rest.Response<com.azure.core.util.BinaryData>> detectUnivariateLastPointWithResponse(com.azure.core.util.BinaryData options, com.azure.core.http.rest.RequestOptions requestOptions)
      Detect anomaly status of the latest point in time series.

      This operation generates a model using the points that you sent into the API, and based on all data to determine whether the last point is anomalous.

      Request Body Schema

      
       {
           series (Required): [
                (Required){
                   timestamp: OffsetDateTime (Optional)
                   value: double (Required)
               }
           ]
           granularity: String(yearly/monthly/weekly/daily/hourly/minutely/secondly/microsecond/none) (Optional)
           customInterval: Integer (Optional)
           period: Integer (Optional)
           maxAnomalyRatio: Double (Optional)
           sensitivity: Integer (Optional)
           imputeMode: String(auto/previous/linear/fixed/zero/notFill) (Optional)
           imputeFixedValue: Double (Optional)
       }
       

      Response Body Schema

      
       {
           period: int (Required)
           suggestedWindow: int (Required)
           expectedValue: double (Required)
           upperMargin: double (Required)
           lowerMargin: double (Required)
           isAnomaly: boolean (Required)
           isNegativeAnomaly: boolean (Required)
           isPositiveAnomaly: boolean (Required)
           severity: Double (Optional)
       }
       
      Parameters:
      options - Method of univariate anomaly detection.
      requestOptions - The options to configure the HTTP request before HTTP client sends it.
      Returns:
      the response of last anomaly detection along with Response on successful completion of Mono.
      Throws:
      com.azure.core.exception.HttpResponseException - thrown if the request is rejected by server.
      com.azure.core.exception.ClientAuthenticationException - thrown if the request is rejected by server on status code 401.
      com.azure.core.exception.ResourceNotFoundException - thrown if the request is rejected by server on status code 404.
      com.azure.core.exception.ResourceModifiedException - thrown if the request is rejected by server on status code 409.
    • detectUnivariateChangePointWithResponse

      public Mono<com.azure.core.http.rest.Response<com.azure.core.util.BinaryData>> detectUnivariateChangePointWithResponse(com.azure.core.util.BinaryData options, com.azure.core.http.rest.RequestOptions requestOptions)
      Detect change point for the entire series

      Evaluate change point score of every series point.

      Request Body Schema

      
       {
           series (Required): [
                (Required){
                   timestamp: OffsetDateTime (Optional)
                   value: double (Required)
               }
           ]
           granularity: String(yearly/monthly/weekly/daily/hourly/minutely/secondly/microsecond/none) (Required)
           customInterval: Integer (Optional)
           period: Integer (Optional)
           stableTrendWindow: Integer (Optional)
           threshold: Double (Optional)
       }
       

      Response Body Schema

      
       {
           period: Integer (Optional)
           isChangePoint (Optional): [
               boolean (Optional)
           ]
           confidenceScores (Optional): [
               double (Optional)
           ]
       }
       
      Parameters:
      options - Method of univariate anomaly detection.
      requestOptions - The options to configure the HTTP request before HTTP client sends it.
      Returns:
      the response of change point detection along with Response on successful completion of Mono.
      Throws:
      com.azure.core.exception.HttpResponseException - thrown if the request is rejected by server.
      com.azure.core.exception.ClientAuthenticationException - thrown if the request is rejected by server on status code 401.
      com.azure.core.exception.ResourceNotFoundException - thrown if the request is rejected by server on status code 404.
      com.azure.core.exception.ResourceModifiedException - thrown if the request is rejected by server on status code 409.
    • getMultivariateBatchDetectionResultWithResponse

      public Mono<com.azure.core.http.rest.Response<com.azure.core.util.BinaryData>> getMultivariateBatchDetectionResultWithResponse(String resultId, com.azure.core.http.rest.RequestOptions requestOptions)
      Get Multivariate Anomaly Detection Result

      For asynchronous inference, get multivariate anomaly detection result based on resultId returned by the BatchDetectAnomaly api.

      Response Body Schema

      
       {
           resultId: String (Required)
           summary (Required): {
               status: String(CREATED/RUNNING/READY/FAILED) (Required)
               errors (Optional): [
                    (Optional){
                       code: String (Required)
                       message: String (Required)
                   }
               ]
               variableStates (Optional): [
                    (Optional){
                       variable: String (Optional)
                       filledNARatio: Double (Optional)
                       effectiveCount: Integer (Optional)
                       firstTimestamp: OffsetDateTime (Optional)
                       lastTimestamp: OffsetDateTime (Optional)
                   }
               ]
               setupInfo (Required): {
                   dataSource: String (Required)
                   topContributorCount: int (Required)
                   startTime: OffsetDateTime (Required)
                   endTime: OffsetDateTime (Required)
               }
           }
           results (Required): [
                (Required){
                   timestamp: OffsetDateTime (Required)
                   value (Optional): {
                       isAnomaly: boolean (Required)
                       severity: double (Required)
                       score: double (Required)
                       interpretation (Optional): [
                            (Optional){
                               variable: String (Optional)
                               contributionScore: Double (Optional)
                               correlationChanges (Optional): {
                                   changedVariables (Optional): [
                                       String (Optional)
                                   ]
                               }
                           }
                       ]
                   }
                   errors (Optional): [
                       (recursive schema, see above)
                   ]
               }
           ]
       }
       
      Parameters:
      resultId - ID of a batch detection result.
      requestOptions - The options to configure the HTTP request before HTTP client sends it.
      Returns:
      detection results for the given resultId along with Response on successful completion of Mono.
      Throws:
      com.azure.core.exception.HttpResponseException - thrown if the request is rejected by server.
      com.azure.core.exception.ClientAuthenticationException - thrown if the request is rejected by server on status code 401.
      com.azure.core.exception.ResourceNotFoundException - thrown if the request is rejected by server on status code 404.
      com.azure.core.exception.ResourceModifiedException - thrown if the request is rejected by server on status code 409.
    • trainMultivariateModelWithResponse

      public Mono<com.azure.core.http.rest.Response<com.azure.core.util.BinaryData>> trainMultivariateModelWithResponse(com.azure.core.util.BinaryData modelInfo, com.azure.core.http.rest.RequestOptions requestOptions)
      Train a Multivariate Anomaly Detection Model

      Create and train a multivariate anomaly detection model. The request must include a source parameter to indicate an externally accessible Azure blob storage URI.There are two types of data input: An URI pointed to an Azure blob storage folder which contains multiple CSV files, and each CSV file contains two columns, timestamp and variable. Another type of input is an URI pointed to a CSV file in Azure blob storage, which contains all the variables and a timestamp column.

      Request Body Schema

      
       {
           dataSource: String (Required)
           dataSchema: String(OneTable/MultiTable) (Optional)
           startTime: OffsetDateTime (Required)
           endTime: OffsetDateTime (Required)
           displayName: String (Optional)
           slidingWindow: Integer (Optional)
           alignPolicy (Optional): {
               alignMode: String(Inner/Outer) (Optional)
               fillNAMethod: String(Previous/Subsequent/Linear/Zero/Fixed) (Optional)
               paddingValue: Double (Optional)
           }
           status: String(CREATED/RUNNING/READY/FAILED) (Optional)
           errors (Optional): [
                (Optional){
                   code: String (Required)
                   message: String (Required)
               }
           ]
           diagnosticsInfo (Optional): {
               modelState (Optional): {
                   epochIds (Optional): [
                       int (Optional)
                   ]
                   trainLosses (Optional): [
                       double (Optional)
                   ]
                   validationLosses (Optional): [
                       double (Optional)
                   ]
                   latenciesInSeconds (Optional): [
                       double (Optional)
                   ]
               }
               variableStates (Optional): [
                    (Optional){
                       variable: String (Optional)
                       filledNARatio: Double (Optional)
                       effectiveCount: Integer (Optional)
                       firstTimestamp: OffsetDateTime (Optional)
                       lastTimestamp: OffsetDateTime (Optional)
                   }
               ]
           }
       }
       

      Response Body Schema

      
       {
           modelId: String (Required)
           createdTime: OffsetDateTime (Required)
           lastUpdatedTime: OffsetDateTime (Required)
           modelInfo (Optional): {
               dataSource: String (Required)
               dataSchema: String(OneTable/MultiTable) (Optional)
               startTime: OffsetDateTime (Required)
               endTime: OffsetDateTime (Required)
               displayName: String (Optional)
               slidingWindow: Integer (Optional)
               alignPolicy (Optional): {
                   alignMode: String(Inner/Outer) (Optional)
                   fillNAMethod: String(Previous/Subsequent/Linear/Zero/Fixed) (Optional)
                   paddingValue: Double (Optional)
               }
               status: String(CREATED/RUNNING/READY/FAILED) (Optional)
               errors (Optional): [
                    (Optional){
                       code: String (Required)
                       message: String (Required)
                   }
               ]
               diagnosticsInfo (Optional): {
                   modelState (Optional): {
                       epochIds (Optional): [
                           int (Optional)
                       ]
                       trainLosses (Optional): [
                           double (Optional)
                       ]
                       validationLosses (Optional): [
                           double (Optional)
                       ]
                       latenciesInSeconds (Optional): [
                           double (Optional)
                       ]
                   }
                   variableStates (Optional): [
                        (Optional){
                           variable: String (Optional)
                           filledNARatio: Double (Optional)
                           effectiveCount: Integer (Optional)
                           firstTimestamp: OffsetDateTime (Optional)
                           lastTimestamp: OffsetDateTime (Optional)
                       }
                   ]
               }
           }
       }
       
      Parameters:
      modelInfo - Model information.
      requestOptions - The options to configure the HTTP request before HTTP client sends it.
      Returns:
      response of getting a model along with Response on successful completion of Mono.
      Throws:
      com.azure.core.exception.HttpResponseException - thrown if the request is rejected by server.
      com.azure.core.exception.ClientAuthenticationException - thrown if the request is rejected by server on status code 401.
      com.azure.core.exception.ResourceNotFoundException - thrown if the request is rejected by server on status code 404.
      com.azure.core.exception.ResourceModifiedException - thrown if the request is rejected by server on status code 409.
    • listMultivariateModels

      public com.azure.core.http.rest.PagedFlux<com.azure.core.util.BinaryData> listMultivariateModels(com.azure.core.http.rest.RequestOptions requestOptions)
      List Multivariate Models

      List models of a resource.

      Query Parameters

      Query Parameters
      NameTypeRequiredDescription
      skipIntegerNoSkip indicates how many models will be skipped.
      topIntegerNoTop indicates how many models will be fetched.
      You can add these to a request with RequestOptions.addQueryParam(java.lang.String, java.lang.String)

      Response Body Schema

      
       {
           modelId: String (Required)
           createdTime: OffsetDateTime (Required)
           lastUpdatedTime: OffsetDateTime (Required)
           modelInfo (Optional): {
               dataSource: String (Required)
               dataSchema: String(OneTable/MultiTable) (Optional)
               startTime: OffsetDateTime (Required)
               endTime: OffsetDateTime (Required)
               displayName: String (Optional)
               slidingWindow: Integer (Optional)
               alignPolicy (Optional): {
                   alignMode: String(Inner/Outer) (Optional)
                   fillNAMethod: String(Previous/Subsequent/Linear/Zero/Fixed) (Optional)
                   paddingValue: Double (Optional)
               }
               status: String(CREATED/RUNNING/READY/FAILED) (Optional)
               errors (Optional): [
                    (Optional){
                       code: String (Required)
                       message: String (Required)
                   }
               ]
               diagnosticsInfo (Optional): {
                   modelState (Optional): {
                       epochIds (Optional): [
                           int (Optional)
                       ]
                       trainLosses (Optional): [
                           double (Optional)
                       ]
                       validationLosses (Optional): [
                           double (Optional)
                       ]
                       latenciesInSeconds (Optional): [
                           double (Optional)
                       ]
                   }
                   variableStates (Optional): [
                        (Optional){
                           variable: String (Optional)
                           filledNARatio: Double (Optional)
                           effectiveCount: Integer (Optional)
                           firstTimestamp: OffsetDateTime (Optional)
                           lastTimestamp: OffsetDateTime (Optional)
                       }
                   ]
               }
           }
       }
       
      Parameters:
      requestOptions - The options to configure the HTTP request before HTTP client sends it.
      Returns:
      response of listing models as paginated response with PagedFlux.
      Throws:
      com.azure.core.exception.HttpResponseException - thrown if the request is rejected by server.
      com.azure.core.exception.ClientAuthenticationException - thrown if the request is rejected by server on status code 401.
      com.azure.core.exception.ResourceNotFoundException - thrown if the request is rejected by server on status code 404.
      com.azure.core.exception.ResourceModifiedException - thrown if the request is rejected by server on status code 409.
    • deleteMultivariateModelWithResponse

      public Mono<com.azure.core.http.rest.Response<Void>> deleteMultivariateModelWithResponse(String modelId, com.azure.core.http.rest.RequestOptions requestOptions)
      Delete Multivariate Model

      Delete an existing multivariate model according to the modelId.

      Parameters:
      modelId - Model identifier.
      requestOptions - The options to configure the HTTP request before HTTP client sends it.
      Returns:
      the Response on successful completion of Mono.
      Throws:
      com.azure.core.exception.HttpResponseException - thrown if the request is rejected by server.
      com.azure.core.exception.ClientAuthenticationException - thrown if the request is rejected by server on status code 401.
      com.azure.core.exception.ResourceNotFoundException - thrown if the request is rejected by server on status code 404.
      com.azure.core.exception.ResourceModifiedException - thrown if the request is rejected by server on status code 409.
    • getMultivariateModelWithResponse

      public Mono<com.azure.core.http.rest.Response<com.azure.core.util.BinaryData>> getMultivariateModelWithResponse(String modelId, com.azure.core.http.rest.RequestOptions requestOptions)
      Get Multivariate Model

      Get detailed information of multivariate model, including the training status and variables used in the model.

      Response Body Schema

      
       {
           modelId: String (Required)
           createdTime: OffsetDateTime (Required)
           lastUpdatedTime: OffsetDateTime (Required)
           modelInfo (Optional): {
               dataSource: String (Required)
               dataSchema: String(OneTable/MultiTable) (Optional)
               startTime: OffsetDateTime (Required)
               endTime: OffsetDateTime (Required)
               displayName: String (Optional)
               slidingWindow: Integer (Optional)
               alignPolicy (Optional): {
                   alignMode: String(Inner/Outer) (Optional)
                   fillNAMethod: String(Previous/Subsequent/Linear/Zero/Fixed) (Optional)
                   paddingValue: Double (Optional)
               }
               status: String(CREATED/RUNNING/READY/FAILED) (Optional)
               errors (Optional): [
                    (Optional){
                       code: String (Required)
                       message: String (Required)
                   }
               ]
               diagnosticsInfo (Optional): {
                   modelState (Optional): {
                       epochIds (Optional): [
                           int (Optional)
                       ]
                       trainLosses (Optional): [
                           double (Optional)
                       ]
                       validationLosses (Optional): [
                           double (Optional)
                       ]
                       latenciesInSeconds (Optional): [
                           double (Optional)
                       ]
                   }
                   variableStates (Optional): [
                        (Optional){
                           variable: String (Optional)
                           filledNARatio: Double (Optional)
                           effectiveCount: Integer (Optional)
                           firstTimestamp: OffsetDateTime (Optional)
                           lastTimestamp: OffsetDateTime (Optional)
                       }
                   ]
               }
           }
       }
       
      Parameters:
      modelId - Model identifier.
      requestOptions - The options to configure the HTTP request before HTTP client sends it.
      Returns:
      detailed information of multivariate model, including the training status and variables used in the model along with Response on successful completion of Mono.
      Throws:
      com.azure.core.exception.HttpResponseException - thrown if the request is rejected by server.
      com.azure.core.exception.ClientAuthenticationException - thrown if the request is rejected by server on status code 401.
      com.azure.core.exception.ResourceNotFoundException - thrown if the request is rejected by server on status code 404.
      com.azure.core.exception.ResourceModifiedException - thrown if the request is rejected by server on status code 409.
    • detectMultivariateBatchAnomalyWithResponse

      public Mono<com.azure.core.http.rest.Response<com.azure.core.util.BinaryData>> detectMultivariateBatchAnomalyWithResponse(String modelId, com.azure.core.util.BinaryData options, com.azure.core.http.rest.RequestOptions requestOptions)
      Detect Multivariate Anomaly

      Submit multivariate anomaly detection task with the modelId of trained model and inference data, the input schema should be the same with the training request. The request will complete asynchronously and return a resultId to query the detection result.The request should be a source link to indicate an externally accessible Azure storage Uri, either pointed to an Azure blob storage folder, or pointed to a CSV file in Azure blob storage.

      Request Body Schema

      
       {
           dataSource: String (Required)
           topContributorCount: int (Required)
           startTime: OffsetDateTime (Required)
           endTime: OffsetDateTime (Required)
       }
       

      Response Body Schema

      
       {
           resultId: String (Required)
           summary (Required): {
               status: String(CREATED/RUNNING/READY/FAILED) (Required)
               errors (Optional): [
                    (Optional){
                       code: String (Required)
                       message: String (Required)
                   }
               ]
               variableStates (Optional): [
                    (Optional){
                       variable: String (Optional)
                       filledNARatio: Double (Optional)
                       effectiveCount: Integer (Optional)
                       firstTimestamp: OffsetDateTime (Optional)
                       lastTimestamp: OffsetDateTime (Optional)
                   }
               ]
               setupInfo (Required): {
                   dataSource: String (Required)
                   topContributorCount: int (Required)
                   startTime: OffsetDateTime (Required)
                   endTime: OffsetDateTime (Required)
               }
           }
           results (Required): [
                (Required){
                   timestamp: OffsetDateTime (Required)
                   value (Optional): {
                       isAnomaly: boolean (Required)
                       severity: double (Required)
                       score: double (Required)
                       interpretation (Optional): [
                            (Optional){
                               variable: String (Optional)
                               contributionScore: Double (Optional)
                               correlationChanges (Optional): {
                                   changedVariables (Optional): [
                                       String (Optional)
                                   ]
                               }
                           }
                       ]
                   }
                   errors (Optional): [
                       (recursive schema, see above)
                   ]
               }
           ]
       }
       
      Parameters:
      modelId - Model identifier.
      options - Request of multivariate anomaly detection.
      requestOptions - The options to configure the HTTP request before HTTP client sends it.
      Returns:
      detection results for the given resultId along with Response on successful completion of Mono.
      Throws:
      com.azure.core.exception.HttpResponseException - thrown if the request is rejected by server.
      com.azure.core.exception.ClientAuthenticationException - thrown if the request is rejected by server on status code 401.
      com.azure.core.exception.ResourceNotFoundException - thrown if the request is rejected by server on status code 404.
      com.azure.core.exception.ResourceModifiedException - thrown if the request is rejected by server on status code 409.
    • detectMultivariateLastAnomalyWithResponse

      public Mono<com.azure.core.http.rest.Response<com.azure.core.util.BinaryData>> detectMultivariateLastAnomalyWithResponse(String modelId, com.azure.core.util.BinaryData options, com.azure.core.http.rest.RequestOptions requestOptions)
      Detect anomalies in the last point of the request body

      Submit multivariate anomaly detection task with the modelId of trained model and inference data, and the inference data should be put into request body in a JSON format. The request will complete synchronously and return the detection immediately in the response body.

      Request Body Schema

      
       {
           variables (Required): [
                (Required){
                   variable: String (Required)
                   timestamps (Required): [
                       String (Required)
                   ]
                   values (Required): [
                       double (Required)
                   ]
               }
           ]
           topContributorCount: int (Required)
       }
       

      Response Body Schema

      
       {
           variableStates (Optional): [
                (Optional){
                   variable: String (Optional)
                   filledNARatio: Double (Optional)
                   effectiveCount: Integer (Optional)
                   firstTimestamp: OffsetDateTime (Optional)
                   lastTimestamp: OffsetDateTime (Optional)
               }
           ]
           results (Optional): [
                (Optional){
                   timestamp: OffsetDateTime (Required)
                   value (Optional): {
                       isAnomaly: boolean (Required)
                       severity: double (Required)
                       score: double (Required)
                       interpretation (Optional): [
                            (Optional){
                               variable: String (Optional)
                               contributionScore: Double (Optional)
                               correlationChanges (Optional): {
                                   changedVariables (Optional): [
                                       String (Optional)
                                   ]
                               }
                           }
                       ]
                   }
                   errors (Optional): [
                        (Optional){
                           code: String (Required)
                           message: String (Required)
                       }
                   ]
               }
           ]
       }
       
      Parameters:
      modelId - Model identifier.
      options - Request of last detection.
      requestOptions - The options to configure the HTTP request before HTTP client sends it.
      Returns:
      results of last detection along with Response on successful completion of Mono.
      Throws:
      com.azure.core.exception.HttpResponseException - thrown if the request is rejected by server.
      com.azure.core.exception.ClientAuthenticationException - thrown if the request is rejected by server on status code 401.
      com.azure.core.exception.ResourceNotFoundException - thrown if the request is rejected by server on status code 404.
      com.azure.core.exception.ResourceModifiedException - thrown if the request is rejected by server on status code 409.
    • detectUnivariateEntireSeries

      public Mono<UnivariateEntireDetectionResult> detectUnivariateEntireSeries(UnivariateDetectionOptions options)
      Detect anomalies for the entire series in batch.

      This operation generates a model with an entire series, each point is detected with the same model. With this method, points before and after a certain point are used to determine whether it is an anomaly. The entire detection can give user an overall status of the time series.

      Parameters:
      options - Method of univariate anomaly detection.
      Returns:
      the response of entire anomaly detection on successful completion of Mono.
      Throws:
      IllegalArgumentException - thrown if parameters fail the validation.
      com.azure.core.exception.HttpResponseException - thrown if the request is rejected by server.
      com.azure.core.exception.ClientAuthenticationException - thrown if the request is rejected by server on status code 401.
      com.azure.core.exception.ResourceNotFoundException - thrown if the request is rejected by server on status code 404.
      com.azure.core.exception.ResourceModifiedException - thrown if the request is rejected by server on status code 409.
      RuntimeException - all other wrapped checked exceptions if the request fails to be sent.
    • detectUnivariateLastPoint

      public Mono<UnivariateLastDetectionResult> detectUnivariateLastPoint(UnivariateDetectionOptions options)
      Detect anomaly status of the latest point in time series.

      This operation generates a model using the points that you sent into the API, and based on all data to determine whether the last point is anomalous.

      Parameters:
      options - Method of univariate anomaly detection.
      Returns:
      the response of last anomaly detection on successful completion of Mono.
      Throws:
      IllegalArgumentException - thrown if parameters fail the validation.
      com.azure.core.exception.HttpResponseException - thrown if the request is rejected by server.
      com.azure.core.exception.ClientAuthenticationException - thrown if the request is rejected by server on status code 401.
      com.azure.core.exception.ResourceNotFoundException - thrown if the request is rejected by server on status code 404.
      com.azure.core.exception.ResourceModifiedException - thrown if the request is rejected by server on status code 409.
      RuntimeException - all other wrapped checked exceptions if the request fails to be sent.
    • detectUnivariateChangePoint

      Detect change point for the entire series

      Evaluate change point score of every series point.

      Parameters:
      options - Method of univariate anomaly detection.
      Returns:
      the response of change point detection on successful completion of Mono.
      Throws:
      IllegalArgumentException - thrown if parameters fail the validation.
      com.azure.core.exception.HttpResponseException - thrown if the request is rejected by server.
      com.azure.core.exception.ClientAuthenticationException - thrown if the request is rejected by server on status code 401.
      com.azure.core.exception.ResourceNotFoundException - thrown if the request is rejected by server on status code 404.
      com.azure.core.exception.ResourceModifiedException - thrown if the request is rejected by server on status code 409.
      RuntimeException - all other wrapped checked exceptions if the request fails to be sent.
    • getMultivariateBatchDetectionResult

      public Mono<MultivariateDetectionResult> getMultivariateBatchDetectionResult(String resultId)
      Get Multivariate Anomaly Detection Result

      For asynchronous inference, get multivariate anomaly detection result based on resultId returned by the BatchDetectAnomaly api.

      Parameters:
      resultId - ID of a batch detection result.
      Returns:
      detection results for the given resultId on successful completion of Mono.
      Throws:
      IllegalArgumentException - thrown if parameters fail the validation.
      com.azure.core.exception.HttpResponseException - thrown if the request is rejected by server.
      com.azure.core.exception.ClientAuthenticationException - thrown if the request is rejected by server on status code 401.
      com.azure.core.exception.ResourceNotFoundException - thrown if the request is rejected by server on status code 404.
      com.azure.core.exception.ResourceModifiedException - thrown if the request is rejected by server on status code 409.
      RuntimeException - all other wrapped checked exceptions if the request fails to be sent.
    • trainMultivariateModel

      public Mono<AnomalyDetectionModel> trainMultivariateModel(ModelInfo modelInfo)
      Train a Multivariate Anomaly Detection Model

      Create and train a multivariate anomaly detection model. The request must include a source parameter to indicate an externally accessible Azure blob storage URI.There are two types of data input: An URI pointed to an Azure blob storage folder which contains multiple CSV files, and each CSV file contains two columns, timestamp and variable. Another type of input is an URI pointed to a CSV file in Azure blob storage, which contains all the variables and a timestamp column.

      Parameters:
      modelInfo - Model information.
      Returns:
      response of getting a model on successful completion of Mono.
      Throws:
      IllegalArgumentException - thrown if parameters fail the validation.
      com.azure.core.exception.HttpResponseException - thrown if the request is rejected by server.
      com.azure.core.exception.ClientAuthenticationException - thrown if the request is rejected by server on status code 401.
      com.azure.core.exception.ResourceNotFoundException - thrown if the request is rejected by server on status code 404.
      com.azure.core.exception.ResourceModifiedException - thrown if the request is rejected by server on status code 409.
      RuntimeException - all other wrapped checked exceptions if the request fails to be sent.
    • listMultivariateModels

      public com.azure.core.http.rest.PagedFlux<AnomalyDetectionModel> listMultivariateModels()
      List Multivariate Models

      List models of a resource.

      Returns:
      response of listing models as paginated response with PagedFlux.
      Throws:
      com.azure.core.exception.HttpResponseException - thrown if the request is rejected by server.
      com.azure.core.exception.ClientAuthenticationException - thrown if the request is rejected by server on status code 401.
      com.azure.core.exception.ResourceNotFoundException - thrown if the request is rejected by server on status code 404.
      com.azure.core.exception.ResourceModifiedException - thrown if the request is rejected by server on status code 409.
      RuntimeException - all other wrapped checked exceptions if the request fails to be sent.
    • deleteMultivariateModel

      public Mono<Void> deleteMultivariateModel(String modelId)
      Delete Multivariate Model

      Delete an existing multivariate model according to the modelId.

      Parameters:
      modelId - Model identifier.
      Returns:
      A Mono that completes when a successful response is received.
      Throws:
      IllegalArgumentException - thrown if parameters fail the validation.
      com.azure.core.exception.HttpResponseException - thrown if the request is rejected by server.
      com.azure.core.exception.ClientAuthenticationException - thrown if the request is rejected by server on status code 401.
      com.azure.core.exception.ResourceNotFoundException - thrown if the request is rejected by server on status code 404.
      com.azure.core.exception.ResourceModifiedException - thrown if the request is rejected by server on status code 409.
      RuntimeException - all other wrapped checked exceptions if the request fails to be sent.
    • getMultivariateModel

      public Mono<AnomalyDetectionModel> getMultivariateModel(String modelId)
      Get Multivariate Model

      Get detailed information of multivariate model, including the training status and variables used in the model.

      Parameters:
      modelId - Model identifier.
      Returns:
      detailed information of multivariate model, including the training status and variables used in the model on successful completion of Mono.
      Throws:
      IllegalArgumentException - thrown if parameters fail the validation.
      com.azure.core.exception.HttpResponseException - thrown if the request is rejected by server.
      com.azure.core.exception.ClientAuthenticationException - thrown if the request is rejected by server on status code 401.
      com.azure.core.exception.ResourceNotFoundException - thrown if the request is rejected by server on status code 404.
      com.azure.core.exception.ResourceModifiedException - thrown if the request is rejected by server on status code 409.
      RuntimeException - all other wrapped checked exceptions if the request fails to be sent.
    • detectMultivariateBatchAnomaly

      public Mono<MultivariateDetectionResult> detectMultivariateBatchAnomaly(String modelId, MultivariateBatchDetectionOptions options)
      Detect Multivariate Anomaly

      Submit multivariate anomaly detection task with the modelId of trained model and inference data, the input schema should be the same with the training request. The request will complete asynchronously and return a resultId to query the detection result.The request should be a source link to indicate an externally accessible Azure storage Uri, either pointed to an Azure blob storage folder, or pointed to a CSV file in Azure blob storage.

      Parameters:
      modelId - Model identifier.
      options - Request of multivariate anomaly detection.
      Returns:
      detection results for the given resultId on successful completion of Mono.
      Throws:
      IllegalArgumentException - thrown if parameters fail the validation.
      com.azure.core.exception.HttpResponseException - thrown if the request is rejected by server.
      com.azure.core.exception.ClientAuthenticationException - thrown if the request is rejected by server on status code 401.
      com.azure.core.exception.ResourceNotFoundException - thrown if the request is rejected by server on status code 404.
      com.azure.core.exception.ResourceModifiedException - thrown if the request is rejected by server on status code 409.
      RuntimeException - all other wrapped checked exceptions if the request fails to be sent.
    • detectMultivariateLastAnomaly

      public Mono<MultivariateLastDetectionResult> detectMultivariateLastAnomaly(String modelId, MultivariateLastDetectionOptions options)
      Detect anomalies in the last point of the request body

      Submit multivariate anomaly detection task with the modelId of trained model and inference data, and the inference data should be put into request body in a JSON format. The request will complete synchronously and return the detection immediately in the response body.

      Parameters:
      modelId - Model identifier.
      options - Request of last detection.
      Returns:
      results of last detection on successful completion of Mono.
      Throws:
      IllegalArgumentException - thrown if parameters fail the validation.
      com.azure.core.exception.HttpResponseException - thrown if the request is rejected by server.
      com.azure.core.exception.ClientAuthenticationException - thrown if the request is rejected by server on status code 401.
      com.azure.core.exception.ResourceNotFoundException - thrown if the request is rejected by server on status code 404.
      com.azure.core.exception.ResourceModifiedException - thrown if the request is rejected by server on status code 409.
      RuntimeException - all other wrapped checked exceptions if the request fails to be sent.