Install any skill in seconds. Free to start, no credit card required.
Get Started Free →jaechang-hits/rdkit-chemdraw-cdxml
Read, write, and edit ChemDraw CDX/CDXML files with RDKit's rdkit.Chem.rdChemDraw plus direct XML editing, always paired with a rendered PNG. Parse molecules and reactions from .cdxml/.cdx, write structures with good 2D depiction, and hand-build or modify the parts RDKit cannot write: reaction arrows, plus signs, schemes/steps, and text/labels.
Passed 13 of 19 test cases with the skill, and 7 of 19 without it.
and 5 more in the full report
7 fixed9 passed either way7 still failing0 broke
Tokens, turns and time describe resource use, not a dollar price.
One of 6 test cases the skill fixed. Same model, same prompt, with and without the skill.
I want to export `CC(=O)Oc1ccccc1C(=O)O` to CDXML string using Python. I noticed when I convert SMILES directly without any preprocessing, the output drawing appears collapsed at a single point. What step must be performed before passing the Mol object to the ChemDraw exporter?
| Checked | Without skill | With skill |
|---|---|---|
| Calls rdDepictor.Compute2DCoords on the molecule object prior to calling MolToChemDrawBlock. | Missed | Passed |
The instructions your model reads when the skill loads.
CDXML is an XML serialization of ChemDraw's object tree (CDX is its binary form). RDKit 2022.09+ exposes an optional Revvity ChemDraw parser at rdkit.Chem.rdChemDraw that reads molecules and reactions and writes molecule structures. RDKit cannot write arrows, plus signs, schemes, or text — those are built or edited at the XML level. This skill covers the full read → depict → annotate → write → modify → render loop.
A .cdxml is not viewable without ChemDraw, and you cannot run ChemDraw here — so the rendered PNG is the only evidence the file is correct. Therefore:
<name>.cdxml and <name>.png together, matching basenames — never the CDXML alone. build_scheme() and Module 9 write both; the helper raises if the PNG cannot be produced.scripts/check_scheme.py (rebuilds each molecule from the drawing, sanitizes, checks mass balance across arrows, and critiques layout). Drive it to zero problems..cdxml files that open cleanly in ChemDraw.cdxml or .cdx+ separators + conditions textrdkit-cheminformatics instead for descriptors/fingerprints/SMARTS with no ChemDraw I/Oopenbabel; this toolkit is 2D ChemDraw-specificrdkit (2023.03+, built with ChemDraw support), epam.indigo (renders CDXML→PNG); xml.etree.ElementTree (stdlib) handles all XML editing..cdxml (UTF-8 text) or .cdx (binary) for reading.python -c "import rdkit" first; inside pixi use pixi run python ....epam.indigo into the interpreter that runs your code. A bare pip install can land in a different Python than the kernel (e.g. system /usr/local vs the pixi env that has rdkit), so import indigo still fails even though the install "succeeded" — and no single interpreter then has both rdkit and indigo. In a Jupyter/IPython kernel use %pip install epam.indigo; otherwise python -m pip install epam.indigo (the running interpreter), or add it to the project env (pixi add epam.indigo). For the same reason, do not run the build/render in a fresh subprocess (["python", …] may resolve yet another interpreter) — import the helper and run it in the current process.python -m pip install epam.indigo # the running interpreter; or %pip install epam.indigo in Jupyter
python -c "from rdkit import Chem; print('ChemDraw write support:', Chem.HasChemDrawCDXSupport())"
from rdkit import Chem
test cases passed, vs 7 / 19 without
More skills from the same source and nearby in the registry, with their headline benchmark lift.