{
  "id": "tangram",
  "name": "Tangram",
  "description": "Command-line tool to train and use machine learning models.",
  "executables": [
    "tangram"
  ],
  "commands": {
    "format": 1,
    "label": "Tangram",
    "description": "Train a model from a CSV file or make predictions with one. The app and migrate commands are left out.",
    "quality": "ai-draft",
    "base": "fig:tangram",
    "parser": {
      "end_of_options": "--",
      "interleave": "permute",
      "long_equals": true,
      "short_attached": true,
      "short_bundles": false
    },
    "source": [
      {
        "id": "fig",
        "kind": "completion",
        "url": "https://github.com/withfig/autocomplete/blob/master/src/tangram.ts",
        "license": "MIT"
      }
    ],
    "subcommand": [
      {
        "path": [
          "train"
        ],
        "label": "Train a model",
        "source": [
          {
            "id": "fig",
            "kind": "completion",
            "url": "https://github.com/withfig/autocomplete/blob/master/src/tangram.ts",
            "license": "MIT"
          }
        ],
        "field": [
          {
            "id": "file",
            "label": "Training CSV",
            "type": "path",
            "option": [
              "--file",
              "-f"
            ],
            "path": {
              "kind": "file",
              "role": "input",
              "must_exist": true
            },
            "sources": [
              "fig"
            ]
          },
          {
            "id": "target",
            "label": "Target column",
            "type": "string",
            "option": [
              "--target",
              "-t"
            ],
            "sources": [
              "fig"
            ]
          },
          {
            "id": "output",
            "label": "Output .tangram file",
            "type": "path",
            "option": [
              "--output",
              "-o"
            ],
            "path": {
              "kind": "file",
              "role": "output",
              "must_exist": false
            },
            "effect": "overwrite",
            "sources": [
              "fig"
            ]
          },
          {
            "id": "config",
            "label": "Config file",
            "type": "path",
            "option": [
              "--config",
              "-c"
            ],
            "path": {
              "kind": "file",
              "role": "input",
              "must_exist": true
            },
            "sources": [
              "fig"
            ]
          },
          {
            "id": "file_train",
            "label": "Train CSV",
            "type": "path",
            "option": [
              "--file-train"
            ],
            "path": {
              "kind": "file",
              "role": "input",
              "must_exist": true
            },
            "sources": [
              "fig"
            ]
          },
          {
            "id": "file_test",
            "label": "Test CSV",
            "type": "path",
            "option": [
              "--file-test"
            ],
            "path": {
              "kind": "file",
              "role": "input",
              "must_exist": true
            },
            "sources": [
              "fig"
            ]
          }
        ],
        "task": [
          {
            "id": "train",
            "label": "Train from one CSV",
            "fields": [
              "file",
              "target",
              "output"
            ],
            "required": [
              "file",
              "target"
            ]
          },
          {
            "id": "split",
            "label": "Train with separate test file",
            "fields": [
              "file_train",
              "file_test",
              "target",
              "output"
            ],
            "required": [
              "file_train",
              "file_test",
              "target"
            ]
          }
        ],
        "group": [
          {
            "id": "basic",
            "label": "Basic",
            "fields": [
              "file",
              "target",
              "output"
            ]
          },
          {
            "id": "advanced",
            "label": "Advanced",
            "fields": [
              "config",
              "file_train",
              "file_test"
            ]
          }
        ]
      },
      {
        "path": [
          "predict"
        ],
        "label": "Make predictions",
        "source": [
          {
            "id": "fig",
            "kind": "completion",
            "url": "https://github.com/withfig/autocomplete/blob/master/src/tangram.ts",
            "license": "MIT"
          }
        ],
        "field": [
          {
            "id": "model",
            "label": "Model",
            "type": "path",
            "option": [
              "--model",
              "-m"
            ],
            "path": {
              "kind": "file",
              "role": "input",
              "must_exist": true
            },
            "sources": [
              "fig"
            ]
          },
          {
            "id": "file",
            "label": "Input CSV",
            "type": "path",
            "option": [
              "--file",
              "-f"
            ],
            "description": "Defaults to standard input.",
            "path": {
              "kind": "file",
              "role": "input",
              "must_exist": true
            },
            "sources": [
              "fig"
            ]
          },
          {
            "id": "output",
            "label": "Output file",
            "type": "path",
            "option": [
              "--output",
              "-o"
            ],
            "description": "Defaults to standard output.",
            "path": {
              "kind": "file",
              "role": "output",
              "must_exist": false
            },
            "effect": "overwrite",
            "sources": [
              "fig"
            ]
          }
        ],
        "task": [
          {
            "id": "predict",
            "label": "Predict",
            "fields": [
              "model",
              "file",
              "output"
            ],
            "required": [
              "model"
            ]
          }
        ],
        "group": [
          {
            "id": "basic",
            "label": "Basic",
            "fields": [
              "model",
              "file",
              "output"
            ]
          }
        ]
      }
    ]
  }
}
