datamol

A Python wrapper around RDKit, a widely used toolkit for working with chemical structures. It provides simpler functions for reading, standardising, measuring, comparing and visualising molecules.

In plain words
What is it for?
Converting SMILES, SELFIES and InChI formats, cleaning structures, calculating descriptors and fingerprints, generating 3D conformers, clustering molecules, selecting diverse compounds, analysing scaffolds and processing batches.
Why use it?
It removes repetitive setup and gives common cheminformatics tasks sensible defaults. Its molecular objects remain compatible with RDKit for more specialised work.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/k-dense-ai/scientific-agent-skills/datamol
Any agent
npx skills add K-Dense-AI/scientific-agent-skills --skill datamol
Clone the repo
git clone --depth 1 https://github.com/K-Dense-AI/scientific-agent-skills

Made for: Claude Code, Codex.

Per session 67 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,973 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00067 $0.01973
Opus 5 $0.00034 $0.00986
Sonnet 5 $0.00013 $0.00395
Haiku 4.5 $0.00007 $0.00197

Measured yesterday against content hash 41062cea6b8a, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

datamol scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/datamol/SKILL.md · 201 lines

How it starts

The opening of the file, as written. The whole thing — 201 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Datamol Cheminformatics Skill

Overview

Datamol is a Python library that provides a lightweight, Pythonic abstraction layer over RDKit for molecular cheminformatics. Simplify complex molecular operations with sensible defaults, efficient parallelization, and modern I/O capabilities. All molecular objects are native rdkit.Chem.Mol instances, ensuring full compatibility with the RDKit ecosystem.

Version note: Examples target datamol 0.12.x (PyPI stable: 0.12.5, June 2024). Since 0.10.0, modules are lazy-loaded by default (set DATAMOL_DISABLE_LAZY_LOADING=1 to disable). Since 0.12.2, RDKit is a direct PyPI dependency of datamol. Fingerprints use RDKit's rdFingerprintGenerator API (0.12.5+).

Key capabilities:

  • Molecular format conversion (SMILES, SELFIES, InChI)
  • Structure standardization and sanitization
  • Molecular descriptors and fingerprints
  • 3D conformer generation and analysis
  • Clustering and diversity selection
  • Scaffold and fragment analysis
  • Chemical reaction application
  • Visualization and alignment
  • Batch processing with parallelization
  • Cloud storage support via fsspec

Installation and Setup

Guide users to install datamol:

uv pip install datamol

RDKit is installed automatically with datamol. For remote file paths (S3, GCS, HTTP), install the matching fsspec backend:

uv pip install s3fs   # AWS S3
uv pip install gcsfs  # Google Cloud Storage

Import convention:

import datamol as dm

Core Workflows

Ten workflow areas, each with worked code, are documented in references/core_workflows.md:

# Area Covers
1 Basic molecule handling to_mol, batch conversion, error handling, canonical and isomeric SMILES, sanitization and full standardization
2 Reading and writing files SDF, SMILES, CSV, Excel with rendered structures, the universal reader/writer, and cloud or HTTPS paths
3 Descriptors and properties the standard descriptor set, parallel computation, aromaticity, stereochemistry, flexibility, and filtering
4 Fingerprints and similarity ECFP4 and other types, pairwise and cross-set distances, nearest-neighbour lookup (Tanimoto distance = 1 − similarity)
5 Clustering and diversity similarity clustering, diverse subset picking, and cluster centroids
6 Scaffold analysis Bemis-Murcko scaffolds, grouping and counting, and scaffold-disjoint train/test splits
7 Fragmentation fragmenting molecules, finding common fragments across a library, and fragment-based scoring
8 3D conformers generation, access, RMSD clustering, representative selection, and SASA
9 Visualization grids, files, publication SVG, substructure alignment, atom and bond highlighting, conformer display
10 Chemical reactions reaction SMARTS, applying to a molecule or a whole library

Read the full file on GitHub · 201 lines

Files

What ships with it

8 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 201 lines · 67 tokens per session scan A 41062cea6b8a

Subscribe to this mod's changes

datamol is a skill published in the GitHub repository K-Dense-AI/scientific-agent-skills (40,390 stars, last pushed yesterday), licensed MIT. It adds 67 tokens to every session and 1,973 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

discovery-toolbox

A routed repertoire of 90 scientific thinking operators for biological research agents - visual reasoning, detectability and information budgets, search reframing, causal identification, competing explanations, observation and selection processes, pipeline artifact diagnosis, effort allocation, and confirmation…

dekan-aleksandr/biodiscovery-skills · 122 tokens

alphafold-pocket-evaluator

Parses AlphaFold2 PDB files, computes per-residue pLDDT confidence scores, and evaluates Solvent Accessible Surface Area (SASA) of active site pockets.

YuliaNuzhnenko/bioinformatics-agent-skills · 43 tokens

pydeseq2-bulk-rna

Automated negative binomial differential gene expression analysis, log2 fold-change calculation, p-value adjustment (FDR), and Volcano plot generation.

YuliaNuzhnenko/bioinformatics-agent-skills · 38 tokens

scanpy-sc-analyzer

Autonomous single-cell RNA-seq quality control filtering, Harmony batch-effect correction, Leiden clustering, UMAP visualization, and marker gene annotation.

YuliaNuzhnenko/bioinformatics-agent-skills · 34 tokens

card-amr-profiler

Scans bacterial genome assemblies against CARD (Comprehensive Antibiotic Resistance Database) and ResFinder to map drug-class resistance heatmaps.

YuliaNuzhnenko/bioinformatics-agent-skills · 32 tokens

diffdock-virtual-screener

Runs DiffDock generative diffusion models for blind protein-ligand docking against AlphaFold structures and ranks candidates by confidence scores.

YuliaNuzhnenko/bioinformatics-agent-skills · 33 tokens