SimulSI
Simulation Intelligence - Model the system. Simulate the future.
SimulSI is a general-purpose, reproducible simulation and scenario experimentation framework for Python. You describe a system - customers and tellers, patients and doctors, jobs and machines, aircraft and gates, requests and servers - as discrete-event processes; SimulSI runs it, measures it, and helps you answer what if? with replications, confidence intervals, scenario comparisons, Monte Carlo and sensitivity analysis.
from simulsi import Experiment, Scenario, Simulation, model
from simulsi.randomness import Exponential
@model(duration=480, parameters={"arrival_rate": 1.0, "tellers": 3})
def bank(sim: Simulation, p):
tellers = sim.resource("teller", capacity=p.tellers)
arrivals, service = sim.stream("arrivals"), sim.stream("service")
def customer(sim):
yield sim.request(tellers) # wait for a teller
yield Exponential(mean=2.6).sample(service) # being served
sim.release(tellers)
def source(sim):
while True:
yield Exponential(rate=p.arrival_rate).sample(arrivals)
sim.process(customer(sim))
sim.process(source(sim))
result = Experiment(
bank,
[Scenario("baseline"), Scenario("four_tellers", {"tellers": 4})],
replications=30,
seed=42,
).run()
print(result.format_summary(["resource.teller.wait.mean", "resource.teller.utilization"]))
print(result.compare("baseline", metrics=["resource.teller.wait.mean"]).format())
Why SimulSI?
Discrete-event engines tell you what happened in one run. Decisions need more: how sure are we, which scenario is better, which input matters most, and can someone else reproduce this? SimulSI is built experiment-first:
| Reproducible by construction | Every run is determined by its seed. Named random streams (sim.stream("arrivals")) are derived from the seed with NumPy's SeedSequence, so adding a resource never shifts another stream. Serial and parallel runs give identical numbers. |
| Scenario comparison | Scenarios share replication seeds (common random numbers) and comparisons use paired confidence intervals, which are usually much tighter than comparing independent runs. |
| Statistics built in | t and bootstrap CIs, Wilson intervals for probabilities, "have I run enough replications?" advice, convergence curves, batch means for long runs. |
| Monte Carlo & sensitivity | Propagate input uncertainty (random or Latin hypercube sampling, vectorised or per simulation run). One-at-a-time, finite-difference, correlation and standardised-regression sensitivity. |
| Provenance | Each experiment records id, model name/version, git commit, timestamp, seeds, parameters, runtime and environment. Results export to JSON, CSV and Parquet. |
| Model introspection | snapshot() of live state, structured event logs, observed flow graphs (arrival -> queue -> service -> departure), entity state machines, and model validation with a smoke run (unreleased resources, possible deadlocks, zero capacities, unreached states). |
| Decision support | Cost/revenue models on top of metrics; an Objective adapter that hands models to scipy.optimize, OR-Tools, evolutionary or Bayesian optimisers without depending on any of them. |
| Local-first | No LLMs, API keys, telemetry or network access. Core dependencies: NumPy, SciPy, pydantic, PyYAML. Plotting, pandas, Parquet and the web dashboard are optional. |
SimulSI is not a replacement for mature engines such as SimPy or Salabim, or for commercial packages; see how SimulSI differs.
Installation
Python 3.11+, from PyPI:
pip install simulsi # core (includes the CLI and the web dashboard)
pip install "simulsi[viz]" # + matplotlib plots
pip install "simulsi[all]" # + pandas, Parquet, matplotlib, Plotly
With Docker (dashboard and CLI, no Python needed; the image is published for each release):
docker run --rm -p 127.0.0.1:8642:8642 ghcr.io/yashjindal11/simulsi # dashboard on http://localhost:8642
docker run --rm -v "$PWD:/work" ghcr.io/yashjindal11/simulsi run model.py # any CLI command
From source (for development):
git clone https://github.com/Yashjindal11/simulsi.git && cd simulsi
python -m venv .venv
.venv/bin/pip install -e ".[dev]" # everything needed to run the tests
Command line
simulsi init my-study # starter model.py + experiment.yaml
simulsi validate my-study/experiment.yaml # schema check + model smoke run
simulsi run examples/queue.py -p servers=3 # one replication, metrics table
simulsi experiment my-study/experiment.yaml # scenarios x replications, comparison, saved results
simulsi analyze my-study/results/service-desk --precision 0.05
simulsi visualize my-study/results/service-desk --out plots
simulsi models # built-in models and their what-if presets
simulsi whatif builtin:epidemic --presets # how outputs change across scenarios
simulsi benchmark # events/sec on this machine
simulsi ui my-study/results/service-desk # local dashboard on 127.0.0.1
Experiments are described in YAML - data only, validated against a strict schema:
model: model.py:service_desk
simulation: {seed: 42, duration: 480}
experiment: {replications: 30, workers: 4}
parameters: {arrival_rate: 0.9}
scenarios:
- {name: high_demand, parameters: {arrival_rate: 1.3}}
- {name: extra_server, parameters: {servers: 3}}
Built-in models
Seven ready-to-run models, each with what-if presets that show how the system reacts when a parameter changes:
| Model | What changes when you turn the knobs |
|---|---|
builtin:airline |
schedule buffer, crews, gates, spares and storms vs on-time performance and delay propagation |
builtin:epidemic |
R0, vaccination, beds and lockdown policy vs attack rate, hospital overflow and deaths |
builtin:supply_chain |
lead times, forecasting and information sharing vs the bullwhip effect |
builtin:ride_hailing |
fleet size, rush hours and surge pricing vs service level and driver earnings |
builtin:cloud_autoscaling |
cold starts, scaling policy and traffic bursts vs SLO, errors and cost |
builtin:traffic_signal |
cycle length, green split, fixed vs actuated control (checked against Webster) |
builtin:mmc |
the M/M/c queue (checked against Erlang C) |
simulsi models airline # parameters and presets
simulsi whatif builtin:airline --presets # compare every preset
simulsi whatif builtin:traffic_signal --vary cycle=30,60,90,120
See the model gallery for what each one shows.
Examples
| Example | Shows |
|---|---|
queue.py |
Minimal M/M/c model checked against Erlang C |
bank_queue.py |
Reneging customers, staffing scenarios, replication advice |
hospital.py |
Priority triage, several resources, service levels |
warehouse.py |
Time-varying demand, picking/packing buffers, backlog |
manufacturing.py |
Breakdowns with a repair crew, blocking, cost model |
transportation.py |
Shuttle loop, boarding capacity, left-behind passengers |
aviation.py |
Synthetic airport gates, taxiway holds, tows, weather disruption |
python examples/hospital.py
python scripts/run_examples.py # all of them, quick mode
Documentation
The full documentation, including an API reference for every public class
and function, is at https://yashjindal11.github.io/simulsi/. The same
pages are in docs/:
- Getting started - installation, quickstart, first experiment
- Core concepts - simulation, events, entities, resources, queues, processes, randomness, metrics, disruptions, validation, introspection
- Experiments and analysis - scenarios, experiments, Monte Carlo, statistics, variance reduction, comparison, sensitivity, ranking and selection, cost, optimisation, surrogates
- Visualization - plots, HTML reports, notebooks and the web dashboard
- CLI and configuration
- Architecture - design, module map, performance, limitations
- Extending SimulSI
- Research workflow - reproducibility, provenance, statistical practice
- Built-in model gallery - airline, epidemic, supply chain, ride hailing, cloud, traffic, M/M/c
- Examples and notebooks - walkthroughs of the domain examples and tutorial notebooks
- Coming from SimPy - concept map and a side-by-side port
- FAQ - including how SimulSI compares with other tools
- Benchmarks - measured numbers and how to reproduce them
Status
SimulSI is alpha software (0.x) and the API may still change. It is tested on Python 3.11-3.13 (Linux, macOS, Windows in CI) with unit, property-based (Hypothesis), statistical, integration, CLI and performance tests - including checks of simulated M/M/c queues against closed-form Erlang-C results.
Contributing
Issues and pull requests are welcome - see CONTRIBUTING.md and the Code of Conduct. For security reports see SECURITY.md.
License
MIT © 2026 Yash Jindal
Metadata
Release files for simulsi 0.5.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| simulsi-0.5.0.tar.gz | 310.1 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| simulsi-0.5.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 574.7 kB
Release files / simulsi-0.5.0.tar.gz
| Download URL | simulsi-0.5.0.tar.gz |
|---|---|
| Size | 310.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
b89cf79487b2ed3751d2c66f452eef8ada3c84b4666edf29591b52739c951fcb
|
|
BLAKE2b-256 checksum How to use checksums |
3b29e2837533b4ffa1b8413ed1a76cb3bb8cab788fe4a364b5498f8f7cdf47a8
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 7, 2026.
Transparency logRelease files / simulsi-0.5.0-py3-none-any.whl
| Download URL | simulsi-0.5.0-py3-none-any.whl |
|---|---|
| Size | 264.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
71312a992f5d89f3aa7a52e27e4feaca8d01d1779dc9c9cf30e909a6628c9848
|
|
BLAKE2b-256 checksum How to use checksums |
2487e490ecfeef5fba8b8b8402471658cef74a98884a4173d39449713b413fec
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 7, 2026.
Transparency log