OpenViSTAI · Agents · Blockchain · Crypto
Menu
AI Models

MoLeR

MoLeR is a Python implementation of a generative model for molecular graphs, with code for training and inference and support for generating molecules conditioned on a scaffold. The repository also includes a CGVAE implementation without integration into its high-level model interface.

Independent OpenViST project profile, based on linked sources.

MoLeR — OpenViST project profile in AI Models.
OpenViST project illustration. See the linked sources for product details.
Understand the project

Practical overview

When it fits

Use MoLeR when a research workflow needs a programmable molecular graph generator, particularly when generated candidates should be conditioned on a specified scaffold. The repository also documents encoding, decoding, sampling and data-preparation stages.

Who it is for

  • Computational chemistry researchers exploring generated molecular structures.
  • Developers building research workflows for molecular graph generation, encoding or scaffold-conditioned decoding.
  • Teams with SMILES datasets that want to preprocess data and train or fine-tune the model.

Documented uses

  • Sample candidate molecular structures from a trained model.
  • Generate molecular structures while supplying a scaffold constraint.
  • Encode SMILES strings into latent vectors and decode vectors into molecular structures.
  • Preprocess SMILES datasets into graph data and generation traces for model training.
Before you choose

Requirements & limits

The implementation is public on GitHub and identifies an MIT license. The README documents installation through pip and Conda environment files.

  • The documented stack includes Python, TensorFlow and RDKit; GPU use additionally requires CUDA libraries.
  • The CLI supports sampling and encoding, but the README says it does not expose all useful inference functionality; the Python interface documents encoding and decoding with scaffold inputs.
  • The repository is archived, a relevant consideration for teams planning to maintain or adapt the implementation.

Check current requirements in the official documentation. Source-based guidance does not mean OpenViST has run or independently tested this project.

Source-based practical guide

Install MoLeR and prepare a checkpoint for sampling

Install the package and arrange the documented pretrained checkpoint for use with the sampling command.

Before you start

  • Python 3.7 or later, TensorFlow 2.1.0 or later, and RDKit 2020.09.1 or later; the repository points to its Conda environment files for tested configurations.
  • CUDA libraries are needed if using a GPU.
  • A MoLeR checkpoint downloaded from the linked location.

Steps

  1. Create and activate the environment with conda env create -f environment.yml and conda activate moler-env.

  2. Install the package with the command below.

    Documented command
    pip install molecule-generation
  3. Save the checkpoint in a fresh model directory and rename it with a .pkl ending.

  4. Run molecule_generation sample MODEL_DIR 10, replacing MODEL_DIR with that directory.

Expected outcome

The sampling command requests 10 molecules from the checkpoint in the specified model directory.

Guide limitations

  • The model directory must contain exactly one .pkl checkpoint for the documented model loader.
  • The README describes CLI inference as mainly intended for simple tests and notes that it does not expose all useful functionality.
Source-based practical guide

Prepare SMILES files for MoLeR preprocessing

Set up the documented input layout for preprocessing molecular data into graph descriptions and generation traces.

Before you start

  • A directory containing train.smiles, valid.smiles and test.smiles, each with one SMILES string per line.
  • The installed molecule_generation package.

Steps

  1. Place the three SMILES files in an input directory.

  2. Choose separate directories for intermediate output and final generation traces.

  3. Run molecule_generation preprocess INPUT_DIR OUTPUT_DIR TRACE_DIR, substituting the chosen directory paths.

Expected outcome

The preprocessing stage produces processed molecular graph data and generation traces for the subsequent training workflow.

Guide limitations

  • The generation-trace stage is described as typically the most compute-intensive part of preprocessing.
  • The README notes that some molecules may fail parsing or trace generation.
Evidence and transparency

Sources & review

Source record details
Source availability
Active
Sources checked
20 November 2026
Original website title
microsoft/molecule-generation · Official homepage title · retained in its source language