This skill calls DNA base modifications (5mC, 5hmC, 6mA, 4mC) directly from Oxford Nanopore and PacBio HiFi long reads and piles them into per-site methylation with modkit (or pb-CpG-tools for PacBio). The fact that governs the whole pipeline is that methylation is a basecalling decision: modifications are inferred from raw signal at basecall time and stored as MM/ML SAM tags, so a BAM basecalled without a modification model can never yield methylation, and the tags silently die in a normal alignment workflow unless preserved. The skill covers the modBAM pipeline, the MM/ML tag spec, modkit's 18-column bedMethyl and its 10th-percentile auto-threshold, 5mC vs 5hmC handling relative to bisulfite, phased allele-specific methylation, and the PacBio path. RNA modifications are out of scope (see epitranscriptomics).
conda install -c bioconda modkit samtools minimap2 htslib
# PacBio path: pbmm2, pb-CpG-tools, jasmine
# Methylation must be requested at basecall time (see basecalling):
# dorado basecaller sup,5mCG_5hmCG pod5/ > calls.bam
Tell your AI agent what you want to do: - "Call 5mC CpG methylation from my modBAM and make a bedMethyl" - "Align my Dorado methylation BAM without losing the MM/ML tags" - "Get per-haplotype allele-specific methylation" - "Compare methylation between two samples"
"Check whether my BAM actually has MM/ML methylation tags, then pile up 5mC at CpG sites with strands combined into a bedMethyl."
"I have a Dorado modification BAM. Align it to the genome without dropping the MM/ML tags, and confirm they survived before I run modkit."
"I want to compare my Nanopore methylation to WGBS. Combine 5mC and 5hmC so the comparison is fair, and tell me why."
"Phase my sample, haplotag the BAM, and give me per-haplotype methylation at imprinted loci."
"My data is PacBio HiFi with kinetics. Call 5mC and make a bedMethyl - and do not suggest primrose."
samtools fastq -T MM,ML | minimap2 -y -Y) and verify they survived.--partition-tag HP.samtools view in.bam | head | grep MM:Z. No tags means re-basecall, not re-analyze.dorado aligner or samtools fastq -T MM,ML | minimap2 -y -Y; always re-check after alignment.--min-coverage flag on pileup - filter on Nvalid_cov afterward.--combine-mods/--preset traditional) to compare, keep them split to study 5hmC.? modifier means no-call (Nnocall), not unmethylated; misreading it deflates methylation.-y -Y)