Command Palette

Search for a command to run...

Назад к скиллам
скилл № 16705

bio-blast-searches

Run remote BLAST searches against NCBI servers using Biopython Bio.Blast.NCBIWWW. Use when identifying unknown sequences, finding homologs, picking the…

БесплатноЗапускает вложенные скрипты
BioTender-maxот BioTender-max★ 235 звёзд на GitHub

Установить bio-blast-searches в Claude Code и Claude Desktop

Зарегайся, чтобы установить скилл

Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.

  • Открой команду установки в одну строку
  • Сохраняй скиллы в синхронизируемую библиотеку
  • Уведомления, когда скиллы обновляются
Зарегаться бесплатноУ меня уже есть аккаунт

Об этом скилле

Version Compatibility

Reference examples tested with: BioPython 1.83+, NCBI BLAST+ 2.15+

Before using code patterns, verify installed versions match. If versions differ:

  • Python: pip show biopython then help(Bio.Blast.NCBIWWW.qblast) to check signatures
  • CLI: blastn -version then blastn -help

If code throws ImportError, AttributeError, or TypeError, introspect the installed package and adapt the example to match the actual API rather than retrying.

BLAST Searches (Remote)

"Find similar sequences in NCBI's database" -> Submit a query to NCBI's remote BLAST servers; receive a Request ID (RID); poll for completion; parse the XML hit table. Best for one-off identification of a few sequences. For >50 sequences, switch to local-blast or DIAMOND/MMseqs2 in remote-homology.

The two most consequential decisions: which program (defines query+target molecule types and word-size defaults) and which database (defines the search space and therefore E-value baselines). The third most important: do NOT misuse max_target_seqs -- it is an early-termination heuristic, not a "give me the top N hits" filter (Shah et al. 2019).

  • Python: NCBIWWW.qblast(program, db, sequence) + NCBIXML.read(handle) (BioPython)
  • CLI: blastn -remote -db nt -query seq.fa -out hits.xml -outfmt 5 (BLAST+)
  • Web: https://blast.ncbi.nlm.nih.gov/Blast.cgi (RID lookup)

Required Setup

from Bio.Blast import NCBIWWW, NCBIXML
from Bio import SeqIO

No API key needed for remote BLAST itself, but NCBI's general rate-limit ethic still applies -- one search at a time, polite waiting, no parallelism.

Program decision (query vs database molecule)

Program Query Target Word size default Use case
blastn DNA DNA 11 General DNA similarity
megablast DNA DNA 28 High-identity DNA (>=95%) -- PCR primer hits, contamination
dc-megablast DNA DNA 11 (discontiguous) Cross-species mRNA (sensitive, gapped)
blastp Protein Protein 3 (6 also valid) General protein homology
blastx DNA Protein 3 Translated DNA query vs protein DB; ORF discovery
tblastn Protein DNA 3 Protein query vs translated DB; find unannotated CDS
tblastx DNA DNA 3 (both translated) Most expensive; deep cross-species coding similarity
psiblast Protein Protein 3 Iterative PSSM-based remote homology -- see remote-homology

The misuse to avoid: using default blastn (word=11) for cross-species DNA where dc-megablast is the right tool. Or using megablast (word=28) for cross-species homology where it will miss every divergent hit. The most-misused BLAST parameter according to literature.

Database decision (search space)

Database (db=) Content Size (2026 approx) Stable for reproducibility?
nt Non-redundant nucleotide (all GenBank+EMBL+DDBJ) ~250 GB NO -- changes daily
nr Non-redundant protein ~300 GB NO -- changes daily
refseq_select One curated rep per species (RNA + protein) small YES -- versioned releases
refseq_rna RefSeq mRNA ~10 GB YES
refseq_protein RefSeq protein small YES
swissprot UniProt Swiss-Prot (reviewed) small YES -- monthly releases
pdb Protein structures small YES
refseq_genomic RefSeq genomic huge YES
env_nr / env_nt Environmental (metagenomic) huge YES

For publication reproducibility, never search nt or nr without recording the snapshot date and ideally archiving a frozen copy. Default to refseq_select for any cross-species homology question; switch to nt/nr only when curated coverage is insufficient.

E-value interpretation (Karlin-Altschul)

E-value = K * m * n * exp(-lambda * S), where m = effective query length, n = effective database size, lambda and K are scoring-matrix-dependent constants (Karlin & Altschul 1990 PNAS 87:2264).

E-value Bit-score (BLOSUM62, protein) Interpretation
< 1e-50 > 200 Strong; almost certainly homologous
1e-50 to 1e-10 100-200 Significant; likely homolog
1e-10 to 1e-3 50-100 Marginal; check identity + coverage
0.01 to 10 30-50 Possible remote homolog; needs profile method
> 10 < 30 Random; not meaningful

Key implication of E = K * m * n * exp(-lambda * S): the same alignment against a 100x larger database has a 100x larger E-value. Cross-database E-value comparison is meaningless. Bit-score is database-size normalized and is the right cross-database metric.

For protein remote homology where E is marginal (10^-3 to 10^-1), reach for profile methods: PSI-BLAST, jackhmmer, HHblits, or Foldseek -- see remote-homology skill.

Composition-Based Statistics (CBS)

Compositional bias inflates significance for low-complexity proteins. The CBS modes (Yu et al. 2006 Nucleic Acids Res 34:5966):

| `composition_based_statistic

Полный SKILL.md на GitHub

Разрешённые инструменты

Инструменты, которые скиллу разрешено вызывать.

Без ограничений — скилл может использовать любой инструмент.

Вложенные файлы

  • examples/basic_blast.py
  • examples/blastp_filtered.py
  • examples/save_and_parse.py
  • usage-guide.md

FAQ

Что делает скилл bio-blast-searches?

Run remote BLAST searches against NCBI servers using Biopython Bio.Blast.NCBIWWW. Use when identifying unknown sequences, finding homologs, picking the correct BLAST program (blastn/blastp/blastx/tblastn/tblastx/psiblast/megablast/dc-megablast), interpreting Karlin-Altschul E-values, avoiding the max_target_seqs trap (Shah 2019), choosing composition-based statistics, or limiting searches by organism. Covers RID lifecycle, database choice (nt/nr/refseq_select/swissprot), word-size and CBS taxonomy.

Как установить скилл bio-blast-searches?

Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.

Скилл bio-blast-searches запускает скрипты?

Да, скилл несёт исполняемые скрипты. Проверь исходник перед установкой.

Похожие скиллы

Сравнить bio-blast-searches с