SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2410.04223 · 2024

Multimodal Large Language Models for Inverse Molecular Design with Retrosynthetic Planning

arXiv · PDF · Open in the Atlas

Code that ran

9 of 11 samples (functions and classes) lifted from this paper's linked repositories executed on a synthesized input in Syntology's jail (0 of them constructed an object rather than computing a result; 3 honoured the contract we drafted, 2 violated it and 0 have no contract verdict; 4 failures of our instrument; 2 no recorded run), measured 2026-11-23; repository links from the Papers with Code archive attributed under CC BY-SA, no affiliation; bodies inline only under a permissive licence as GitHub detects it. Not a reproduction of the paper's results.

"Ran" means the function executed on a synthesized input and returned a value. It is not a reproduction of the paper's results. This record, dated, as JSON: /api/ran/2410.04223.json · badge: /api/ran/2410.04223.svg

Each repository's role is a label: a classifier's output recorded on the link, or, where no role is recorded, what the Papers with Code archive marked. The line under it names its basis. Neither says who wrote the code.

RepositoryRoleRan
liugangcode/Llamole canonical (classifier label)
classifier basis: census
9 ran · 2 no recorded run
FunctionStatusWhere it lives
convert_to_dict Ran
ran; our contract draft was wrong, not the code
liugangcode/Llamole/src/model/modeling_llamole.py
code served (permissive licence) · get_code("684cc182c9aa3bac")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned dict. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import torch.nn as nn

torch.manual_seed(0)

# Test with various object types
class CustomObject:
    def __init__(self):
        self.value = 42
        self.name = "test"
        self.nested = {"key": "value"}
        self._private = "hidden"

class AnotherObject:
    def __init__(self):
        self.data = [1, 2, 3]
        self.tensor = torch.randn(2, 4)

# Construct test object with mixed types
test_obj = {
    "int_val": 10,
    "float_val": 3.14,
    "str_val": "hello",
    "bool_val": True,
    "none_val": None,
    "list_val": [1, 2, "three", 4.5],
    "tuple_val": (10, 20, 30),
    "nested_dict": {
        "inner_int": 99,
        "inner_list": [True, False, None]
    },
    "custom_obj": CustomObject(),
    "another_obj": AnotherObject(),
    "tensor": torch.randn(2, 4),
}

ARGS = {
    "obj": test_obj
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type dict — a dict output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a dict output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
count_parameters Ran
ran, honoured the contract we drafted
liugangcode/Llamole/src/extras/misc.py
code served (permissive licence) · get_code("e493575b4567fc5a")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned tuple, ndim 1, dtype family int; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import torch.nn as nn

torch.manual_seed(0)

# Create a simple model with trainable and non-trainable parameters
class SimpleModel(nn.Module):
    def __init__(self):
        super().__init__()
        # Trainable parameters
        self.linear1 = nn.Linear(4, 3)
        self.linear2 = nn.Linear(3, 2)
        # Non-trainable parameter
        self.register_buffer('buffer', torch.randn(2, 2))
        # Add a non-trainable parameter
        self.register_parameter('frozen_param', nn.Parameter(torch.randn(5)))
        self.frozen_param.requires_grad = False
    
model = SimpleModel()

ARGS = {
    'model': model
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple, ndim 1, dtype family int — a tuple output has no array shape of its own; none is stated
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
dict_to_list Ran
ran, honoured the contract we drafted
liugangcode/Llamole/src/eval/dataset.py
code served (permissive licence) · get_code("87f7bd0b36b591d2")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned list, ndim 1, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import numpy as np

torch.manual_seed(0)

# Construct arguments for dict_to_list
data_dict = {
    'molecular_weight': 180.5,
    'logp': 2.3,
    'hbd': 3,
    'hba': 5,
    'extra_prop': 42.0
}

mol_properties = ['molecular_weight', 'logp', 'hbd', 'hba', 'missing_prop']

ARGS = {
    'data_dict': data_dict,
    'mol_properties': mol_properties
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type list, ndim 1, dtype family float — a list output has no array shape of its own; none is stated
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
format_example Ran
ran; our contract draft was wrong, not the code
liugangcode/Llamole/launch.py
code served (permissive licence) · get_code("3c781f40e814fc9a")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned list, ndim 1, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import numpy as np

def format_example(example):
    formatted = [example['instruction']]
    is_drug = any((prop in example.get('property', {}) for prop in ['HIV', 'BBBP', 'BACE']))
    formatted.append('Drug' if is_drug else 'Material')
    for prop in ['HIV', 'BBBP', 'BACE']:
        value = example.get('property', {}).get(prop, float('nan'))
        formatted.append(value if not np.isnan(value) else 'NAN')
    for prop in ['CO2', 'N2', 'O2', 'FFV', 'TC']:
        value = example.get('property', {}).get(prop, float('nan'))
        formatted.append(value if not np.isnan(value) else 0)
    for prop in ['SC', 'SA']:
        value = example.get('property', {}).get(prop, float('nan'))
        formatted.append(value if not np.isnan(value) else float('nan'))
    return formatted


example = {
    'instruction': 'Analyze the molecular structure',
    'property': {
        'HIV': 0.85,
        'BBBP': 0.72,
        'BACE': 0.91,
        'CO2': 1.23,
        'N2': 2.34,
        'O2': 3.45,
        'FFV': 4.56,
        'TC': 5.67,
        'SC': 6.78,
        'SA': 7.89
    }
}

ARGS = {
    'example': example
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type list, ndim 1, dtype family float — a list output has no array shape of its own; none is stated
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
get_logger Ran
ran; our contract draft was wrong, not the code
liugangcode/Llamole/src/extras/logging.py
pointer only (licence: Apache-2.0); the stored copy get_code serves, from youganglyu/MACPO, is pointer only (licence: NONE) · get_code("4049a2f89b11dd2f")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (Apache-2.0), but get_code serves the stored copy, first harvested from youganglyu/MACPO, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

has_tokenized_data Ran
ran, violated the contract we drafted
liugangcode/Llamole/src/extras/misc.py
code served (permissive licence) · get_code("500cccdb496451fd")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned bool, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import os
import tempfile
import shutil

# Create a temporary directory with some files to simulate tokenized data
temp_dir = tempfile.mkdtemp()
# Add a file to make the directory non-empty
with open(os.path.join(temp_dir, "tokens.txt"), "w") as f:
    f.write("sample tokenized data")

ARGS = {
    "path": temp_dir
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type bool, ndim 0, dtype family float, shape () — shape () as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
process_property Ran
ran, honoured the contract we drafted
liugangcode/Llamole/launch.py
code served (permissive licence) · get_code("9a4743e426fdc4ab")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned float, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch

torch.manual_seed(0)

ARGS = {
    "value": 0
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type float, ndim 0, dtype family float, shape () — shape () as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
remove_extra_spaces Ran
ran; our contract draft was wrong, not the code
liugangcode/Llamole/src/eval/workflow.py
code served (permissive licence) · get_code("952ea691225d8618")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned str. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import re

def remove_extra_spaces(text):
    cleaned_text = re.sub('\\s+', ' ', text)
    return cleaned_text.strip()

ARGS = {
    'text': '  hello    world   this  is   a    test  '
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type str — a str output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a str output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
smooth Ran
ran, violated the contract we drafted
liugangcode/Llamole/src/extras/ploting.py
code served (permissive licence) · get_code("0b9f48a781766d05")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned list, ndim 1, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import math
from typing import List

# Construct a simple list of scalars for testing the smooth function
scalars = [1.0, 2.0, 3.5, 2.8, 4.1, 3.9, 5.2]

ARGS = {
    "scalars": scalars
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type list, ndim 1, dtype family float — a list output has no array shape of its own; none is stated
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
gen_loss_plot Not yet run
unverified (harvested, no recorded run)
liugangcode/Llamole/src/extras/ploting.py
code served (permissive licence) · get_code("b0a7fecf74187af6")
How it ran

no invocation recorded.

infer_optim_dtype Not yet run
unverified (harvested, no recorded run)
liugangcode/Llamole/src/extras/misc.py
code served (permissive licence) · get_code("af446e6ee5be84b9")
How it ran

no invocation recorded.

Also present in other papers' code

Of 11 samples lifted from this paper's linked repositories, 11 carry a function identity and 0 do not. Of the 11 distinct functions with an identity, 4 are also present in other papers whose code we hold (1 with at least one paper dated earlier, 1 the same month, 4 later) and 7 are only here among the 52,977 papers whose code Syntology holds (as of 2026-09-26).

Only here means: among the 52,977 papers whose code Syntology holds (51,887 with lifted samples, 1,090 through their assemblies only), as of 2026-09-26, no other paper's lifted samples or current assembly bricks contain an identical function body after normalisation.

FunctionAlso present inEarliest-datedOthers named
get_logger 8 other papers
5 dated earlier, 2 the same month, 1 later
2311.13246 (2023-11)
CoachLM: Automatic Instruction Revisions Improve the Data Quality in LLM Instruction Tuning
2312.02554 (2023-12)
ULMA: Unified Language Model Alignment with Human Demonstration and Point-wise Preference
2403.13786 (2024-03)
Chain-of-Interaction: Enhancing Large Language Models for Psychiatric Behavior Understanding by Dyadic Contexts
and 5 more not named here
count_parameters 1 other paper
1 later
2503.06252 (2025-03)
Can Atomic Step Decomposition Enhance the Self-structured Reasoning of Multimodal Large Models?
gen_loss_plot 1 other paper
1 later
2503.06252 (2025-03)
Can Atomic Step Decomposition Enhance the Self-structured Reasoning of Multimodal Large Models?
smooth 1 other paper
1 later
2503.06252 (2025-03)
Can Atomic Step Decomposition Enhance the Self-structured Reasoning of Multimodal Large Models?

Presence, not direction: an identical function body in two papers' repositories does not say who wrote it, which came from which, or that either paper's method rests on it. Matching is exact after normalisation, so a renamed or edited function is not matched. Dates are when papers appeared, not when code was written. Only .py files the harvester lifted are covered; notebooks are not read. A new-style arXiv id YYMM.NNNN dates a paper to the month 20YY-MM; otherwise Paper.year dates it to the year; otherwise it is undated. Dates are when the paper appeared, not when the code was written. Read 2026-11-23.

Repositories linked to this paper

Some links come from the archived Papers with Code dataset (CC BY-SA 4.0): attribution and licence.

Abstract

While large language models (LLMs) have integrated images, adapting them to graphs remains challenging, limiting their applications in materials and drug design. This difficulty stems from the need for coherent autoregressive generation across texts and graphs. To address this, we introduce Llamole, the first multimodal LLM capable of interleaved text and graph generation, enabling molecular inverse design with retrosynthetic planning. Llamole integrates a base LLM with the Graph Diffusion Transformer and Graph Neural Networks for multi-conditional molecular generation and reaction inference within texts, while the LLM, with enhanced molecular understanding, flexibly controls activation among the different graph modules. Additionally, Llamole integrates A* search with LLM-based cost functions for efficient retrosynthetic planning. We create benchmarking datasets and conduct extensive experiments to evaluate Llamole against in-context learning and supervised fine-tuning. Llamole significantly outperforms 14 adapted LLMs across 12 metrics for controllable molecular design and retrosynthetic planning.

For agents

The same record, over MCP at https://syntology.ai/mcp:

get_harvested_code_for_paper("2410.04223")
get_code_for_paper("2410.04223")
have("2410.04223")

The run record, dated, one paper per request, free:

curl https://syntology.ai/api/ran/2410.04223.json

A badge for a README (the split and the date, never a ratio):

[![Syntology run record](https://syntology.ai/api/ran/2410.04223.svg)](https://syntology.ai/paper/2410.04223)

Connect an agent — have() is free.