Agent skill

Chemical Compound Retrieval

by lamm-mit in lamm-mit/scienceclaw

ToolUniverse workflow — Chemical Compound Retrieval. An agent skill from lamm-mit/scienceclaw.

Apache-2.0Auto-check passed

Install Chemical Compound Retrieval

skills CLI
$ npx skills add lamm-mit/scienceclaw --skill chemical-compound-retrieval -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install lamm-mit/scienceclaw chemical-compound-retrieval --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/lamm-mit/scienceclaw.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/chemical-compound-retrieval .claude/skills/chemical-compound-retrieval && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
chemical-compound-retrieval
GitHub stars
246
Token cost
~2.4k tokens
SKILL.md length
573 words
Files
3 (incl. scripts)
Skills in repo
86
Repo updated
First seen
Licence
Apache-2.0

At a glance

ToolUniverse workflow — Chemical Compound Retrieval. An agent skill from lamm-mit/scienceclaw.

  • Works in 4 steps: Clarification (When Needed) → Compound Disambiguation → Data Retrieval (Internal) → …
  • SKILL.md covers Workflow Overview, Phase 0: Clarification (When…, Phase 1: Compound Disambiguation and Phase 2: Data Retrieval…, plus 6 more sections
  • Runs Python scripts from its folder

What it does

Chemical Compound Retrieval is an agent skill from lamm-mit/scienceclaw. ToolUniverse workflow — Chemical Compound Retrieval

Its SKILL.md is about 2.4k tokens, which your agent loads only when the skill is triggered. The skill folder holds 4 other files, including scripts (for example `scripts/run.py`).

The licence is Apache-2.0.

Example prompts

  • “/chemical-compound-retrieval”

Requirements

  • Python 3

Workflow steps

4 steps, taken from the step headings in SKILL.md.

  1. Clarification (When Needed)
  2. Compound Disambiguation
  3. Data Retrieval (Internal)
  4. Report Compound Profile

What it can do on your machine

Read from SKILL.md and the folder at commit ab9aba1. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Ships 2 files in scripts/ (Python), which the agent can run.

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Chemical Compound Retrieval loads about 2.4k tokens when it runs. Until then it costs about 20 tokens; SKILL.md has 573 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~20
When it runs · the whole SKILL.md, loaded when a task matches
~2.4k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); the scripts in this folder are not scanned.

SKILL.md

The full file from lamm-mit/scienceclaw at commit ab9aba1, republished under its Apache-2.0 licence (© lamm-mit). 573 words, ~2,358 tokens.

Download SKILL.mdSave it as .claude/skills/chemical-compound-retrieval/SKILL.md (or your agent's skills folder). This skill also uses 2 other files; get the full folder from GitHub.
name
chemical-compound-retrieval
description
ToolUniverse workflow — Chemical Compound Retrieval
source
https://github.com/mims-harvard/ToolUniverse/tree/main/skills/tooluniverse-chemical-compound-retrieval

name: tooluniverse-chemical-compound-retrieval description: Retrieves chemical compound information from PubChem and ChEMBL with disambiguation, cross-referencing, and quality assessment. Creates comprehensive compound profiles with identifiers, properties, bioactivity, and drug information. Use when users need chemical data, drug information, or mention PubChem CID, ChEMBL ID, SMILES, InChI, or compound names.

Chemical Compound Information Retrieval

Retrieve comprehensive chemical compound data with proper disambiguation and cross-database validation.

IMPORTANT: Always use English compound names and search terms in tool calls, even if the user writes in another language (e.g., translate "阿司匹林" to "aspirin"). Only try original-language terms as a fallback if English returns no results. Respond in the user's language.

Workflow Overview

Phase 0: Clarify (if needed)
    ↓
Phase 1: Disambiguate Compound Identity
    ↓
Phase 2: Retrieve Data (Internal)
    ↓
Phase 3: Report Compound Profile

Phase 0: Clarification (When Needed)

Ask the user ONLY if:

  • Compound name is highly ambiguous (e.g., "vitamin E" → α, β, γ, δ-tocopherol?)
  • Multiple distinct compounds share the name (e.g., "aspirin" is clear; "sterol" is not)

Skip clarification for:

  • Unambiguous drug names (aspirin, ibuprofen, metformin)
  • Specific identifiers provided (CID, ChEMBL ID, SMILES)
  • Clear structural queries (SMILES, InChI)

Phase 1: Compound Disambiguation

1.1 Resolve Primary Identifier
python
from tooluniverse import ToolUniverse
tu = ToolUniverse()
tu.load_tools()

# Strategy depends on input type
if user_provided_cid:
    cid = user_provided_cid
elif user_provided_smiles:
    result = tu.tools.PubChem_get_CID_by_SMILES(smiles=smiles)
    cid = result["data"]["cid"]
elif user_provided_name:
    result = tu.tools.PubChem_get_CID_by_compound_name(compound_name=name)
    cid = result["data"]["cid"]
1.2 Cross-Reference Identifiers

Always establish compound identity across both databases:

python
# PubChem → ChEMBL cross-reference
chembl_result = tu.tools.ChEMBL_search_compounds(query=compound_name, limit=5)
if chembl_result["data"]:
    chembl_id = chembl_result["data"][0]["molecule_chembl_id"]
1.3 Handle Naming Collisions

For generic names (e.g., "vitamin", "steroid", "acid"):

  • Search returns multiple CIDs → present top matches with structures
  • Verify SMILES/InChI matches user intent
  • Note stereoisomers or salt forms if relevant

Identity Resolution Checklist:

  • PubChem CID established
  • ChEMBL ID cross-referenced (if exists)
  • Canonical SMILES captured
  • Stereochemistry noted (if relevant)
  • Salt forms identified (if applicable)

Phase 2: Data Retrieval (Internal)

Retrieve all data silently. Do NOT narrate the search process.

2.1 Core Properties (PubChem)
python
# Basic properties
props = tu.tools.PubChem_get_compound_properties_by_CID(cid=cid)

# Bioactivity summary
bio = tu.tools.PubChem_get_bioactivity_summary_by_CID(cid=cid)

# Drug label (if approved drug)
drug = tu.tools.PubChem_get_drug_label_info_by_CID(cid=cid)

# Structure image
image = tu.tools.PubChem_get_compound_2D_image_by_CID(cid=cid)
2.2 Bioactivity Data (ChEMBL)
python
if chembl_id:
    # Detailed bioactivity
    activity = tu.tools.ChEMBL_get_bioactivity_by_chemblid(chembl_id=chembl_id)
    
    # Protein targets
    targets = tu.tools.ChEMBL_get_target_by_chemblid(chembl_id=chembl_id)
    
    # Assay data
    assays = tu.tools.ChEMBL_get_assays_by_chemblid(chembl_id=chembl_id)
2.3 Optional Extended Data
python
# Patents (for drugs)
patents = tu.tools.PubChem_get_associated_patents_by_CID(cid=cid)

# Similar compounds (for SAR)
similar = tu.tools.PubChem_search_compounds_by_similarity(cid=cid, threshold=85)
Fallback Chains
PrimaryFallbackNotes
PubChem_get_CID_by_compound_nameChEMBL_search_compounds → get SMILES → PubChem_get_CID_by_SMILESName lookup failed
ChEMBL_get_bioactivityPubChem_get_bioactivity_summaryChEMBL ID unavailable
PubChem_get_drug_label_infoNote "Drug label unavailable"Not an approved drug

Phase 3: Report Compound Profile

Output Structure

Present results as a Compound Profile Report. Hide all search process details.

markdown
# Compound Profile: [Compound Name]

## Identity
| Property | Value |
|----------|-------|
| **PubChem CID** | [cid] |
| **ChEMBL ID** | [chembl_id or "N/A"] |
| **IUPAC Name** | [full name] |
| **Common Names** | [synonyms] |

## Chemical Properties

### Molecular Descriptors
| Property | Value | Drug-Likeness |
|----------|-------|---------------|
| **Formula** | C₉H₈O₄ | - |
| **Molecular Weight** | 180.16 g/mol | ✓ (<500) |
| **LogP** | 1.19 | ✓ (-2 to 5) |
| **H-Bond Donors** | 1 | ✓ (<5) |
| **H-Bond Acceptors** | 4 | ✓ (<10) |
| **Polar Surface Area** | 63.6 Ų | ✓ (<140) |
| **Rotatable Bonds** | 3 | ✓ (<10) |

### Structural Representation
- **SMILES**: `CC(=O)Oc1ccccc1C(=O)O`
- **InChI**: `InChI=1S/C9H8O4/...`

[2D structure image if available]

## Bioactivity Profile

### Summary
- **Active in**: [X] assays out of [Y] tested
- **Primary Targets**: [list top targets]
- **Mechanism**: [if known]

### Key Target Interactions (from ChEMBL)
| Target | Activity Type | Value | Units |
|--------|--------------|-------|-------|
| [Target 1] | IC50 | [value] | nM |
| [Target 2] | Ki | [value] | nM |

## Drug Information (if applicable)

### Clinical Status
| Property | Value |
|----------|-------|
| **Approval Status** | [Approved/Investigational/N/A] |
| **Drug Class** | [therapeutic class] |
| **Indication** | [approved uses] |
| **Route** | [oral/IV/topical/etc.] |

### Safety
- **Black Box Warning**: [Yes/No]
- **Major Interactions**: [if any]

## Related Compounds (if retrieved)

Top 5 structurally similar compounds:
| CID | Name | Similarity | Key Difference |
|-----|------|------------|----------------|
| [cid] | [name] | 95% | [note] |

## Data Sources
- PubChem: [CID link]
- ChEMBL: [ChEMBL ID link]
- Retrieved: [date]

Data Quality Tiers

Apply to data completeness assessment:

TierSymbolCriteria
Complete●●●All core properties + bioactivity + drug info
Substantial●●○Core properties + bioactivity OR drug info
Basic●○○Core properties only
Minimal○○○CID/name only, limited data

Include in report header:

markdown
**Data Completeness**: ●●● Complete (properties, bioactivity, drug data)

Show full SKILL.md (227 more words)Show less

Completeness Checklist

Every compound profile MUST include these sections (even if "unavailable"):

Identity (Required)
  • PubChem CID
  • ChEMBL ID (or "N/A")
  • IUPAC name
  • Canonical SMILES
Properties (Required)
  • Molecular formula
  • Molecular weight
  • LogP
  • Lipinski rule assessment
Bioactivity (Required)
  • Activity summary (or "No bioactivity data")
  • Primary targets (or "Unknown")
Drug Info (If Approved Drug)
  • Approval status
  • Indication
  • Drug class
Always Include
  • Data sources with links
  • Retrieval date
  • Quality tier assessment

Common Use Cases

Drug Property Check

User: "Tell me about metformin" → Full compound profile with drug information emphasis

Structure Verification

User: "Verify this SMILES: CC(=O)Oc1ccccc1C(=O)O" → Disambiguation-focused profile, confirm identity

SAR Analysis

User: "Find compounds similar to ibuprofen" → Similarity search + comparative property table

Target Identification

User: "What proteins does gefitinib target?" → ChEMBL bioactivity emphasis with target list


Error Handling

ErrorResponse
"Compound not found"Try synonyms, verify spelling, offer SMILES search
"No ChEMBL ID"Note in Identity section, continue with PubChem data
"No bioactivity data"Include section with "No bioactivity screening data available"
"API timeout"Retry once, note unavailable data with "(retrieval failed)"

Tool Reference

PubChem (Chemical Database)

ToolPurpose
PubChem_get_CID_by_compound_nameName → CID
PubChem_get_CID_by_SMILESStructure → CID
PubChem_get_compound_properties_by_CIDMolecular properties
PubChem_get_compound_2D_image_by_CIDStructure visualization
PubChem_get_bioactivity_summary_by_CIDActivity overview
PubChem_get_drug_label_info_by_CIDFDA drug labels
PubChem_get_associated_patents_by_CIDIP information
PubChem_search_compounds_by_similarityFind analogs
PubChem_search_compounds_by_substructureSubstructure search

ChEMBL (Bioactivity Database)

ToolPurpose
ChEMBL_search_compoundsName/structure search
ChEMBL_get_compound_by_chemblidCompound details
ChEMBL_get_bioactivity_by_chemblidActivity data
ChEMBL_get_target_by_chemblidProtein targets
ChEMBL_search_targetsTarget search
ChEMBL_get_assays_by_chemblidAssay metadata

© lamm-mit, Apache-2.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 2 other files (scripts) in skills/chemical-compound-retrieval of lamm-mit/scienceclaw.

  • SKILL.md
  • scripts/__pycache__/run.cpython-313.pyc
  • scripts/run.py

Open the folder on GitHubat commit ab9aba1

Compare with similar skills

Chemical Compound Retrieval next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Chemical Compound Retrieval compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Chemical Compound Retrieval this skilllamm-mit/scienceclaw246—~2.4kAutomated safety check: PassApache-2.0
Tooluniverse Chemical Compound Retrievalwu-yc/LabClaw1.1k2 repos~2.3kAutomated safety check: PassNone
Iterative Retrievalaffaan-m/ECC277k7 repos~1.6kAutomated safety check: PassMIT
Tooluniverse Chemical Safetywu-yc/LabClaw1.1k2 repos~7.5kAutomated safety check: PassNone
Tooluniverse Sequence Retrievalwu-yc/LabClaw1.1k2 repos~2.7kAutomated safety check: PassNone
Tooluniverse Expression Data Retrievalwu-yc/LabClaw1.1k2 repos~2.6kAutomated safety check: PassNone

Similar skills

  • Retrieves chemical compound information from PubChem and ChEMBL with disambiguation, cross-referencing, and quality assessment.

    1.1k GitHub starsUsed in 2 repos~2.3k tokens
    Research & ScienceAuto-check passed
  • Pattern for progressively refining context retrieval to solve the subagent context problem.

    277k GitHub starsUsed in 7 repos~1.6k tokens
    Agent WorkflowsAuto-check passed
  • Comprehensive chemical safety and toxicology assessment integrating ADMET-AI predictions, CTD toxicogenomics, FDA label safety data, DrugBank safety profiles, and STITCH chemical-protein interactions.

    1.1k GitHub starsUsed in 2 repos~7.5k tokens
    Research & ScienceAuto-check passed
  • Retrieves biological sequences (DNA, RNA, protein) from NCBI and ENA with gene disambiguation, accession type handling, and comprehensive sequence profiles.

    1.1k GitHub starsUsed in 2 repos~2.7k tokens
    Research & ScienceAuto-check passed
  • Retrieves gene expression and omics datasets from ArrayExpress and BioStudies with gene disambiguation, experiment quality assessment, and structured reports.

    1.1k GitHub starsUsed in 2 repos~2.6k tokens
    Research & ScienceAuto-check passed
  • Retrieves protein structure data from RCSB PDB, PDBe, and AlphaFold with protein disambiguation, quality assessment, and comprehensive structural profiles.

    1.1k GitHub starsUsed in 2 repos~2.8k tokens
    Research & ScienceAuto-check passed

More from lamm-mit/scienceclaw

All 86 skills in this repo
  • Fred Economic Data

    lamm-mit/scienceclaw

    Query FRED (Federal Reserve Economic Data) API for 800,000+ economic time series from 100+ sources.

    246 GitHub starsUsed in 4 repos~3k tokens
    Auto-check passed
  • Drug Research

    lamm-mit/scienceclaw

    Generates comprehensive drug research reports with compound disambiguation, evidence grading, and mandatory completeness sections.

    246 GitHub starsUsed in 3 repos~1.7k tokens
    Auto-check passed
  • Imaging Data Commons

    lamm-mit/scienceclaw

    Query and download public cancer imaging data from NCI Imaging Data Commons using idc-index.

    246 GitHub starsUsed in 5 repos~11k tokens
    Auto-check passed
  • Rowan

    lamm-mit/scienceclaw

    Cloud-based quantum chemistry platform with Python API. An agent skill from lamm-mit/scienceclaw.

    246 GitHub starsUsed in 4 repos~3.1k tokens
    Auto-check: warnings
  • Infographics

    lamm-mit/scienceclaw

    Create professional infographics using Nano Banana Pro AI with smart iterative refinement.

    246 GitHub starsUsed in 6 repos~4.4k tokens
    Auto-check: notes
  • Disease Research

    lamm-mit/scienceclaw

    Generate comprehensive disease research reports using 100+ ToolUniverse tools.

    246 GitHub stars~946 tokensUpdated 1 mo ago
    Auto-check passed

Questions about Chemical Compound Retrieval

What does Chemical Compound Retrieval do?

ToolUniverse workflow — Chemical Compound Retrieval. An agent skill from lamm-mit/scienceclaw. Chemical Compound Retrieval is an agent skill from lamm-mit/scienceclaw.

How do I install Chemical Compound Retrieval in Claude Code?

Run `npx skills add lamm-mit/scienceclaw --skill chemical-compound-retrieval -a claude-code`. Or copy the skill folder (skills/chemical-compound-retrieval in lamm-mit/scienceclaw) into .claude/skills/chemical-compound-retrieval in your project. Claude Code loads it when a task matches its description.

How do I install Chemical Compound Retrieval in Codex?

Run `npx skills add lamm-mit/scienceclaw --skill chemical-compound-retrieval -a codex`. Or copy the skill folder (skills/chemical-compound-retrieval in lamm-mit/scienceclaw) into .agents/skills/chemical-compound-retrieval in your project. Codex loads it when a task matches its description.

Can I use Chemical Compound Retrieval in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add lamm-mit/scienceclaw --skill chemical-compound-retrieval -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/chemical-compound-retrieval, .gemini/skills/chemical-compound-retrieval, .github/skills/chemical-compound-retrieval and .opencode/skills/chemical-compound-retrieval in your project.

What does Chemical Compound Retrieval need to run?

Going by SKILL.md and its folder, Chemical Compound Retrieval needs Python for the scripts in its folder. Our summary lists: Python 3.

Does Chemical Compound Retrieval access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Chemical Compound Retrieval safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. The check reads SKILL.md only: the scripts in the folder are not scanned, so read them before running anything.

What licence does Chemical Compound Retrieval use?

Chemical Compound Retrieval is published under the Apache-2.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Chemical Compound Retrieval use?

About 2.4k tokens (SKILL.md is roughly 9.4k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Chemical Compound Retrieval?

Skills that share tags, products or a category with Chemical Compound Retrieval: Tooluniverse Chemical Compound Retrieval (wu-yc/LabClaw, 1.1k stars), Iterative Retrieval (affaan-m/ECC, 277k stars), Tooluniverse Chemical Safety (wu-yc/LabClaw, 1.1k stars) and Tooluniverse Sequence Retrieval (wu-yc/LabClaw, 1.1k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Chemical Compound Retrieval?

lamm-mit (a GitHub user) maintains it in lamm-mit/scienceclaw, which has 246 GitHub stars. The repository holds 86 skills in this directory. The repository was last updated on August 21, 2026.

Source: lamm-mit/scienceclaw on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.