Back

Using large language models for enhancing accessibility for Monte Carlo photon transport simulations and beyond

Yen, F.-Y.; Liu, Y.; Fang, Q.

2026-07-21 bioengineering
10.64898/2026.07.20.738933 bioRxiv
Show abstract

SignificanceComputational modeling and the use of simulation software tools are essential for biomedical optics research. Designing effective simulations often requires in-depth understanding of the underlying physical problems and proper configuration of the software settings, which often constitute key barriers for novice users including students. The rapid emergence of large language models (LLMs) offers new opportunities for natural-language-based interaction, but integrating them with technical software remains challenging because of their limited output reproducibility. Overcoming these limitations would allow more intuitive, efficient, and reproducible interaction between scientists and scientific software. AimWe investigate the use of LLMs in quantitative biophotonics simulation tools, with a goal of enabling novice users to build complex photon simulations using intuitive natural-language-based problem descriptions. ApproachWe have explored prompt engineering strategies that enable LLMs to bridge the gap between natural language descriptions and advanced simulation software by constraining LLM outputs using a data schema (i.e., format) and a modular component architecture, followed by deterministic validation to ensure correctness and reproducibility of the outputs. ResultsUsing Monte Carlo eXtreme (MCX) - a widely used photon transport simulator - as an example, we showcase the capability of the proposed framework to convert user descriptions to structured simulation inputs. Benchmarked using 33 diverse natural language simulation descriptions, our LLM interface, MCX-LLM, achieves 98% accuracy and 99% repeatability, with an average processing time of 8.96 seconds per prompt. The framework also successfully handles various linguistic styles and diverse simulation settings, achieving a 100% success rate on 20 unconstrained real-world prompts. With only minor adjustments, our LLM interface also produces valid inputs for a finite-element-based diffusion solver to demonstrate generality towards other optical simulators. ConclusionsBy combining LLMs capability for textual data comprehension with structured constraints, this work provides a pathway to making complex scientific tools accessible while ensuring the reliability and technical correctness required for rigorous scientific research. MCX-LLM has been integrated with MCX Cloud accessible at https://mcx.space/cloud.

Matching journals

The top 11 journals account for 50% of the predicted probability mass.

50% of probability mass above

"Similar papers" are the closest papers from that journal in the model's embedding space. They show what the match is built on, but the ranking comes mostly from a classifier over the whole training set, not from these examples alone.