Token导航 LogoToken导航TokenDH.com
研究检索敏感数据github未标认证来源可访问许可证需确认审计通过

gtex-databasegtex 数据库

Agent Skill

用于辅助数据库表结构、查询语句、迁移脚本和数据维护任务。它适合让 Agent 分析 schema、编写 SQL、排查查询问题、整理索引或生成迁移建议。使用时需要明确数据库类型、连接环境和目标表,区分只读分析与写入变更;涉及删除、更新、迁移和批量导入时,应优先 dry-run、备份或事务保护,避免误操作。

总安装

423

周安装

18

GitHub Stars

19,723

下载量

148
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

unknown

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:gtex-database(gtex 数据库)
来源仓库:https://github.com/k-dense-ai/claude-scientific-skills
仓库路径:skills/gtex-database
安装命令:
npx skills add https://github.com/k-dense-ai/claude-scientific-skills --skill gtex-database
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/k-dense-ai/claude-scientific-skills --skill gtex-database

简介

gtex-database 用于辅助数据库表结构分析和查询编写,支持迁移脚本生成。

  • 适用于 schema 分析、SQL 编写和索引优化等数据维护任务。
  • 通过 npx skills add 命令从 GitHub 仓库安装并使用。
  • 需明确数据库类型和连接环境,涉及写入操作时应优先备份或事务保护。
  • 适用宿主包括 Codex、Claude、Cursor、Gemini CLI,接入前应确认版本、权限和运行环境要求。

SKILL.md

GTEx Database

Overview

The Genotype-Tissue Expression (GTEx) project provides a comprehensive resource for studying tissue-specific gene expression and genetic regulation across 54 non-diseased human tissues from nearly 1,000 individuals. GTEx v10 (the latest release) enables researchers to understand how genetic variants regulate gene expression (eQTLs) and splicing (sQTLs) in a tissue-specific manner, which is critical for interpreting GWAS loci and identifying regulatory mechanisms.

Key resources:

When to Use This Skill

Use GTEx when:

  • GWAS locus interpretation: Identifying which gene a non-coding GWAS variant regulates via eQTLs
  • Tissue-specific expression: Comparing gene expression levels across 54 human tissues
  • eQTL colocalization: Testing if a GWAS signal and an eQTL signal share the same causal variant
  • Multi-tissue eQTL analysis: Finding variants that regulate expression in multiple tissues
  • Splicing QTLs (sQTLs): Identifying variants that affect splicing ratios
  • Tissue specificity analysis: Determining which tissues express a gene of interest
  • Gene expression exploration: Retrieving normalized expression levels (TPM) per tissue

Core Capabilities

1. GTEx REST API v2

Base URL: https://gtexportal.org/api/v2/

The API returns JSON and does not require authentication. All endpoints support pagination.

import requests

BASE_URL = "https://gtexportal.org/api/v2"

def gtex_get(endpoint, params=None):
    """Make a GET request to the GTEx API."""
    url = f"{BASE_URL}/{endpoint}"
    response = requests.get(url, params=params, headers={"Accept": "application/json"})
    response.raise_for_status()
    return response.json()

2. Gene Expression by Tissue

import requests
import pandas as pd

def get_gene_expression_by_tissue(gene_id_or_symbol, dataset_id="gtex_v10"):
    """Get median gene expression across all tissues."""
    url = "https://gtexportal.org/api/v2/expression/medianGeneExpression"
    params = {
        "gencodeId": gene_id_or_symbol,
        "datasetId": dataset_id,
        "itemsPerPage": 100
    }
    response = requests.get(url, params=params)
    data = response.json()

    records = data.get("data", [])
    df = pd.DataFrame(records)
    if not df.empty:
        df = df[["tissueSiteDetailId", "tissueSiteDetail", "median", "unit"]].sort_values(
            "median", ascending=False
        )
    return df

# Example: get expression of APOE across tissues
df = get_gene_expression_by_tissue("ENSG00000130203.10")  # APOE GENCODE ID
# Or use gene symbol (some endpoints accept both)
print(df.head(10))
# Output: tissue name, median TPM, sorted by highest expression

3. eQTL Lookup

import requests
import pandas as pd

def query_eqtl(gene_id, tissue_id=None, dataset_id="gtex_v10"):
    """Query significant eQTLs for a gene, optionally filtered by tissue."""
    url = "https://gtexportal.org/api/v2/association/singleTissueEqtl"
    params = {
        "gencodeId": gene_id,
        "datasetId": dataset_id,
        "itemsPerPage": 250
    }
    if tissue_id:
        params["tissueSiteDetailId"] = tissue_id

    all_results = []
    page = 0
    while True:
        params["page"] = page
        response = requests.get(url, params=params)
        data = response.json()
        results = data.get("data", [])
        if not results:
            break
        all_results.extend(results)
        if len(results) < params["itemsPerPage"]:
            break
        page += 1

    df = pd.DataFrame(all_results)
    if not df.empty:
        df = df.sort_values("pval", ascending=True)
    return df

# Example: Find eQTLs for PCSK9
df = query_eqtl("ENSG00000169174.14")
print(df[["snpId", "tissueSiteDetailId", "slope", "pval", "gencodeId"]].head(20))

4. Single-Tissue eQTL by Variant

import requests

def query_variant_eqtl(variant_id, tissue_id=None, dataset_id="gtex_v10"):
    """Get all eQTL associations for a specific variant."""
    url = "https://gtexportal.org/api/v2/association/singleTissueEqtl"
    params = {
        "variantId": variant_id,  # e.g., "chr1_55516888_G_GA_b38"
        "datasetId": dataset_id,
        "itemsPerPage": 250
    }
    if tissue_id:
        params["tissueSiteDetailId"] = tissue_id

    response = requests.get(url, params=params)
    return response.json()

# GTEx variant ID format: chr{chrom}_{pos}_{ref}_{alt}_b38
# Example: "chr17_43094692_G_A_b38"

5. Multi-Tissue eQTL (eGenes)

import requests

def get_egenes(tissue_id, dataset_id="gtex_v10"):
    """Get all eGenes (genes with at least one significant eQTL) in a tissue."""
    url = "https://gtexportal.org/api/v2/association/egene"
    params = {
        "tissueSiteDetailId": tissue_id,
        "datasetId": dataset_id,
        "itemsPerPage": 500
    }

    all_egenes = []
    page = 0
    while True:
        params["page"] = page
        response = requests.get(url, params=params)
        data = response.json()
        batch = data.get("data", [])
        if not batch:
            break
        all_egenes.extend(batch)
        if len(batch) < params["itemsPerPage"]:
            break
        page += 1
    return all_egenes

# Example: all eGenes in whole blood
egenes = get_egenes("Whole_Blood")
print(f"Found {len(egenes)} eGenes in Whole Blood")

6. Tissue List

import requests

def get_tissues(dataset_id="gtex_v10"):
    """Get all available tissues with metadata."""
    url = "https://gtexportal.org/api/v2/dataset/tissueSiteDetail"
    params = {"datasetId": dataset_id, "itemsPerPage": 100}
    response = requests.get(url, params=params)
    return response.json()["data"]

tissues = get_tissues()
# Key fields: tissueSiteDetailId, tissueSiteDetail, colorHex, samplingSite
# Common tissue IDs:
# Whole_Blood, Brain_Cortex, Liver, Kidney_Cortex, Heart_Left_Ventricle,
# Lung, Muscle_Skeletal, Adipose_Subcutaneous, Colon_Transverse, ...

7. sQTL (Splicing QTLs)

import requests

def query_sqtl(gene_id, tissue_id=None, dataset_id="gtex_v10"):
    """Query significant sQTLs for a gene."""
    url = "https://gtexportal.org/api/v2/association/singleTissueSqtl"
    params = {
        "gencodeId": gene_id,
        "datasetId": dataset_id,
        "itemsPerPage": 250
    }
    if tissue_id:
        params["tissueSiteDetailId"] = tissue_id

    response = requests.get(url, params=params)
    return response.json()

Query Workflows

Workflow 1: Interpreting a GWAS Variant via eQTLs

  1. Identify the GWAS variant (rs ID or chromosome position)
  2. Convert to GTEx variant ID format (chr{chrom}_{pos}_{ref}_{alt}_b38)
  3. Query all eQTL associations for that variant across tissues
  4. Check effect direction: is the GWAS risk allele the same as the eQTL effect allele?
  5. Prioritize tissues: select tissues biologically relevant to the disease
  6. Consider colocalization using coloc (R package) with full summary statistics
import requests, pandas as pd

def interpret_gwas_variant(variant_id, dataset_id="gtex_v10"):
    """Find all genes regulated by a GWAS variant."""
    url = "https://gtexportal.org/api/v2/association/singleTissueEqtl"
    params = {"variantId": variant_id, "datasetId": dataset_id, "itemsPerPage": 500}
    response = requests.get(url, params=params)
    data = response.json()

    df = pd.DataFrame(data.get("data", []))
    if df.empty:
        return df
    return df[["geneSymbol", "tissueSiteDetailId", "slope", "pval", "maf"]].sort_values("pval")

# Example
results = interpret_gwas_variant("chr1_154453788_A_T_b38")
print(results.groupby("geneSymbol")["tissueSiteDetailId"].count().sort_values(ascending=False))

Workflow 2: Gene Expression Atlas

  1. Get median expression for a gene across all tissues
  2. Identify the primary expression site(s)
  3. Compare with disease-relevant tissues
  4. Download raw data for statistical comparisons

Workflow 3: Tissue-Specific eQTL Analysis

  1. Select tissues relevant to your disease
  2. Query all eGenes in that tissue
  3. Cross-reference with GWAS-significant loci
  4. Identify co-localized signals

Key API Endpoints

EndpointDescription
/expression/medianGeneExpressionMedian TPM by tissue for a gene
/expression/geneExpressionFull distribution of expression per tissue
/association/singleTissueEqtlSignificant eQTL associations
/association/singleTissueSqtlSignificant sQTL associations
/association/egeneeGenes in a tissue
/dataset/tissueSiteDetailAvailable tissues with metadata
/reference/geneGene metadata (GENCODE IDs, coordinates)
/variant/variantPageVariant lookup by rsID or position

Datasets Available

IDDescription
gtex_v10GTEx v10 (current; ~960 donors, 54 tissues)
gtex_v8GTEx v8 (838 donors, 49 tissues) — older but widely cited

Best Practices

  • Use GENCODE IDs (e.g., ENSG00000130203.10) for gene queries; the .version suffix matters for some endpoints
  • GTEx variant IDs use the format chr{chrom}_{pos}_{ref}_{alt}_b38 (GRCh38) — different from rs IDs
  • Handle pagination: Large queries (e.g., all eGenes) require iterating through pages
  • Tissue nomenclature: Use tissueSiteDetailId (e.g., Whole_Blood) not display names for API calls
  • FDR correction: GTEx uses FDR < 0.05 (q-value) as the significance threshold for eQTLs
  • Effect alleles: The slope field is the effect of the alternative allele; positive = higher expression with alt allele

Data Downloads (for large-scale analysis)

For genome-wide analyses, download full summary statistics rather than using the API:

# All significant eQTLs (v10)
wget https://storage.googleapis.com/adult-gtex/bulk-qtl/v10/single-tissue-cis-qtl/GTEx_Analysis_v10_eQTL.tar

# Normalized expression matrices
wget https://storage.googleapis.com/adult-gtex/bulk-gex/v10/rna-seq/GTEx_Analysis_v10_RNASeQCv2.4.2_gene_reads.gct.gz

Additional Resources

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Codex

34.15%
按下载量换算51

Claude

28.73%
按下载量换算43

Cursor

18.71%
按下载量换算28

Gemini CLI

9.61%
按下载量换算14

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

敏感数据

该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills