mmpa

mmpa is a skill for Claude Code, Codex from Kdevos12/ALKYL. It costs 79 tokens per session (1,515 once invoked), scanned A, original, MIT.

A method for comparing pairs of molecules that differ by one small structural change. It links that change to differences in measured properties or biological activity, which is often called structure–activity relationship analysis.

In plain words
What is it for?
Use it to extract SAR rules from compound datasets, find activity cliffs, identify bioisosteres, estimate the effect of a proposed change, and generate analogue ideas.
Why use it?
It reveals which chemical substitutions tend to help or hurt a property and can expose cases where a tiny change causes a large effect.

Skill for Claude CodeCodex

Part of the alkyl plugin — 27 skills shipped together

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/kdevos12/alkyl/mmpa
Any agent
npx skills add Kdevos12/ALKYL --skill mmpa
Clone the repo
git clone --depth 1 https://github.com/Kdevos12/ALKYL

Made for: Claude Code, Codex.

Or install alkyl, the plugin that ships this one along with the rest of its 27 skills.

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 mmpa

README.md
[![agentmods](https://agentmods.dev/badge/skills/kdevos12/alkyl/mmpa.svg)](https://agentmods.dev/skills/kdevos12/alkyl/mmpa)
Your own site
<a href="https://agentmods.dev/skills/kdevos12/alkyl/mmpa"><img src="https://agentmods.dev/badge/skills/kdevos12/alkyl/mmpa.svg" alt="Measured on agentmods" height="20"></a>
Per session 79 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,515 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.00079 $0.01515
Opus 5 $0.00039 $0.00758
Sonnet 5 $0.00016 $0.00303
Haiku 4.5 $0.00008 $0.00152

Measured 4d ago against content hash 304e5dac2e25, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

mmpa 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 4d 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.

skills/mmpa/SKILL.md · 128 lines

How it starts

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

Matched Molecular Pair Analysis (MMPA)

MMPA identifies pairs of molecules (A, B) that differ by a single structural transformation (R₁ → R₂) at one site while sharing an identical molecular context. Aggregating ΔProperty across hundreds of such pairs extracts robust, context-free SAR rules.

When to Use This Skill

  • Extract SAR rules from a compound dataset (e.g., which H→F swap improves metabolic stability?)
  • Identify activity cliffs (large ΔActivity for small structural change)
  • Find bioisosteric replacements supported by experimental data
  • Predict property changes for a proposed structural modification
  • Generate analogue libraries from a lead compound using proven transforms
  • Prioritize which substituent to try next based on MMPA-derived rules

Core Concept

Molecule A:  [Context]-[R₁]   →   transform: R₁ → R₂
Molecule B:  [Context]-[R₂]

ΔProperty = P(B) - P(A)

SAR rule: "R₁ → R₂ causes ΔlogP = +0.45 ± 0.12 (N=18 pairs)"

Fragmentation (single-cut):

  • Variable part: the part that changes between A and B
  • Context: the shared skeleton (everything outside the cut bond)
  • Represented via SMIRKS: [R₁:1]>>[R₂:1] at attachment point

Double-cut: both variable parts and a central linker can vary — rarer, more specific.

Quick Start — mmpdb 4

pip install mmpdb
# or: conda install -c conda-forge mmpdb

# Full pipeline: SMILES file → SAR rules
mmpdb fragment compounds.smi -o fragments.h5
mmpdb index fragments.h5 -o mmpdb.db

# Load experimental properties (CSV with: smiles, id, prop1, prop2)
mmpdb loadprops mmpdb.db properties.csv

# Query: what transforms improve LogD?
mmpdb transform --smiles "c1ccc(cc1)C(=O)O" mmpdb.db \
    --property LogD \
    --min-pairs 3 \
    -o transform_results.csv

# Analyze SAR rules for a property
mmpdb analyze mmpdb.db --property pIC50 -o sar_rules.csv

Quick Start — Programmatic (RDKit + mmpdb Python API)

import mmpdblib
from mmpdblib import do_fragment, do_index

# Fragment a SMILES list programmatically
from mmpdblib.analysis_algorithms import find_mmps

smiles_dict = {
    "mol_A": "c1ccc(CC)cc1",   # ethylbenzene
    "mol_B": "c1ccc(CF)cc1",   # fluoromethylbenzene
    "mol_C": "c1ccc(CCl)cc1",  # chloromethylbenzene
}

# Find matched molecular pairs
pairs = find_mmps(list(smiles_dict.values()), list(smiles_dict.keys()))
# pairs: list of (id1, id2, transform_SMIRKS, context_SMILES)

Read the full file on GitHub · 128 lines

Files

What ships with it

5 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. 4d ago First seen · 128 lines · 79 tokens per session scan A 304e5dac2e25

Subscribe to this mod's changes

mmpa is a skill published in the GitHub repository Kdevos12/ALKYL (6 stars, last pushed 5mo ago), licensed MIT. It adds 79 tokens to every session and 1,515 once invoked, about $0.0004 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-31.

Related

Other skills, from other repositories

datamol

Pythonic wrapper around RDKit with simplified interface and sensible defaults. Preferred for standard drug discovery including SMILES parsing, standardization, descriptors, fingerprints, clustering, 3D conformers, parallel processing. Returns native rdkit.Chem.Mol objects. For advanced control or custom parameters…

synthetic-sciences/openscience · 67 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

molecular-optimization

Iterative lead optimization with analyze-reason-generate-verify-evaluate loop. Paper-backed (MT-Mol, DrugR, MultiMol).

synthetic-sciences/openscience · 34 tokens

admet-reasoning

Interpretable ADMET analysis with mechanistic reasoning. Maps liabilities to structural causes and biological pathways. Based on CoTox (Park 2025) and DrugR (Liu 2026).

synthetic-sciences/openscience · 47 tokens

rdkit

Cheminformatics toolkit for fine-grained molecular control. SMILES/SDF parsing, descriptors (MW, LogP, TPSA), fingerprints, substructure search, 2D/3D generation, similarity, reactions. For standard workflows with simpler interface, use datamol (wrapper around RDKit). Use rdkit for advanced control, custom…

synthetic-sciences/openscience · 80 tokens

smiles-validation

Strict SMILES validation, structural comparison, and modification verification. Catches invalid LLM-generated molecules.

synthetic-sciences/openscience · 24 tokens