AI Workforce Simulator
A deterministic, reproducible discrete-event simulator that stress-tests staffing plans and demand before you touch a real contact centre.
Built by naman · AI Developer Intern

The system, up close
Real captures from the running system — the demo, screenshots and architecture come first, then the deep dive.
Screenshots
Architecture
.png)
Why this needed to be built
Contact-centre leaders need to test staffing plans, demand spikes and process changes, but doing it on a live floor is risky, expensive and slow.
Spreadsheet estimates can't capture queue dynamics, SLA erosion or utilization realistically, and never expose the assumptions behind the numbers.
What we built, and how it changes the workflow
We built a discrete-event simulation engine that models configurable virtual agents and replays demand scenarios deterministically — so plans can be compared side by side with full transparency.
A FastAPI backend runs a single-seeded RNG discrete-event engine: Poisson arrivals, priority+FIFO queue, worker assignment by skill/shift, log-normal processing times, Bernoulli errors and SLA measurement. The React dashboard visualizes throughput, SLA, utilization, backlog and time-series.
An optional OpenRouter-backed AI Analyst explains the pre-computed numbers only — it never generates or alters results. Every run is reproducible: same config + seed + version ⇒ identical output.
Core design principle
- The simulation engine is the single source of truth; the AI only explains, never invents numbers
- Every run records its seed, config and version for bit-for-bit reproducibility
- A full assumption inspector exposes every model input
What it can do
A focused set of capabilities that define the system — no marketable filler, only what actually runs.
Discrete-event engine
Deterministic, event-driven simulation with one seeded RNG per run.
Worker modeling
Per-agent skill, speed, error rate and shift availability.
Task & queue system
Poisson arrivals with priority + FIFO queue and configurable task types.
KPI metrics
Throughput, SLA compliance, error rate, utilization, backlog and time-series.
Scenario comparison
Side-by-side KPI deltas across competing configurations.
Validation suite
Edge cases: zero staffing, extreme demand, no demand, reproducibility, invalid input.
AI Analyst
Optional OpenRouter operational insight with graceful fallback.
The end-to-end workflow
The system processing path, in order.
- 1
Configure workforce
Set agents' skill, speed, error rate and shifts.
- 2
Set demand profile
Define arrival rate and task mix over the horizon.
- 3
Run simulation
The engine processes events deterministically to the horizon.
- 4
Compute KPIs
Throughput, SLA, utilization and backlog are measured.
- 5
Compare scenarios
Competing configurations are scored side by side with deltas.
- 6
Review & explain
The AI Analyst summarizes results; the assumption inspector shows all inputs.
Stack & tech choices
- Backend
- Python 3.11, FastAPI, Pydantic, NumPy, SQLAlchemy 2.0, aiosqlite
- Simulation
- Custom discrete-event engine
- Frontend
- React 19, Vite, Tailwind CSS, Recharts
- AI Analyst
- OpenRouter (optional, backend-only)
Tested, verified and honestly scoped
Validation & tests
A validation suite covers normal operation plus edge cases; reproducibility is verified by an automated same-seed test.
- Normal run: SLA ~95%, utilization 70–85% within limits
- Zero staffing: 0 completions, backlog grows, no crash / div-by-zero
- Extreme demand: backlog bounded by cap; no demand: all-zero metrics
- Reproducibility: identical results across runs with the same seed
Security & hardening
- No hardcoded secrets; .env excluded from Git
- API keys backend-only, never sent to the frontend
- Parameterized ORM queries; restricted CORS; sanitized AI payloads
Honest limitations
AI Workforce Simulator is an internally developed engineering prototype. We state limitations rather than overclaim production readiness.
- SQLite for the MVP (swap DATABASE_URL for production)
- Errors mark tasks done-but-failed (no auto re-queue)
- Staffing optimizer and Monte-Carlo sensitivity are future work
Deep-dive references
Where this can go next
Realistic next steps we've scoped — not aspirational marketing copy.
- Staffing optimizer (LP / heuristic solver)
- Monte-Carlo sensitivity analysis
- Historical calibration against real AHT / SLA data
- Live scenario tuning from the dashboard
- PDF report export
Have a similar workflow?
Zenera Labs can build a custom version for your business.
This is one of naman's internally developed systems. Tell us about your requirement and we'll scope a tailored build around it.
Other systems we've built internally

AI Contract Analysis & Risk Detection
Faster document review with traceable evidence — upload a contract and get risk findings with source-verified citations.
naman · Engineering Portfolio
View case study
SentinelAI — Security Log Anomaly Detection
Risk-scored alerts from security events — a full-stack Mini-SIEM with ML detection, attack-chain correlation and explainable alerts.
pragna · Engineering Portfolio
View case study
AI Data Analyst & Business Intelligence Agent
Evidence-grounded business intelligence from spreadsheets — upload CSV/XLSX, get analysis, visualizations and explained answers.
priyanka · Engineering Portfolio
View case study