retrosynthesis
Skill8 starsChanged 5 months agoMITView on GitHub
Performs retrosynthetic planning using AiZynthFinder (MCTS, template-based), Chemformer (template-free transformer), ASKCOS, and emerging RetroSynFormer with explicit handling of route scoring, building-block availability (eMolecules, Enamine, Mcule), forward prediction validation (Molecular Transformer), and disconnection-aware multi-objective search (MO-MCTS). Use when assessing synthetic feasibility of generated or selected molecules, planning multi-step syntheses, building synthesis-aware design pipelines, or screening libraries for retro-route feasibility.
3 other projects use a version of this.
Adopted by
Most recently taken up by
- BuildHarbor/sciagent-skillstheir own version, first seen Nov 1, 2026
- Pratikrishi97/sciagent-skillstheir own version, first seen Aug 29, 2026
- K-Dense-AI/drug-discovery-agent-skillstheir own version, first seen Aug 16, 2026
Other versions3 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 3
- K-Dense-AI/drug-discovery-agent-skills★ 54same name
- BuildHarbor/sciagent-skills★ 1same name
- Pratikrishi97/sciagent-skills★ 1same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository125 other files it gives its agents.
- AGENTS.mdAGENTS.md
- skills/AGENTS.mdAGENTS.md
- batch-processingSkill
- bowtie2-alignmentSkill
- bwa-alignmentSkill
- bwa-mem2-alignmentSkill
- codon-usageSkill
- compressed-sequence-filesSkill
- fastq-quality-scoresSkill
- filter-sequencesSkill
- format-conversionSkill
- hisat2-alignmentSkill
- motif-searchSkill
- paired-end-fastqSkill
- pysam-genomicsSkill
- read-write-sequencesSkill
- reverse-complementSkill
- sam-bam-basicsSkill
- samtools-bam-processingSkill
- seq-objectsSkill
- sequence-propertiesSkill
- sequence-slicingSkill
- sequence-statisticsSkill
- star-alignmentSkill
- transcription-translationSkill
- academic-cvSkill
- faculty-interviewSkill
- fellowship-applicationSkill
- industry-transitionSkill
- negotiationSkill
- tenure-dossierSkill
- admet-predictionSkill
- conformer-generationSkill
- covalent-designSkill
- docking-rescoringSkill
- free-energy-calculationsSkill
- generative-designSkill
- molecular-descriptorsSkill
- molecular-ioSkill
- molecular-standardizationSkill
- pharmacophore-modelingSkill
- pose-validationSkill
- protac-degradersSkill
- qsar-modelingSkill
- scaffold-analysisSkill
- shape-similaritySkill
- similarity-searchingSkill
- substructure-searchSkill
- virtual-screeningSkill
- snakemake-workflow-engineSkill
- ai-disclosureSkill
- data-privacySkill
- image-integritySkill
- irb-protocolSkill
- ai-detection-awarenessSkill
- ai-disclosure-statementSkill
- scientific-voice-styleSkill
- text-humanizing-editorialSkill
- cellprofiler-pipelinesSkill
- image-analysis-best-practicesSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
6 rules. 0 are common, 5 are distinctive, and 1 is very specific to this project.
0
Common
Most of the 3 edited versions we read keep these.
5
Distinctive
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 20
Before using code patterns, verify installed versions match.
- Distinctive: line 24
If code throws ImportError, AttributeError, or TypeError, introspect the installed package and adapt the example to match the actual API …
- Distinctive: line 30
No fabricated citations: Every cited work must resolve to a verifiable
- Distinctive: line 31
No claim without provenance: Every quantitative or factual claim
- Distinctive: line 32
No silent failure: Every script invocation, API call, or tool use must declare its exit status and what to do on non-zero.
- Very specific: line 43
Do not load this skill if the question is in a sibling skill's domain (see ## Cross-references), if the user explicitly asks for a …
“Common” is measured: kept by at least 6 in 10 of the 3 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
<!-- metadata:
category: chemoinformatics
oversight: low
version: 1.0.0
author: Pradyumna Jayaram
tags: [chemoinformatics, research]
difficulty: intermediate
-->Version Compatibility
Reference examples tested with: AiZynthFinder 4.4+, Chemformer 1.3+, RDKit 2024.09+, RDChiral 1.1+, Aizynthtrain 1.0+, ASKCOS Lite 0.5+.
Before using code patterns, verify installed versions match. If versions differ:
- Python:
pip show <package>thenhelp(module.function)to check signatures - CLI:
aizynthcli --version
If code throws ImportError, AttributeError, or TypeError, introspect the installed package and adapt the example to match the actual API rather than retrying.
Retrosynthesis
Hard rules
- No fabricated citations. Every cited work must resolve to a verifiable
- No claim without provenance. Every quantitative or factual claim
- No silent failure. Every script invocation, API call, or tool use must declare its exit status and what to do on non-zero. A skill that silently swallows errors is a violation.
When to use
Load this skill when the user asks a question that matches its declared
trigger conditions (see the frontmatter description for the most common
ones). Do not load it for questions outside its scope — defer to the
appropriate ORS skill instead.
When NOT to use
Do not load this skill if the question is in a sibling skill's domain
(see ## Cross-references), if the user explicitly asks for a different
tool, or if the task is outside the skill's declared category.
Method Taxonomy
| Tool | Approach | Strength | Fails when |
| AiZynthFinder 4.0 | Template-based MCTS | Open, scalable, well-validated | Beyond template coverage |
| Chemformer | Template-free transformer | Novel disconnections | Less interpretable |
| ASKCOS | Template-based + neural | MIT-quality academic standard | Setup complexity |
| Molecular Transformer | Forward + retro transformer | Single SMILES-to-SMILES | Less robust OOD |
| IBM RXN | Cloud service | High quality | API access required |
Decision: For most users, AiZynthFinder 4.4 with USPTO + USPTO-50k templates is the open-source standard. For high-stakes routes, validate with Molecular Transformer forward prediction.
AiZynthFinder Setup
Goal: Configure AiZynthFinder with USPTO templates and a building-block stock; run MCTS retrosynthesis on a target SMILES.
Approach: Build a configuration dict pointing to policy templates and a stock HDF5, instantiate AiZynthFinder, set the target SMILES, then call tree_search() followed by build_routes().
from aizynthfinder.aizynthfinder import AiZynthFinder
config_dict = {
'policy': {
'files': {
'uspto': ['policy/uspto_model.onnx', 'templates/uspto_templates.csv'],
}
},
'stock': {
'files': {
'zinc': 'stock/zinc.h5',
}
},
'finder': {
'algorithm': 'mcts',
'iteration_limit': 100,
'time_limit': 120,
}
}
finder = AiZynthFinder(configdict=config_dict)
finder.target_smiles = 'CC(=O)Nc1ccc(C(=O)Nc2cccc(C(F)(F)F)c2)cc1'
finder.tree_search()
finder.build_routes()Route Output Analysis
for route in finder.routes:
print(f'Depth: {route.depth}, Score: {route.score:.2f}')
print(f'In-stock: {sum(node.in_stock for node in route.leafs())}')
print(f'Building blocks: {[node.smiles for node in route.leafs()]}')Critical metrics:
- Depth: synthetic steps (1-3 typical for medchem)
- Score: AiZynthFinder route score (0-1)
- In-stock: how many leaf nodes are commercially available
Route Scoring (MO-MCTS)
AiZynthFinder 4.0 supports multi-objective scoring:
config_dict['finder']['algorithm'] = 'mo_mcts'
config_dict['finder']['mo_mcts'] = {
'objectives': [
{'name': 'state_score', 'weight': 0.5},
{'name': 'broken_bonds_score', 'weight': 0.3},
{'name': 'route_length', 'weight': 0.2, 'maximize': False},
]
}Building Block Stocks
| Stock | Compounds | Source | Cost-tier |
| ZINC clean leads | 250k | ZINC22 | Various |
| Enamine Building Blocks | 200k+ | Enamine | $$ |
| Enamine REAL | 29B (make-on-demand) | Enamine | $$$ |
| Mcule | 25M | Mcule | $$ |
| eMolecules | 16M | eMolecules | $$ |
| ChemBridge | 1M | ChemBridge | $$ |
aizynthtrain build-stock --input zinc_building_blocks.smi --output zinc.h5Forward Validation with Molecular Transformer
from molecular_transformer import predict_forward
precursors = route.leafs()
predicted_product = predict_forward(precursors)
match = (Chem.CanonSmiles(predicted_product) ==
Chem.CanonSmiles(finder.target_smiles))Routes where the forward prediction reproduces the target are highest confidence. ~30-50% of AiZynthFinder routes pass forward validation.
Template-Free with Chemformer
from chemformer import Chemformer
cf = Chemformer.load_pretrained('USPTO_RETROSYNTHESIS_TEMPLATE_FREE')
predictions = cf.predict('CC(=O)Nc1ccc(C(=O)Nc2cccc(C(F)(F)F)c2)cc1',
beam_search=10)Trade-off: Template-free is more flexible but harder to debug. Combining with AiZynthFinder template MCTS gives best of both.
Disconnection-Aware Design (DAD)
aizynthcli --smiles compounds.smi --output routes.json \
--config config.yaml --policy uspto --stock zincFor each compound, returns top-K routes. Score-feasibility for generative design:"
- "Synthesizable" = in-stock leaves >= 2 in best route
- "Routable" = at least one route depth <= 5
- "Easy" = at least one route depth <= 3 with all leaves in-stock
References
- Saigiridharan et al., J. Cheminform. 16:57 -- AiZynthFinder 4.0.
- Irwin et al., 2022 -- Chemformer.
- Schwaller et al. -- Molecular Transformer.
Related Skills
- chemoinformatics/generative-design - Generative design with feasibility scoring
- chemoinformatics/reaction-enumeration - Forward direction
- chemoinformatics/scaffold-analysis - R-group decomposition
Cross-references
Other skills in this category:
- admet-prediction
- conformer-generation
- covalent-design
- docking-rescoring
- free-energy-calculations
- generative-design
- molecular-descriptors
- molecular-io
- molecular-standardization
- pharmacophore-modeling
- pose-validation
- protac-degraders
- qsar-modeling
- scaffold-analysis
- shape-similarity
- similarity-searching
- substructure-search
- virtual-screening
Changelog
- 1.1.0 (migration) — Bulk-migrated to v0.4.0 schema: canonical metadata block, base Hard rules, Cross-references. Body content unchanged; author should review and fill in any domain-specific extensions to the Hard rules.
- 1.0.0 — Initial release.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

