Sources used:
https://ethereum-economic-model.cadlabs.org/ASSUMPTIONS.html
https://ethereum-economic-model.cadlabs.org/docs/model_specification/mathematical_specification.html
This repository is organized as two separate Docker Compose services:
simulator/is the modern Python environment for Hoodi analytics, plots, and custom staking-simulator logic.cadlabs/is a separate container for the CADLabs Ethereum Economic Model and must keep its own virtualenv, requirements flow, and notebook-oriented workflow.
repo-root/
compose.yaml
.env.example
README.md
simulator/
Dockerfile
requirements.txt
test.py
fetch_hoodi.py
live_dashboard.py
live_dashboard_data.py
output/
cadlabs/
Dockerfile
entrypoint.sh
notebooks/ (for local experimentation)
shared/
output/
data/
shared/ is the host-mounted exchange area for CSV, JSON, and plots produced by either container.
From the repo root, with .env and pool_config.yaml already in place:
./build.sh
docker compose up --build simulatorOpen:
http://localhost:8501
Stop the live instance with Ctrl+C, then:
docker compose downBootstrap the whole workspace, including the first CADLabs clone/install flow:
./build.shLaunch the live Streamlit dashboard on localhost:
docker compose up --build simulator
docker compose up --build simulatorThen open:
http://localhost:8501
Run the simulator smoke test explicitly:
docker compose run --rm simulator python -m simulator.testFetch optional Hoodi read-only data:
docker compose run --rm simulator python simulator/fetch_hoodi.pyOutputs are written to /app/shared/output and /app/shared/data inside the container, which map to shared/output and shared/data on the host.
The simulator service also mounts the repo into /app, so the dashboard sees local code and pool config changes immediately.
The CADLabs container clones the model repository at runtime, creates its own virtual environment, and installs the model using its own requirements workflow:
docker compose run --rm cadlabsYou can override the upstream repo and branch through environment variables in .env.
Start the localhost dashboard service:
docker compose up --build simulatorThe Compose file intentionally keeps separate images and Dockerfiles for simulator and cadlabs so the environments stay independent even though the simulator container now mounts the repo for local dashboard development.
The simulator service now includes a Streamlit webapp that layers a live UI over the existing pool_tracker backend for Ethereum Hoodi.
- reads validator balances and status from the Hoodi Beacon API
- aggregates validator-centric balances into pool-level NAV and PnL
- stores per-epoch validator and pool snapshots in SQLite