{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://catalog.lintel.tools/schemas/schemastore/mlos-config-mlos-jsonc-mlos-json5-mlos-json/_shared/latest--cli-schema.json",
  "title": "mlos_bench CLI config",
  "description": "config for the mlos_bench cli args",
  "x-lintel": {
    "source": "https://raw.githubusercontent.com/microsoft/MLOS/main/mlos_bench/mlos_bench/config/schemas/cli/cli-schema.json",
    "sourceSha256": "9629eb6ca66a7bfb2f9bc5d049738252eb895a2608781691b08d9bcbf7310981"
  },
  "type": "object",
  "properties": {
    "$schema": {
      "description": "The schema to use for validating the config (accepts both URLs and local paths).",
      "type": "string",
      "$comment": "This is optional, but if provided, should match the name of this file.",
      "pattern": "/schemas/cli/cli-schema.json$"
    },
    "config_path": {
      "description": "Search path(s) for resolving additional config file references.  Note: the path to internal examples are included by default.",
      "type": "array",
      "items": {
        "type": "string"
      },
      "uniqueItems": true
    },
    "services": {
      "description": "Path to the json config(s) describing the services to use for setting up and running the benchmark environment. These are initial services for all environments.  Individual environments can specify their own service configs to include as well.",
      "type": "array",
      "items": {
        "$ref": "#/$defs/json_config_path"
      },
      "minItems": 1,
      "uniqueItems": true
    },
    "scheduler": {
      "description": "Path to the json config of scheduler to use for running the experiments.",
      "$ref": "#/$defs/json_config_path"
    },
    "environment": {
      "description": "Path to the json config describing the environment to run the benchmark in.",
      "$ref": "#/$defs/json_config_path"
    },
    "optimizer": {
      "description": "Path to the json config describing the optimizer to use.",
      "$ref": "#/$defs/json_config_path"
    },
    "trial_config_repeat_count": {
      "description": "Number of times to repeat a config.",
      "type": "integer",
      "minimum": 1,
      "examples": [
        3,
        5
      ]
    },
    "num_trial_runners": {
      "description": "Number of trial runner instances to use to execute benchmark environments. Individual TrialRunners can be identified in configs with $trial_runner_id and optionally run in parallel.",
      "type": "integer",
      "minimum": 1,
      "examples": [
        1,
        3,
        5,
        10
      ]
    },
    "storage": {
      "description": "Path to the json config describing the storage backend to use.",
      "$ref": "#/$defs/json_config_path"
    },
    "random_init": {
      "description": "If true, initialize the tunables with random values; otherwise, use the defaults.",
      "type": "boolean"
    },
    "random_seed": {
      "description": "Random seed to use in conjunction with random_init.",
      "type": "number"
    },
    "tunable_params_map": {
      "$ref": "https://catalog.lintel.tools/schemas/schemastore/mlos-config-mlos-jsonc-mlos-json5-mlos-json/_shared/latest--common-defs-subschemas.json#/$defs/tunable_params_map"
    },
    "tunable_values": {
      "description": "Path to the json config(s) describing the tunable values to use.",
      "$ref": "#/$defs/json_config_path_or_paths"
    },
    "globals": {
      "description": "Path to the json config(s) describing the global config overrides to use.",
      "$ref": "#/$defs/json_config_path_or_paths"
    },
    "experiment_id": {
      "$ref": "https://catalog.lintel.tools/schemas/schemastore/mlos-config-mlos-jsonc-mlos-json5-mlos-json/_shared/latest--common-defs-subschemas.json#/$defs/experiment_id"
    },
    "trial_id": {
      "$ref": "https://catalog.lintel.tools/schemas/schemastore/mlos-config-mlos-jsonc-mlos-json5-mlos-json/_shared/latest--common-defs-subschemas.json#/$defs/trial_id"
    },
    "config_id": {
      "$ref": "https://catalog.lintel.tools/schemas/schemastore/mlos-config-mlos-jsonc-mlos-json5-mlos-json/_shared/latest--common-defs-subschemas.json#/$defs/config_id"
    },
    "teardown": {
      "description": "Whether to teardown the experiment after running it.",
      "type": "boolean"
    },
    "log_file": {
      "description": "Path to the log file to use.",
      "type": "string"
    },
    "log_level": {
      "description": "Log level to use.",
      "enum": [
        "CRITICAL",
        "FATAL",
        "ERROR",
        "WARNING",
        "WARN",
        "INFO",
        "DEBUG"
      ]
    }
  },
  "$defs": {
    "json_config_path": {
      "type": "string",
      "pattern": "[.]json[c]?$"
    },
    "json_config_path_list": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/json_config_path"
      },
      "uniqueItems": true,
      "minItems": 1
    },
    "json_config_path_or_paths": {
      "oneOf": [
        {
          "$ref": "#/$defs/json_config_path"
        },
        {
          "$ref": "#/$defs/json_config_path_list"
        }
      ]
    }
  },
  "unevaluatedProperties": false
}
