Inspiration
Bengaluru was built around hundreds of man-made tanks (kere), linked by channels that carried rainwater from one to the next. As the city grew, many were drained and built over. The best-known example sits at the city's heart: Majestic, Bengaluru's main bus station, stands on the bed of the old Dharmambudhi tank.
Those former lake beds are still low ground, and water still finds them in heavy rain. But nothing in a property listing or a map app tells you that a street was once a lake. The evidence is in old maps, which are public domain but impossible to read against today's streets. We wanted to make that history checkable in ten seconds, by anyone, for any address.
The Frankenstein category fit perfectly: stitch a 1914 map onto a modern vector map and bring the dead lakes back as ghosts.
What it does
- Summoning intro. The map opens in fog, and 11 lost lakes materialise one by one.
- Search any address, or tap a preset like Majestic. The map flies there, a sonar ping finds the nearest traced lake, and a card answers plainly: on, near or not near a former lake bed, or not traced yet when the old map doesn't cover that spot.
- Slide back in time. Drag from 2026 to 1914 and the sepia 1914 map fades in under today's streets, pinned where it was georeferenced. The glowing halos sit on the old blue tanks.
- Rain haunting. The next three days of rain for the selected place, using IMD categories. When heavy rain is forecast, the ghost lakes stir, with a link to the official forecast.
- Neer, the lake ghost. An original water-drop ghost guides you through loading, empty and error states with a joke and a next step, but never appears over a verdict.
- How we know. The method, the alignment error, every source and licence, a Trace your city guide, and links to the Kiro specs and build log.
Honest by design
The app never says "will flood", "unsafe", "illegal" or "encroached", and a property test checks every string it can show. Distances are rounded and prefixed "about". Lake edges are soft halos, never hard lines. Every result shows how far off the old map may be, and that number is computed, not typed in:
$$ \text{alignment error} = \sqrt{\frac{1}{n}\sum_{i=1}^{n} r_i^{2}} \times s $$
where \( r_i \) is each control point's residual in pixels and \( s \) is the ground size of one pixel at the map's centre. For our six control points, about 24.5 px × 2.7 m/px gives about 66 m. When a place is closer to a lake than that, the app says "within the old map's margin of error" instead of quoting a false-precise distance.
How we built it
- Found the map: a 1914 Bangalore city map by Wagner & Debes, Leipzig (from Baedeker's Indien), public domain on Wikimedia Commons.
- Georeferenced it in QGIS by matching landmarks that survive in both maps: City Station, the Race Course, Lalbagh, Holy Trinity Church, Bangalore Palace and St Andrew's Kirk, with a Helmert transform.
- Traced 11 tanks by hand, each with a name, a confidence level and whether it still holds water today, plus a coverage polygon marking exactly which area the map checked.
- Built a tested data pipeline in TypeScript. It validates the GeoJSON, computes lake areas, the map's corners from the world file and the alignment error from the control points. Two runs give byte-identical output.
- Built the app with Vite, React and TypeScript, MapLibre GL JS on OpenFreeMap tiles, turf.js for every distance, Nominatim for search and Open-Meteo for rain. No backend, no API keys, hosted on Netlify.
How we used Kiro
I'm a designer, not a GIS engineer. Kiro's spec-driven mode is what made a geometry-heavy app buildable in four days: every rule about coordinates, distances and honesty was written down before any code, and then tested.
- Specs (requirements → design → tasks): full specs for the
data-pipelineand theghost-mapapp, every task traced to numbered EARS acceptance criteria. - Steering in all three modes:
- Always:
data-honesty.mdbans alarming words;git-workflow.mdmakes Kiro commit after every task. - fileMatch:
geo-conventions.mdenforces[lng, lat], metres and turf-only maths on geometry files;design.mdcarries the visual direction for UI files. - Manual:
#project-briefpulls in the whole brief on demand.
- Always:
- Hooks: lint on save, rebuild the data when a traced lake is saved, run tests, and log every finished task.
- Property-based testing: 13 fast-check properties, including the world-file round trip, "distance is zero only inside a lake", reorder invariance, reproducible builds, "every system state has a next action", "no copy contains a banned phrase" and "more rain never gives a lower category".
- Parallel task execution: sub-agents ran tasks side by side, each ending in its own Conventional Commit with lint, type check and tests passing.
- Build log:
docs/kiro-log.mdhas one row per task, with a "Surprise" column.
The result: 760+ tests, a byte-reproducible data pipeline, and over 100 small commits you can read in order.
Where Kiro surprised us
- It broke its own property test, on purpose. 80,000 random cases passed "distance grows as you move away from a lake". Then Kiro hand-built a 4 km square lake and showed the rule fails: turf measures to great-circle arcs, which bow a few centimetres outside GeoJSON's straight edges. It stopped and asked instead of weakening the test. We capped generated edges at 1.4 km (our longest real edge is 711 m) and documented the limit.
- It found a turf edge case: a point exactly on a lake's hole edge got about 5 mm instead of 0 m.
- It caught floating-point rounding:
Math.round(x * 100) / 100turns 0.285 into 0.28, because the double is really 0.28499… - It refused to bend the data. Two demo presets came out "near", not "on" (Majestic is 6.8 m from the traced edge). Kiro reported it instead of nudging coordinates, exactly as our honesty steering asked.
Challenges
- Lining up a 112-year-old map. Our first fit was off by up to 500 m. Some landmarks had moved, and one (Vidhana Soudha) didn't exist until the 1950s. Keeping only the points that agreed with each other brought the error down to about 66 m.
- Saying something useful without scaring people. "Near a former lake bed" must never read as "your house will flood".
- Tests don't replace looking. 704 tests passed while the live map was completely blank: MapLibre's worker file failed to load under Vite. One look in a real browser found it in seconds.
What we learned
- Specs are where the hard thinking happens. Writing "a point outside the traced area must say not traced yet, never not near" prevented the most misleading answer the app could give.
- Property tests find edge cases nobody writes by hand: great-circle arcs, hole edges, float rounding.
- Honesty can be engineered: steering files and tests, not a disclaimer page.
What's next
- Trace your city: the repo includes a step-by-step QGIS guide and a city template, so any city with an old public-domain map can be added without touching the code.
- A 1950s US Army Map Service sheet is already in the repo, waiting to be traced as a second time-slider step.
- Flood-point data: the pipeline already supports municipal flood-prone locations, ready to report how many sit near former lakes.
- Open data: the traced lakes are published under CC BY 4.0 for researchers and journalists.
Built With
- fast-check
- geojson
- kiro
- maplibre-gl
- motion
- netlify
- nominatim
- open-meteo
- openfreemap
- openstreetmap
- qgis
- react
- turf.js
- typescript
- vite
- vitest