Inspiration

Urban air pollution is a silent systems failure.

Cities like Amsterdam publish open environmental data, but most dashboards are descriptive, not deterministic. They show what happened, not whether the signal is trustworthy, drifted, or cryptographically verifiable.

As AI becomes embedded in civic decision systems, we asked a harder question:

What if a city’s pollution twin refused to hallucinate?

Amsterdam Pollution Twin Copilot was inspired by the need for:

  • Deterministic environmental modeling
  • Cryptographically signed AI outputs
  • Drift-aware inference
  • Transparent, auditable civic AI

We wanted to build a digital twin that behaves less like a chatbot — and more like a regulated system.


What it does

Amsterdam Pollution Twin Copilot is a deterministic urban digital twin that:

  • Divides Amsterdam into H3 hexagonal grids
  • Computes pollution risk scores per cell
  • Attaches confidence (CONF) metrics
  • Signs every model output with Ed25519
  • Tracks model drift in real-time
  • Displays system integrity state (NORMAL / CAUTION / DEGRADED)

Each pollution prediction is treated as:

[ \text{PollutionScore} = f(\text{sensor}, \text{traffic}, \text{wind}, \text{historical trend}) ]

But unlike typical AI dashboards:

  • Every output is signed
  • Every inference is reproducible
  • Every state is auditable

The system surfaces:

  • CRS (Cell Risk Score)
  • CONF (confidence level)
  • Drift Gauge
  • AI Energy/Integrity meter

This ensures trust before insight.


How we built it

Architecture Overview

Frontend

  • Next.js
  • Three.js for 3D Amsterdam twin
  • H3-js for hexagonal grid overlay
  • Glassmorphism UI system

Backend

  • Node.js / TypeScript
  • Deterministic scoring engine
  • Ed25519 signing via libsodium
  • Drift detection module

Data Layer

  • Open environmental APIs
  • Synthetic augmentation for simulation
  • PostgreSQL + PostGIS for geo indexing

Deterministic Scoring

Instead of stochastic LLM inference, we implemented:

[ \text{CRS}_i = \alpha S_i + \beta T_i + \gamma W_i + \delta H_i ]

Where:

  • (S_i) = sensor value
  • (T_i) = traffic density
  • (W_i) = wind dispersion factor
  • (H_i) = historical anomaly delta

All weights are versioned and signed.

Integrity Layer

Each output is:

  1. Canonically serialized
  2. Hashed
  3. Signed with Ed25519
  4. Stored with audit log metadata

If model drift exceeds threshold:

  • System switches state
  • Visual drift gauge moves to CAUTION/DEGRADED
  • Confidence score decreases

Challenges we ran into

1. Drift Detection vs False Alarms

Balancing sensitivity without triggering noise required statistical smoothing and rolling baseline windows.

2. Determinism in a Fast Hackathon

Ensuring reproducibility meant removing randomness from pipelines — including sorting, floating precision normalization, and canonical serialization.

3. UX vs Complexity

We had to compress:

  • Cryptographic verification
  • Geo computation
  • Drift telemetry

Into a UI that felt clean and SaaS-ready.

4. Performance on 3D H3 Grid

Rendering dense H3 overlays with real-time updates required optimizing instanced meshes in Three.js.


Accomplishments that we're proud of

  • ✅ Fully deterministic scoring pipeline
  • ✅ Cryptographically signed pollution outputs
  • ✅ Drift-aware AI system
  • ✅ Trust-first dashboard design
  • ✅ Zero LLM hallucination risk
  • ✅ Clean, production-grade UI

Most importantly:

We proved civic AI can be auditable by design, not by policy.


What we learned

  • Deterministic systems build trust faster than generative ones in regulated domains.
  • Cryptographic signing is lightweight but massively increases credibility.
  • Model drift visualization improves operator confidence.
  • Judges respond strongly to auditability + reproducibility narratives.

We also learned that “AI integrity” is a feature — not just a compliance checkbox.


What’s next for Amsterdam Pollution Twin Copilot

  1. Real sensor streaming integration
  2. EU Open Data compliance packaging
  3. Policy simulation mode (what-if traffic reduction scenarios)
  4. Public transparency portal
  5. Multi-city expansion framework

Long-term vision:

A network of cryptographically verifiable urban digital twins across Europe.

Built With

Share this project:

Updates