llm_simpy_models

The SimPy models and apps generated by LLMs, deployed as a single app.

https://github.com/pythonhealthdatascience/llm_simpy_models

Science Score: 67.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
    Found CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
    Found 5 DOI reference(s) in README
  • Academic publication links
    Links to: zenodo.org
  • Academic email domains
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (12.9%) to scientific vocabulary
Last synced: 4 months ago · JSON representation ·

Repository

The SimPy models and apps generated by LLMs, deployed as a single app.

Basic Info
Statistics
  • Stars: 1
  • Watchers: 1
  • Forks: 0
  • Open Issues: 0
  • Releases: 3
Created 10 months ago · Last pushed 10 months ago
Metadata Files
Readme Changelog License Citation

README.md

Licence: MIT Python 3.10+ DOI

Complementary repository: Final discrete-event simulation models and streamlit applications from Large Language Models

This repository is complementary to:

Thomas Monks, Alison Harper, and Amy Heather. Research Compendium: Replicating Simulations in Python using Generative AI. https://github.com/pythonhealthdatascience/llm_simpy.

It contains the final formatted code from each of the SimPy discrete-event simulation models that were generated by Perplexity as part of that project.

The web applications are deployed as a single app on GitHub pages using stlite. This allows the app to run directly in a user's web browser without requiring any manual installations. It achieves this by using WebAssembly technology to run a serverless version of streamlit (i.e. stlite). The entire app, along with all its dependencies, are downloaded and installed within the browser at runtime using pyodide and micropip. There will be a short wait while the app is setup. Once the setup is complete, the app runs locally in the browser, meaning that no user data leaves the local machine. Please note that stlite does not currently work in Mozilla Firefox.

Link to the deployed app: https://pythonhealthdatascience.github.io/llmsimpymodels/

Code: The final formatted code from each stage are stored in 📁pages\:

  • CCU_Stage_1.py
  • CCU_Stage_2.py
  • Stroke_Stage_1.py
  • Stroke_Stage_2.py

The stroke .py files combine the seperate model and app .py files from the llm_simpy repository.

For a full record of the generation of these models, please refer to: https://github.com/pythonhealthdatascience/llm_simpy.


👥 Authors

  • Thomas Monks    ORCID: Monks

  • Alison Harper    ORCID: Harper

  • Amy Heather    ORCID: Heather


🌐 Creating the environment

The project uses conda to manage dependencies. Navigate your terminal to the directory containing the code and run:

conda env create -f binder/environment.yml

This will create a conda environment called gen_simpy_apps. To activate:

conda activate gen_simpy_apps

This environment is a simplified version of that from the llm_simpy repository, containing only the dependencies required for running the apps.


🖥️ Viewing the apps locally

For deployment, we have brought the LLM-generated apps together into a single app, which can be deployed by running:

streamlit run Home.py

However, you can also run the individual original apps generated by the LLMs by calling on a specific file - for example:

streamlit run pages/CCU_Stage_1.py

To test the stlite app locally, run the following command, and then open http://0.0.0.0:8000/ on your web browser:

python3 -m http.server


📝 Citation

Please cite the archived repository:

Thomas Monks, Alison Harper, and Amy Heather. Complementary repository: Final discrete-event simulation models and streamlit applications from Large Language Models. https://doi.org/10.5281/zenodo.15082494.

You can also cite this GitHub repository as:

Thomas Monks, Alison Harper, and Amy Heather. Complementary repository: Final discrete-event simulation models and streamlit applications from Large Language Models. https://github.com/pythonhealthdatascience/llm_simpy_models.

A CITATION.cff file is also provided.


💰 Funding

This project was developed as part of the project STARS: Sharing Tools and Artefacts for Reproducible Simulations. It is supported by the Medical Research Council [grant number MR/Z503915/1].

Owner

  • Name: pythonhealthdatascience
  • Login: pythonhealthdatascience
  • Kind: organization

Citation (CITATION.cff)

# This CITATION.cff file was generated with cffinit.
# Visit https://bit.ly/cffinit to generate yours today!

cff-version: 1.2.0
title: >-
  Complementary repository: Final discrete-event simulation models and
  streamlit applications from Large Language Models
message: >-
  If you use this software, please cite it using the
  metadata from this file.
type: software
authors:
  - given-names: Thomas
    family-names: Monks
    orcid: 'https://orcid.org/0000-0003-2631-4481'
    affiliation: University of Exeter
    email: t.m.w.monks@exeter.ac.uk
  - given-names: Alison
    family-names: Harper
    affiliation: University of Exeter
    orcid: 'https://orcid.org/0000-0001-5274-5037'
    email: a.l.harper@exeter.ac.uk
  - given-names: Amy
    family-names: Heather
    email: a.heather2@exeter.ac.uk
    affiliation: University of Exeter
    orcid: 'https://orcid.org/0000-0002-6596-3479'
repository-code: 'https://github.com/pythonhealthdatascience/llm_simpy_models'
abstract: >-
  The SimPy models and apps generated by LLMs, deployed as a single app.
license: MIT
version: '1.0.2'
date-released: '2025-03-25'

GitHub Events

Total
  • Release event: 2
  • Public event: 1
  • Push event: 6
  • Create event: 2
Last Year
  • Release event: 2
  • Public event: 1
  • Push event: 6
  • Create event: 2

Issues and Pull Requests

Last synced: 10 months ago

All Time
  • Total issues: 0
  • Total pull requests: 0
  • Average time to close issues: N/A
  • Average time to close pull requests: N/A
  • Total issue authors: 0
  • Total pull request authors: 0
  • Average comments per issue: 0
  • Average comments per pull request: 0
  • Merged pull requests: 0
  • Bot issues: 0
  • Bot pull requests: 0
Past Year
  • Issues: 0
  • Pull requests: 0
  • Average time to close issues: N/A
  • Average time to close pull requests: N/A
  • Issue authors: 0
  • Pull request authors: 0
  • Average comments per issue: 0
  • Average comments per pull request: 0
  • Merged pull requests: 0
  • Bot issues: 0
  • Bot pull requests: 0
Top Authors
Issue Authors
Pull Request Authors
Top Labels
Issue Labels
Pull Request Labels

Dependencies

requirements.txt pypi
  • matplotlib ==3.8.1
  • numpy ==1.26.0
  • pandas ==2.1.3
  • pip ==23.3.1
  • sim-tools ==0.5.0
  • simpy ==4.1.1
  • streamlit ==1.34.0
binder/environment.yml conda
  • matplotlib 3.8.1.*
  • numpy 1.26.0.*
  • pandas 2.1.3.*
  • pip 23.3.1.*
  • python 3.10.13.*
  • sim-tools 0.5.0.*
  • simpy 4.1.1.*
  • streamlit 1.34.0.*