Skip to content

Commit

Permalink
[DOCS] Fix titles for ML APIs (#63152) (#63207)
Browse files Browse the repository at this point in the history
  • Loading branch information
lcawl authored Oct 2, 2020
1 parent ade91a2 commit 4de6104
Show file tree
Hide file tree
Showing 46 changed files with 131 additions and 125 deletions.
6 changes: 3 additions & 3 deletions docs/java-rest/high-level/ml/close-job.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@
--
[role="xpack"]
[id="{upid}-{api}"]
=== Close {anomaly-job} API
=== Close {anomaly-jobs} API

Closes {anomaly-jobs} in the cluster. It accepts a +{request}+ object and responds with a +{response}+ object.

[id="{upid}-{api}-request"]
==== Close {anomaly-job} request
==== Close {anomaly-jobs} request

A +{request}+ object gets created with an existing non-null `jobId`.

Expand All @@ -27,7 +27,7 @@ which has not responded to its initial close request.
execution should wait for the job to be closed.

[id="{upid}-{api}-response"]
==== Close {anomaly-job} response
==== Close {anomaly-jobs} response

["source","java",subs="attributes,callouts,macros"]
--------------------------------------------------
Expand Down
7 changes: 4 additions & 3 deletions docs/java-rest/high-level/ml/delete-calendar-event.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,14 @@
--
[role="xpack"]
[id="{upid}-{api}"]
=== Delete calendar event API
=== Delete calendar events API

Removes a scheduled event from an existing {ml} calendar.
The API accepts a +{request}+ and responds
with a +{response}+ object.

[id="{upid}-{api}-request"]
==== Delete calendar event request
==== Delete calendar events request

A +{request}+ is constructed referencing a non-null
calendar ID, and eventId which to remove from the calendar
Expand All @@ -24,7 +25,7 @@ include-tagged::{doc-tests-file}[{api}-request]
<2> The eventId to remove from the calendar

[id="{upid}-{api}-response"]
==== Delete calendar event response
==== Delete calendar events response

The returned +{response}+ acknowledges the success of the request:

Expand Down
1 change: 1 addition & 0 deletions docs/java-rest/high-level/ml/delete-calendar-job.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
[role="xpack"]
[id="{upid}-{api}"]
=== Delete {anomaly-jobs} from calendar API

Removes {anomaly-jobs} from an existing {ml} calendar.
The API accepts a +{request}+ and responds
with a +{response}+ object.
Expand Down
9 changes: 5 additions & 4 deletions docs/java-rest/high-level/ml/delete-calendar.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,14 @@
--
[role="xpack"]
[id="{upid}-{api}"]
=== Delete calendar API
Delete a {ml} calendar.
=== Delete calendars API

Deletes a {ml} calendar.
The API accepts a +{request}+ and responds
with a +{response}+ object.

[id="{upid}-{api}-request"]
==== Delete calendar request
==== Delete calendars request

A `DeleteCalendar` object requires a non-null `calendarId`.

Expand All @@ -22,7 +23,7 @@ include-tagged::{doc-tests-file}[{api}-request]
<1> Constructing a new request referencing an existing calendar

[id="{upid}-{api}-response"]
==== Delete calendar response
==== Delete calendars response

The returned +{response}+ object indicates the acknowledgement of the request:
["source","java",subs="attributes,callouts,macros"]
Expand Down
6 changes: 3 additions & 3 deletions docs/java-rest/high-level/ml/delete-datafeed.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@
--
[role="xpack"]
[id="{upid}-delete-datafeed"]
=== Delete datafeed API
=== Delete datafeeds API

Deletes an existing datafeed.

[id="{upid}-{api}-request"]
==== Delete datafeed request
==== Delete datafeeds request

A +{request}+ object requires a non-null `datafeedId` and can optionally set `force`.

Expand All @@ -24,7 +24,7 @@ stopping and deleting the datafeed. Defaults to `false`.
include::../execution.asciidoc[]

[id="{upid}-{api}-response"]
==== Delete datafeed response
==== Delete datafeeds response

The returned +{response}+ object indicates the acknowledgement of the request:
["source","java",subs="attributes,callouts,macros"]
Expand Down
3 changes: 2 additions & 1 deletion docs/java-rest/high-level/ml/delete-expired-data.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,8 @@
[role="xpack"]
[id="{upid}-{api}"]
=== Delete expired data API
Delete expired {ml} data.

Deletes expired {ml} data.
The API accepts a +{request}+ and responds
with a +{response}+ object.

Expand Down
9 changes: 5 additions & 4 deletions docs/java-rest/high-level/ml/delete-filter.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,14 @@
--
[role="xpack"]
[id="{upid}-{api}"]
=== Delete filter API
Delete a {ml} filter.
=== Delete filters API

Deletes a {ml} filter.
The API accepts a +{request}+ and responds
with a +{response}+ object.

[id="{upid}-{api}-request"]
==== Delete filter request
==== Delete filters request

A +{request}+ object requires a non-null `filterId`.

Expand All @@ -22,7 +23,7 @@ include-tagged::{doc-tests-file}[{api}-request]
<1> Constructing a new request referencing an existing filter

[id="{upid}-{api}-response"]
==== Delete filter response
==== Delete filters response

The returned +{response}+ object indicates the acknowledgement of the request:
["source","java",subs="attributes,callouts,macros"]
Expand Down
9 changes: 4 additions & 5 deletions docs/java-rest/high-level/ml/delete-forecast.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,14 @@
--
[role="xpack"]
[id="{upid}-{api}"]
=== Delete forecast API
=== Delete forecasts API

The delete forecast API provides the ability to delete a {ml} job's
forecast in the cluster.
Deletes forecasts from an {anomaly-job}.
It accepts a +{request}+ object and responds
with an +{response}+ object.

[id="{upid}-{api}-request"]
==== Delete forecast request
==== Delete forecasts request

A +{request}+ object gets created with an existing non-null `jobId`.
All other fields are optional for the request.
Expand All @@ -39,7 +38,7 @@ include-tagged::{doc-tests-file}[{api}-request-options]
request finds no forecasts. It defaults to `true`

[id="{upid}-{api}-response"]
==== Delete forecast response
==== Delete forecasts response

An +{response}+ contains an acknowledgement of the forecast(s) deletion

Expand Down
6 changes: 3 additions & 3 deletions docs/java-rest/high-level/ml/delete-job.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@
--
[role="xpack"]
[id="{upid}-{api}"]
=== Delete {anomaly-job} API
=== Delete {anomaly-jobs} API

Deletes an {anomaly-job} that exists in the cluster.

[id="{upid}-{api}-request"]
==== Delete {anomaly-job} request
==== Delete {anomaly-jobs} request

A +{request}+ object requires a non-null `jobId` and can optionally set `force`.

Expand Down Expand Up @@ -40,7 +40,7 @@ before returning. Defaults to `true`.


[id="{upid}-{api}-response"]
==== Delete {anomaly-job} response
==== Delete {anomaly-jobs} response

The returned +{response}+ object indicates the acknowledgement of the job
deletion or the deletion task depending on whether the request was set to wait
Expand Down
8 changes: 5 additions & 3 deletions docs/java-rest/high-level/ml/delete-model-snapshot.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,12 @@
--
[role="xpack"]
[id="{upid}-{api}"]
=== Delete model snapshot API
=== Delete model snapshots API

Deletes an existing model snapshot.

[id="{upid}-{api}-request"]
==== Delete model snapshot request
==== Delete model snapshots request

A +{request}+ object requires both a non-null `jobId` and a non-null `snapshotId`.

Expand All @@ -21,7 +23,7 @@ include-tagged::{doc-tests-file}[{api}-request]
include::../execution.asciidoc[]

[id="{upid}-{api}-response"]
==== Delete model snapshot response
==== Delete model snapshots response

The returned +{response}+ object indicates the acknowledgement of the request:
["source","java",subs="attributes,callouts,macros"]
Expand Down
4 changes: 2 additions & 2 deletions docs/java-rest/high-level/ml/delete-trained-models.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,15 @@
--
[role="xpack"]
[id="{upid}-{api}"]
=== Delete trained model API
=== Delete trained models API

experimental::[]

Deletes a previously saved trained model.
The API accepts a +{request}+ object and returns a +{response}+.

[id="{upid}-{api}-request"]
==== Delete trained model request
==== Delete trained models request

A +{request}+ requires a valid trained model ID.

Expand Down
2 changes: 1 addition & 1 deletion docs/java-rest/high-level/ml/evaluate-data-frame.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

experimental::[]

Evaluates the {ml} algorithm that ran on a {dataframe}.
Evaluates the {dfanalytics} for an annotated index.
The API accepts an +{request}+ object and returns an +{response}+.

[id="{upid}-{api}-request"]
Expand Down
13 changes: 6 additions & 7 deletions docs/java-rest/high-level/ml/find-file-structure.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,12 @@

experimental::[]

The Find File Structure API can be used to find the structure of a text file
and other information that will be useful to import its contents to an {es}
index. It accepts a +{request}+ object and responds
with a +{response}+ object.
Determines the structure of a text file and other information that will be
useful to import its contents to an {es} index. It accepts a +{request}+ object
and responds with a +{response}+ object.

[id="{upid}-{api}-request"]
==== Find File Structure Request
==== Find file structure request

A sample from the beginning of the file (or the entire file contents if
it's small) must be added to the +{request}+ object using the
Expand All @@ -28,7 +27,7 @@ include-tagged::{doc-tests-file}[{api}-request]
<1> Create a new `FindFileStructureRequest` object
<2> Add the contents of `anInterestingFile` to the request

==== Optional Arguments
==== Optional arguments

The following arguments are optional.

Expand All @@ -43,7 +42,7 @@ include-tagged::{doc-tests-file}[{api}-request-options]
include::../execution.asciidoc[]

[id="{upid}-{api}-response"]
==== Find File Structure Response
==== Find file structure response

A +{response}+ contains information about the file structure,
as well as mappings and an ingest pipeline that could be used
Expand Down
9 changes: 4 additions & 5 deletions docs/java-rest/high-level/ml/flush-job.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,14 @@
--
[role="xpack"]
[id="{upid}-{api}"]
=== Flush job API
=== Flush jobs API

The flush job API provides the ability to flush a {ml} job's
datafeed in the cluster.
Flushes an anomaly detection job's datafeed in the cluster.
It accepts a +{request}+ object and responds
with a +{response}+ object.

[id="{upid}-{api}-request"]
==== Flush job request
==== Flush jobs request

A +{request}+ object gets created with an existing non-null `jobId`.
All other fields are optional for the request.
Expand Down Expand Up @@ -41,7 +40,7 @@ to calculate interim results (requires `calc_interim` to be `true`)
<5> Set the skip time to skip a particular time value

[id="{upid}-{api}-response"]
==== Flush job response
==== Flush jobs response

A +{response}+ contains an acknowledgement and an optional end date for the
last finalized bucket
Expand Down
12 changes: 5 additions & 7 deletions docs/java-rest/high-level/ml/forecast-job.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,13 @@
--
[role="xpack"]
[id="{upid}-{api}"]
=== Forecast job API
=== Forecast jobs API

The forecast job API provides the ability to forecast a {ml} job's behavior based
on historical data.
It accepts a +{request}+ object and responds
with a +{response}+ object.
Forecasts a {ml} job's behavior based on historical data. It accepts a
+{request}+ object and responds with a +{response}+ object.

[id="{upid}-{api}-request"]
==== Forecast job request
==== Forecast jobs request

A +{request}+ object gets created with an existing non-null `jobId`.
All other fields are optional for the request.
Expand All @@ -40,7 +38,7 @@ include-tagged::{doc-tests-file}[{api}-request-options]
automatically reduced to below that number.

[id="{upid}-{api}-response"]
==== Forecast job response
==== Forecast jobs response

A +{response}+ contains an acknowledgement and the forecast ID

Expand Down
5 changes: 3 additions & 2 deletions docs/java-rest/high-level/ml/get-calendar-events.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,13 @@
[role="xpack"]
[id="{upid}-{api}"]
=== Get calendar events API

Retrieves a calendar's events.
It accepts a +{request}+ and responds
with a +{response}+ object.

[id="{upid}-{api}-request"]
==== Get calendars request
==== Get calendar events request

A +{request}+ requires a non-null calendar ID.
Using the literal `_all` returns the events for all calendars.
Expand Down Expand Up @@ -54,7 +55,7 @@ include-tagged::{doc-tests-file}[{api}-jobid]
include::../execution.asciidoc[]

[id="{upid}-{api}-response"]
==== Get calendars response
==== Get calendar events response

The returned +{response}+ contains the requested events:

Expand Down
1 change: 1 addition & 0 deletions docs/java-rest/high-level/ml/get-calendars.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
[role="xpack"]
[id="{upid}-{api}"]
=== Get calendars API

Retrieves one or more calendar objects.
It accepts a +{request}+ and responds
with a +{response}+ object.
Expand Down
6 changes: 3 additions & 3 deletions docs/java-rest/high-level/ml/get-datafeed.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,13 @@
--
[role="xpack"]
[id="{upid}-{api}"]
=== Get datafeed API
=== Get datafeeds API

Retrieves configuration information about {ml} datafeeds in the cluster.
It accepts a +{request}+ object and responds with a +{response}+ object.

[id="{upid}-{api}-request"]
==== Get datafeed request
==== Get datafeeds request

A +{request}+ object gets can have any number of `datafeedId` entries. However,
they all must be non-null. An empty list is the same as requesting for all
Expand All @@ -27,7 +27,7 @@ contain wildcards.
(This includes `_all` string or when no datafeeds have been specified).

[id="{upid}-{api}-response"]
==== Get datafeed response
==== Get datafeeds response

["source","java",subs="attributes,callouts,macros"]
--------------------------------------------------
Expand Down
Loading

0 comments on commit 4de6104

Please sign in to comment.