torchdrug

torchdrug is a skill for Claude Code, Codex from dralkh/iktinah. It costs 67 tokens per session (3,462 once invoked), scanned A, a copy of torchdrug, MIT.

A PyTorch-based machine-learning toolkit for molecules, proteins, chemical reactions, and biological knowledge graphs. It represents these subjects as connected structures so graph neural networks can learn from their relationships.

In plain words
What is it for?
Use it to predict molecular properties, model proteins, estimate drug-target binding, generate molecules, plan synthesis routes, or reason over biomedical knowledge graphs.
Why use it?
Building models for drug discovery and molecular science requires specialized data formats, model components, and datasets. This toolkit brings those pieces together for custom experiments.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to predict molecular properties, model proteins, estimate drug-target binding, generate molecules, plan synthesis routes, or reason over biomedical knowledge graphs.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/dralkh/iktinah/torchdrug
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.

Any agent
npx skills add dralkh/iktinah --skill torchdrug
Clone the repo
git clone --depth 1 https://github.com/dralkh/iktinah

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for torchdrug

README.md
[![agentmods](https://agentmods.dev/badge/skills/dralkh/iktinah/torchdrug/github.svg)](https://agentmods.dev/skills/dralkh/iktinah/torchdrug)
Your own site
<a href="https://agentmods.dev/skills/dralkh/iktinah/torchdrug"><img src="https://agentmods.dev/badge/skills/dralkh/iktinah/torchdrug/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for torchdrug

Your own site · 80×15
<a href="https://agentmods.dev/skills/dralkh/iktinah/torchdrug"><img src="https://agentmods.dev/badge/skills/dralkh/iktinah/torchdrug.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 67 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 3,462 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin 88% copy Near-identical to another mod 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.1 $0.00067 $0.03462
Opus 5 $0.00034 $0.01731
Sonnet 5 $0.00013 $0.00692
Haiku 4.5 $0.00007 $0.00346

Measured 7d ago against content hash f258d624bfcc, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-10, from the pricing page.

Security

Grade A, and why

torchdrug 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 7d ago.

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.

Origin

This is a copy

88% identical to torchdrug — 24 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

skills/torchdrug/SKILL.md · 460 lines

How it starts

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

TorchDrug

Overview

TorchDrug is a comprehensive PyTorch-based machine learning toolbox for drug discovery and molecular science. Apply graph neural networks, pre-trained models, and task definitions to molecules, proteins, and biological knowledge graphs, including molecular property prediction, protein modeling, knowledge graph reasoning, molecular generation, retrosynthesis planning, with 40+ curated datasets and 20+ model architectures.

When to Use This Skill

This skill should be used when working with:

Data Types:

  • SMILES strings or molecular structures
  • Protein sequences or 3D structures (PDB files)
  • Chemical reactions and retrosynthesis
  • Biomedical knowledge graphs
  • Drug discovery datasets

Tasks:

  • Predicting molecular properties (solubility, toxicity, activity)
  • Protein function or structure prediction
  • Drug-target binding prediction
  • Generating new molecular structures
  • Planning chemical synthesis routes
  • Link prediction in biomedical knowledge bases
  • Training graph neural networks on scientific data

Libraries and Integration:

  • TorchDrug is the primary library
  • Often used with RDKit for cheminformatics
  • Compatible with PyTorch and PyTorch Lightning
  • Integrates with AlphaFold and ESM for proteins

Getting Started

Installation

TorchDrug 0.2.1 (latest on PyPI, July 2023) requires Python 3.7–3.10 and PyTorch 1.8–2.0. Install PyTorch and torch-scatter / torch-cluster first (wheel URL depends on your PyTorch and CUDA versions — see installation docs).

uv pip install torch
# Match torch/CUDA in the URL, e.g. torch-2.0.0+cu118 or cpu
uv pip install torch-scatter torch-cluster -f https://pytorch-geometric.com/whl/torch-2.0.0+cu118.html
uv pip install torchdrug==0.2.1

On Apple Silicon, compile scatter/cluster from source; TorchDrug runs on CPU only (no MPS). Conda: conda install torchdrug -c milagraph -c conda-forge -c pytorch -c pyg.

Quick Example

Read the full file on GitHub · 460 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. 7d ago First seen · 460 lines · 67 tokens per session scan A f258d624bfcc

Subscribe to this mod's changes

torchdrug is a skill published in the GitHub repository dralkh/iktinah (77 stars, last pushed 2mo ago), licensed MIT. It adds 67 tokens to every session and 3,462 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. It is 88% identical to torchdrug, differing in 24 lines, and is treated as a copy.

Related

Other skills, from other repositories

histolab

Lightweight WSI tile extraction and preprocessing. Use for basic slide processing tissue detection, tile extraction, stain normalization for H&E images. Best for simple pipelines, dataset preparation, quick tile-based analysis. For advanced spatial proteomics, multiplexed imaging, or deep learning pipelines use pathml.

synthetic-sciences/openscience · 62 tokens

pyhealth

Comprehensive healthcare AI toolkit for developing, testing, and deploying machine learning models with clinical data. This skill should be used when working with electronic health records (EHR), clinical prediction tasks (mortality, readmission, drug recommendation), medical coding systems (ICD, NDC, ATC)…

synthetic-sciences/openscience · 109 tokens

deepchem

Molecular ML with diverse featurizers and pre-built datasets. Use for property prediction (ADMET, toxicity) with traditional ML or GNNs when you want extensive featurization options and MoleculeNet benchmarks. Best for quick experiments with pre-trained models, diverse molecular representations. For graph-first…

synthetic-sciences/openscience · 78 tokens

torch-geometric

Graph Neural Networks (PyG). Node/graph classification, link prediction, GCN, GAT, GraphSAGE, heterogeneous graphs, molecular property prediction, for geometric deep learning.

synthetic-sciences/openscience · 41 tokens

zarr-python

Chunked N-D arrays for cloud storage. Compressed arrays, parallel I/O, S3/GCS integration, NumPy/Dask/Xarray compatible, for large-scale scientific computing pipelines.

synthetic-sciences/openscience · 42 tokens

glycobiology

Glycosylation site prediction and glycobiology analysis. N-glycosylation motif finding, O-glycosylation hotspot prediction, glycan structure resources. Lightweight, pure Python. For protein function queries use uniprot-database; for structure analysis use alphafold-database.

synthetic-sciences/openscience · 67 tokens