name: pseudo_alignment_and_quant
namespace: workflows
description: |
  A viash sub-workflow for pseudo alignment and quantification stage of nf-core/rnaseq pipeline.

argument_groups:
  - name: "Input"
    arguments:
    - name: "--id"
      required: true
      type: string
      description: ID of the sample.
      example: foo
    - name: "--fastq_1"
      alternatives: [-i]
      type: file
      description: Path to the sample (or read 1 of paired end sample).
      required: true
      example: input.fastq.gz
    - name: "--fastq_2"
      type: file
      required: false
      description: Path to read 2 of the sample.
    - name: "--strandedness"
      type: string 
      required: false
      description: Sample strand-specificity. Must be one of unstranded, forward, or reverse
      choices: [forward, reverse, unstranded]
    - name: "--gtf"
      type: file
      description: GTF file
    - name: "--transcript_fasta"
      type: file
      description: Fasta file of the reference transcriptome.
    - name: "--pseudo_aligner"
      type: string
      default: false
      description: Specifies the pseudo aligner to use - available options are 'salmon'. Runs in addition to '--aligner'. 
      choices: [salmon, kallisto]
    - name: "--salmon_index"
      type: file
      description: Salmon index
    - name: "--kallisto_index"
      type: file
      description: Kallisto index
    - name: "--lib_type"
      type: string
      description: Override library type inferred based on strandedness defined in meta object
      default: ''
    - name: "--kallisto_quant_fragment_length"
      type: double
      description: For single-end mode only, the estimated average fragment length to use for quantification with Kallisto.
    - name: "--kallisto_quant_fragment_length_sd"
      type: double
      description: For single-end mode only, the estimated standard deviation of the fragment length for quantification with Kallisto. 
    
  - name: "Output"
    arguments:
    - name: "--pseudo_multiqc"
      type: file
      direction: output
    - name: "--quant_out_dir"
      type: file
      direction: output
      default: $id.quant
    - name: "--salmon_quant_results_file"
      type: file
      direction: output
      default: $id.quant.sf
    - name: "--kallisto_quant_results_file"
      type: file
      direction: output
      default: $id.abundance.tsv
 
resources:
  - type: nextflow_script
    path: main.nf
    entrypoint: run_wf

dependencies:
  - name: salmon/salmon_quant
    repository: biobox
  - name: kallisto/kallisto_quant
    repository: biobox

runners: 
- type: executable
- type: nextflow
