revert-model-snapshot.asciidoc 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. --
  2. :api: revert-model-snapshot
  3. :request: RevertModelSnapshotRequest
  4. :response: RevertModelSnapshotResponse
  5. --
  6. [role="xpack"]
  7. [id="{upid}-{api}"]
  8. === Revert model snapshots API
  9. Reverts to a previous {ml} model snapshot.
  10. It accepts a +{request}+ object and responds
  11. with a +{response}+ object.
  12. [id="{upid}-{api}-request"]
  13. ==== Revert model snapshots request
  14. A +{request}+ requires the following arguments:
  15. ["source","java",subs="attributes,callouts,macros"]
  16. --------------------------------------------------
  17. include-tagged::{doc-tests-file}[{api}-request]
  18. --------------------------------------------------
  19. <1> Constructing a new request referencing existing `jobId` and `snapshotId` values.
  20. ==== Optional arguments
  21. The following arguments are optional:
  22. ["source","java",subs="attributes,callouts,macros"]
  23. --------------------------------------------------
  24. include-tagged::{doc-tests-file}[{api}-delete-intervening-results]
  25. --------------------------------------------------
  26. <1> A flag indicating whether or not results in the period between the timestamp on the reverted snapshot and the latest results should be deleted
  27. include::../execution.asciidoc[]
  28. [id="{upid}-{api}-response"]
  29. ==== Revert job response
  30. A +{response}+ contains the full representation of the reverted `ModelSnapshot`.
  31. ["source","java",subs="attributes,callouts,macros"]
  32. --------------------------------------------------
  33. include-tagged::{doc-tests-file}[{api}-response]
  34. --------------------------------------------------
  35. <1> The reverted `ModelSnapshot`