biology-biopython
하는 일
스킬은 Python에서 생물학적 서열과 데이터베이스를 다루는 규칙을 제공합니다. 서열 파일이나 유전 데이터를 다루는 연구자와 학생을 위한 스킬입니다.
사용하는 경우
- ✓Python으로 DNA, RNA, 단백질 서열을 다룰 때.
- ✓FASTA나 GenBank 파일을 읽거나 변환해야 할 때.
- ✓BLAST 검색을 실행하거나 NCBI 데이터베이스에서 기록을 가져오고 싶은 경우.
스킬 링크
https://github.com/aiming-lab/AutoResearchClaw/blob/main/.claude/skills/biology-biopython/SKILL.md복사해서 AI(Claude, ChatGPT, Cursor)에 붙여넣고 지침을 따르도록 요청하세요.
사용 방법
가장 쉬운 방법입니다. 메시지를 복사해 AI에 붙여넣으세요. AI가 스킬을 읽고 지침을 따릅니다.
바로 붙여넣을 수 있는 메시지
Claude Code, Codex, Cursor용입니다. 프로젝트 폴더에서 실행하면 스킬이 설치됩니다.
SKILL.md를 다운로드해 에이전트의 스킬 폴더에 넣으세요.
AI에게 요청하는 예시
“이 FASTA 파일을 읽고, 각 DNA 서열을 단백질로 번역한 뒤 GC 함량을 보고해 주세요.”
매주 새 스킬 5개. 읽는 데 1분.
작동 방식
에이전트는 Biopython 라이브러리로 서열 파일을 읽고, GC 함량 같은 값을 계산하고, DNA를 번역하며, NCBI 데이터베이스를 검색합니다. NCBI에 접근하기 전에 이메일 주소를 설정하는 것 같은 규칙을 따릅니다.
기술 내용 (원본 SKILL.md)
작성자의 영어 원문을 GitHub에서 그대로 가져왔습니다.
Biopython Bioinformatics Best Practice
Sequence Manipulation
- Create sequences:
from Bio.Seq import Seq; seq = Seq("ATGCGA") - Complement:
seq.complement(); Reverse complement:seq.reverse_complement() - Transcription:
seq.transcribe()(DNA to RNA) - Translation:
seq.translate()(DNA/RNA to protein) - GC content:
from Bio.SeqUtils import gc_fraction; gc_fraction(seq) - Molecular weight:
from Bio.SeqUtils import molecular_weight
File Parsing (SeqIO)
- Read FASTA:
for rec in SeqIO.parse("file.fasta", "fasta"): ... - Read GenBank:
for rec in SeqIO.parse("file.gb", "genbank"): ... - Read single record:
rec = SeqIO.read("file.fasta", "fasta") - Write sequences:
SeqIO.write(records, "output.fasta", "fasta") - Convert formats:
SeqIO.convert("input.gb", "genbank", "output.fasta", "fasta") - Index large files:
idx = SeqIO.index("large.fasta", "fasta")for random access
BLAST Operations
- Online BLAST:
from Bio.Blast import NCBIWWW; result = NCBIWWW.qblast("blastn", "nt", seq) - Parse results:
from Bio.Blast import NCBIXML; records = NCBIXML.parse(result) - Local BLAST: run via subprocess, parse XML output with NCBIXML
- Always set
Entrez.emailbefore any NCBI access - Filter results by e-value (typically < 1e-5) and coverage
NCBI Database Access (Entrez)
- Always set email:
Entrez.email = "your@email.com" - Search:
handle = Entrez.esearch(db="pubmed", term="query") - Fetch records:
handle = Entrez.efetch(db="nucleotide", id="ID", rettype="fasta") - Use API key for higher rate limits (10 req/s vs 3 req/s)
- Respect NCBI rate limits; add delays between batch requests
Phylogenetics (Bio.Phylo)
- Read trees:
from Bio import Phylo; tree = Phylo.read("tree.nwk", "newick") - Draw trees:
Phylo.draw(tree)orPhylo.draw_ascii(tree) - Supported formats: newick, nexus, phyloxml
- Traverse clades:
for clade in tree.find_clades(): ... - Calculate distances:
tree.distance(clade1, clade2)
Structure Analysis (Bio.PDB)
- Parse PDB:
parser = PDBParser(); structure = parser.get_structure("id", "file.pdb") - Hierarchy: Structure > Model > Chain > Residue > Atom
- Get atoms: iterate through
structure.get_atoms() - Calculate distances: use atom coordinate vectors
- For mmCIF files: use
MMCIFParser()instead ofPDBParser()
Common Pitfalls
- Always handle
SeqIO.parseas an iterator — it exhausts after one pass - Check sequence alphabet compatibility before operations
- Large files: use
SeqIO.index()notSeqIO.to_dict()to avoid memory issues - Set proper timeout for remote BLAST queries (can take minutes)
- Validate parsed data — missing annotations are common in public databases
자주 묻는 질문
NCBI를 쓰기 전에 설정할 것이 있나요?
네. NCBI 데이터베이스에 접근하기 전에 이메일 주소를 설정하라고 스킬은 말합니다.
큰 파일도 다룰 수 있나요?
네. 큰 FASTA 파일을 무작위 접근이 가능하도록 색인할 수 있습니다.
BLAST를 로컬에서 실행할 수 있나요?
네. 로컬 명령으로 BLAST를 실행해 XML 출력을 파싱하거나, 온라인에서 검색할 수 있습니다.
상세 정보
작성자의 원본 설명
Bioinformatics with Biopython for sequence manipulation, file parsing, BLAST, and phylogenetics. Use when working with DNA/RNA/protein sequences or biological databases.
인기도
- GitHub 스타
- 15k
- 순위
- #11045
- 라이선스
- MIT
- 업데이트
- 2026. 8. 19.
댓글
- …
이 저장소의 다른 스킬
a-evolve
15k반복 실행에 걸쳐 실패를 진단하고, 오류 패턴에서 맞춤 스킬을 만들고, 나중에 쓸 교훈을 기록해 에이전트가 나아지도록 돕습니다.
chemistry-rdkit
15kRDKit으로 SMILES 문자열로 된 분자를 분석하도록 에이전트를 돕습니다. 기술자, 지문, 유사도, 부분 구조 검색을 포함합니다.
hypothesis-formulation
15k관찰 내용을 검증 가능한 가설로 바꾸도록 에이전트를 돕습니다. 경쟁하는 설명과, 가설이 틀렸음을 보여 줄 수 있는 명확한 예측을 포함합니다.
literature-search
15k검색어, 포함 기준, 선별 단계, PRISMA 방식의 결과 집계를 갖춘 체계적인 문헌 검색을 계획하고 실행하도록 에이전트를 돕습니다.
비슷한 스킬
gitcrawl
394k에이전트가 저장된 GitHub 이슈와 풀 리퀘스트 보관본을 검색하고, 중복 항목을 묶고, GitHub에서 현재 상태를 확인하도록 돕습니다.
slacrawl
394k에이전트가 로컬 Slack 보관본에서 메시지를 검색하고 개수를 세며, 보관본이 얼마나 최신인지 확인하고 필요할 때 새로 고치도록 돕습니다.
goplaces
394k에이전트가 Google Places로 장소를 검색하고, 세부 정보와 리뷰를 가져오고, 장소 이름을 확인하며, 스크립트용 JSON을 출력하도록 돕습니다.