Skip to main content

JAMS-Fetch (Joint Automated Multi-source Sequence Fetcher) is a Python package. It automates the retrieval of sequence and structure data from major bioinformatics databases using a unified, user-friendly interface.

Project description

🧬 JAMS-Fetch

JAMS-Fetch (Joint Automated Multi-source Sequence Fetcher) is a Python package. It automates the retrieval of sequence and structure data from major bioinformatics databases using a unified, user-friendly interface.

Supported databases:

  • NCBI Nucleotide
  • NCBI Genome Assembly
  • UniProt
  • RCSB PDB
  • AlphaFold DB
  • ESM Metagenomic Atlas

Whether you're working with DNA sequences, protein sequences, or molecular structures, JAMS-Fetch simplifies the download process and saves files in standard formats.


🚀 Features

  • 🧠 Automatically detects the correct source based on ID format.
  • ⚙️ Unified API for batch FASTA sequence downloading.
  • 🔍 Separate functions for advanced, source-specific queries.
  • 💾 Saves sequences and structures in appropriate formats (FASTA, PDB, CIF).
  • 📁 Organizes downloads into user-defined directories.

📦 Installation

pip install jamsfetch

🚀 Quick Start

Use fetch_fasta() to automatically download sequences or structure files from multiple sources with a single list of IDs:

from jamsfetch import fetch_fasta

ids = ["P12345", "NM_001200.2", "GCF_000001405.39"]
fetch_fasta(
    id_list=ids,
    output_dir="downloads/",
    assembly_data_type="genomic"  # or "protein"
)

To download 3D protein structures, either experimentally determined or predicted, use fetch_structure():

from jamsfetch import fetch_structure

ids = ["Q8WXF3", "1A2B"]       # UniProt, PDB and ESM IDs are accepted
fetch_structure(
    id_list=ids,
    output_dir="downloads/",
    file_format="pdb",          # or "cif"
    source="experimental"       # or "predicted"
)

🔧 Advanced Usage

Use the following source-specific functions when you need greater control over what and how data is downloaded.

⛁ Uniprot

Download the original FASTA file(s) from UniProt:

get_uniprot( uniprot_ids='P12345', # specify a single UniProt ID or a list of IDs outdir="uniprot_fasta", # specify output directory for FASTA files )

⛁ NCBI Nucleotide

⛁ NCBI Genome Assembly

Download genomic or protein data for specific organisms or id(s):

from jamsfetch.utils import get_assembly

get_assembly(
    organism="Homo sapiens",         # specify an organism name
    ids=None,                        # or use specific assembly IDs
    bioproject=None,                 # or BioProject
    output_dir="genomes/",           # specify output directory
    data_type="genomic",             # "genomic" or "protein"
    n=1,                             # if organism was passed, number of genome/proteoms to download
    unzip=True,                  
    reference_only=True              # Only reference genomes if True
)

⛁ PDB

Download desired protein structures:

from jamsfetch.utils import get_pdb

get_pdb(
    pdb_ids=['1TUP', '9E2J'],       # specify a single ID or a list of IDs
    output_dir="structures/",       # specify output directory
    file_format="pdb",              # or "cif"
    unzip=True                      # whether to unzip or leave .gz files
)

⛁ AlphaFold DB

Download AlphaFold-predicted protein structures:

from jamsfetch.utils import get_alphafold

get_alphafold(
    uniprot_ids='P12345',           # specify a single ID or a list of IDs
    output_dir="structures/",       # specify output directory
    file_format="pdb",              # or "cif"
)

⛁ ESM Metagenomic Atlas

Download ESMFold-predicted protein structures:

from jamsfetch.utils import get_esm

get_esm(
    esm_ids='MGYP000740062793',     # specify a single ID or a list of IDs
    output_dir="structures/",       # specify output directory
    file_format="pdb",              # or "cif"
)

Upcoming capabilities:

  • Testing - Staszek

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

jamsfetch-0.0.1.tar.gz (10.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

jamsfetch-0.0.1-py3-none-any.whl (12.8 kB view details)

Uploaded Python 3

File details

Details for the file jamsfetch-0.0.1.tar.gz.

File metadata

  • Download URL: jamsfetch-0.0.1.tar.gz
  • Upload date:
  • Size: 10.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.8

File hashes

Hashes for jamsfetch-0.0.1.tar.gz
Algorithm Hash digest
SHA256 23840b71240d2a4e022b0cb7b67975d4d0f2b727a0a173b56335eb1c15311306
MD5 7d26e7a1a67d956eb7013a7bed43a56c
BLAKE2b-256 8361701333d03c0bc1dad3d0ad50941719bc9db62f1149400ccc9838acf44d37

See more details on using hashes here.

Provenance

The following attestation bundles were made for jamsfetch-0.0.1.tar.gz:

Publisher: publish.yml on aszymik/jams-fetch

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file jamsfetch-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: jamsfetch-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 12.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.8

File hashes

Hashes for jamsfetch-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 1cb0be16866c1bab805002f91b1a2dd10540990b03b9b50a668b2c6a8700e23d
MD5 ec80fd13a333e711c7307e88567c3ad5
BLAKE2b-256 20d8cbb9c0959e6991d890be7543ad3742b7f9f55d6d00eab37ea7e799d33d5a

See more details on using hashes here.

Provenance

The following attestation bundles were made for jamsfetch-0.0.1-py3-none-any.whl:

Publisher: publish.yml on aszymik/jams-fetch

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page