AGENT SKILL

datamol

Guides agents using the datamol Python package for RDKit-first molecular IO, preparation, fingerprints, similarity, structure generation, visualization, and utility workflows.

License 许可
Apache-2.0
最近更新
2026-09-03
Stars
★ 351
Forks
27

01 前言 Front Matter

name
datamol
license
Apache 2.0
metadata
{ "disco-role": "operating" }
description
Guides agents using the datamol Python package for RDKit-first molecular IO, preparation, fingerprints, similarity, structure generation, visualization, and utility workflows.
disable-model-invocation
true

02 资源文件 5

03 SKILL.md 正文

Datamol Repo Skill

Use this skill when a task names datamol, asks for RDKit-first molecule processing in Python, or needs practical guidance for molecular IO, standardization, fingerprints, descriptors, clustering, conformers, scaffolds, reactions, isomers, visualization, or datamol utility helpers.

Datamol is a Python layer on top of RDKit. Assume user-facing objects are usually rdkit.Chem.Mol instances, SMILES strings, pandas dataframes, NumPy arrays, or small molecule files such as SDF/SMI/CSV/XLSX.

Install And Import

Prefer the public package install used by the project:

mamba install -c conda-forge datamol
# or, when conda is unavailable:
python -m pip install datamol

Minimal import check:

import datamol as dm
mol = dm.to_mol("CCO")
assert dm.to_smiles(mol) == "CCO"

Run scripts/check_datamol_environment.py when an environment, RDKit install, optional dependency, or basic API smoke check is uncertain.

Choose A Sub-Skill

  • Use sub-skills/molecule-io-prep/SKILL.md for molecule construction, SMILES/InChI/SMARTS/SELFIES conversion, SDF/CSV/XLSX/dataframe IO, standardization, sanitization, salts/solvents, properties, bundled toy datasets, and molar unit helpers.
  • Use sub-skills/fingerprints-similarity/SKILL.md for fingerprints, descriptors, fingerprint arrays, pairwise or cross-distance matrices, clustering, diversity/centroid picking, MCS, and molecular graph matching.
  • Use sub-skills/structure-generation/SKILL.md for conformers, 3D features, alignment, atom reordering, fragmentation, assembly, scaffolds/fuzzy scaffolds, reactions, attachments, tautomers, stereoisomers, and structural isomers.
  • Use sub-skills/visualization-utilities/SKILL.md for molecule grids, SVG/PNG rendering, substructure or lasso highlighting, dataframe rendering, existing conformer display, filesystem helpers, parallel jobs, RDKit log control, and diagnostics.

Common Workflow Order

  1. Start in molecule-io-prep to parse inputs, sanitize/standardize molecules, preserve properties, and choose dataframe/file formats.
  2. Move to fingerprints-similarity when the next step needs numeric descriptors, distance matrices, clusters, diversity selection, MCS, or graph correspondence.
  3. Move to structure-generation when the task creates new chemistry or 3D structures through conformers, fragments, scaffolds, reactions, or isomer enumeration.
  4. Move to visualization-utilities when the output needs images, highlights, notebook/file rendering, parallel utility helpers, fsspec checks, or RDKit logging control.

Read references/capability-map.md for natural task phrases and the owning sub-skill. Read references/troubleshooting.md for cross-cutting install/import, RDKit, file-format, optional dependency, and workflow routing failures.

Safety Defaults

  • Keep examples small and deterministic until molecule parsing, sanitization, and output formats are verified.
  • Bound expensive or combinatorial chemistry with small n_confs, n_variants, timeout, timeout_seconds, depth, max_n_mols, num_threads=1, and n_jobs=1 first.
  • Treat network files, cloud URIs, notebook widgets, and optional renderers as environment-specific; validate them with the nearest troubleshooting reference before relying on them.
  • Prefer SVG output for deterministic visual artifacts and use PNG/Pillow only when the caller explicitly needs raster output.
  • Preserve row identifiers, molecule properties, and invalid-row handling explicitly when converting between dataframes and molecule files.

Bundled Checks

Each script supports --help and uses only tiny local examples by default.

Provenance And Refresh

Read references/repo-provenance.md before deciding whether this skill is current for a datamol checkout. If the current commit, dirty state, package metadata, or major evidence paths differ from that snapshot, run refresh-repo-skill before relying on stale API details.

04 同仓库更多 Skills

VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-triton-opt

Make a single PassNet Triton kernel fast AND numerically faithful: performance model (when a replacement can win at all), block/grid/warp tuning, autotune policy, launch overhead, and per-op numeric recipes to pass the dtype baseline tolerances. Use when a pass matches and is correct but speedup below expected, or when correctness fails by small numeric margins.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-solve

END-TO-END playbook for solving one PassNet sample: analyze the computation graphs, decide the optimization strategy (what to fuse, what to replace, what to leave alone), drive the iteration loop, and maximize the sample score. This is the ENTRY skill — invoke it first for any PassNet optimization task; it tells you when to use passnet-pattern-fusion, passnet-triton-opt and passnet-feedback.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-skill

PassNet GPU kernel optimization via compiler passes. Design and implement Triton-based optimization passes, create pass files under ./pass_dir/, self-evaluate with pass_evaluator, and iterate to maximize GPU speedup.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-pattern-fusion

Author PassNet pass files: write patterns that actually MATCH the FX graph, pick fusion regions (which ops to absorb into one Triton kernel), and structure multi-pass submissions with the mandatory shared-dispatch architecture. Use when creating or fixing pattern()/replacement_args()/replacement_func() files, when a pass "failed to match", or when deciding how to fuse multiple kernels/ops.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-orchestrate

Round/batch planning and decision support for PassNet graph optimization. Use for multi-sample triage, worker allocation, eval-budget policy, and post-eval keep/revert decisions. For solving one concrete sample end to end, use passnet-solve as the entry skill; consult this skill only when you need broader planning or a specific decision gate.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-feedback

Fast, deterministic feedback for PassNet work: pre-flight pattern/match verification WITHOUT burning a GPU evaluation, per-node bottleneck analysis of a sample's graphs, and eval-log parsing into per-variant status + estimated score + failure classification. Use BEFORE every GPU evaluation (check_pattern), at the START of a sample (analyze_graph), and AFTER every evaluation (parse_eval_log).

★ 351