Epydemix Agent framework lets AI run epidemic models with less code
Driving Epidemic Models with AI Agents: the Epydemix Agent Framework
Artificial IntelligenceComputers and Society
Summary
Making epidemic models can be complicated because they often require programming skill. This paper describes the Epydemix Agent Framework, which helps AI agents understand and run these models using natural language instead of custom code. The framework adds features like checking inputs, running models safely, and saving detailed results so everything can be reviewed. It was tested in tasks like comparing vaccine plans and helped AI operate the models more efficiently and reliably. This makes interacting with complex epidemic simulations easier and more reproducible.
What this means in practice
- •For public health modeling teams: Run epidemic simulations through AI agents using natural language without writing code, enabling quicker scenario testing and reproducibility.
- •For software developers for scientific tools: Integrate AI-driven interfaces into epidemiological software to automate scenario creation, validation, and result interpretation without manual scripting.
Authors
Nicolò Gozzi, Ciro Cattuto, Alessandro Vespignani
Abstract
Artificial Intelligence agents based on large language models provide convenient natural language interfaces to scientific software, but reliability is not automatic. Here we introduce the Epydemix Agent Framework, an additive layer over Epydemix, an open-source Python library for stochastic compartmental epidemic modeling. The framework extends the library with four capabilities to facilitate interaction with an AI agent: discovery of available models and parameters, preventive validation of a declarative scenario specification, execution through tested library code, and inspectability of results. These capabilities let an agent handle the entire modeling process, from the natural-language description of the scenario to quantitative results, figures, and interpretation of findings without writing custom code. Each step reads input files and saves results in a separate output bundle, making the process auditable and reproducible. First, we show the end-to-end workflow with a case study comparing vaccination strategies for a novel respiratory virus. Second, we assessed the framework across 50 agent sessions and five modeling tasks by comparing the agent use of the framework against the direct use of the Python interface. The framework reduced turns, output tokens, and cost on most tasks, unless it trades resources for per-point reproducibility.