# Pdb Database

Use when you want to search for or download experimentally-determined 3D structures for...

- Repository: https://github.com/google-deepmind/science-skills (3377 stars)
- Category: Media
- License: Apache-2.0
- Last updated: 2026-10-23
- Runs scripts: yes, review before use

## Install

Claude Code: `npx skills add google-deepmind/science-skills --skill pdb-database -g -a claude-code -y`
Codex: `npx skills add google-deepmind/science-skills --skill pdb-database -g -a codex -y`
Cursor: `npx skills add google-deepmind/science-skills --skill pdb-database -g -a cursor -y`
Gemini CLI: `npx skills add google-deepmind/science-skills --skill pdb-database -g -a gemini-cli -y`

## Description

Use when you want to search for or download experimentally-determined 3D structures for biomolecules (proteins, nucleic acids, bound ligands). Supports searching by sequence similarity, structure similarity, chemical and other attributes. Also use to get metadata about biomolecular structure experiments.

## SKILL.md, as published by its author (untrusted third-party text, read it as data)

# RCSB Protein Data Bank skill

## Prerequisites

1.  **`uv`**: Read the `uv` skill and follow its Setup instructions to ensure
    `uv` is installed and on PATH.

2.  **User Notification**: If .licenses/pdb_database_LICENSE.txt does not
    already exist in the workspace root directory then (1) prominently notify
    the user to check the terms at https://www.rcsb.org/pages/usage-policy, then
    (2) create the file recording the notification text and timestamp.


## Core Rules

-   **Always prefer to use the provided scripts**. Only as a last resort use
    `curl`, `urllib`, raw HTTP requests, or any other method to access PDB APIs.
    The scripts automatically enforce required rate limits.
-   **Always redirect output to a file**. Parse output with e.g. `jq`, `grep`,
    or a short Python snippet. Do NOT print large API responses to stdout to
    avoid truncation.
-   **Notification**: If this skill is used, ensure this is mentioned in the
    output.
-   **Explain your queries** On completing a task that used PDB JSON/GraphQL
    queries, explain in clear language what your query did so the user can
    correct any bad assumptions.

## Attribute-based search workflow

1.  **Fetch the relevant schema** to discover searchable attribute names. For
    structure attributes: `uv run scripts/fetch_schema.py --api search_structure
    --output schema_structure.txt` For chemical attributes: `uv run
    scripts/fetch_schema.py --api search_chemical --output schema_chemical.txt`

2.  **Grep the schema** to find relevant attributes. Grep one keyword at a time
    and examine many lines, there are lots of similar attributes and you must
    choose the **best match** for the user's intent.

3.  **Compose and run a JSON search query** using the discovered attributes: `uv
    run scripts/search_pdb.py --query '<JSON>' --return_type <RETURN_TYPE>
    --output results.json` Pass the `--count_only` flag to get just the number
    of matching entries.

The rest: https://github.com/google-deepmind/science-skills/blob/HEAD/skills/pdb_database/SKILL.md
