{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "title": "bowtie2_build",
  "description": "Build Bowtie2 index files from reference sequences.\n\nThe Bowtie2 index is based on the FM Index of Ferragina and Manzini, which in turn \nis based on the Burrows-Wheeler Transform. The algorithm used to build the index is \nbased on the blockwise algorithm of Karkkainen.\n",
  "type": "object",
  "$defs": {
    "inputs": {
      "title": "Inputs",
      "type": "object",
      "description": "No description",
      "properties": {
        "input": {
          "type": "string",
          "format": "path",
          "exists": true,
          "description": "Input reference sequences in FASTA format",
          "help_text": "Type: `file`, multiple: `False`, required, direction: `input`, example: `\"reference.fasta\"`. "
        }
      }
    },
    "outputs": {
      "title": "Outputs",
      "type": "object",
      "description": "No description",
      "properties": {
        "output": {
          "type": "string",
          "format": "path",
          "description": "Directory where the index files will be written.",
          "help_text": "Type: `file`, multiple: `False`, required, default: `\"$id.$key.output\"`, direction: `output`, example: `\"bowtie2_index\"`. ",
          "default": "$id.$key.output"
        },
        "index_name": {
          "type": "string",
          "description": "Base name for the index files",
          "help_text": "Type: `string`, multiple: `False`, example: `\"my_reference\"`. "
        }
      }
    },
    "index construction options": {
      "title": "Index Construction Options",
      "type": "object",
      "description": "No description",
      "properties": {
        "large_index": {
          "type": "boolean",
          "description": "Force generated index to be 'large', even if reference has fewer than 4 billion nucleotides.",
          "help_text": "Type: `boolean_true`, multiple: `False`, default: `false`. ",
          "default": false
        },
        "noauto": {
          "type": "boolean",
          "description": "Disable automatic -p/--bmax/--dcv memory-fitting.",
          "help_text": "Type: `boolean_true`, multiple: `False`, default: `false`. ",
          "default": false
        },
        "packed": {
          "type": "boolean",
          "description": "Use packed strings internally; slower, less memory.",
          "help_text": "Type: `boolean_true`, multiple: `False`, default: `false`. ",
          "default": false
        },
        "bmax": {
          "type": "integer",
          "description": "Max bucket size for blockwise suffix-array builder.",
          "help_text": "Type: `integer`, multiple: `False`, example: `200000000`. "
        },
        "bmaxdivn": {
          "type": "integer",
          "description": "Max bucket size as divisor of reference length.",
          "help_text": "Type: `integer`, multiple: `False`, example: `4`. "
        },
        "dcv": {
          "type": "integer",
          "description": "Diff-cover period for blockwise (default 1024).",
          "help_text": "Type: `integer`, multiple: `False`, example: `1024`. "
        },
        "nodc": {
          "type": "boolean",
          "description": "Disable diff-cover (algorithm becomes quadratic).",
          "help_text": "Type: `boolean_true`, multiple: `False`, default: `false`. ",
          "default": false
        },
        "noref": {
          "type": "boolean",
          "description": "Don't build .3/.4 index files.",
          "help_text": "Type: `boolean_true`, multiple: `False`, default: `false`. ",
          "default": false
        },
        "justref": {
          "type": "boolean",
          "description": "Just build .3/.4 index files.",
          "help_text": "Type: `boolean_true`, multiple: `False`, default: `false`. ",
          "default": false
        },
        "offrate": {
          "type": "integer",
          "description": "SA is sampled every 2^<int> BWT chars (default 5).",
          "help_text": "Type: `integer`, multiple: `False`, example: `5`. "
        },
        "ftabchars": {
          "type": "integer",
          "description": "Number of chars consumed in initial lookup (default 10).",
          "help_text": "Type: `integer`, multiple: `False`, example: `10`. "
        },
        "seed": {
          "type": "integer",
          "description": "Seed for random number generator.",
          "help_text": "Type: `integer`, multiple: `False`, example: `42`. "
        },
        "quiet": {
          "type": "boolean",
          "description": "Suppress verbose output.",
          "help_text": "Type: `boolean_true`, multiple: `False`, default: `false`. ",
          "default": false
        },
        "verbose": {
          "type": "boolean",
          "description": "Log the issued command.",
          "help_text": "Type: `boolean_true`, multiple: `False`, default: `false`. ",
          "default": false
        },
        "debug": {
          "type": "boolean",
          "description": "Use the debug binary; slower, assertions enabled.",
          "help_text": "Type: `boolean_true`, multiple: `False`, default: `false`. ",
          "default": false
        },
        "sanitized": {
          "type": "boolean",
          "description": "Use sanitized binary; slower, uses ASan and/or UBSan.",
          "help_text": "Type: `boolean_true`, multiple: `False`, default: `false`. ",
          "default": false
        }
      }
    },
    "input format options": {
      "title": "Input Format Options",
      "type": "object",
      "description": "No description",
      "properties": {
        "fasta": {
          "type": "boolean",
          "description": "Reference files are FASTA (default).",
          "help_text": "Type: `boolean_true`, multiple: `False`, default: `false`. ",
          "default": false
        },
        "cmdline": {
          "type": "boolean",
          "description": "Reference sequences given on command line.",
          "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/inputs"
    },
    {
      "$ref": "#/$defs/outputs"
    },
    {
      "$ref": "#/$defs/index construction options"
    },
    {
      "$ref": "#/$defs/input format options"
    },
    {
      "$ref": "#/$defs/nextflow input-output arguments"
    }
  ]
}
