Skip to content

Commit 19165e4

Browse files
author
David Roberts
committed
[ML] Add docs for ML info endpoint (#35783)
This endpoint was not previously documented as it was not particularly useful to end users. However, since the HLRC will support the endpoint we need some documentation to link to. The purpose of the endpoint is to provide defaults and limits used by ML. These are needed to fully understand configurations that have missing values because the missing value means the default should be used. Relates #35777
1 parent bb1efac commit 19165e4

File tree

2 files changed

+67
-0
lines changed

2 files changed

+67
-0
lines changed
Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
[role="xpack"]
2+
[testenv="platinum"]
3+
[[get-ml-info]]
4+
=== Get Machine Learning Info API
5+
++++
6+
<titleabbrev>Get Machine Learning Info</titleabbrev>
7+
++++
8+
9+
Returns defaults and limits used by machine learning.
10+
11+
==== Request
12+
13+
`GET _xpack/ml/info`
14+
15+
==== Description
16+
17+
This endpoint is designed to be used by a user interface that needs to fully
18+
understand machine learning configurations where some options are not specified,
19+
meaning that the defaults should be used. This endpoint may be used to find out
20+
what those defaults are.
21+
22+
23+
==== Authorization
24+
25+
You must have `monitor_ml`, `monitor`, `manage_ml`, or `manage` cluster
26+
privileges to use this API. The `machine_learning_admin` and `machine_learning_user`
27+
roles provide these privileges. For more information, see
28+
{stack-ov}/security-privileges.html[Security Privileges] and
29+
{stack-ov}/built-in-roles.html[Built-in Roles].
30+
31+
32+
==== Examples
33+
34+
The endpoint takes no arguments:
35+
36+
[source,js]
37+
--------------------------------------------------
38+
GET _xpack/ml/info
39+
--------------------------------------------------
40+
// CONSOLE
41+
// TEST
42+
43+
This is a possible response:
44+
[source,js]
45+
----
46+
{
47+
"defaults" : {
48+
"anomaly_detectors" : {
49+
"model_memory_limit" : "1gb",
50+
"categorization_examples_limit" : 4,
51+
"model_snapshot_retention_days" : 1
52+
},
53+
"datafeeds" : {
54+
"scroll_size" : 1000
55+
}
56+
},
57+
"limits" : { }
58+
}
59+
----
60+
// TESTRESPONSE

docs/reference/ml/apis/ml-api.asciidoc

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,12 @@ machine learning APIs and in advanced job configuration options in Kibana.
7676

7777
* <<ml-find-file-structure,Find file structure>>
7878

79+
[float]
80+
[[ml-api-ml-info-endpoint]]
81+
=== Info
82+
83+
* <<get-ml-info,Machine learning info>>
84+
7985
//ADD
8086
include::post-calendar-event.asciidoc[]
8187
include::put-calendar-job.asciidoc[]
@@ -111,6 +117,7 @@ include::get-datafeed-stats.asciidoc[]
111117
include::get-influencer.asciidoc[]
112118
include::get-job.asciidoc[]
113119
include::get-job-stats.asciidoc[]
120+
include::get-ml-info.asciidoc[]
114121
include::get-snapshot.asciidoc[]
115122
include::get-calendar-event.asciidoc[]
116123
include::get-filter.asciidoc[]

0 commit comments

Comments
 (0)