Skip to main content

chembl_gen_check

chembl_gen_check is a Python library for rapidly assessing how reasonable a (generated) molecule is. It ships with precomputed databases for both ChEMBL (medicinal chemistry from the scientific literature) and SureChEMBL (chemical structures extracted from patent literature), so no downloads or preprocessing are required: just pick one when loading your checker.

Using lightweight MolBloom filters, it verifies whether a compound's scaffolds, generic scaffolds or ring systems already exist in the selected database. It can also flag uncommon bonds via the LACAN algorithm and report structural alerts. Taken together, these checks give a fast read on the plausibility of a molecule's ring systems and scaffolds, and ensure that its atom and bond environments have precedent.

Installation

pip install chembl-gen-check

Usage example

from chembl_gen_check import Checker

checker = Checker("chembl")
#checker = Checker("surechembl")

smiles = "CCN(CC)C(=O)C[C@H]1C[C@@H]1c1ccccc1"
checker.load_smiles(smiles)

# Murcko scaffold found in the loaded database (True/False)
checker.check_scaffold()

# Generic Murcko scaffold found in loaded database (True/False)
checker.check_skeleton()

# All molecule ring systems found in loaded database (True/False)
checker.check_ring_systems()

# Number of structural alerts using the ChEMBL set in RDKit(integer)
checker.check_structural_alerts()

# LACAN hard pass/fail filter (default mode="threshold"): reject if any bond's
# PMI is below the threshold t (default 0.05). Returns 1.0 (pass) or 0.0 (fail).
checker.check_lacan()

How LACAN Works

Reference: Dehaen, W. LACAN. ChemRxiv preprint.

LACAN scores a molecule one bond at a time. Each bond is split into its two atom environments, and a PMI ratio (pointwise mutual information) is computed from the reference database:

PMI = P(env_a, env_b) / (P(env_a) * P(env_b))

that is, how often the two halves are actually bonded together versus how often they would be by pure chance. PMI > 1 means the bond is more common than chance, PMI ≈ 1 is as expected, and PMI ≈ 0 flags a junction that is essentially never seen in the database (a likely artifact).

A molecule is summarized by its weakest bond, min_PMI:

  • mode="threshold"(default): a single bond is enough to fail the whole molecule — if any bond has PMI < t (default 0.05) it returns 0.0 (fail), otherwise 1.0 (pass).
  • mode="score" : returns min_PMI / (1 + min_PMI), a value in [0, 1). Higher is more reasonable; 0.5 corresponds to min_PMI = 1.

Code to extract ring systems adapted from: W Patrick Walters. useful_rdkit_utils

Code to calculate LACAN scores adapted from: Dehaen, W. LACAN. https://github.com/dehaenw/lacan/

Metadata

Release files for chembl-gen-check 0.1.4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for chembl-gen-check 0.1.4
File Size Uploaded
chembl_gen_check-0.1.4.tar.gz 46.1 MB Details

Built distribution (wheel)

Table of built distributions (wheels) for chembl-gen-check 0.1.4
File Interpreter ABI Platform
chembl_gen_check-0.1.4-py3-none-any.whl Python 3 none any Details

Total release size: 92.4 MB

Release files / chembl_gen_check-0.1.4.tar.gz

Download URL chembl_gen_check-0.1.4.tar.gz
Size 46.1 MB
Tags Source
SHA-256 checksum
How to use checksums
70e755c7fdb5ebb143325e42b15dd482605e1516dce257cdb7eafb6dd06ae96b
BLAKE2b-256 checksum
How to use checksums
765e116de689dba23eee05c31ad33bf5779abb9f310af99e91c8ddfaa41182e3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.12

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Jun 21, 2026.

Transparency log

Release files / chembl_gen_check-0.1.4-py3-none-any.whl

Download URL chembl_gen_check-0.1.4-py3-none-any.whl
Size 46.3 MB
Tags Python 3
SHA-256 checksum
How to use checksums
2a8eaf69d3fba2553dfd0edc3cca94cc2209b7b4073dc6a016bb2e1b5a2fd434
BLAKE2b-256 checksum
How to use checksums
b682bac51cb68917ef235b27d0bd2e6d86abf7cd7830cf47ec3992a9a76947bf
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.12

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Jun 21, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.1.4 This release

2 release files

0.1.3

2 release files

0.1.2

2 release files

0.1.1

2 release files

0.1.0

2 release files

0.0.5

2 release files

0.0.4

2 release files

0.0.3

2 release files

0.0.2

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page