molecular-optimization
Iterative lead optimization with analyze-reason-generate-verify-evaluate loop. Paper-backed (MT-Mol, DrugR, MultiMol).
- License 许可
- MIT
- 最近更新
- 2026-10-28
- Stars
- ★ 0
- Forks
- 0
01 前言 Front Matter
- name
- molecular-optimization
- tags
- [ "drug-discovery", "lead-optimization", "molecular-design", "ADMET" ]
- license
- MIT
- version
- 1.0.0
- category
- chemistry
- metadata
- { "skill-author": "Synthetic Sciences" }
- description
- Iterative lead optimization with analyze-reason-generate-verify-evaluate loop. Paper-backed (MT-Mol, DrugR, MultiMol).
- dependencies
- [ "rdkit-pypi", "numpy", "pandas" ]
02 资源文件 3
- 脚本scripts/compare_candidates.py5.7 KB
- 脚本scripts/optimize.py13.4 KB
- 脚本scripts/verify_smiles.py10.1 KB
03 SKILL.md 正文
Molecular Optimization
Overview
Lead optimization is the bottleneck of drug discovery — modifying a hit compound to improve potency, selectivity, and ADMET properties without breaking what already works. LLMs frequently generate invalid SMILES or propose modifications that don't appear in the actual structure.
This skill implements an iterative optimization protocol based on three peer-reviewed approaches:
- MT-Mol (Kim et al., 2025): Multi-agent tool-based reasoning with verification — SOTA on 17/23 PMO benchmark tasks
- DrugR (Liu et al., 2026): Explicit liability reasoning before generation — 18× improvement over blind generation
- MultiMol (Yu et al., 2025): Generate-then-rank with scaffold preservation — 82.3% multi-objective success rate
The core loop: Analyze → Identify Liabilities → Generate Candidates → Verify → Evaluate & Rank → Iterate.
When to Use This Skill
- Lead optimization: Improve ADMET properties of a hit while preserving potency
- Scaffold hopping: Find new scaffolds that maintain key pharmacophoric features
- Property-driven design: Generate analogs targeting specific property improvements (lower LogP, reduce hERG, improve solubility)
- Multi-objective optimization: Balance multiple properties simultaneously
Do NOT use this skill for:
- De novo design from scratch (use
denovo-designinstead) - Simple property prediction without optimization (use
admet-prediction) - Docking or binding affinity estimation (use
molecular-docking,binding-affinity)
Related Skills
- admet-prediction: Compute ADMET properties (this skill uses it internally)
- admet-reasoning: Interpretable ADMET analysis with mechanistic explanations
- smiles-validation: Strict SMILES parsing and structural verification
- rdkit: Core molecular operations
- medchem: Medicinal chemistry filters and transformations
Installation
Required dependencies
pip install rdkit-pypi numpy pandas
Optional dependencies
pip install PyTDC datamol
- PyTDC: Access to TDC ADMET predictors for enhanced property scoring
- datamol: Convenient molecular manipulation utilities
Core Workflows
1. Single-Molecule Optimization
Optimize one molecule for improved properties:
python scripts/optimize.py \
--smiles "c1ccc(NC(=O)c2ccccc2Cl)cc1" \
--targets "LogP<3,hERG<0.3,QED>0.5" \
--max-iterations 3 \
--candidates 8 \
--output results.json
2. Batch Optimization
Optimize a CSV of molecules:
python scripts/optimize.py \
--input leads.csv \
--smiles-col SMILES \
--targets "LogP<3,hERG<0.3" \
--output optimized.csv
3. Verification Only
Verify a proposed SMILES matches a claimed modification:
python scripts/verify_smiles.py \
--original "c1ccccc1" \
--proposed "c1ccc(O)cc1" \
--claimed-modification "Added hydroxyl group at para position"
4. Candidate Comparison
Compare multiple candidates against a reference:
python scripts/compare_candidates.py \
--reference "c1ccc(NC(=O)c2ccccc2Cl)cc1" \
--candidates candidates.csv \
--output comparison.html
Script Reference
| Script | Purpose | Key Outputs |
|---|---|---|
optimize.py |
Full iterative optimization loop | results.json with ranked candidates, descriptor deltas, reasoning |
verify_smiles.py |
Validate SMILES and check claimed modifications | Pass/fail report with structural analysis |
compare_candidates.py |
Side-by-side descriptor comparison | Comparison table (CSV/HTML) with liability flags |
Optimization Protocol Detail
Step 1: ANALYZE
Compute molecular descriptors: MW, LogP, TPSA, HBA, HBD, RotBonds, QED, aromatic rings, Murcko scaffold. Flag properties outside ADMET target thresholds.
Step 2: IDENTIFY LIABILITIES
Rank flagged properties by severity (hERG > DILI > CYP > solubility). For each, identify the structural feature causing the liability and propose a specific modification.
Step 3: GENERATE CANDIDATES
Apply proposed modifications via:
- Bioisosteric replacement (e.g., phenyl → pyridine, amide → sulfonamide)
- Functional group addition/removal
- Ring system modification
- Chain length adjustment
Generate 4-8 candidates per iteration.
Step 4: VERIFY
For each candidate:
Chem.MolFromSmiles()— discard if None- Scaffold preservation: Murcko scaffold match
- Tanimoto similarity (ECFP4): flag if < 0.4
- Structural verification: confirm claimed modification exists
Step 5: EVALUATE & RANK
Recompute descriptors, build comparison table, score by net liability improvement (+1 per fix, -0.5 per new liability).
Step 6: ITERATE
If no improvement after 3 iterations, return best found with honest assessment.
ADMET Target Thresholds
| Property | Target | Severity |
|---|---|---|
| hERG inhibition | < 0.3 | Critical |
| DILI | < 0.5 | Critical |
| CYP inhibition | < 0.5 | High |
| LogP | 1.0 – 3.0 | Medium |
| TPSA | 20 – 130 | Medium |
| MW | 150 – 500 | Medium |
| QED | > 0.5 | Low |
| Solubility (LogS) | > -4.0 | Medium |
04 同仓库更多 Skills
statistical-power
Sample size calculation, power analysis, and effect size conversion for scientific studies. Use BEFORE data collection (a priori) to determine required N, or after (post-hoc) to compute achieved power. Covers parametric tests (t-test, ANOVA, chi-square, proportions, correlation, regression), simulation-based power for complex/clustered/nested designs, and power curves. Use this skill when someone asks 'how many samples do I need', 'what is my power', 'what effect size can I detect', or any variant. Pairs with /experimental-design (choose design first, then compute power) and /statistical-analysis (analyze data after collection).
statistical-analysis
Guided statistical analysis with test selection and reporting. Use when you need help choosing appropriate tests for your data, assumption checking, power analysis, and APA-formatted results. Best for academic research reporting, test selection guidance. For implementing specific models programmatically use statsmodels.
scientific-writing
Core skill for the deep research and writing tool. Write scientific manuscripts in full paragraphs (never bullet points). Use two-stage process with (1) section outlines with key points using research-lookup then (2) convert to flowing prose. IMRAD structure, citations (APA/AMA/Vancouver), figures/tables, reporting guidelines (CONSORT/STROBE/PRISMA), for research papers and journal submissions.
scientific-visualization
Meta-skill for publication-ready figures. Use when creating journal submission figures requiring multi-panel layouts, significance annotations, error bars, colorblind-safe palettes, and specific journal formatting (Nature, Science, Cell). Orchestrates matplotlib/seaborn/plotly with publication styles. For quick exploration use seaborn or plotly directly.
research-code
Debug, profile, review, and restructure Python research and analysis code. Use when analysis scripts crash, produce wrong results, run too slowly, or need a correctness review. Covers: reading tracebacks and diagnosing root causes, hypothesis-driven debugging, reviewing code for common statistical/numerical errors, profiling data pipelines, improving reproducibility (seeds, environments, determinism), and structuring analysis scripts for sharing. Distinct from /exploratory-data-analysis (which understands data) and /statistical-analysis (which chooses and runs tests) — this skill focuses on the code itself.
markdown-mermaid-writing
Comprehensive markdown and Mermaid diagram writing skill. Use when creating any scientific document, report, analysis, or visualization. Establishes text-based diagrams as the default documentation standard with full style guides (markdown + mermaid), 24 diagram type references, and 9 document templates.