Agent skill · Data & Analytics

bio-alignment-validation

Validate alignment quality with insert size distribution, proper pairing rates, GC bias, strand balance, and other post-alignment metrics. Use when verifying alignment data quality before variant calling or quantification.

BioTender-maxgithub.com/BioTender-maxGitHub ↗
claude-codeships scriptsNOASSERTION
Install
npx skills add BioTender-max/awesome-bio-agent-skills --skill alignment-validation --agent claude-code

Same command for any agent — swap --agent for codex, cursor, copilot.

Facts
Files in the skill folder: 4
SKILL.md size: 14 KB
Bundled scripts: yes
Path: skills/bioskills/alignment-validation/SKILL.md
Open the folder on GitHub →
Where it comes from
Stars: 135
Language: Python

Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.

From the SKILL.md

## Version Compatibility Reference examples tested with: matplotlib 3.8+, numpy 1.26+, picard 3.1+, pysam 0.22+, samtools 1.19+ Before using code patterns, verify installed versions match. If versions differ: - Python: `pip show <package>` then `help(module.function)` to check signatures - CLI: `<tool> --version` then `<tool> --help` to confirm flags If code throws ImportError, AttributeError, or TypeError, introspect the installed package and adapt the example to match the actual API rather than retrying. # Alignment Validation Post-alignment quality control to verify alignment quality and identify issues. **"Check alignment quality"** → Compute post-alignment QC metrics (mapping rate, pairing, insert size, strand balance) to identify issues before downstream analysis. - CLI: `samtools flagstat`, `samtools stats`, Picard `CollectAlignmentSummaryMetrics` - Python: `pysam.AlignmentFile` iteration with metric calculations ## Two Different Validations | Concern | Tools | What it catches | |---------|-------|-----------------| | **File integrity** | `samtools quickcheck`, `picard ValidateSamFile` | Truncation, missing EOF, malformed records, wrong CIGAR, MAPQ out of range | | **Sequenc

What's inside
Steps it walks through
  1. Version Compatibility
  2. Two Different Validations
  3. File Integrity
  4. Sequence Dictionary Cross-Validation (M5)
  5. Contamination and Sample Swap
  6. Insert Size Distribution
  7. samtools stats
  8. Picard CollectInsertSizeMetrics
  9. Expected Insert Sizes by Library
  10. Python Insert Size Analysis
  11. Proper Pairing Rate
  12. samtools flagstat
  13. Calculate Pairing Rate
  14. Expected Rates
Ships with 3 files
  • examples/validate_alignment.py
  • examples/validate_alignment.sh
  • usage-guide.md
Commands it runs
samtools quickcheck -v in.bam || echo "QUICKCHECK FAILED"
samtools quickcheck -v *.bam > bad_bams.fofn   # one fail-line per bad file
Slow but thorough: structural validation
picard ValidateSamFile I=in.bam MODE=SUMMARY R=ref.fa
picard ValidateSamFile I=in.bam MODE=SUMMARY R=ref.fa \
test -s in.bam \
Compare per-contig MD5 between BAM and reference
diff \
Cross-sample contamination
verifybamid2 --SVDPrefix /resources/1000g.b38.vcf.gz.SVD \
More from awesome-bio-agent-skills
All skills →
About this skill
What does the bio-alignment-validation skill do?

Validate alignment quality with insert size distribution, proper pairing rates, GC bias, strand balance, and other post-alignment metrics. Use when verifying alignment data quality before variant calling or quantification.

How do I install it?

Run `npx skills add BioTender-max/awesome-bio-agent-skills --skill alignment-validation --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.

Where does this skill come from?

From BioTender-max/awesome-bio-agent-skills, a repository with 135 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.

Is a popular skill a good skill?

Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.

Keep going