MIGO (Miagao Incident Gateway for Operations) is an incident intake system for the Municipal Disaster Risk Reduction and Management Office (MDRRMO) of Miagao, Iloilo.
Residents report through Messenger or a web form and get a tracking link back. Responders see reports live, correct them, and send advisories to the barangays that need them.
I lead the team building it and own report intake. It grew out of Project HERMES, a hackathon prototype. MIGO is the version we plan to deploy.
Why we built it
MDRRMO’s biggest gap isn’t response. It’s communication with the barangays.
Reports arrive by call, Messenger, SMS, radio and word of mouth, each in a different format. All of it gets re-typed into spreadsheets by hand, and residents never know if their report landed.
The reports themselves are messy. People write the way they talk, in Hiligaynon, Kinaray-a, Tagalog or English, often mixed together. In areas with poor signal, they ask someone else to relay the message.
Building it with the office
We treated MDRRMO as a client to build with, not a source of requirements to collect once.
Before proposing anything, we had them walk us through a report from the first call to the final logbook entry. Then we showed them HERMES. Their feedback reshaped the scope right away: they wanted more detail about the people hurt and the person reporting, and suggested barangay officials use the bot too.
We turned those conversations into requirements and brought them back for the office to check. Since then, we’ve kept returning with progress, so problems surface while they’re still cheap to fix.
AI in a system that can’t afford to be wrong
An LLM is good at exactly this kind of mess. But a wrong answer here can send a team to the wrong place.
The office had already solved that. They validate every report by sending a team and calling around before acting. They assume any report might be wrong.
So that became the rule for the AI: it can save people time, but it never decides anything.
- It only fills in fields. It never validates a report or decides who responds.
- It only fills what it’s sure of. Everything else gets asked.
- If it fails, nothing breaks. Reports still come in, just with more questions.
- People have the final say. Every correction is recorded next to what the model said.
How it turned out
A resident’s first message becomes a report right away, so it reaches responders even if they stop replying. MIGO reads what it can from that message, then asks only for what’s missing.
Responders get a live feed, a map, and a queue of reports that need attention. Each report shows the resident’s own words next to what MIGO extracted, so responders can compare, fix, and move it along.
How we built it
| Frontend | React + TanStack Router + Tailwind |
| Backend | NestJS + PostgreSQL/PostGIS |
| Chat | Vercel Chat SDK (Messenger) |
| AI | Vercel AI SDK + Gemini |
Confidence per field, not per report
The model returns each field with its own confidence instead of one guess for the whole report. Confident fields get filled, and the bot asks for the rest.
That way, one bad guess, like a misread location, doesn’t ride along with the good ones. A good parse just means fewer questions.
Uncertainty is visible
The confidence is saved with the report. Reports the model was unsure about get flagged for attention, so responders know what to check first.
The model is optional
If the model is slow, fails, or is turned off, the bot simply asks every question itself.
The same goes for the whole system. Every bot message includes the hotline, and both channels share one pipeline. If any part goes down, residents can still reach a person.
What I learned
Adding an LLM to an app is easy. In a critical system, the hard part is deciding what happens when it’s wrong, and making that path just as good as the one where it’s right.
That design didn’t come from us, though. MDRRMO already worked that way. We only saw it because we went to their office and listened first.
