MCP Server Experiment Notes - laser-base/laser-measles GitHub Wiki
Decision: We will run 2 MCP servers, 1 that just knows about laser-core and one that just knows about laser-measles.
For each MCP server, we need:
- Dockerfile
- ingest.py -> vector_store
- main.py
- Generate vector store by running (a version of)
ingest.py - Build and run MCP server in docker via
docker-compose up -d
Because our docker-compose.yml files is:
services:
laser-mcp:
build:
context: .
dockerfile: Dockerfile
container_name: laser-mcp-test
ports:
- "8088:8000"
env_file:
- .env
restart: unless-stopped
volumes:
- ./vectorstore:/app/vectorstore
healthcheck:
test: ["CMD", "python", "-c", "import requests; requests.get('http://localhost:8000/health')"]
interval: 30s
timeout: 10s
retries: 3
start_period: 10s
laser-measles-mcp:
build:
context: .
dockerfile: Dockerfile.measles
container_name: laser-measles-mcp
ports:
- "8089:8000"
env_file:
- .env
restart: unless-stopped
volumes:
- ./vectorstore_measles:/app/vectorstore
healthcheck:
test: ["CMD", "python", "-c", "import requests; requests.get('http://localhost:8000/health')"]
interval: 30s
timeout: 10s
retries: 3
start_period: 10s
And we then observe:
docker container ps
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
87f88fb0d167 laser-mcp-laser-mcp "python main.py" 3 days ago Up 3 days (healthy) 0.0.0.0:8088->8000/tcp laser-mcp-test
7aee67a32a48 laser-mcp-measles:latest "python main.py" 3 days ago Up 3 days 0.0.0.0:8001->8000/tcp laser-mcp-measles
Configure mcp servers like this:
$ claude mcp add jenner-core-mcp --transport http "http://localhost:8088/mcp"
$ claude mcp add jenner-mcp --transport http "http://localhost:8001/mcp"
Notes:
- This is for a locally running mcp server. We want to run them in some remote service, at least in AKS, but that's future.
- All attempts to get claude code to configure itself correctly with mcp services failed.
-
jenner-mcpis the laser-measles JENNER.jenner-core-mcpis the laser-core JENNER. Naming things well is hard.
❯ Using python3.11 and /var/opt/idm/venv_measles and the MCP server available to you, build up a series of progressively more interesting working laser-measles models. Do not rummage around on local disk for information outside of the pwd.
Perfect! I've successfully built 5 progressively more interesting LASER-measles models using the MCP server tools. Here's what was created:
📊 Model Series Summary
✅ Model 1: Simple Single-Patch SEIR
- Type: Compartmental (deterministic)
- Features: Basic SEIR dynamics, 100K population, R₀=15
- Result: 100% attack rate, peak at day 35, classic epidemic curve
- Runtime: ~0.1s
✅ Model 2: ABM with Age Structure
- Type: Agent-Based (stochastic)
- Features: 50K individual agents, vital dynamics, stochastic transmission
- Result: 86% attack rate, highly variable epidemic pattern
- Runtime: ~4s
✅ Model 3: ABM with Vaccination
- Type: Agent-Based with routine immunization
- Features: Compares 4 MCV1 coverage levels (0%, 50%, 80%, 95%)
- Result: Demonstrates vaccination infrastructure (limited 1-year impact)
- Runtime: ~0.5s
✅ Model 4: Multi-Patch Spatial Model
- Type: Compartmental with 9 spatial patches
- Features: Urban center + suburbs + rural areas, gravity mixing
- Result: Beautiful spatial spread visualization, wave propagation from center
- Key Finding: Distance vs arrival time shows linear relationship (2.3 days/unit)
- Runtime: ~0.1s
✅ Model 5: Spatial Interventions
- Type: Compartmental spatial with intervention comparison
- Features: 3 scenarios - baseline, urban vaccination (60%), reduced mixing (50%)
- Result: Urban vaccination reduces peak by 21%, averts 877 cases
- Runtime: ~0.2s
📁 All Files Generated
- 5 Python scripts (working models)
- 5 PNG visualizations (publication-quality plots)
- 5 CSV result files (time series data)
- 1 comprehensive README.md (documentation)
🎯 Key Concepts Demonstrated
1. Compartmental vs ABM - Deterministic vs stochastic approaches
2. Spatial structure - Gravity-based mixing, wave propagation
3. Interventions - Pre-outbreak vaccination and mobility reduction
4. Visualization - Multi-panel comparisons, spatial maps
5. MCP integration - Used search tools to learn LASER API
All models use python3.11 and the specified venv, with no local disk exploration outside the working directory!
- Models 1, 4 and 5 looks great. 2 and 3 seem wrong.