[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M75KEGPC6067Q07BMA79SA9A":3,"skill-same:01M75KEGPC6067Q07BMA79SA9A":46},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":24,"commitSha":25,"skillDirectory":26,"forksCount":27,"repositoryHtmlUrl":28,"repositoryHomepageUrl":6,"ownerHtmlUrl":29,"ownerBlogUrl":6,"ownerDescription":30,"updatedAt":31,"install":32,"resources":45},"01M75KEGPC6067Q07BMA79SA9A","shape-similarity",null,"Performs 3D shape-based similarity searching using ROCS (OpenEye), USRCAT (ultra-fast), Open3DAlign (RDKit), ESPSim (electrostatic), and ShaEP with explicit handling of Tanimoto-Combo (shape + color), shape vs ECFP4 complementarity, conformer-ensemble searching, alignment optimization, and scaffold hopping. Use when searching for shape-mimicking compounds with different scaffolds, identifying bioisosteric replacements, prospective scaffold hopping, or expanding hit series beyond 2D similarity.","pradyumnasagar\u002Fopen-research-skills","pradyumnasagar","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F10559871?v=4","01M75K78MYCCVKRTYGT8KKC380","Pradyumna Jayaram","01M75K78NTNE41F2PE1XBVFHAS",8,"MIT","https:\u002F\u002Fgithub.com\u002Fpradyumnasagar\u002Fopen-research-skills\u002Fblob\u002Fmain\u002Fskills\u002Fchemoinformatics\u002Fshape-similarity\u002FSKILL.md",[],[],"2026-11-12 13:55:43",false,"---\n\nname: shape-similarity\ndescription: \"Performs 3D shape-based similarity searching using ROCS (OpenEye), USRCAT (ultra-fast), Open3DAlign (RDKit), ESPSim (electrostatic), and ShaEP with explicit handling of Tanimoto-Combo (shape + color), shape vs ECFP4 complementarity, conformer-ensemble searching, alignment optimization, and scaffold hopping. Use when searching for shape-mimicking compounds with different scaffolds, identifying bioisosteric replacements, prospective scaffold hopping, or expanding hit series beyond 2D similarity.\"\nlicense: MIT\n---\n\u003C!-- metadata:\n  category: chemoinformatics\n  oversight: low\n  version: 1.0.0\n  author: Pradyumna Jayaram\n  tags: [chemoinformatics, research]\n  difficulty: intermediate\n-->\n\n## Version Compatibility\n\nReference examples tested with: RDKit 2024.09+ (Open3DAlign), USRCAT 1.2+, ShaEP 1.7+, ROCS (OpenEye, commercial).\n\nBefore using code patterns, verify installed versions match. If versions differ:\n- Python: `pip show \u003Cpackage>` then `help(module.function)` to check signatures\n\nIf code throws ImportError, AttributeError, or TypeError, introspect the installed package and adapt the example to match the actual API rather than retrying.\n\n# Shape Similarity\n\n## Hard rules\n\n1. **No fabricated citations.** Every cited work must resolve to a verifiable\n2. **No claim without provenance.** Every quantitative or factual claim\n3. **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.\n\n## When to use\n\nLoad this skill when the user asks a question that matches its declared\ntrigger conditions (see the frontmatter `description` for the most common\nones). Do not load it for questions outside its scope — defer to the\nappropriate ORS skill instead.\n\n## When NOT to use\n\nDo not load this skill if the question is in a sibling skill's domain\n(see `## Cross-references`), if the user explicitly asks for a different\ntool, or if the task is outside the skill's declared category.\n\n## Shape Method Taxonomy\n\n| Tool | Speed | Approach | Open-source | Fails when |\n|------|-------|----------|-------------|------------|\n| ROCS (OpenEye) | 1k mols\u002Fsec on GPU (FastROCS) | Gaussian shape + color | No | License cost |\n| ROCS X (Sept 2025) | Multi-billion library, GPU | ML-enhanced shape | No | Limited release |\n| USRCAT | 100k mols\u002Fsec | Ultrafast moment-based + atom types | Yes | Coarse approximation |\n| Open3DAlign (RDKit) | 100 mols\u002Fsec | Iterative volume overlap | Yes | Optimization slow |\n| ShaEP | 10 mols\u002Fsec | Field-based (shape + ESP) | Yes | Less standard |\n| ESPSim | similar to ShaEP | Electrostatic + shape | Yes | Limited public benchmarks |\n| Phase-Shape (Schrödinger) | commercial | Shape + pharmacophore | No | Commercial |\n| USR (original) | 100k mols\u002Fsec | Moment-based only | Yes | No atom type info |\n\n**Decision:** For commercial pipelines, **ROCS** is the gold standard. For open-source, **Open3DAlign** is the most accurate; **USRCAT** is the fastest for ultralarge libraries.\n\n## Decision Tree by Scenario\n\n| Scenario | Method | Notes |\n|----------|--------|-------|\n| Lead-like library, search top 100k | USRCAT pre-filter + Open3DAlign rescore | Hybrid speed\u002Faccuracy |\n| Production VS for scaffold hop | ROCS + color (commercial) | Industry standard |\n| Scaffold hopping prospective | Open3DAlign with conformer ensemble | Shape + flexibility |\n| Bioisostere replacement | ROCS color with neutral scoring | Pharmacophore-equivalent matches |\n| Patent space carve-out | Shape constraint + 2D dissimilarity | Combine shape + dissimilar scaffold |\n| Library diversity assessment | USRCAT k-nearest neighbor | Fast |\n| Crystal-bound conformer template | Open3DAlign starting from co-crystal pose | Bioactive shape |\n| Cross-target screening | Shape + pharmacophore feature | Combined screen |\n\n## Tanimoto-Combo Scoring (ROCS Standard)\n\nTanimoto-Combo = (Tanimoto_shape + Tanimoto_color) \u002F 2\n\n- Tanimoto_shape: volume overlap normalized\n- Tanimoto_color: pharmacophore feature overlap\n\n| Range | Interpretation |\n|-------|----------------|\n| > 1.0 | Very similar shape + color (rare; top hits) |\n| 0.7-1.0 | Strong hit; likely binding mode similarity |\n| 0.5-0.7 | Moderate; further validation needed |\n| 0.3-0.5 | Weak; many false positives |\n| \u003C 0.3 | Background |\n\nIn ROCS production, hits with TanimotoCombo > 0.7 are typically followed up.\n\n## USRCAT (Ultra-Fast Shape Recognition + Atom Types)\n\nUSRCAT extends Ultrafast Shape Recognition (USR) with atom-type information. Each molecule is represented as a 60-dimensional moment vector (12 moments × 5 atom types).\n\n**Goal:** Encode a molecule into the 60-D USRCAT moment vector and score similarity against another molecule for alignment-free shape search.\n\n**Approach:** Parse the SMILES, add hydrogens, generate one 3D conformer with ETKDGv3, compute USRCAT descriptors, and apply the inverse-mean-absolute-difference similarity to a second descriptor vector.\n\n```python\nfrom usrcat import compute_usrcat_descriptors, compute_similarity\n\nmol = Chem.MolFromSmiles('CCO')\nmol = Chem.AddHs(mol)\nAllChem.EmbedMolecule(mol, AllChem.ETKDGv3())\n\ndescriptors = compute_usrcat_descriptors(mol)\n# Returns numpy array of 60 floats: 12 USR moments x 5 atom types\n# (hydrophobic, aromatic, acceptor, donor, anion\u002Fcation)\n# Similarity between two descriptor vectors: 1 \u002F (1 + mean_abs_difference)\n\nsimilarity = compute_similarity(desc1, desc2)  # 0-1, higher = more similar\n```\n\n**Speed:** O(N) descriptor calculation (no alignment); O(1) similarity comparison. Suitable for >10M compound libraries.\n\n**Limit:** USRCAT is a coarse approximation. Predictive for analog identification; less precise for scaffold hopping.\n\n## Open3DAlign (RDKit)\n\nOpen3DAlign performs iterative alignment to maximize volume overlap:\n\n**Goal:** Align a target molecule onto a query in 3D and score volume overlap with Open3DAlign.\n\n**Approach:** Build 3D structures for query and target (parse SMILES, add hydrogens, ETKDG embed), run `GetO3A` to find the best alignment, then call `Align()` for the in-place RMSD and `Score()` for the overlap score.\n\n```python\nfrom rdkit.Chem import rdMolAlign\n\nquery = Chem.MolFromSmiles('CCC(=O)Nc1ccccc1')\nquery = Chem.AddHs(query)\nAllChem.EmbedMolecule(query, AllChem.ETKDGv3())\n\ntarget = Chem.MolFromSmiles('CCC(=O)Nc1ccc(F)cc1')\ntarget = Chem.AddHs(target)\nAllChem.EmbedMolecule(target, AllChem.ETKDGv3())\n\nO3A = rdMolAlign.GetO3A(target, query)\nrmsd = O3A.Align()  # aligns target to query in place\nscore = O3A.Score()\n```\n\n`GetO3A` finds best alignment between conformers; `Align()` aligns and returns RMSD; `Score()` returns Open3DAlign score (similar to TanimotoCombo).\n\n**Open3DAlign vs ROCS:** Open3DAlign is open-source and competitive on small benchmarks; slower than ROCS at scale.\n\n## Conformer-Ensemble Shape Searching\n\nFor each library molecule, generate ensemble of conformers; pick best-shape conformer:\n\n**Goal:** Run shape-similarity search over a conformer ensemble per library molecule so bound-conformer-like shapes are recovered.\n\n**Approach:** For each library molecule, add hydrogens, embed n_conf conformers with ETKDGv3, MMFF-optimize, score each conformer against the query with Open3DAlign, and keep the best score per molecule.\n\n```python\ndef shape_search_ensemble(query_mol, library_mols, n_conf=20):\n    hits = []\n    for target in library_mols:\n        target = Chem.AddHs(target)\n        AllChem.EmbedMultipleConfs(target, numConfs=n_conf,\n                                    params=AllChem.ETKDGv3())\n        AllChem.MMFFOptimizeMoleculeConfs(target)\n\n        scores = []\n        for c in range(target.GetNumConformers()):\n            O3A = rdMolAlign.GetO3A(target, query_mol, prbCid=c)\n            scores.append(O3A.Score())\n        hits.append((target, max(scores)))\n    return sorted(hits, key=lambda x: x[1], reverse=True)\n```\n\n**Critical:** Single-conformer shape search misses ~30% of true hits because the wrong conformer is sampled. Always use ensemble.\n\n## ESP Similarity (Electrostatic)\n\nShaEP and ESPSim extend shape with electrostatic surface potential overlap. For ESP-relevant pharmacophores (binding pockets with strong electrostatics):\n\n```bash\nshaep --query query.mol2 --target target.mol2 --output match.sdf \\\n      --esp-weight 0.5\n```\n\nESP scoring catches electrostatic-equivalent bioisosteres that pure shape misses (carboxylate vs tetrazole same charge).\n\n## Shape vs ECFP4 Complementarity\n\n| Shape Tanimoto | ECFP4 Tanimoto | Interpretation |\n|----------------|----------------|----------------|\n| > 0.7 | > 0.7 | Same chemotype, same shape (close analog) |\n| > 0.7 | \u003C 0.5 | Scaffold-hop! Different chemotype, similar shape |\n| \u003C 0.5 | > 0.7 | Same chemotype, different shape (flexible) |\n| \u003C 0.5 | \u003C 0.5 | Unrelated |\n\nThe shape >> ECFP4 quadrant is the scaffold-hopping gold:\n\n**Goal:** Identify scaffold-hop candidates that are 3D-shape-similar but 2D-chemotype-dissimilar to the query.\n\n**Approach:** Run the conformer-ensemble shape search, keep hits above a shape Tanimoto cutoff, then retain only those whose ECFP4 Tanimoto to the query is below an ECFP4 dissimilarity cutoff.\n\n```python\ndef scaffold_hop_candidates(query_mol, library, shape_threshold=0.7,\n                            ecfp_threshold=0.5):\n    shape_hits = shape_search_ensemble(query_mol, library)\n    candidates = []\n    for target, shape_score in shape_hits:\n        if shape_score >= shape_threshold:\n            ecfp_sim = ecfp_tanimoto(query_mol, target)\n            if ecfp_sim \u003C ecfp_threshold:\n                candidates.append((target, shape_score, ecfp_sim))\n    return candidates\n```\n\n## Per-Tool Failure Modes\n\n### USRCAT -- false positive on small molecules\n\n**Trigger:** Library has many fragment-sized compounds.\n\"\n**Mechanism:** USRCAT moments dominated by overall shape; small molecules look \"similar\" if shape resemble.\n\n**Symptom:** Many fragment hits; not pharmacophore-relevant.\n\n**Fix:** Filter by MW (>= 200); use Open3DAlign for rescoring.\n\n### Open3DAlign -- slow on large library\n\n**Trigger:** Million-compound library, full alignment.\n\n**Mechanism:** Open3DAlign is iterative; O(N) per molecule.\n\n**Symptom:** Hours of compute.\n\n**Fix:** Pre-filter with USRCAT (fast), Open3DAlign on top 10k.\n\n### Shape only -- wrong stereochemistry match\n\n**Trigger:** Mirror-image of correct binder.\n\n**Mechanism:** Pure shape Tanimoto symmetric under chirality inversion.\n\n**Symptom:** Enantiomer of inactive scores as hit.\n\n**Fix:** Validate hits by 3D pose; check stereochemistry.\n\n### ROCS color -- bioisostere missed\n\n**Trigger:** -COOH replaced by -SO3H or tetrazole.\n\n**Mechanism:** Default color types may not equate these bioisosteres.\n\n**Symptom:** Known bioisostere doesn't score high.\n\n**Fix:** Use color-only scoring without size penalty; or pharmacophore-feature-equivalence.\n\n### Conformer not bioactive\n\n**Trigger:** Library compound generated conformer is not the bound conformation.\n\n**Mechanism:** ETKDGv3 generates plausible conformers; bound conformer may be higher energy.\n\n**Symptom:** Known active doesn't shape-match query.\n\n**Fix:** Use larger conformer ensemble; weight by Boltzmann; or use CREST + GFN2-xTB for high-quality sampling.\n\n### Field-based methods slower\n\n**Trigger:** ShaEP or ESPSim on production library.\n\n**Mechanism:** Field-based methods compute Gaussian fields per molecule.\n\n**Symptom:** 10-100x slower than ROCS shape-only.\n\n**Fix:** Use as second-stage rescore; not primary screen.\n\n## Reconciliation: Shape vs Pharmacophore\n\n| Aspect | Shape | Pharmacophore |\n|--------|-------|----------------|\n| Representation | Volume distribution | Discrete features in space |\n| Captures | Overall bulk | Interaction-relevant features |\n| Speed | Fast (USRCAT) to medium (Open3DAlign) | Fast |\n| Specificity | Lower | Higher |\n| False positive rate | Medium | Lower |\n| Best for | Scaffold hopping initial | Scaffold hopping refinement |\n\nUse shape for *broad search* (high recall, moderate precision); use pharmacophore for *refinement* (lower recall, high precision).\n\n## Common Errors\n\n| Symptom | Cause | Fix |\n|---------|-------|-----|\n| Open3DAlign returns 0 | No reasonable alignment found | Use random starting rotation; increase attempts |\n| USRCAT vector all zeros | Mol has no 3D coords | Generate conformer first |\n| Shape Tanimoto > 1 | Implementation bug or unnormalized | Check formula; ROCS reports unnormalized possible |\n| ROCS very slow | Sequential processing | Use parallel batching |\n| Shape match but no docking pose | Wrong binding pose | Use docking on top shape hits, not shape alone |\n| Missing co-crystal template | Apo or AlphaFold-only structure | Use ligand-based pharmacophore + shape |\n| ShaEP returns no hits | Strict tolerance | Loosen overlap thresholds |\n\n## References\n\n- Hawkins et al., *J. Med. Chem.* 50:74 -- ROCS algorithm.\n- Schreyer & Blundell, *J. Cheminformatics* 4:27 -- USRCAT.\n- Vainio & Johnson, *J. Chem. Inf. Model.* 47:2462 -- ShaEP.\n- Liu et al., *J. Chem. Inf. Model.* (2024) -- Open3DAlign improvements.\n- Roy et al., *J. Med. Chem.* 65:11875 -- shape-based VS modern review.\n\n## Related Skills\n\n- chemoinformatics\u002Fmolecular-io - Parse query and library\n- chemoinformatics\u002Fconformer-generation - Generate 3D conformer ensembles\n- chemoinformatics\u002Fsimilarity-searching - 2D similarity comparison\n- chemoinformatics\u002Fpharmacophore-modeling - Pharmacophore alternative\n- chemoinformatics\u002Fscaffold-analysis - 2D scaffold analysis\n- chemoinformatics\u002Fvirtual-screening - Shape as pre-filter to docking\n\n## Cross-references\n\nOther skills in this category:\n\n- admet-prediction\n- conformer-generation\n- covalent-design\n- docking-rescoring\n- free-energy-calculations\n- generative-design\n- molecular-descriptors\n- molecular-io\n- molecular-standardization\n- pharmacophore-modeling\n- pose-validation\n- protac-degraders\n- qsar-modeling\n- retrosynthesis\n- scaffold-analysis\n- similarity-searching\n- substructure-search\n- virtual-screening\n\n## Changelog\n\n- **1.1.0** (migration) — Bulk-migrated to v0.4.0 schema: canonical\n  metadata block, base Hard rules, Cross-references. Body content\n  unchanged; author should review and fill in any domain-specific\n  extensions to the Hard rules.\n- **1.0.0** — Initial release.\n\n","\u003C!-- metadata:\n  category: chemoinformatics\n  oversight: low\n  version: 1.0.0\n  author: Pradyumna Jayaram\n  tags: [chemoinformatics, research]\n  difficulty: intermediate\n-->\n\n## Version Compatibility\n\nReference examples tested with: RDKit 2024.09+ (Open3DAlign), USRCAT 1.2+, ShaEP 1.7+, ROCS (OpenEye, commercial).\n\nBefore using code patterns, verify installed versions match. If versions differ:\n- Python: `pip show \u003Cpackage>` then `help(module.function)` to check signatures\n\nIf code throws ImportError, AttributeError, or TypeError, introspect the installed package and adapt the example to match the actual API rather than retrying.\n\n# Shape Similarity\n\n## Hard rules\n\n1. **No fabricated citations.** Every cited work must resolve to a verifiable\n2. **No claim without provenance.** Every quantitative or factual claim\n3. **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.\n\n## When to use\n\nLoad this skill when the user asks a question that matches its declared\ntrigger conditions (see the frontmatter `description` for the most common\nones). Do not load it for questions outside its scope — defer to the\nappropriate ORS skill instead.\n\n## When NOT to use\n\nDo not load this skill if the question is in a sibling skill's domain\n(see `## Cross-references`), if the user explicitly asks for a different\ntool, or if the task is outside the skill's declared category.\n\n## Shape Method Taxonomy\n\n| Tool | Speed | Approach | Open-source | Fails when |\n|------|-------|----------|-------------|------------|\n| ROCS (OpenEye) | 1k mols\u002Fsec on GPU (FastROCS) | Gaussian shape + color | No | License cost |\n| ROCS X (Sept 2025) | Multi-billion library, GPU | ML-enhanced shape | No | Limited release |\n| USRCAT | 100k mols\u002Fsec | Ultrafast moment-based + atom types | Yes | Coarse approximation |\n| Open3DAlign (RDKit) | 100 mols\u002Fsec | Iterative volume overlap | Yes | Optimization slow |\n| ShaEP | 10 mols\u002Fsec | Field-based (shape + ESP) | Yes | Less standard |\n| ESPSim | similar to ShaEP | Electrostatic + shape | Yes | Limited public benchmarks |\n| Phase-Shape (Schrödinger) | commercial | Shape + pharmacophore | No | Commercial |\n| USR (original) | 100k mols\u002Fsec | Moment-based only | Yes | No atom type info |\n\n**Decision:** For commercial pipelines, **ROCS** is the gold standard. For open-source, **Open3DAlign** is the most accurate; **USRCAT** is the fastest for ultralarge libraries.\n\n## Decision Tree by Scenario\n\n| Scenario | Method | Notes |\n|----------|--------|-------|\n| Lead-like library, search top 100k | USRCAT pre-filter + Open3DAlign rescore | Hybrid speed\u002Faccuracy |\n| Production VS for scaffold hop | ROCS + color (commercial) | Industry standard |\n| Scaffold hopping prospective | Open3DAlign with conformer ensemble | Shape + flexibility |\n| Bioisostere replacement | ROCS color with neutral scoring | Pharmacophore-equivalent matches |\n| Patent space carve-out | Shape constraint + 2D dissimilarity | Combine shape + dissimilar scaffold |\n| Library diversity assessment | USRCAT k-nearest neighbor | Fast |\n| Crystal-bound conformer template | Open3DAlign starting from co-crystal pose | Bioactive shape |\n| Cross-target screening | Shape + pharmacophore feature | Combined screen |\n\n## Tanimoto-Combo Scoring (ROCS Standard)\n\nTanimoto-Combo = (Tanimoto_shape + Tanimoto_color) \u002F 2\n\n- Tanimoto_shape: volume overlap normalized\n- Tanimoto_color: pharmacophore feature overlap\n\n| Range | Interpretation |\n|-------|----------------|\n| > 1.0 | Very similar shape + color (rare; top hits) |\n| 0.7-1.0 | Strong hit; likely binding mode similarity |\n| 0.5-0.7 | Moderate; further validation needed |\n| 0.3-0.5 | Weak; many false positives |\n| \u003C 0.3 | Background |\n\nIn ROCS production, hits with TanimotoCombo > 0.7 are typically followed up.\n\n## USRCAT (Ultra-Fast Shape Recognition + Atom Types)\n\nUSRCAT extends Ultrafast Shape Recognition (USR) with atom-type information. Each molecule is represented as a 60-dimensional moment vector (12 moments × 5 atom types).\n\n**Goal:** Encode a molecule into the 60-D USRCAT moment vector and score similarity against another molecule for alignment-free shape search.\n\n**Approach:** Parse the SMILES, add hydrogens, generate one 3D conformer with ETKDGv3, compute USRCAT descriptors, and apply the inverse-mean-absolute-difference similarity to a second descriptor vector.\n\n```python\nfrom usrcat import compute_usrcat_descriptors, compute_similarity\n\nmol = Chem.MolFromSmiles('CCO')\nmol = Chem.AddHs(mol)\nAllChem.EmbedMolecule(mol, AllChem.ETKDGv3())\n\ndescriptors = compute_usrcat_descriptors(mol)\n# Returns numpy array of 60 floats: 12 USR moments x 5 atom types\n# (hydrophobic, aromatic, acceptor, donor, anion\u002Fcation)\n# Similarity between two descriptor vectors: 1 \u002F (1 + mean_abs_difference)\n\nsimilarity = compute_similarity(desc1, desc2)  # 0-1, higher = more similar\n```\n\n**Speed:** O(N) descriptor calculation (no alignment); O(1) similarity comparison. Suitable for >10M compound libraries.\n\n**Limit:** USRCAT is a coarse approximation. Predictive for analog identification; less precise for scaffold hopping.\n\n## Open3DAlign (RDKit)\n\nOpen3DAlign performs iterative alignment to maximize volume overlap:\n\n**Goal:** Align a target molecule onto a query in 3D and score volume overlap with Open3DAlign.\n\n**Approach:** Build 3D structures for query and target (parse SMILES, add hydrogens, ETKDG embed), run `GetO3A` to find the best alignment, then call `Align()` for the in-place RMSD and `Score()` for the overlap score.\n\n```python\nfrom rdkit.Chem import rdMolAlign\n\nquery = Chem.MolFromSmiles('CCC(=O)Nc1ccccc1')\nquery = Chem.AddHs(query)\nAllChem.EmbedMolecule(query, AllChem.ETKDGv3())\n\ntarget = Chem.MolFromSmiles('CCC(=O)Nc1ccc(F)cc1')\ntarget = Chem.AddHs(target)\nAllChem.EmbedMolecule(target, AllChem.ETKDGv3())\n\nO3A = rdMolAlign.GetO3A(target, query)\nrmsd = O3A.Align()  # aligns target to query in place\nscore = O3A.Score()\n```\n\n`GetO3A` finds best alignment between conformers; `Align()` aligns and returns RMSD; `Score()` returns Open3DAlign score (similar to TanimotoCombo).\n\n**Open3DAlign vs ROCS:** Open3DAlign is open-source and competitive on small benchmarks; slower than ROCS at scale.\n\n## Conformer-Ensemble Shape Searching\n\nFor each library molecule, generate ensemble of conformers; pick best-shape conformer:\n\n**Goal:** Run shape-similarity search over a conformer ensemble per library molecule so bound-conformer-like shapes are recovered.\n\n**Approach:** For each library molecule, add hydrogens, embed n_conf conformers with ETKDGv3, MMFF-optimize, score each conformer against the query with Open3DAlign, and keep the best score per molecule.\n\n```python\ndef shape_search_ensemble(query_mol, library_mols, n_conf=20):\n    hits = []\n    for target in library_mols:\n        target = Chem.AddHs(target)\n        AllChem.EmbedMultipleConfs(target, numConfs=n_conf,\n                                    params=AllChem.ETKDGv3())\n        AllChem.MMFFOptimizeMoleculeConfs(target)\n\n        scores = []\n        for c in range(target.GetNumConformers()):\n            O3A = rdMolAlign.GetO3A(target, query_mol, prbCid=c)\n            scores.append(O3A.Score())\n        hits.append((target, max(scores)))\n    return sorted(hits, key=lambda x: x[1], reverse=True)\n```\n\n**Critical:** Single-conformer shape search misses ~30% of true hits because the wrong conformer is sampled. Always use ensemble.\n\n## ESP Similarity (Electrostatic)\n\nShaEP and ESPSim extend shape with electrostatic surface potential overlap. For ESP-relevant pharmacophores (binding pockets with strong electrostatics):\n\n```bash\nshaep --query query.mol2 --target target.mol2 --output match.sdf \\\n      --esp-weight 0.5\n```\n\nESP scoring catches electrostatic-equivalent bioisosteres that pure shape misses (carboxylate vs tetrazole same charge).\n\n## Shape vs ECFP4 Complementarity\n\n| Shape Tanimoto | ECFP4 Tanimoto | Interpretation |\n|----------------|----------------|----------------|\n| > 0.7 | > 0.7 | Same chemotype, same shape (close analog) |\n| > 0.7 | \u003C 0.5 | Scaffold-hop! Different chemotype, similar shape |\n| \u003C 0.5 | > 0.7 | Same chemotype, different shape (flexible) |\n| \u003C 0.5 | \u003C 0.5 | Unrelated |\n\nThe shape >> ECFP4 quadrant is the scaffold-hopping gold:\n\n**Goal:** Identify scaffold-hop candidates that are 3D-shape-similar but 2D-chemotype-dissimilar to the query.\n\n**Approach:** Run the conformer-ensemble shape search, keep hits above a shape Tanimoto cutoff, then retain only those whose ECFP4 Tanimoto to the query is below an ECFP4 dissimilarity cutoff.\n\n```python\ndef scaffold_hop_candidates(query_mol, library, shape_threshold=0.7,\n                            ecfp_threshold=0.5):\n    shape_hits = shape_search_ensemble(query_mol, library)\n    candidates = []\n    for target, shape_score in shape_hits:\n        if shape_score >= shape_threshold:\n            ecfp_sim = ecfp_tanimoto(query_mol, target)\n            if ecfp_sim \u003C ecfp_threshold:\n                candidates.append((target, shape_score, ecfp_sim))\n    return candidates\n```\n\n## Per-Tool Failure Modes\n\n### USRCAT -- false positive on small molecules\n\n**Trigger:** Library has many fragment-sized compounds.\n\"\n**Mechanism:** USRCAT moments dominated by overall shape; small molecules look \"similar\" if shape resemble.\n\n**Symptom:** Many fragment hits; not pharmacophore-relevant.\n\n**Fix:** Filter by MW (>= 200); use Open3DAlign for rescoring.\n\n### Open3DAlign -- slow on large library\n\n**Trigger:** Million-compound library, full alignment.\n\n**Mechanism:** Open3DAlign is iterative; O(N) per molecule.\n\n**Symptom:** Hours of compute.\n\n**Fix:** Pre-filter with USRCAT (fast), Open3DAlign on top 10k.\n\n### Shape only -- wrong stereochemistry match\n\n**Trigger:** Mirror-image of correct binder.\n\n**Mechanism:** Pure shape Tanimoto symmetric under chirality inversion.\n\n**Symptom:** Enantiomer of inactive scores as hit.\n\n**Fix:** Validate hits by 3D pose; check stereochemistry.\n\n### ROCS color -- bioisostere missed\n\n**Trigger:** -COOH replaced by -SO3H or tetrazole.\n\n**Mechanism:** Default color types may not equate these bioisosteres.\n\n**Symptom:** Known bioisostere doesn't score high.\n\n**Fix:** Use color-only scoring without size penalty; or pharmacophore-feature-equivalence.\n\n### Conformer not bioactive\n\n**Trigger:** Library compound generated conformer is not the bound conformation.\n\n**Mechanism:** ETKDGv3 generates plausible conformers; bound conformer may be higher energy.\n\n**Symptom:** Known active doesn't shape-match query.\n\n**Fix:** Use larger conformer ensemble; weight by Boltzmann; or use CREST + GFN2-xTB for high-quality sampling.\n\n### Field-based methods slower\n\n**Trigger:** ShaEP or ESPSim on production library.\n\n**Mechanism:** Field-based methods compute Gaussian fields per molecule.\n\n**Symptom:** 10-100x slower than ROCS shape-only.\n\n**Fix:** Use as second-stage rescore; not primary screen.\n\n## Reconciliation: Shape vs Pharmacophore\n\n| Aspect | Shape | Pharmacophore |\n|--------|-------|----------------|\n| Representation | Volume distribution | Discrete features in space |\n| Captures | Overall bulk | Interaction-relevant features |\n| Speed | Fast (USRCAT) to medium (Open3DAlign) | Fast |\n| Specificity | Lower | Higher |\n| False positive rate | Medium | Lower |\n| Best for | Scaffold hopping initial | Scaffold hopping refinement |\n\nUse shape for *broad search* (high recall, moderate precision); use pharmacophore for *refinement* (lower recall, high precision).\n\n## Common Errors\n\n| Symptom | Cause | Fix |\n|---------|-------|-----|\n| Open3DAlign returns 0 | No reasonable alignment found | Use random starting rotation; increase attempts |\n| USRCAT vector all zeros | Mol has no 3D coords | Generate conformer first |\n| Shape Tanimoto > 1 | Implementation bug or unnormalized | Check formula; ROCS reports unnormalized possible |\n| ROCS very slow | Sequential processing | Use parallel batching |\n| Shape match but no docking pose | Wrong binding pose | Use docking on top shape hits, not shape alone |\n| Missing co-crystal template | Apo or AlphaFold-only structure | Use ligand-based pharmacophore + shape |\n| ShaEP returns no hits | Strict tolerance | Loosen overlap thresholds |\n\n## References\n\n- Hawkins et al., *J. Med. Chem.* 50:74 -- ROCS algorithm.\n- Schreyer & Blundell, *J. Cheminformatics* 4:27 -- USRCAT.\n- Vainio & Johnson, *J. Chem. Inf. Model.* 47:2462 -- ShaEP.\n- Liu et al., *J. Chem. Inf. Model.* (2024) -- Open3DAlign improvements.\n- Roy et al., *J. Med. Chem.* 65:11875 -- shape-based VS modern review.\n\n## Related Skills\n\n- chemoinformatics\u002Fmolecular-io - Parse query and library\n- chemoinformatics\u002Fconformer-generation - Generate 3D conformer ensembles\n- chemoinformatics\u002Fsimilarity-searching - 2D similarity comparison\n- chemoinformatics\u002Fpharmacophore-modeling - Pharmacophore alternative\n- chemoinformatics\u002Fscaffold-analysis - 2D scaffold analysis\n- chemoinformatics\u002Fvirtual-screening - Shape as pre-filter to docking\n\n## Cross-references\n\nOther skills in this category:\n\n- admet-prediction\n- conformer-generation\n- covalent-design\n- docking-rescoring\n- free-energy-calculations\n- generative-design\n- molecular-descriptors\n- molecular-io\n- molecular-standardization\n- pharmacophore-modeling\n- pose-validation\n- protac-degraders\n- qsar-modeling\n- retrosynthesis\n- scaffold-analysis\n- similarity-searching\n- substructure-search\n- virtual-screening\n\n## Changelog\n\n- **1.1.0** (migration) — Bulk-migrated to v0.4.0 schema: canonical\n  metadata block, base Hard rules, Cross-references. Body content\n  unchanged; author should review and fill in any domain-specific\n  extensions to the Hard rules.\n- **1.0.0** — Initial release.\n\n",{"name":5,"license":15,"description":7},"main","9c0b41e2036cc5588c699f06e658ea6dc3b9685d","skills\u002Fchemoinformatics\u002Fshape-similarity",2,"https:\u002F\u002Fgithub.com\u002Fpradyumnasagar\u002Fopen-research-skills","https:\u002F\u002Fgithub.com\u002Fpradyumnasagar","PhD Scholar,\r\nManipal School Of Life Sciences, Manipal\r\n #OpenSourceDeveloper #LifeSciences #ComputationalBiology","2026-10-30 01:30:52",{"source":8,"skillName":5,"commands":33,"prompt":43,"zipAvailable":44},[34,37,40],{"tool":35,"command":36},"npx","npx skills add pradyumnasagar\u002Fopen-research-skills --skill shape-similarity",{"tool":38,"command":39},"bunx","bunx skills add pradyumnasagar\u002Fopen-research-skills --skill shape-similarity",{"tool":41,"command":42},"pnpm","pnpm dlx skills add pradyumnasagar\u002Fopen-research-skills --skill shape-similarity","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fpradyumnasagar\u002Fopen-research-skills\u002Fblob\u002Fmain\u002Fskills\u002Fchemoinformatics\u002Fshape-similarity\u002FSKILL.md",true,[],[47,54,60,67,74,81],{"skillNo":48,"name":49,"nameZh":6,"description":50,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":51,"categories":52,"keywords":53,"publishedAt":19},"01M75KTS5K9QNX8FQBTJW2GQSH","good-skill","A well-formed test fixture for the validation script.","https:\u002F\u002Fgithub.com\u002Fpradyumnasagar\u002Fopen-research-skills\u002Fblob\u002Fmain\u002Ftests\u002Ffixtures\u002Fgood-skill\u002FSKILL.md",[],[],{"skillNo":55,"name":56,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":57,"categories":58,"keywords":59,"publishedAt":19},"01M75KTR7FAT0MMMED2EGC9WZZ","BadSkill","https:\u002F\u002Fgithub.com\u002Fpradyumnasagar\u002Fopen-research-skills\u002Fblob\u002Fmain\u002Ftests\u002Ffixtures\u002Fbad-skill\u002FSKILL.md",[],[],{"skillNo":61,"name":62,"nameZh":6,"description":63,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":64,"categories":65,"keywords":66,"publishedAt":19},"01M75KTN949EDF77GJDS8H6VR8","my-new-skill","One sentence (max 200 chars) — what the skill does and when to use it.","https:\u002F\u002Fgithub.com\u002Fpradyumnasagar\u002Fopen-research-skills\u002Fblob\u002Fmain\u002Ftemplate\u002FSKILL.md",[],[],{"skillNo":68,"name":69,"nameZh":6,"description":70,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":71,"categories":72,"keywords":73,"publishedAt":19},"01M75KTHTFS121SSF1Q5X2FXDA","thesis-structure","Use when planning or checking the architecture of a PhD \u002F MPhil thesis in the life sciences or bioinformatics — monograph vs article-based, chapter sequence, IMRaD-based chapters, abstract-to-conclusion flow, and the examiner expectations that the structure must meet.","https:\u002F\u002Fgithub.com\u002Fpradyumnasagar\u002Fopen-research-skills\u002Fblob\u002Fmain\u002Fskills\u002Fthesis-writing\u002Fthesis-structure\u002FSKILL.md",[],[],{"skillNo":75,"name":76,"nameZh":6,"description":77,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":78,"categories":79,"keywords":80,"publishedAt":19},"01M75KTE3WKW46FXFHQ579H8YP","thesis-methods-reproducibility","Use when writing or checking the Methods, figures, data, and code of a bioinformatics \u002F microbiology \u002F life-science PhD thesis — the FAIR data, versioned code, report-generation, figure-and-table discipline, and the reproducibility expectations that examiners probe at viva.","https:\u002F\u002Fgithub.com\u002Fpradyumnasagar\u002Fopen-research-skills\u002Fblob\u002Fmain\u002Fskills\u002Fthesis-writing\u002Fthesis-methods-reproducibility\u002FSKILL.md",[],[],{"skillNo":82,"name":83,"nameZh":6,"description":84,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":85,"categories":86,"keywords":87,"publishedAt":19},"01M75KTA033ZQCJY3DC8P5VQET","thesis-defense-viva","Use when preparing for the viva voce \u002F oral thesis defense — building the examiner's question set, rehearsing the presentation, and the pre-defense polish (slides, summary, the 'what if I'm stuck' responses) for a life-science or bioinformatics PhD.","https:\u002F\u002Fgithub.com\u002Fpradyumnasagar\u002Fopen-research-skills\u002Fblob\u002Fmain\u002Fskills\u002Fthesis-writing\u002Fthesis-defense-viva\u002FSKILL.md",[],[]]