Somerville, MA — Resident Open-Data Project

Somerville city data,
queryable in plain English.

Service requests since 2015 and crime incidents since 2017, joined to wards and asked through a chat interface that hands over the SQL, row count, and source citations on every answer. A curated dashboard layered on top; more coming.

Private beta — try the chat →
1.23M
311 requests loaded
23.4K
Crime incidents loaded
7
Wards covered
35
Documented limitations
2026-10-06
Latest data point (311)
2026-10-05
06:18 ET
Last pipeline run
142 of 146
Data quality tests passed
01
Welcome

This is an independent, resident-built data platform for exploring Somerville's public Open Data. It is not affiliated with the City of Somerville — it draws on the city's public data feeds (311 service requests, crime incidents, permits, traffic citations, the biennial Happiness Survey, ward boundaries, and the at-a-glance city indicators) and joins them so they can be queried in plain English. Every answer carries its own receipts: SQL, row count, source citations, and any relevant caveats.

How to use this

Start with the chat at /chat. Ask a plain-language question; the Answer Agent picks the right semantic-layer view, writes the SQL, runs it on the warehouse, and replies with the answer plus the executed SQL, the row count, citations to the source tables, and any relevant entries from the limitations registry.

If a question recurs — or if you want a visual answer — check /dashboards. Each dashboard is a versioned apps/*.app.yml file in the repo carrying the same trust contract as the chat agent. New dashboards are drafted with Builder Agent and reviewed before they ship.

For architecture and ground truth: /trust shows the most recent pipeline-run test results, /metrics publishes every semantic-layer measure with its expanded SQL, /profile surfaces per-column shape data, /erd renders the warehouse + semantic-layer diagrams, and /docs is the dbt-generated data dictionary.

The trust contract

Every chat reply and every dashboard panel ships with four receipts: the SQL that produced the number, the row count returned, citations to the source tables and Airlayer views, and any limitations from the registry that apply to what was asked. The contract holds across surfaces — chat, dashboards, the homepage cards above, all of them. If a surface drops a receipt, that's the bug.

02
What's in the data
Topic · service_requests
311 service requests
Rows 1,227,208
Date range 2015-07-01 to 2026-10-06
Request types 354
Wards covered 7 / 7
3 active limitations affecting this dataset — see /trust
Topic · public_safety
Crime incidents
Rows 23,448
Date range 2017-01-01 to 2026-09-02
Offense categories 4
Wards covered 8 / 7
4 active limitations affecting this dataset — see /trust
03
Try a question
How many 311 requests came in last month, by ward? Copy & ask → Which 311 categories take the longest to resolve? Copy & ask → What kinds of crime are reported across Somerville? Copy & ask → Which wards see the highest combined 311 + crime activity? Copy & ask → Rat complaints by ward — frequency, resolution, equity Open dashboard → Browse all curated dashboards /dashboards →
Question copied — paste it in the chat
04
Platform surfaces
>_
Analytics chat
Every reply includes the SQL the agent ran, the row count returned, and citations to the source tables, views, and any matching limitations.
/chat -> Ask a question
::
Dashboards
Curated visual answers to recurring questions. Each dashboard carries its own trust contract: source tables, last refreshed, relevant limitations.
/dashboards -> Browse
[m]
Metrics catalog
Auto-generated from the Airlayer semantic layer. Each measure is published with its expanded SQL and description -- no hand-written copy.
/metrics -> Definitions
[v]
Trust page
Driven by the admin schema. Shows pass/fail counts and per-test results from the most recent pipeline run, plus drift-fail status against frozen baselines.
/trust -> Latest run
[p]
Column profiles
Per-column shape data: distinct counts, null %, type-specific stats (numeric distributions, date ranges, text top-5). Refreshed when schema or row counts shift.
/profile -> Browse columns
[E]
Schema diagrams
Mermaid ERD for the warehouse plus the semantic-layer view-and-topic graph. Generated from dbt relationships tests + Airlayer YAML.
/erd -> Browse diagrams
[d]
Data dictionary
Generated by dbt docs. Every model and column has a description; relationships, tests, and lineage are inspectable.
/docs -> Browse models
05
What's not yet possible
Sub-ward geography Today's gold layer surfaces ward and block code; the silver-layer dim_location (neighborhoods, intersections, parcels) is MVP 3 work. Until then, "by neighborhood" questions land "by ward" instead.
Demographic correlations No ACS or census data joined yet. "Are complaint rates higher in low-income wards?" can't be answered until MVP 3 brings in external reference data.
Survey signal Accuracy / courtesy / ease / overall-experience columns exist on 311 requests but are populated for <1% of rows; not statistically meaningful yet. See the limitation entry on /trust.
Sub-month crime resolution Sensitive crime incidents carry year-only dates (no month, day, or block); aggregate analysis by month or block isn't accurate for those rows. See crime-sensitive-incidents-no-month on /trust.
Sharing surfaces Chat is Tailnet-only during private beta; Slack, MCP, A2A, and public access are MVP 4. Findings stay personal until then.
Verified queries Recurring questions don't yet have curated SQL fingerprints with sign-off; that's MVP 3. Today the agent re-writes SQL from scratch per question; usually identical, occasionally varies on phrasing.
06
How it works

Built on Oxygen

Somerville's 311 and crime SODA feeds are ingested via dlt to DuckDB, transformed through bronze and gold dbt layers, and surfaced through the Airlayer semantic layer. The chat interface is an Oxygen Answer Agent backed by Claude Opus 4.7; dashboards are Oxygen Data Apps drafted by Builder Agent.

The platform operates under a trust contract: every chat reply and every dashboard panel includes the executed SQL, the row count returned, citations to source tables and Airlayer views, and surfaced entries from the limitations registry when the query touches a flagged area. Methodology is always inspectable.

MVP 2 adds visual data products on top of the MVP 1 substrate. MVP 3 will add full governance (Verified Queries, PII redaction, star schema); MVP 4 adds sharing surfaces (Slack, MCP, public access).

Ingestion dlt Somerville SODA API
Warehouse DuckDB 311 + crime
Transform dbt Core Bronze → Gold
Semantics Airlayer Oxygen native
Chat Answer Agent Claude Opus
Model Claude Opus 4.7 Anthropic
07
Roadmap
MVP 1 Conversational analytics Done -- 311 + crime -> DuckDB -> chat with trust contract
MVP 2 Visual data products Active -- curated dashboards from /dashboards, Builder Agent for new apps
MVP 3 Governance layer Star schema, PII redaction, Verified Queries, data quality guardrails
MVP 4 Rich semantics + sharing Full metric library, routing agent, Slack + MCP + public access