Skip to main content

Species Specificity

Ensure your primers amplify only your target organism and ignore background DNA.

Use Cases

  • Pathogen Detection: Detect Salmonella in a Human sample.
  • Environmental DNA (eDNA): Identify specific species in water/soil samples.
  • GMO Testing: Distinguish transgenic sequences from host crops.

How It Works

PrimerLab uses BLAST+ to check primer candidates against two databases:
  1. Target Database: The genome(s) of the organism you WANT to amplify.
  2. Background Database: The genome(s) of organisms you do NOT want to amplify (e.g., Human, Mouse, Soil metagenome).
It calculates a Specificity Score:
  • + Points: Perfect matches in Target Database.
  • - Points: Significant matches in Background Database, especially at the 3’ end.

Configuration

Add a specificity block to your config:
# specificity_config.yaml
specificity:
  # Positive control: Primers MUST bind here
  target_database: ./data/salmonella_genome.fasta
  
  # Negative control: Primers MUST NOT bind here
  background_database: ./data/human_genome.fasta
  
  # Thresholds
  min_specificity_score: 90
  check_3_end: true  # Critical for specificity

Running the Check

Integrated Workflow

Run this during primer design to filter out non-specific primers automatically:
primerlab run pcr --config specificity_config.yaml --species-check

Standalone Tool

Check existing primers:
primerlab species-check \
  --primers my_primers.json \
  --target-db salmonella.fasta \
  --background-db human.fasta

Interpreting Results

The tool outputs a summary table:
Primer PairTarget HitsBackground HitsSpecificity ScoreStatus
Pair 110100✅ PASS
Pair 21545❌ FAIL
Pair 311 (weak)85⚠️ WARN
  • FAIL: Significant background amplification likely.
  • WARN: Weak background binding; may work if annealing temperature is optimized.