Breaking Bad Molecules: Are MLLMs Ready for Structure-Level Molecular Detoxification?
Paper
β’
2506.10912
β’
Published
Error code: StreamingRowsError
Exception: CastError
Message: Couldn't cast
task: string
id: int64
smiles: string
image: binary
-- schema metadata --
pandas: '{"index_columns": [], "column_indexes": [], "columns": [{"name":' + 504
to
{'task': Value('string'), 'id': Value('int64'), 'smiles': Value('string'), 'image_path': Value('string')}
because column names don't match
Traceback: Traceback (most recent call last):
File "/src/services/worker/src/worker/utils.py", line 99, in get_rows_or_raise
return get_rows(
^^^^^^^^^
File "/src/libs/libcommon/src/libcommon/utils.py", line 272, in decorator
return func(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^
File "/src/services/worker/src/worker/utils.py", line 77, in get_rows
rows_plus_one = list(itertools.islice(ds, rows_max_number + 1))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/datasets/iterable_dataset.py", line 2543, in __iter__
for key, example in ex_iterable:
^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/datasets/iterable_dataset.py", line 2060, in __iter__
for key, pa_table in self._iter_arrow():
^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/datasets/iterable_dataset.py", line 2083, in _iter_arrow
for key, pa_table in self.ex_iterable._iter_arrow():
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/datasets/iterable_dataset.py", line 544, in _iter_arrow
for key, pa_table in iterator:
^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/datasets/iterable_dataset.py", line 383, in _iter_arrow
for key, pa_table in self.generate_tables_fn(**gen_kwags):
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/datasets/packaged_modules/parquet/parquet.py", line 180, in _generate_tables
yield Key(file_idx, batch_idx), self._cast_table(pa_table)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/datasets/packaged_modules/parquet/parquet.py", line 143, in _cast_table
pa_table = table_cast(pa_table, self.info.features.arrow_schema)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/datasets/table.py", line 2272, in table_cast
return cast_table_to_schema(table, schema)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/datasets/table.py", line 2218, in cast_table_to_schema
raise CastError(
datasets.table.CastError: Couldn't cast
task: string
id: int64
smiles: string
image: binary
-- schema metadata --
pandas: '{"index_columns": [], "column_indexes": [], "columns": [{"name":' + 504
to
{'task': Value('string'), 'id': Value('int64'), 'smiles': Value('string'), 'image_path': Value('string')}
because column names don't matchNeed help to make the dataset viewer work? Make sure to review how to configure the dataset viewer, and open a discussion for direct support.
ToxiMol is the first comprehensive benchmark for molecular toxicity repair tailored to general-purpose Multimodal Large Language Models (MLLMs). This is the dataset repository for the paper "Breaking Bad Molecules: Are MLLMs Ready for Structure-Level Molecular Detoxification?".
The molecular toxicity repair task requires models to:
| Dataset | Task Type | # Molecules | Description |
|---|---|---|---|
| AMES | Binary Classification | 60 | Mutagenicity testing |
| Carcinogens | Binary Classification | 60 | Carcinogenicity prediction |
| ClinTox | Binary Classification | 60 | Clinical toxicity data |
| DILI | Binary Classification | 60 | Drug-induced liver injury |
| hERG | Binary Classification | 60 | hERG channel inhibition |
| hERG_Central | Binary Classification | 60 | Large-scale hERG database with integrated cardiac safety profiles |
| hERG_Karim | Binary Classification | 60 | hERG data from Karim et al. |
| LD50_Zhu | Regression (log(LD50) < 2) | 60 | Acute toxicity |
| Skin_Reaction | Binary Classification | 60 | Adverse skin reactions |
| Tox21 | Binary Classification (12 sub-tasks) | 60 | Nuclear receptors, stress response pathways, and cellular toxicity mechanisms (ARE, p53, ER, AR, etc.) |
| ToxCast | Binary Classification (10 sub-tasks) | 60 | Diverse toxicity pathways including mitochondrial dysfunction, immunosuppression, and neurotoxicity |
Each entry contains:
{
"task": "string", // Toxicity task identifier
"id": "int", // Molecule ID
"smiles": "string", // SMILES representation
"image": "binary" // 2D molecular structure image binary
}
subdatasets = [
"ames", "carcinogens_lagunin", "clintox", "dili",
"herg", "herg_central", "herg_karim", "ld50_zhu",
"skin_reaction", "tox21", "toxcast"
]
# Load all datasets
datasets = {}
for name in subdatasets:
datasets[name] = load_dataset("DeepYoke/ToxiMol-benchmark", data_dir=name)
Our systematic evaluation of ~30 mainstream MLLMs reveals:
If you use this dataset in your research, please cite:
@misc{lin2025breakingbadmoleculesmllms,
title={Breaking Bad Molecules: Are MLLMs Ready for Structure-Level Molecular Detoxification?},
author={Fei Lin and Ziyang Gong and Cong Wang and Yonglin Tian and Tengchao Zhang and Xue Yang and Gen Luo and Fei-Yue Wang},
year={2025},
eprint={2506.10912},
archivePrefix={arXiv},
primaryClass={cs.AI},
url={https://arxiv.org/abs/2506.10912},
}
This project is licensed under the MIT License - see the LICENSE file for details.