Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update contract for anomaly detector #12487

Merged
merged 13 commits into from
Feb 9, 2021
Merged
Show file tree
Hide file tree
Changes from 10 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -31,5 +31,5 @@ These settings apply only when `--tag=release_1_0 --go` is specified on the comm
Please also specify `--go-sdk-folder=<path to the root directory of your azure-sdk-for-go clone>`.

``` yaml $(tag) == 'release_1_0' && $(go)
output-folder: $(go-sdk-folder)/services/preview/cognitiveservices/v1.0/$(namespace)
output-folder: $(go-sdk-folder)/services/stable/cognitiveservices/v1.0/$(namespace)
guinao marked this conversation as resolved.
Show resolved Hide resolved
```
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ openapi-type: data-plane
These settings apply only when `--tag=release_1_0` is specified on the command line.

``` yaml $(tag) == 'release_1_0'
input-file: preview/v1.0/AnomalyDetector.json
input-file: stable/v1.0/AnomalyDetector.json
```

## Swagger to SDK
Expand Down Expand Up @@ -77,7 +77,7 @@ java:
regenerate-manager: true
```

## Multi-API/Profile support for AutoRest v3 generators
## Multi-API/Profile support for AutoRest v3 generators

AutoRest V3 generators require the use of `--tag=all-api-versions` to select api files.

Expand All @@ -89,15 +89,15 @@ require: $(this-folder)/../../../../profiles/readme.md

# all the input files across all versions
input-file:
- $(this-folder)/preview/v1.0/AnomalyDetector.json
- $(this-folder)/stable/v1.0/AnomalyDetector.json

```

If there are files that should not be in the `all-api-versions` set,
If there are files that should not be in the `all-api-versions` set,
uncomment the `exclude-file` section below and add the file paths.

``` yaml $(tag) == 'all-api-versions'
#exclude-file:
#exclude-file:
# - $(this-folder)/Microsoft.Example/stable/2010-01-01/somefile.json
```

Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@
},
"TimeGranularity": {
"type": "string",
"description": "Can only be one of yearly, monthly, weekly, daily, hourly, minutely or secondly. Granularity is used for verify whether input series is valid.",
"description": "Optional argument, can be one of yearly, monthly, weekly, daily, hourly, minutely, secondly, microsecond or none. If granularity is not present, it will be none by default. If granularity is none, the timestamp property in time series point can be absent.",
"x-nullable": false,
"x-ms-enum": {
"name": "TimeGranularity",
Expand Down Expand Up @@ -216,6 +216,12 @@
{
"name": "perSecond",
"value": "secondly"
},
{
"value": "microsecond"
},
{
"value": "none"
}
]
},
Expand All @@ -226,7 +232,9 @@
"daily",
"hourly",
"minutely",
"secondly"
"secondly",
"microsecond",
"none"
]
},
"CustomInterval": {
Expand All @@ -238,7 +246,6 @@
"DetectRequest": {
"type": "object",
"required": [
"granularity",
"series"
],
"properties": {
Expand Down Expand Up @@ -270,20 +277,23 @@
"type": "integer",
"format": "int32",
"description": "Optional argument, advanced model parameter, between 0-99, the lower the value is, the larger the margin value will be which means less anomalies will be accepted."
},
"imputeStrategy": {
"$ref": "#/definitions/ImputeStrategy",
"description": "Optional argument, indicates how to impute the missing values in the series."
}
}
},
"TimeSeriesPoint": {
"type": "object",
"required": [
"timestamp",
"value"
],
"properties": {
"timestamp": {
"type": "string",
"format": "date-time",
"description": "Timestamp of a data point (ISO8601 format)."
"description": "Optional argument, timestamp of a data point (ISO8601 format)."
},
"value": {
"type": "number",
Expand Down Expand Up @@ -455,22 +465,19 @@
},
"ChangePointDetectResponse": {
"type": "object",
"required": [
"isChangePoint",
"confidenceScores",
"period"
],
"properties": {
"period": {
"type": "integer",
"format": "int32",
"readOnly": true,
"description": "Frequency extracted from the series, zero means no recurrent pattern has been found."
},
"isChangePoint": {
"type": "array",
"description": "isChangePoint contains change point properties for each input point. True means an anomaly either negative or positive has been detected. The index of the array is consistent with the input series.",
"items": {
"type": "boolean",
"readOnly": true,
"x-nullable": false
}
},
Expand All @@ -480,6 +487,7 @@
"items": {
"type": "number",
"format": "float",
"readOnly": true,
"x-nullable": false
}
}
Expand Down