{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "title": "bwa_index",
  "description": "Index sequences in the FASTA format for BWA alignment.",
  "type": "object",
  "$defs": {
    "input": {
      "title": "Input",
      "type": "object",
      "description": "No description",
      "properties": {
        "input": {
          "type": "string",
          "format": "path",
          "exists": true,
          "description": "Input FASTA file to be indexed.",
          "help_text": "Type: `file`, multiple: `False`, required, direction: `input`, example: `\"reference.fasta\"`. "
        }
      }
    },
    "output": {
      "title": "Output",
      "type": "object",
      "description": "No description",
      "properties": {
        "output": {
          "type": "string",
          "format": "path",
          "description": "Output directory containing BWA index files (.amb, .ann, .bwt, .pac, .sa).",
          "help_text": "Type: `file`, multiple: `False`, default: `\"$id.$key.output\"`, direction: `output`, example: `\"bwa_index\"`. ",
          "default": "$id.$key.output"
        }
      }
    },
    "options": {
      "title": "Options",
      "type": "object",
      "description": "No description",
      "properties": {
        "algorithm": {
          "type": "string",
          "description": "BWT construction algorithm",
          "help_text": "Type: `string`, multiple: `False`, choices: ``bwtsw`, `is`, `rb2``. ",
          "enum": [
            "bwtsw",
            "is",
            "rb2"
          ]
        },
        "prefix": {
          "type": "string",
          "description": "Prefix of the index files",
          "help_text": "Type: `string`, multiple: `False`. "
        },
        "block_size": {
          "type": "integer",
          "description": "Block size for the bwtsw algorithm (effective with -a bwtsw)",
          "help_text": "Type: `integer`, multiple: `False`. "
        },
        "use_64bit_names": {
          "type": "boolean",
          "description": "Index files named as <in.fasta>.64.* instead of <in.fasta>.*.",
          "help_text": "Type: `boolean_true`, multiple: `False`, default: `false`. ",
          "default": false
        }
      }
    },
    "nextflow input-output arguments": {
      "title": "Nextflow input-output arguments",
      "type": "object",
      "description": "Input/output parameters for Nextflow itself. Please note that both publishDir and publish_dir are supported but at least one has to be configured.",
      "properties": {
        "publish_dir": {
          "type": "string",
          "description": "Path to an output directory.",
          "help_text": "Type: `string`, multiple: `False`, required, example: `\"output/\"`. "
        }
      }
    }
  },
  "allOf": [
    {
      "$ref": "#/$defs/input"
    },
    {
      "$ref": "#/$defs/output"
    },
    {
      "$ref": "#/$defs/options"
    },
    {
      "$ref": "#/$defs/nextflow input-output arguments"
    }
  ]
}
