Inspiration

Wildfires are no longer a "California problem", but they're a recurring national crisis. When a fire breaks out, the people in the Incident Command tent have to make life-or-death decisions in minutes: where to evacuate, which roads will choke, where to stage engines, when to cut a dozer line, and what to tell the public. That coordination happens across a half-dozen specialized roles speaking different professional languages, such as fire behavior, traffic engineering, resource logistics, and public information.

We were inspired by the Incident Command System (ICS) itself: the idea that complex disasters are managed by a team of specialists coordinated through structured radio traffic. Modern AI is finally good enough to simulate that whole team. Instead of one monolithic chatbot, we built seven coordinated agents that mirror real ICS roles, talking to each other over a virtual radio net while a physics engine simulates the fire underneath them.

What it does

PyroTech is a real-time wildfire incident command simulation and decision-support platform. You pick any city in the world, drop a fire ignition point, set the weather, and watch a full multi-agency response unfold on a 3D map:

  • Physics-informed fire spread: vector-based elliptical growth driven by wind, humidity, temperature, with head/flank/back fire sectors
  • Seven specialized Gemini agents: Disaster, Evacuation, Resource, Infrastructure, Communications, Congestion, and Synthesis — streaming radio-style transmissions and a structured map events
  • Live evacuation traffic: ~180 ambient particles flowing on the real OSM road graph, with congestion that reacts to fire proximity and auto-closes routes
  • Resource deployment with real suppression geometry: engines and dozers actually carve suppression zones into the fire perimeter (dozer firebreaks are now hard-stop barriers per recent
    commits)
  • What-if branching: fork the timeline at any tick to test "what if the wind shifts?" or "what if we pre-stage south?"

How we built it

Stack: Next.js 16 + React 19 + TypeScript + Mapbox GL v3 + deck.gl v9 on the frontend; Node 20 + Express 5 + WebSocket + Google Gemini on the backend.
Architecture:

  • Dual-loop simulation in backend/orchestration/turnSequencer.js: physics ticks every 500ms (smooth visuals), agent cycle every 30 logical minutes (~10s real-time)
  • Agent system in backend/agents/: each agent streams prose + JSON map events via Gemini streaming. A conflictDetector flags contradictions (e.g., Evac orders a route Infra says is downed), and the SynthesisAgent resolves them into an Incident Action Plan
  • Physics modules: wildfireEngine.js (elliptical growth), suppressionProbe.js (dozer/engine geometry), trafficModel.js (route congestion), particleEngine.js (ambient vehicles),
    resourceModel.js
  • Real geospatial data: OSM Overpass for roads/buildings/hospitals, NASA FIRMS for live fire pixels, Census for population density, all stitched with turf.js polygon intersections
  • State + branching: StateManager keeps a canonical event log, so any tick can be forked

Challenges we ran into

One of the most significant challenges was replicating the realism during a wildfire. We spent many hours refining the dozer and firefighter process. Furthermore, we came across many issues with rendering and optimizing the map, especially given the sheer volumes of data we were required to process, as well as the number of components rendered at any given moment. A large chunk of time was spent optimizing the camera operations, such as zooming in and out, changing the angle, and ensuring consistency of the wind. Finally, we ran into issues with the ElevenLabs integration, as we had to consider syncing the text-to-speech with the agent transmissions and guarantee no agents spoke over each other.

Accomplishments that we're proud of

We were especially proud of completing such a large-scale project within the 36-hour timeline, achieving a technical complexity that none of us had achieved before. As described above (and then some), we ran into many challenges. However, working through each of these as a team allowed us to build this project in a timely manner, while simultaneously granting us the satisfaction of solving problems as a unit. From coordinating system design to implementing each individual feature to filming the demo video, we are most proud of being able to crank out this project over this weekend (while still being able to sleep!).

What we learned

  • A single LLM is the wrong shape for complex domains. The win came from giving each agent a narrow, opinionated role and forcing them through a synthesis step. Conflicts between agents are a feature, as they surface real trade-offs.
  • Physics and AI must be coupled, not stacked. Early on, suppression was a post-hoc subtraction from the fire polygon, which caused unrealistic "catch-up" jumps. We had to fold suppression into the perimeter calculation itself (and most recently made dozer barriers true hard-stops).
  • Real-time UX is a systems problem, not a frontend one. Getting 500ms physics ticks, 10s agent cycles, WebSocket fan-out, and deck.gl layer reducers to feel cohesive required treating the whole pipeline as one product.
  • Design discipline pays off under information density. A war-room dashboard with 11+ map layers only works because every color has a strict semantic meaning (red=fire, blue=movement, green=safe) and the type system is constrained.
  • Geospatial integration is most of the work. Polygon intersections, road graph traversal, and live data from Overpass/FIRMS/Census were both harder and more valuable than the LLM prompts.

What's next for PyroTech

In the future, we have multiple features planned. Here are some:

  • Aerial assets: helicopters and air tankers with retardant drops as time-decaying suppression geometry
  • Structure-level damage: track per-building ignition risk so the headline metric becomes homes saved, not just acres
  • Weather forecast timeline: replace static wind with a forecast curve so agents have to plan for shifts, not just react
  • Replay & after-action review: timeline scrubber, branch comparison, exportable AAR reports for fire academies and EOCs
  • Voice radio net: Whisper STT + existing ElevenLabs TTS so commanders actually talk to the agents
  • Conflict-resolution ledger: surface the existing conflict/synthesis pipeline as a visible audit trail for every IAP decision
  • Live-incident advisor mode: pivot from simulation to real-time decision support using FIRMS, CAL FIRE, and PurpleAir feeds
  • Historical fire validation: replay Palisades, Camp, Lahaina to measure accuracy and earn agency trust
  • General disaster engine: swap the physics module to extend the same agent orchestration to floods, hurricanes, and hazmat

Built With

Share this project:

Updates