agentleFS
Scientific-ToolingScientific-Tooling/structured-intelligence/skills/rnaseq-read-alignment/SKILL.md

rnaseq-read-alignment

Skill4 starsChanged 12 days agoMITView on GitHub

Splice-aware alignment of RNA-seq reads to a reference genome using STAR or HISAT2.

The file

We split this skill into the rules it gives an agent

3 rules. About 0 are common, 1 is distinctive, and 2 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈1

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    If STAR: run STAR with --quantMode GeneCounts (also produces per-gene counts) and --outSAMtype BAM SortedByCoordinate.

    line 32
  2. Distinctive:

    If STAR two-pass: run first pass for junction discovery, generate a new genome index incorporating discovered junctions, then run the …

    line 33
  3. Very specific:

    If HISAT2: run with --dta flag (downstream transcriptome assembly compatible), pipe output to samtools sort for coordinate-sorted BAM.

    line 34

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Skill: RNA-seq Read Alignment

Use When

  • User needs splice-aware alignment for RNA-seq data
  • User wants to produce genome-aligned BAMs for downstream counting
  • User needs two-pass STAR alignment for novel junction discovery
  • User wants to compare STAR vs HISAT2 aligners

Inputs

  • Required:
    • Trimmed FASTQ file(s) (single-end or paired-end)
    • Reference genome index (STAR genome directory or HISAT2 index prefix)
  • Optional:
    • Aligner choice: star or hisat2 (default: star)
    • GTF annotation file (for STAR splice junction database)
    • Reference FASTA path when running STAR in --two-pass mode (--genome-fasta)
    • Number of threads (default: 4)
    • Output directory (default: ./alignment_output)
    • Two-pass mode for STAR (enables novel junction discovery)
    • Maximum intron length

Workflow

  1. Validate that the genome index exists for the chosen aligner.
  2. If STAR: run STAR with --quantMode GeneCounts (also produces per-gene counts) and --outSAMtype BAM SortedByCoordinate.
  3. If STAR two-pass: run first pass for junction discovery, generate a new genome index incorporating discovered junctions, then run the second pass.
  4. If HISAT2: run with --dta flag (downstream transcriptome assembly compatible), pipe output to samtools sort for coordinate-sorted BAM.
  5. Index the output BAM with samtools index.
  6. Report alignment statistics: total reads, uniquely mapped reads, multi-mapped reads, unmapped reads, splice junctions detected.

Output Contract

  • Sorted BAM file (Aligned.sortedByCoord.out.bam for STAR, aligned.sorted.bam for HISAT2)
  • BAM index (.bai)
  • Alignment log/summary (Log.final.out for STAR, hisat2_summary.txt for HISAT2)
  • STAR gene counts file (ReadsPerGene.out.tab, if STAR)
  • Splice junction file (SJ.out.tab for STAR)

Limits

  • STAR requires approximately 32 GB RAM for the human genome; HISAT2 is lighter at approximately 8 GB.
  • Genome index must be pre-built before running this skill.
  • STAR two-pass mode is slower but recommended for novel junction discovery.
  • STAR and HISAT2 must be installed and available on PATH.
  • Common failure cases:
    • STAR genome index built with an incompatible STAR version, causing segfault or load error.
    • Insufficient RAM for STAR genome loading (32 GB for human; job killed by OOM).
    • GTF annotation file missing or mismatched with the genome build, producing zero splice junctions.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.