From 3271b347476abbfa5a59bd30301ac5c028516f67 Mon Sep 17 00:00:00 2001 From: lcawl Date: Wed, 17 Nov 2021 08:37:22 -0800 Subject: [PATCH 1/3] [DOCS] Add missing query parameter in get influencers API --- .../apis/get-influencer.asciidoc | 32 ++++--------------- 1 file changed, 7 insertions(+), 25 deletions(-) diff --git a/docs/reference/ml/anomaly-detection/apis/get-influencer.asciidoc b/docs/reference/ml/anomaly-detection/apis/get-influencer.asciidoc index 2a47765dcb2c7..4c508ded0a144 100644 --- a/docs/reference/ml/anomaly-detection/apis/get-influencer.asciidoc +++ b/docs/reference/ml/anomaly-detection/apis/get-influencer.asciidoc @@ -40,6 +40,11 @@ include::{es-repo-dir}/ml/ml-shared.asciidoc[tag=job-id-anomaly-detection] (Optional, Boolean) include::{es-repo-dir}/ml/ml-shared.asciidoc[tag=desc-results] +`end`:: +(Optional, string) Returns influencers with timestamps earlier than this time. +Defaults to `-1`, which means it is unset and results are not limited to +specific timestamps. + `exclude_interim`:: (Optional, Boolean) include::{es-repo-dir}/ml/ml-shared.asciidoc[tag=exclude-interim-results] @@ -69,22 +74,8 @@ timestamps. [[ml-get-influencer-request-body]] == {api-request-body-title} -`desc`:: -(Optional, Boolean) -include::{es-repo-dir}/ml/ml-shared.asciidoc[tag=desc-results] - -`end`:: -(Optional, string) Returns influencers with timestamps earlier than this time. -Defaults to `-1`, which means it is unset and results are not limited to -specific timestamps. - -`exclude_interim`:: -(Optional, Boolean) -include::{es-repo-dir}/ml/ml-shared.asciidoc[tag=exclude-interim-results] - -`influencer_score`:: -(Optional, double) Returns influencers with anomaly scores greater than or -equal to this value. Defaults to `0.0`. +You can also specify the query parameters (such as `desc` and +`end`) in the request body. `page`.`from`:: (Optional, integer) Skips the specified number of influencers. Defaults to `0`. @@ -93,15 +84,6 @@ equal to this value. Defaults to `0.0`. (Optional, integer) Specifies the maximum number of influencers to obtain. Defaults to `100`. -`sort`:: -(Optional, string) Specifies the sort field for the requested influencers. By -default, the influencers are sorted by the `influencer_score` value. - -`start`:: -(Optional, string) Returns influencers with timestamps after this time. Defaults -to `-1`, which means it is unset and results are not limited to specific -timestamps. - [[ml-get-influencer-results]] == {api-response-body-title} From 0e6b28ef200171aa23acdcedef6e282c27ea55c7 Mon Sep 17 00:00:00 2001 From: lcawl Date: Wed, 17 Nov 2021 08:53:53 -0800 Subject: [PATCH 2/3] [DOCS] Adds missing query parameters to get snapshots API --- .../apis/get-snapshot.asciidoc | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) diff --git a/docs/reference/ml/anomaly-detection/apis/get-snapshot.asciidoc b/docs/reference/ml/anomaly-detection/apis/get-snapshot.asciidoc index 4c44167d85535..ea9af69414a05 100644 --- a/docs/reference/ml/anomaly-detection/apis/get-snapshot.asciidoc +++ b/docs/reference/ml/anomaly-detection/apis/get-snapshot.asciidoc @@ -39,9 +39,8 @@ You can get all snapshots for all calendars by using `_all`, by specifying `*` as the ``, or by omitting the ``. -- - -[[ml-get-snapshot-request-body]] -== {api-request-body-title} +[[ml-get-snapshot-query-parms]] +== {api-query-parms-title} `desc`:: (Optional, Boolean) If true, the results are sorted in descending order. @@ -66,6 +65,19 @@ by specifying `*` as the ``, or by omitting the ``. (Optional, string) Returns snapshots with timestamps after this time. Defaults to unset, which means results are not limited to specific timestamps. +[[ml-get-snapshot-request-body]] +== {api-request-body-title} + +You can also specify the query parameters (such as `desc` and +`end`) in the request body. + +`page`.`from`:: +(Optional, integer) Skips the specified number of snapshots. Defaults to `0`. + +`page`.`size`:: +(Optional, integer) Specifies the maximum number of snapshots to obtain. +Defaults to `100`. + [role="child_attributes"] [[ml-get-snapshot-results]] == {api-response-body-title} From 2a34f6a97551acad02248e9e5455e745fb3cab70 Mon Sep 17 00:00:00 2001 From: lcawl Date: Wed, 17 Nov 2021 09:41:33 -0800 Subject: [PATCH 3/3] More edits --- .../apis/get-snapshot.asciidoc | 9 ++++---- docs/reference/ml/ml-shared.asciidoc | 22 +++++++++---------- 2 files changed, 15 insertions(+), 16 deletions(-) diff --git a/docs/reference/ml/anomaly-detection/apis/get-snapshot.asciidoc b/docs/reference/ml/anomaly-detection/apis/get-snapshot.asciidoc index ea9af69414a05..94c3ed5628126 100644 --- a/docs/reference/ml/anomaly-detection/apis/get-snapshot.asciidoc +++ b/docs/reference/ml/anomaly-detection/apis/get-snapshot.asciidoc @@ -33,10 +33,9 @@ include::{es-repo-dir}/ml/ml-shared.asciidoc[tag=job-id-anomaly-detection] include::{es-repo-dir}/ml/ml-shared.asciidoc[tag=snapshot-id] + -- -You can multiple snapshots for a single job in a single API request -by using a comma-separated list of `` or a wildcard expression. -You can get all snapshots for all calendars by using `_all`, -by specifying `*` as the ``, or by omitting the ``. +You can get information for multiple snapshots by using a comma-separated list +or a wildcard expression. You can get all snapshots by using `_all`, by +specifying `*` as the snapshot ID, or by omitting the snapshot ID. -- [[ml-get-snapshot-query-parms]] @@ -162,7 +161,7 @@ server-time. Contains one of the following values. + -- -* `hard_limit`: The internal models require more space that the configured +* `hard_limit`: The internal models require more space than the configured memory limit. Some incoming data could not be processed. * `ok`: The internal models stayed below the configured value. * `soft_limit`: The internal models require more than 60% of the configured diff --git a/docs/reference/ml/ml-shared.asciidoc b/docs/reference/ml/ml-shared.asciidoc index c9984ef00db17..1d01614a35246 100644 --- a/docs/reference/ml/ml-shared.asciidoc +++ b/docs/reference/ml/ml-shared.asciidoc @@ -109,19 +109,19 @@ Contains messages relating to the selection of a node. end::assignment-explanation-dfanalytics[] tag::assignment-memory-basis[] -Where should the memory requirement used for deciding which node the job -will run on come from? The possible values are: +Indicates where to find the memory requirement that is used to decide where the +job runs. The possible values are: + -- -* `model_memory_limit`: The job's memory requirement will be calculated on -the basis that its model memory will grow to the `model_memory_limit` -specified in the `analysis_limits` of its config. -* `current_model_bytes`: The job's memory requirement will be calculated on -the basis that its current model memory size is a good reflection of what -it will be in the future. -* `peak_model_bytes`: The job's memory requirement will be calculated on -the basis that its peak model memory size is a good reflection of what -the model size will be in the future. +* `model_memory_limit`: The job's memory requirement is calculated on the basis +that its model memory will grow to the `model_memory_limit` specified in the +`analysis_limits` of its config. +* `current_model_bytes`: The job's memory requirement is calculated on the basis +that its current model memory size is a good reflection of what it will be in +the future. +* `peak_model_bytes`: The job's memory requirement is calculated on the basis +that its peak model memory size is a good reflection of what the model size will +be in the future. -- end::assignment-memory-basis[]