获取机器学习信息 API编辑

返回机器学习使用的默认值和限制。

请求编辑

GET _ml/info

先决条件编辑

需要 monitor_ml 集群权限。此权限包含在 machine_learning_user 内置角色中。

描述编辑

此端点旨在供需要完全了解机器学习配置的用户界面使用,其中某些选项未指定,这意味着应使用默认值。此端点可用于查找这些默认值是什么。它还提供有关当前集群配置中可以运行的机器学习作业的最大大小的信息。

示例编辑

该端点不接受任何参数

response = client.ml.info
puts response
GET _ml/info

这是一种可能的响应

{
  "defaults" : {
    "anomaly_detectors" : {
      "categorization_analyzer" : {
        "char_filter" : [
          "first_line_with_letters"
        ],
        "tokenizer" : "ml_standard",
        "filter" : [
          {
            "type" : "stop",
            "stopwords" : [
              "Monday",
              "Tuesday",
              "Wednesday",
              "Thursday",
              "Friday",
              "Saturday",
              "Sunday",
              "Mon",
              "Tue",
              "Wed",
              "Thu",
              "Fri",
              "Sat",
              "Sun",
              "January",
              "February",
              "March",
              "April",
              "May",
              "June",
              "July",
              "August",
              "September",
              "October",
              "November",
              "December",
              "Jan",
              "Feb",
              "Mar",
              "Apr",
              "May",
              "Jun",
              "Jul",
              "Aug",
              "Sep",
              "Oct",
              "Nov",
              "Dec",
              "GMT",
              "UTC"
            ]
          },
          {
            "type": "limit",
            "max_token_count": "100"
          }
        ]
      },
      "model_memory_limit" : "1gb",
      "categorization_examples_limit" : 4,
      "model_snapshot_retention_days" : 10,
      "daily_model_snapshot_retention_after_days" : 1
    },
    "datafeeds" : {
      "scroll_size" : 1000
    }
  },
  "upgrade_mode": false,
  "native_code" : {
    "version": "7.0.0",
    "build_hash": "99a07c016d5a73"
  },
  "limits" : {
    "effective_max_model_memory_limit": "28961mb",
    "total_ml_memory": "86883mb",
    "total_ml_processors": 16,
    "max_single_ml_node_processors": 16
  }
}