[DOCS] Update ML APIs for Elasticsearch Reference (elastic/x-pack-elasticsearch#1718)

* [DOCS] Update ML APIs for Elasticsearch Reference

* [DOCS] Add X-Pack icon for ML APIs

* [DOCS] Add role attribute to ML APIs

Original commit: elastic/x-pack-elasticsearch@997ea39759
This commit is contained in:
Lisa Cawley 2017-06-19 18:23:58 -07:00 committed by GitHub
parent 551f2f6ac2
commit b41ff62bcc
36 changed files with 145 additions and 76 deletions

View File

@ -1,3 +1,4 @@
[role="xpack"]
[[ml-api-definitions]]
== Definitions
@ -11,8 +12,13 @@ job configuration options.
* <<ml-snapshot-resource,Model snapshots>>
* <<ml-results-resource,Results>>
[role="xpack"]
include::ml/datafeedresource.asciidoc[]
[role="xpack"]
include::ml/jobresource.asciidoc[]
[role="xpack"]
include::ml/jobcounts.asciidoc[]
[role="xpack"]
include::ml/snapshotresource.asciidoc[]
[role="xpack"]
include::ml/resultsresource.asciidoc[]

View File

@ -10,8 +10,8 @@
//* <<security-api, Security APIs>>
//* <<watcher-api, Watcher APIs>>
//* <<graph-api, Graph APIs>>
//* <<ml-apis, Machine Learning APIs>>
//* <<ml-api-definitions, Definitions>>
* <<ml-apis, Machine Learning APIs>>
* <<ml-api-definitions, Definitions>>
--
[role="xpack"]
@ -120,5 +120,5 @@ GET /_xpack?human=false
//include::watcher.asciidoc[]
//include::graph.asciidoc[]
//include::ml-api.asciidoc[]
//include::defs.asciidoc[]
include::ml-api.asciidoc[]
include::defs.asciidoc[]

View File

@ -1,3 +1,4 @@
[role="xpack"]
[[ml-apis]]
== Machine Learning APIs

View File

@ -1,4 +1,4 @@
//lcawley Verified example output 2017-04-11
[role="xpack"]
[[ml-close-job]]
=== Close Jobs
@ -58,7 +58,8 @@ results the job might have recently produced or might produce in the future.
==== Authorization
You must have `manage_ml`, or `manage` cluster privileges to use this API.
For more information, see <<privileges-list-cluster>>.
For more information, see {xpack-ref}/security-privileges.html[Security Privileges].
//<<privileges-list-cluster>>.
==== Examples

View File

@ -1,4 +1,4 @@
//lcawley Verified example output 2017-04-11
[role="xpack"]
[[ml-datafeed-resource]]
=== {dfeed-cap} Resources
@ -7,8 +7,9 @@ A {dfeed} resource has the following properties:
`aggregations`::
(object) If set, the {dfeed} performs aggregation searches.
Support for aggregations is limited and should only be used with
low cardinality data. For more information,
see <<ml-configuring-aggregation>>.
low cardinality data. For more information, see
{xpack-ref}/ml-configuring-aggregation.html[Aggregating Data for Faster Performance].
//<<ml-configuring-aggregation>>.
`chunking_config`::
(object) Specifies how data searches are split into time chunks.

View File

@ -1,4 +1,4 @@
//lcawley Verified example output 2017-04-11
[role="xpack"]
[[ml-delete-datafeed]]
=== Delete {dfeeds-cap}
@ -31,7 +31,8 @@ NOTE: Unless the `force` parameter is used, the {dfeed} must be stopped before i
===== Authorization
You must have `manage_ml`, or `manage` cluster privileges to use this API.
For more information, see <<privileges-list-cluster>>.
For more information, see {xpack-ref}/security-privileges.html[Security Privileges].
//<<privileges-list-cluster>>.
==== Examples

View File

@ -1,4 +1,4 @@
//lcawley: Verified example output 2017-04-11
[role="xpack"]
[[ml-delete-job]]
=== Delete Jobs
@ -41,7 +41,8 @@ separated list.
==== Authorization
You must have `manage_ml`, or `manage` cluster privileges to use this API.
For more information, see <<privileges-list-cluster>>.
For more information, see {xpack-ref}/security-privileges.html[Security Privileges].
//<<privileges-list-cluster>>.
==== Examples

View File

@ -1,3 +1,4 @@
[role="xpack"]
[[ml-delete-snapshot]]
=== Delete Model Snapshots
@ -13,7 +14,7 @@ The delete model snapshot API enables you to delete an existing model snapshot.
IMPORTANT: You cannot delete the active model snapshot. To delete that snapshot,
first revert to a different one. To identify the active model snapshot, refer to
the `model_snapshot_id` in the results from the get jobs API.
the `model_snapshot_id` in the results from the get jobs API.
==== Path Parameters
@ -27,7 +28,8 @@ the `model_snapshot_id` in the results from the get jobs API.
==== Authorization
You must have `manage_ml`, or `manage` cluster privileges to use this API.
For more information, see <<privileges-list-cluster>>.
For more information, see {xpack-ref}/security-privileges.html[Security Privileges].
//<<privileges-list-cluster>>.
==== Examples

View File

@ -1,4 +1,4 @@
//lcawley: Verified example output 2017-04-11
[role="xpack"]
[[ml-flush-job]]
=== Flush Jobs
@ -50,7 +50,8 @@ opened again before analyzing further data.
==== Authorization
You must have `manage_ml`, or `manage` cluster privileges to use this API.
For more information, see <<privileges-list-cluster>>.
For more information, see {xpack-ref}/security-privileges.html[Security Privileges].
//<<privileges-list-cluster>>.
==== Examples

View File

@ -1,4 +1,4 @@
//lcawley Verified example output 2017-04-11
[role="xpack"]
[[ml-get-bucket]]
=== Get Buckets
@ -75,7 +75,9 @@ You must have `monitor_ml`, `monitor`, `manage_ml`, or `manage` cluster
privileges to use this API. You also need `read` index privilege on the index
that stores the results. The `machine_learning_admin` and `machine_learning_user`
roles provide these privileges. For more information, see
<<security-privileges>> and <<built-in-roles>>.
{xpack-ref}/security-privileges.html[Security Privileges] and
{xpack-ref}/built-in-roles.html[Built-in Roles].
//<<security-privileges>> and <<built-in-roles>>.
==== Examples

View File

@ -1,4 +1,4 @@
//lcawley Verified example output 2017-04-11
[role="xpack"]
[[ml-get-category]]
=== Get Categories
@ -14,7 +14,9 @@ categories.
==== Description
For more information about categories, see <<ml-configuring-categories>>.
For more information about categories, see
{xpack-ref}/ml-configuring-categories.html[Categorizing Log Messages].
//<<ml-configuring-categories>>.
==== Path Parameters
@ -41,7 +43,7 @@ The API returns the following information:
`categories`::
(array) An array of category objects. For more information, see
<<ml-results-categories,Categories>>.
<<ml-results-categories,Categories>>.
==== Authorization
@ -50,7 +52,9 @@ You must have `monitor_ml`, `monitor`, `manage_ml`, or `manage` cluster
privileges to use this API. You also need `read` index privilege on the index
that stores the results. The `machine_learning_admin` and `machine_learning_user`
roles provide these privileges. For more information, see
<<security-privileges>> and <<built-in-roles>>.
{xpack-ref}/security-privileges.html[Security Privileges] and
{xpack-ref}/built-in-roles.html[Built-in Roles].
//<<security-privileges>> and <<built-in-roles>>.
==== Examples

View File

@ -1,4 +1,4 @@
//lcawley Verified example output 2017-04-11
[role="xpack"]
[[ml-get-datafeed-stats]]
=== Get {dfeed-cap} Statistics
@ -39,7 +39,9 @@ The API returns the following information:
==== Authorization
You must have `monitor_ml`, `monitor`, `manage_ml`, or `manage` cluster
privileges to use this API. For more information, see <<privileges-list-cluster>>.
privileges to use this API. For more information, see
{xpack-ref}/security-privileges.html[Security Privileges].
//<<privileges-list-cluster>>.
==== Examples

View File

@ -1,4 +1,4 @@
//lcawley Verified example output 2017-04-11
[role="xpack"]
[[ml-get-datafeed]]
=== Get {dfeeds-cap}
@ -33,7 +33,9 @@ The API returns the following information:
==== Authorization
You must have `monitor_ml`, `monitor`, `manage_ml`, or `manage` cluster
privileges to use this API. For more information, see <<privileges-list-cluster>>.
privileges to use this API. For more information, see
{xpack-ref}/security-privileges.html[Security Privileges].
//<<privileges-list-cluster>>.
==== Examples

View File

@ -1,3 +1,4 @@
[role="xpack"]
[[ml-get-influencer]]
=== Get Influencers
@ -60,7 +61,9 @@ You must have `monitor_ml`, `monitor`, `manage_ml`, or `manage` cluster
privileges to use this API. You also need `read` index privilege on the index
that stores the results. The `machine_learning_admin` and `machine_learning_user`
roles provide these privileges. For more information, see
<<security-privileges>> and <<built-in-roles>>.
{xpack-ref}/security-privileges.html[Security Privileges] and
{xpack-ref}/built-in-roles.html[Built-in Roles].
//<<security-privileges>> and <<built-in-roles>>.
==== Examples

View File

@ -1,4 +1,4 @@
//lcawley Verified example output 2017-04-11
[role="xpack"]
[[ml-get-job-stats]]
=== Get Job Statistics
@ -33,7 +33,9 @@ The API returns the following information:
==== Authorization
You must have `monitor_ml`, `monitor`, `manage_ml`, or `manage` cluster
privileges to use this API. For more information, see <<privileges-list-cluster>>.
privileges to use this API. For more information, see
{xpack-ref}/security-privileges.html[Security Privileges].
//<<privileges-list-cluster>>.
==== Examples

View File

@ -1,4 +1,4 @@
//lcawley Verified example output 2017-04-11
[role="xpack"]
[[ml-get-job]]
=== Get Jobs
@ -33,7 +33,9 @@ The API returns the following information:
==== Authorization
You must have `monitor_ml`, `monitor`, `manage_ml`, or `manage` cluster
privileges to use this API. For more information, see <<privileges-list-cluster>>.
privileges to use this API. For more information, see
{xpack-ref}/security-privileges.html[Security Privileges].
//<<privileges-list-cluster>>.
==== Examples

View File

@ -1,5 +1,5 @@
[role="xpack"]
[[ml-get-record]]
//lcawley Verified example output 2017-04-11
=== Get Records
The get records API enables you to retrieve anomaly records for a job.
@ -61,7 +61,9 @@ You must have `monitor_ml`, `monitor`, `manage_ml`, or `manage` cluster
privileges to use this API. You also need `read` index privilege on the index
that stores the results. The `machine_learning_admin` and `machine_learning_user`
roles provide these privileges. For more information, see
<<security-privileges>> and <<built-in-roles>>.
{xpack-ref}/security-privileges.html[Security Privileges] and
{xpack-ref}/built-in-roles.html[Built-in Roles].
//<<security-privileges>> and <<built-in-roles>>.
==== Examples

View File

@ -1,4 +1,4 @@
//lcawley Verified example output 2017-04-11
[role="xpack"]
[[ml-get-snapshot]]
=== Get Model Snapshots
@ -56,7 +56,9 @@ The API returns the following information:
==== Authorization
You must have `monitor_ml`, `monitor`, `manage_ml`, or `manage` cluster
privileges to use this API. For more information, see <<privileges-list-cluster>>.
privileges to use this API. For more information, see
{xpack-ref}/security-privileges.html[Security Privileges].
//<<privileges-list-cluster>>.
==== Examples

View File

@ -1,4 +1,4 @@
//lcawley Verified example output 2017-04-11
[role="xpack"]
[[ml-jobstats]]
=== Job Statistics

View File

@ -1,4 +1,4 @@
//lcawley Verified example output 2017-04-11
[role="xpack"]
[[ml-job-resource]]
=== Job Resources
@ -85,7 +85,9 @@ An analysis configuration object has the following properties:
(string) If not null, the values of the specified field will be categorized.
The resulting categories can be used in a detector by setting `by_field_name`,
`over_field_name`, or `partition_field_name` to the keyword `mlcategory`.
For more information, see <<ml-configuring-categories>>.
For more information, see
{xpack-ref}/ml-configuring-categories.html[Categorizing Log Messages].
//<<ml-configuring-categories>>.
`categorization_filters`::
(array of strings) If `categorization_field_name` is specified,
@ -94,8 +96,9 @@ An analysis configuration object has the following properties:
off the categorization field values. This functionality is useful to fine tune
categorization by excluding sequences that should not be taken into
consideration for defining categories. For example, you can exclude SQL
statements that appear in your log files. For more information,
see <<ml-configuring-categories>>.
statements that appear in your log files. For more information, see
{xpack-ref}/ml-configuring-categories.html[Categorizing Log Messages].
//<<ml-configuring-categories>>.
`detectors`::
(array) An array of detector configuration objects,
@ -185,7 +188,8 @@ NOTE: The `field_name` cannot contain double quotes or backslashes.
`function`::
(string) The analysis function that is used.
For example, `count`, `rare`, `mean`, `min`, `max`, and `sum`. For more
information, see <<ml-functions>>.
information, see {xpack-ref}/ml-functions.html[Function Reference].
//<<ml-functions>>.
`over_field_name`::
(string) The field used to split the data.
@ -265,7 +269,10 @@ The `analysis_limits` object has the following properties:
If you set this value to `0`, no examples are stored. +
NOTE: The `categorization_examples_limit` only applies to analysis that uses categorization.
For more information, see <<ml-configuring-categories>>.
For more information, see
{xpack-ref}/ml-configuring-categories.html[Categorizing Log Messages].
//<<ml-configuring-categories>>.
`model_memory_limit`::
(long) The approximate maximum amount of memory resources that are required

View File

@ -1,4 +1,4 @@
//lcawley Verified example output 2017-04-11
[role="xpack"]
[[ml-open-job]]
=== Open Jobs
@ -41,7 +41,9 @@ The job is ready to resume its analysis from where it left off, once new data is
==== Authorization
You must have `manage_ml`, or `manage` cluster privileges to use this API.
For more information, see <<privileges-list-cluster>>.
For more information, see
{xpack-ref}/security-privileges.html[Security Privileges].
//<<privileges-list-cluster>>.
==== Examples

View File

@ -1,4 +1,4 @@
//lcawley: Verified example output 2017-04-11
[role="xpack"]
[[ml-post-data]]
=== Post Data to Jobs
@ -53,7 +53,9 @@ or a comma-separated list.
==== Authorization
You must have `manage_ml`, or `manage` cluster privileges to use this API.
For more information, see <<privileges-list-cluster>>.
For more information, see
{xpack-ref}/security-privileges.html[Security Privileges].
//<<privileges-list-cluster>>.
==== Examples

View File

@ -1,4 +1,4 @@
//lcawley: Verified example output 2017-04-11
[role="xpack"]
[[ml-preview-datafeed]]
=== Preview {dfeeds-cap}
@ -26,7 +26,9 @@ the data that will be passed to the anomaly detection engine.
==== Authorization
You must have `monitor_ml`, `monitor`, `manage_ml`, or `manage` cluster
privileges to use this API. For more information, see <<privileges-list-cluster>>.
privileges to use this API. For more information, see
{xpack-ref}/security-privileges.html[Security Privileges].
//<<privileges-list-cluster>>.
==== Examples

View File

@ -1,4 +1,4 @@
//lcawley Verified example output 2017-04-11
[role="xpack"]
[[ml-put-datafeed]]
=== Create {dfeeds-cap}
@ -80,7 +80,9 @@ see <<ml-datafeed-resource>>.
==== Authorization
You must have `manage_ml`, or `manage` cluster privileges to use this API.
For more information, see <<privileges-list-cluster>>.
For more information, see
{xpack-ref}/security-privileges.html[Security Privileges].
//<<privileges-list-cluster>>.
==== Examples

View File

@ -1,4 +1,4 @@
//lcawley Verified example output 2017-04-11
[role="xpack"]
[[ml-put-job]]
=== Create Jobs
@ -46,7 +46,9 @@ The create job API enables you to instantiate a job.
==== Authorization
You must have `manage_ml`, or `manage` cluster privileges to use this API.
For more information, see <<privileges-list-cluster>>.
For more information, see
{xpack-ref}/security-privileges.html[Security Privileges].
//<<privileges-list-cluster>>.
==== Examples

View File

@ -1,4 +1,4 @@
//lcawley Verified example output 2017-04-11
[role="xpack"]
[[ml-results-resource]]
=== Results Resources
@ -34,8 +34,9 @@ the anomalous behavior.
Categorization results contain the definitions of _categories_ that have been
identified. These are only applicable for jobs that are configured to analyze
unstructured log data using categorization. These results do not contain a
timestamp or any calculated scores. For more information,
see <<ml-configuring-categories>>.
timestamp or any calculated scores. For more information, see
{xpack-ref}/ml-configuring-categories.html[Categorizing Log Messages].
//<<ml-configuring-categories>>.
* <<ml-results-buckets,Buckets>>
* <<ml-results-influencers,Influencers>>

View File

@ -1,4 +1,4 @@
//lcawley Verified example output 2017-04-11
[role="xpack"]
[[ml-revert-snapshot]]
=== Revert Model Snapshots
@ -72,7 +72,9 @@ If you want to resend data, then delete the intervening results.
==== Authorization
You must have `manage_ml`, or `manage` cluster privileges to use this API.
For more information, see <<privileges-list-cluster>>.
For more information, see
{xpack-ref}/security-privileges.html[Security Privileges].
//<<privileges-list-cluster>>.
==== Examples

View File

@ -1,4 +1,4 @@
//lcawley Verified example output 2017-04-11
[role="xpack"]
[[ml-snapshot-resource]]
=== Model Snapshot Resources

View File

@ -1,4 +1,4 @@
//lcawley Verified example output 2017-04
[role="xpack"]
[[ml-start-datafeed]]
=== Start {dfeeds-cap}
@ -73,7 +73,9 @@ of the latest processed record.
==== Authorization
You must have `manage_ml`, or `manage` cluster privileges to use this API.
For more information, see <<privileges-list-cluster>>.
For more information, see
{xpack-ref}/security-privileges.html[Security Privileges].
//<<privileges-list-cluster>>.
==== Examples

View File

@ -1,4 +1,4 @@
//lcawley Verified example output 2017-04-11
[role="xpack"]
[[ml-stop-datafeed]]
=== Stop {dfeeds-cap}
@ -29,7 +29,9 @@ A {dfeed} can be started and stopped multiple times throughout its lifecycle.
==== Authorization
You must have `manage_ml`, or `manage` cluster privileges to use this API.
For more information, see <<privileges-list-cluster>>.
For more information, see
{xpack-ref}/security-privileges.html[Security Privileges].
//<<privileges-list-cluster>>.
==== Examples

View File

@ -1,4 +1,4 @@
//lcawley Verified example output 2017-04
[role="xpack"]
[[ml-update-datafeed]]
=== Update {dfeeds-cap}
@ -75,7 +75,9 @@ see <<ml-datafeed-resource>>.
==== Authorization
You must have `manage_ml`, or `manage` cluster privileges to use this API.
For more information, see <<privileges-list-cluster>>.
For more information, see
{xpack-ref}/security-privileges.html[Security Privileges].
//<<privileges-list-cluster>>.
==== Examples

View File

@ -1,4 +1,4 @@
//lcawley Verified example output 2017-04-11
[role="xpack"]
[[ml-update-job]]
=== Update Jobs
@ -74,7 +74,9 @@ want to re-run this job with an increased `model_memory_limit`.
==== Authorization
You must have `manage_ml`, or `manage` cluster privileges to use this API.
For more information, see <<privileges-list-cluster>>.
For more information, see
{xpack-ref}/security-privileges.html[Security Privileges].
//<<privileges-list-cluster>>.
==== Examples

View File

@ -1,4 +1,4 @@
//lcawley Verified example output 2017-04-11
[role="xpack"]
[[ml-update-snapshot]]
=== Update Model Snapshots
@ -42,7 +42,9 @@ The following properties can be updated after the model snapshot is created:
==== Authorization
You must have `manage_ml`, or `manage` cluster privileges to use this API.
For more information, see <<privileges-list-cluster>>.
For more information, see
{xpack-ref}/security-privileges.html[Security Privileges].
//<<privileges-list-cluster>>.
==== Examples

View File

@ -1,4 +1,4 @@
//lcawley Verified example output 2017-04-11
[role="xpack"]
[[ml-valid-detector]]
=== Validate Detectors
@ -22,7 +22,9 @@ see <<ml-detectorconfig,detector configuration objects>>.
==== Authorization
You must have `manage_ml`, or `manage` cluster privileges to use this API.
For more information, see <<privileges-list-cluster>>.
For more information, see
{xpack-ref}/security-privileges.html[Security Privileges].
//<<privileges-list-cluster>>.
==== Examples

View File

@ -1,4 +1,4 @@
//lcawley Verified example output 2017-04-11
[role="xpack"]
[[ml-valid-job]]
=== Validate Jobs
@ -22,7 +22,9 @@ see <<ml-job-resource,Job Resources>>.
==== Authorization
You must have `manage_ml`, or `manage` cluster privileges to use this API.
For more information, see <<privileges-list-cluster>>.
For more information, see
{xpack-ref}/security-privileges.html[Security Privileges].
//<<privileges-list-cluster>>.
==== Examples

View File

@ -9,7 +9,7 @@
* <<security-api, Security APIs>>
* <<watcher-api, Watcher APIs>>
* <<graph-api, Graph APIs>>
* <<ml-apis, Machine Learning APIs>>
* Machine Learning APIs
* <<ml-api-definitions, Definitions>>
--
@ -118,5 +118,5 @@ include::security.asciidoc[]
include::watcher.asciidoc[]
include::graph.asciidoc[]
include::ml-api.asciidoc[]
include::defs.asciidoc[]
//include::ml-api.asciidoc[]
//include::defs.asciidoc[]