download-gdc
Skill4 starsChanged 12 days agoMITView on GitHub
Download files from the NCI Genomic Data Commons (GDC) using the GDC Data Transfer Tool and REST API, supporting both open-access and controlled-access data.
- Sends data out
In this repository56 other files it gives its agents.
- bioinformatics-env-setupSkill
- design-thermostable-mutationsSkill
- download-geoSkill
- download-sraSkill
- source-summarizerSkill
- genome-alignment-qcSkill
- genome-read-alignmentSkill
- genome-variant-annotationSkill
- genome-variant-callingSkill
- genome-variant-filteringSkill
- metagenome-assemblySkill
- metagenome-binningSkill
- metagenome-functional-profilingSkill
- metagenome-host-removalSkill
- metagenome-taxonomic-profilingSkill
- ncbi-eutilities-assistantSkill
- ngs-quality-controlSkill
- ngs-read-preprocessingSkill
- paper-to-briefSkill
- predict-protein-heat-stabilitySkill
- researchSkill
- rnaseq-alignment-qcSkill
- rnaseq-differential-expressionSkill
- rnaseq-functional-enrichmentSkill
- rnaseq-read-alignmentSkill
- rnaseq-read-countingSkill
- rnaseq-transcript-quantificationSkill
- rpsblast-assistantSkill
- scrnaseq-cellranger-countSkill
- scrnaseq-cell-type-annotationSkill
- scrnaseq-clusteringSkill
- scrnaseq-differential-expressionSkill
- scrnaseq-integrationSkill
- scrnaseq-quality-controlSkill
- scrnaseq-trajectory-analysisSkill
- search-enaSkill
- search-geoSkill
- search-gsaSkill
- search-ncbi-datasetsSkill
- search-sraSkill
- stat-analyze-distributionSkill
- stat-assess-data-qualitySkill
- stat-bayesian-estimationSkill
- stat-cluster-samplesSkill
- stat-compare-multiple-groupsSkill
- stat-compare-two-groupsSkill
- stat-fit-glmSkill
- stat-fit-linear-modelSkill
- stat-learn-bayesian-networkSkill
- stat-logistic-regressionSkill
- stat-nonlinear-embeddingSkill
- stat-pairwise-correlationSkill
- stat-pcaSkill
- stat-survival-analysisSkill
- structured-intelligence-skill-creatorSkill
- <skill-id>Skill
The file
We split this skill into the rules it gives an agent
4 rules. About 0 are common, 2 are distinctive, and 2 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈2
Distinctive · estimate
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 38
If a manifest file is provided, validate it (check columns: id, filename, md5, size, state).
- Distinctive: line 39
If UUIDs are provided, generate a manifest via GDC API:
- Distinctive: line 44
If a project ID and filters are provided, query the GDC files endpoint and produce a manifest:
- Very specific: line 83
Write download_report.tsv with: uuid, filename, expected_md5, actual_md5, size_bytes, status.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Skill: Download GDC
Use When
- A user wants to download BAM, VCF, FASTQ, or other files from the NCI GDC (TCGA, TARGET, CPTAC, etc.).
- A user has a GDC manifest file and wants to download all listed files.
- A user wants to query the GDC API to build a manifest by project, data type, workflow, or data category.
- A user wants to download controlled-access data using a GDC user token.
- A user wants to verify downloaded file integrity using MD5 checksums from the GDC manifest.
- A user wants to organize downloaded files by case, sample, or data type.
Inputs
- Required:
- one of:
- path to a GDC manifest file (TSV with columns:
id,filename,md5,size,state) - GDC file UUID(s) to generate a manifest on the fly
- GDC project ID (e.g.,
TCGA-BRCA) and filters to query and build a manifest
- path to a GDC manifest file (TSV with columns:
- one of:
- Optional:
--token-file FILE— GDC user token for controlled-access data (required for dbGaP-protected files)--outdir DIR— output directory (default:gdc_downloads)--jobs N— number of parallel download streams (default: 1; max recommended: 8)--retries N— retry count on network errors (default: 3)--no-verify— skip MD5 verification after download--dry-run— print manifest and download commands without executing--data-type TYPE— filter for manifest generation (e.g.,"Aligned Reads","Masked Somatic Mutation")--workflow TYPE— workflow filter (e.g.,"STAR 2-Pass","MuTect2")--experimental-strategy— filter (e.g.,"RNA-Seq","WXS","WGS")
Workflow
- Obtain a manifest:
- If a manifest file is provided, validate it (check columns:
id,filename,md5,size,state). - If UUIDs are provided, generate a manifest via GDC API:
curl -o manifest.txt \ "https://api.gdc.cancer.gov/manifest?ids=$(echo "$UUIDS" | tr ' ' ',')" - If a project ID and filters are provided, query the GDC files endpoint and produce a manifest:
curl -XPOST "https://api.gdc.cancer.gov/files" \ -H "Content-Type: application/json" \ -d '{"filters":{"op":"and","content":[ {"op":"=","content":{"field":"cases.project.project_id","value":"TCGA-BRCA"}}, {"op":"=","content":{"field":"data_type","value":"Aligned Reads"}}, {"op":"=","content":{"field":"access","value":"open"}}]}, "fields":"file_id,file_name,md5sum,file_size,state", "size":"10000","format":"tsv"}'
- If a manifest file is provided, validate it (check columns:
- Check access tier: inspect the
accessfield in the API response.open: no token needed.controlled:--token-fileis required; warn the user if it is absent.
- Download with gdc-client:
gdc-client download \ -m manifest.txt \ [-t token.txt] \ -d "$OUTDIR" \ --n-processes "$JOBS" \ --retry-amount "$RETRIES" - Verify MD5 checksums:
while IFS=$'\t' read -r uuid filename md5 size state; do [[ "$uuid" == "id" ]] && continue actual=$(md5sum "$OUTDIR/$uuid/$filename" | awk '{print $1}') if [[ "$actual" != "$md5" ]]; then echo "CHECKSUM FAIL: $filename" >&2 fi done < manifest.txt - Organize files (optional): flatten the
<uuid>/<filename>layout into a user-specified directory structure by data type, project, or sample. - Write
download_report.tsvwith:uuid,filename,expected_md5,actual_md5,size_bytes,status.
Output Contract
- Downloaded files under
<outdir>/<uuid>/<filename>(GDC default layout) manifest.txtused for the download (generated or provided)download_report.tsvwith columns:uuid,filename,expected_md5,actual_md5,size_bytes,status(OK/CHECKSUM_FAIL/MISSING)failed_uuids.txtlisting UUIDs that failed all retry attempts- Exact
gdc-clientcommand issued
Limits
- GDC Data Transfer Tool (
gdc-client) must be installed; download from https://gdc.cancer.gov/access-data/gdc-data-transfer-tool. - Controlled-access data requires a GDC user token obtained from https://portal.gdc.cancer.gov after dbGaP authorization. Tokens expire after 30 days.
- Open-access files (e.g., gene expression counts, masked somatic mutations) do not require a token.
- GDC manifest files are project-snapshot–specific; file UUIDs are stable but a manifest generated today may differ from one generated later as projects update.
- Parallel downloads (
--jobs > 1) may trigger GDC rate limiting; start with 3–4 jobs and increase cautiously. - Common failure cases:
- expired or invalid token causing 403 errors on controlled-access files
- manifest containing files from multiple access tiers; download will fail on controlled-access files if no token is provided
- disk space exhaustion for large TCGA BAM files (whole-genome BAMs are 50–200 GB each)
- MD5 mismatch indicating a partial or corrupted download; delete the file and retry
- mixing GDC file UUIDs with TCGA barcode IDs (barcodes must be resolved to UUIDs via the GDC API before use)
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

