Skip to content

Varattach matching#1243

Merged
egonw merged 2 commits intomainfrom
varattach-matching
Nov 9, 2025
Merged

Varattach matching#1243
egonw merged 2 commits intomainfrom
varattach-matching

Conversation

@johnmay
Copy link
Copy Markdown
Member

@johnmay johnmay commented Nov 9, 2025

Adds support for variable attach matching in SMARTS. I've been doing some work on this at NextMove recently and need to support in CDK to get the highlight working correction Arthor. To get reasonable support it's not much code at all but allows us to support queries like:

(chloro-pyrid-2-yl)-indole

…t-processing filter of the mapped atoms.

We skip over the '*' attachments when creating the mapping and then check/fill-in the mapping using the filter. This allows correct handling of complex cases like nested attachments, attachments which form rings and double-end attachments.
@sonarqubecloud
Copy link
Copy Markdown

sonarqubecloud bot commented Nov 9, 2025

@egonw
Copy link
Copy Markdown
Member

egonw commented Nov 9, 2025

Nice work! code looks good. I cannot oversee all the implications, but see how this can seriously help fields like metabolomics

@egonw egonw merged commit 0d72a42 into main Nov 9, 2025
12 checks passed
@johnmay johnmay deleted the varattach-matching branch March 3, 2026 13:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants