Search for a command to run...
New Features and APIs Hydrogen normalisation A new API has been added to simplify hydrogen representation normalisation. In the past we had the ability to suppress all hydrogens, make them all explicit or remove all non-chiral hydrogens. We now have a single function which does all of this, the caller specifies what you want and it will add/remove hydrogens as needed keeping all internal state correct and in sync. IChemObjectBuilder bldr = SilentChemObjectBuilder.getInstance(); SmilesParser smipar = new SmilesParser(bldr); SmilesGenerator smigen = new SmilesGenerator(SmiFlavor.Default); IAtomContainer mol = smipar.parseSmiles("C1[C@@H]2CCC(C[C@H](O)C)C[C@@H]2C(C1)[2H]"); AtomContainerManipulator.normalizeHydrogens(mol, HydrogenState.Depiction); System.err.println(smigen.create(mol) + " Depiction"); AtomContainerManipulator.normalizeHydrogens(mol, HydrogenState.Stereo); System.err.println(smigen.create(mol) + " Stereo"); AtomContainerManipulator.normalizeHydrogens(mol, HydrogenState.Minimal); System.err.println(smigen.create(mol) + " Minimal"); AtomContainerManipulator.normalizeHydrogens(mol, HydrogenState.Unsafe); System.err.println(smigen.create(mol) + " Minimal (unsafe)"); Result: C1[C@@]2(CCC(C[C@H](O)C)C[C@@]2(C(C1)[2H])[H])[H] Depiction C1[C@@]2(CCC(C[C@](O)(C)[H])C[C@@]2(C(C1)[2H])[H])[H] Stereo C1[C@@H]2CCC(C[C@H](O)C)C[C@@H]2C(C1)[2H] Minimal C1[C@@H]2CCC(C[C@H](O)C)C[C@@H]2CC1 Minimal (unsafe) <img src="https://private-user-images.githubusercontent.com/983232/440539732-6d5c451c-3aec-4e47-b06b-400ccc5edb18.svg?jwt=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3NzI1NDk4MTQsIm5iZiI6MTc3MjU0OTUxNCwicGF0aCI6Ii85ODMyMzIvNDQwNTM5NzMyLTZkNWM0NTFjLTNhZWMtNGU0Ny1iMDZiLTQwMGNjYzVlZGIxOC5zdmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjYwMzAzJTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI2MDMwM1QxNDUxNTRaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT1mNmViMmUyMTA3OGZlOGYxNGNlZTk3ODBiYTYwYjFiNmIxOWZmMDkwNTBjM2IxZGU3ZThmNTIyZmVkNzBlZjgzJlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCJ9.KCSQLfnhCC2lREtj-SQClND8dESA66qBKVw10XBo2Sw" width="300px"> Markush / RGroup support We already had some basic support for R Group Query files but this was not tied in nicely to the main toolkit. This release adds the ability to work with these files easier as well as support in CXSMILES. It is now possible to load a CXSMILES with R groups and depict it correctly. IChemObjectBuilder bldr = SilentChemObjectBuilder.getInstance(); SmilesParser smipar = new SmilesParser(bldr); IAtomContainer mol = smipar.parseSmiles("C1CNCC(*)C1 |$;;;;;R1$,LN:0:1.3,RG:_R1={OC},{Cl},{C#N}|"); new DepictionGenerator().depict(mol).writeTo("/tmp/tmp.svg"); <img width="617" height="407" alt="Screenshot 2026-03-03 at 15 04 39" src="https://github.com/user-attachments/assets/21dabbda-c373-4350-a723-0e8dec14c5f2" /> Note: the link node is now also parsed and stored. Atropisomers (via RDKit extension) We have supported atropisomers for some time but only via 2D coordinates with layouts and CIP naming etc working as expected. RDKit has an extension to allow loading from CXSMILES - although it is not perfect I was at a loss to think of something better and so it makes sense to support it. Currently this is read-only and mainly intended for depiction. C=CC(=O)N1CCN(c2nc(=O)n(-c3c(C)ccnc3C(C)C)c3nc(-c4c(O)cccc4F)c(F)cc23)[C@@H](C)C1 |wU:12.23| (m)-sotorasib <img width="193" height="252" alt="image" src="https://github.com/user-attachments/assets/032b630b-8af8-468f-8455-7deeb7ae48bf" /> (via CDK depict) API to set wedge bonds A new API has been added to allow setting of wedge bonds to a structure where the coordinates are already known. Note: This function is called automatically when a layout is generated. StructureDiagramGenerator sdg = new StructureDiagramGenerator(); sdg.generateWedges(mol); Sugar Detection Utility See https://github.com/cdk/cdk/pull/1225 <img width="3626" height="1462" alt="image" src="https://github.com/user-attachments/assets/90952096-607a-4e31-85e8-66de8439601f" /> If you want to see the SugarDetectionUtility in action, check out our MOlecule fRagmenTAtion fRamework (MORTAR) application, the SDU will be part of the next release. What's Changed Merged test-extra into extra and more by @egonw in https://github.com/cdk/cdk/pull/1180 Ported cdk.core test classes to the module being tested by @egonw in https://github.com/cdk/cdk/pull/1179 If any bond is hidden in the ring, it should not be filled. by @johnmay in https://github.com/cdk/cdk/pull/1181 Fix #1174. We need better logic when the ring closures are near exten… by @johnmay in https://github.com/cdk/cdk/pull/1182 FIx #1183 InChITautomerGenerator on AtomContainer2 by @johnmay in https://github.com/cdk/cdk/pull/1184 Ensure MDLV3000 stereo 0d works correctly. by @johnmay in https://github.com/cdk/cdk/pull/1187 We need a static variable to be able to use it from a static context. by @johnmay in https://github.com/cdk/cdk/pull/1186 Fix some corner cases in reading of stereochemistry from chair projec… by @johnmay in https://github.com/cdk/cdk/pull/1192 Remove some redundant exceptions. by @johnmay in https://github.com/cdk/cdk/pull/1194 Allow the ExtendedFingerprinter to setHashExplicitHydrogens by @johnmay in https://github.com/cdk/cdk/pull/1196 Fix some issues highlighted by SonarCloud by @johnmay in https://github.com/cdk/cdk/pull/1200 Fixes/smirks 9jul by @johnmay in https://github.com/cdk/cdk/pull/1201 Patch/beam central by @johnmay in https://github.com/cdk/cdk/pull/1202 fix atom property cleanup in DepictionGenerator by @uli-f in https://github.com/cdk/cdk/pull/1203 update maven-compiler-plugin configuration to use <release> instead of <source> and <target> by @uli-f in https://github.com/cdk/cdk/pull/1205 Depedency updated 2025-07-25 by @egonw in https://github.com/cdk/cdk/pull/1204 dependency updates 08-Aug-2025, use <release> instead of <source> and <target> by @uli-f in https://github.com/cdk/cdk/pull/1209 Moved more tests from test-standard to standard by @egonw in https://github.com/cdk/cdk/pull/1207 ConjugatedPiSystemsDetector allene handling fix by @JonasSchaub in https://github.com/cdk/cdk/pull/1211 RDKit atropisomers by @johnmay in https://github.com/cdk/cdk/pull/1212 Allow annotation of bond numbers, this was useful for debugging the a… by @johnmay in https://github.com/cdk/cdk/pull/1213 Add InChI AuxInfo to structure functionality; by @fbaensch-beilstein in https://github.com/cdk/cdk/pull/1208 fix issue with empty annotation in depiction by @uli-f in https://github.com/cdk/cdk/pull/1214 Tweaks for jchempaint by @johnmay in https://github.com/cdk/cdk/pull/1215 Depict background size by @johnmay in https://github.com/cdk/cdk/pull/1216 Depict background by @johnmay in https://github.com/cdk/cdk/pull/1217 LargestPiSystemDescriptor visited flags and minor code improvements by @JonasSchaub in https://github.com/cdk/cdk/pull/1218 Fix a corner case with titles for reactions not being set if no CXSMI… by @johnmay in https://github.com/cdk/cdk/pull/1219 Clean up IBond.Stereo and IBond.Display by @johnmay in https://github.com/cdk/cdk/pull/1220 Improved stereochemistry invalidation when modifying molecules (Fixes… by @johnmay in https://github.com/cdk/cdk/pull/1222 Rgroup Improvements by @johnmay in https://github.com/cdk/cdk/pull/1223 Sugar Detection Utility by @JonasSchaub in https://github.com/cdk/cdk/pull/1225 Test cleanup by @johnmay in https://github.com/cdk/cdk/pull/1228 Additional test simplification/dreprecation by @johnmay in https://github.com/cdk/cdk/pull/1229 Move around some XML config files. by @johnmay in https://github.com/cdk/cdk/pull/1230 Simplify the SybylAtomTypeMatcherTest. by @johnmay in https://github.com/cdk/cdk/pull/1231 Handle Link Nodes in CXSMILES (Ring flags now set when reading from SMILES) by @johnmay in https://github.com/cdk/cdk/pull/1232 Make SmallRingDescriptor, WienerNumbersDescriptor, and ALogPDescriptor parallelisable by @JonasSchaub in https://github.com/cdk/cdk/pull/1234 Move the InChI Readers to cdk-inchi module. by @johnmay in https://github.com/cdk/cdk/pull/1235 Add JDK-25 to CI by @mjw99 in https://github.com/cdk/cdk/pull/1237 swap carrier order in DoubleBondStereochemistry::create to satisfy bond alignment constraint by @uli-f in https://github.com/cdk/cdk/pull/1226 use thread safe collection in RoundRobinFormulaGenerator by @SteffenHeu in https://github.com/cdk/cdk/pull/1239 Exhaustive fragmenter fix and improvements by @ToLeWeiss in https://github.com/cdk/cdk/pull/1238 Varattach matching by @johnmay in https://github.com/cdk/cdk/pull/1243 Updated dependencies: maven plugins and library deps by @egonw in https://github.com/cdk/cdk/pull/1242 Some tweaks to abbreviations - based on feedback from https://github.… by @johnmay in https://github.com/cdk/cdk/pull/1247 Add support for loading selection/highlight from CXSMILES and MDL Mol… by @johnmay in https://github.com/cdk/cdk/pull/1246 Add a method to the SDG which allows wedges to be assigned to a struc… by @johnmay in https://github.com/cdk/cdk/pull/1249 adopt <dependencyManagment> and <pluginManagement> by @egonw in https://github.com/cdk/cdk/pull/1250 CMLXOM 4.15 and Log4j 2.25.3 by @egonw in https://github.com/cdk/cdk/pull/1252 Fix a null pointer exception in MDLV2000Reader by @Mailaender in https://github.com/cdk/cdk/pull/1254 Misc tweaks for Markush rendering. by @johnmay in https://github.com/cdk/cdk/pull/1257 Update the connectivity checker to either respect/ignore (default) va… by @johnmay in https://github.com/cdk/cdk/pull/1258 two more dependency updates (compatible with java 8) by @egonw in https://github.com/cdk/cdk/pull/1259 CDK RGroups by @johnmay in https://github.com/cdk/cdk/pull/1260 Hydrogen Normalization by @johnmay in https://github.com/cdk