scientific-pkg-gget

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

gget

gget

Use this skill when a task needs quick bioinformatics lookup across genomic reference databases with the
gget
CLI or Python package.
当任务需要使用
gget
CLI 或 Python 包快速查询基因组参考数据库时,使用此 skill。

When to Use

使用场景

  • Finding Ensembl IDs, gene metadata, transcript details, or sequences.
  • Running quick BLAST or BLAT lookups without building a full local pipeline.
  • Fetching reference genome links and annotations from Ensembl.
  • Querying protein structure, pathway, cancer, expression, or disease-association modules through a single interface.
  • Creating a reproducible first-pass evidence log before moving to heavier tools such as Biopython, Snakemake, Nextflow, BLAST+, or database-specific clients.
Use a dedicated workflow instead of
gget
when the task requires regulated clinical interpretation, high-throughput production pipelines, or fine-grained control over database versions and local indexes.
  • 查找 Ensembl ID、基因元数据、转录本详情或序列。
  • 无需构建完整的本地流水线,即可快速执行 BLAST 或 BLAT 查询。
  • 从 Ensembl 获取参考基因组链接和注释。
  • 通过单一接口查询蛋白质结构、通路、癌症、表达或疾病关联模块。
  • 在转向 Biopython、Snakemake、Nextflow、BLAST+ 或数据库专用客户端等更强大的工具之前,创建可复现的第一轮证据日志。
对于需要受监管的临床解读、高吞吐量生产流水线,或需要精细控制数据库版本和本地索引的任务,应使用专用工作流,而不是
gget
。

Installation

安装

Use a clean Python environment.
bash
python -m venv .venv
. .venv/bin/activate
python -m pip install --upgrade pip
python -m pip install --upgrade gget
gget --help
If
uv
is available:
bash
uv venv
. .venv/bin/activate
uv pip install gget
Before relying on an older environment, upgrade
gget
and re-check the module docs. The upstream databases queried by
gget
change over time.
使用干净的 Python 环境。
bash
python -m venv .venv
. .venv/bin/activate
python -m pip install --upgrade pip
python -m pip install --upgrade gget
gget --help
如果已安装
uv
:
bash
uv venv
. .venv/bin/activate
uv pip install gget
在依赖旧环境之前,升级
gget
并重新检查模块文档。
gget
查询的上游数据库会随时间变化。

Basic Patterns

基本模式

CLI shape:
bash
gget <module> [arguments] [options]
Python shape:
python
import gget

result = gget.search(["BRCA1"], species="human")
print(result)
Common workflow:
  1. Identify the species, assembly, gene ID type, and database needed.
  2. Check the current module documentation for arguments.
  3. Run a small query first.
  4. Save output with an explicit filename and date.
  5. Record module name, version, arguments, and database assumptions.
CLI 形式:
bash
gget <module> [arguments] [options]
Python 形式:
python
import gget

result = gget.search(["BRCA1"], species="human")
print(result)
常见工作流:
  1. 确定物种、基因组组装、基因 ID 类型和所需数据库。
  2. 查看当前模块文档以了解参数。
  3. 首先运行一个小型查询。
  4. 使用明确的文件名和日期保存输出。
  5. 记录模块名称、版本、参数和数据库假设。

Common Modules

常用模块

Use current upstream docs for exact arguments. These modules are common first choices:
  • gget search
    : find Ensembl IDs from search terms.
  • gget info
    : retrieve metadata for Ensembl, UniProt, or related IDs.
  • gget seq
    : fetch nucleotide or amino-acid sequences.
  • gget ref
    : retrieve reference genome download links.
  • gget blast
    : run a quick BLAST query.
  • gget blat
    : locate a sequence against supported genome assemblies.
  • gget muscle
    : run multiple sequence alignment.
  • gget diamond
    : run local sequence alignment against reference sequences.
  • gget alphafold
    and
    gget pdb
    : inspect protein-structure references.
  • gget enrichr
    ,
    gget opentargets
    ,
    gget archs4
    ,
    gget bgee
    ,
    gget cbio
    , and
    gget cosmic
    : explore enrichment, target, expression, cancer, and disease association data.
Do not assume every module supports every Python version or dependency set. Some optional scientific dependencies have narrower version support than the core package.
有关准确的参数,请参阅当前上游文档。以下模块是常见的第一选择:
  • gget search
    :根据搜索词查找 Ensembl ID。
  • gget info
    :获取 Ensembl、UniProt 或相关 ID 的元数据。
  • gget seq
    :获取核苷酸或氨基酸序列。
  • gget ref
    :获取参考基因组下载链接。
  • gget blast
    :运行快速 BLAST 查询。
  • gget blat
    :在支持的基因组组装中定位序列。
  • gget muscle
    :执行多序列比对。
  • gget diamond
    :针对参考序列运行本地序列比对。
  • gget alphafold
    和
    gget pdb
    :查看蛋白质结构参考信息。
  • gget enrichr
    、
    gget opentargets
    、
    gget archs4
    、
    gget bgee
    、
    gget cbio
    和
    gget cosmic
    :探索富集、靶点、表达、癌症和疾病关联数据。
不要假设每个模块都支持所有 Python 版本或依赖集。一些可选科学依赖项的版本支持范围比核心包更窄。

Quick Examples

快速示例

Find genes:
bash
gget search -s human brca1 dna repair -o brca1-search.json
Fetch gene metadata:
bash
gget info ENSG00000012048 -o brca1-info.json
Fetch a sequence:
bash
gget seq ENSG00000012048 -o brca1-seq.fa
Run a small BLAST query:
bash
gget blast "MEEPQSDPSVEPPLSQETFSDLWKLLPEN" -l 10 -o blast-results.json
Python example:
python
import gget

genes = gget.search(["BRCA1", "DNA repair"], species="human")
info = gget.info(["ENSG00000012048"])
sequence = gget.seq("ENSG00000012048")
查找基因:
bash
gget search -s human brca1 dna repair -o brca1-search.json
获取基因元数据:
bash
gget info ENSG00000012048 -o brca1-info.json
获取序列:
bash
gget seq ENSG00000012048 -o brca1-seq.fa
运行小型 BLAST 查询:
bash
gget blast "MEEPQSDPSVEPPLSQETFSDLWKLLPEN" -l 10 -o blast-results.json
Python 示例:
python
import gget

genes = gget.search(["BRCA1", "DNA repair"], species="human")
info = gget.info(["ENSG00000012048"])
sequence = gget.seq("ENSG00000012048")

Reproducibility Log

可复现性日志

For scientific outputs, include enough metadata to replay the query.
markdown
| Date | gget version | Module | Query | Species/assembly | Output | Notes |
| --- | --- | --- | --- | --- | --- | --- |
| 2026-05-11 | `gget --version` | search | `BRCA1 DNA repair` | human | `brca1-search.json` | Docs checked before run |
Also record:
  • Python version and environment manager.
  • Any optional dependency installed through
    gget setup
    .
  • Database-specific identifiers returned by the query.
  • Whether output is JSON, CSV, FASTA, or a DataFrame export.
  • Any failures that were resolved by upgrading
    gget
    .
对于科学输出,应包含足够的元数据,以便重现查询。
markdown
| 日期 | gget 版本 | 模块 | 查询 | 物种/组装 | 输出 | 备注 |
| --- | --- | --- | --- | --- | --- | --- |
| 2026-05-11 | `gget --version` | search | `BRCA1 DNA repair` | human | `brca1-search.json` | 运行前已检查文档 |
还应记录:
  • Python 版本和环境管理器。
  • 通过
    gget setup
    安装的所有可选依赖项。
  • 查询返回的数据库专用标识符。
  • 输出是 JSON、CSV、FASTA,还是 DataFrame 导出。
  • 通过升级
    gget
    解决的所有失败问题。

Review Checklist

检查清单

  • Did you upgrade or verify the installed
    gget
    version?
  • Did you check the current upstream module docs before using arguments?
  • Is the species or assembly explicit?
  • Are identifiers preserved exactly, including Ensembl/UniProt prefixes?
  • Is the result labeled as database output rather than clinical interpretation?
  • Is the query reproducible from the saved command or Python snippet?
  • Are optional dependencies installed in an isolated environment?
  • 是否升级或验证了已安装的
    gget
    版本?
  • 是否在使用参数前查看了当前上游模块文档?
  • 是否明确指定了物种或组装?
  • 是否完整保留了标识符,包括 Ensembl/UniProt 前缀?
  • 是否将结果标记为数据库输出,而非临床解读?
  • 是否可以通过保存的命令或 Python 代码片段重现查询?
  • 是否在隔离环境中安装了可选依赖项?

References

参考资料