Inspiration
City planning decisions often require piecing together unstructured information from multiple sources — zoning laws, infrastructure plans, traffic studies — each stored in different formats and locations. Even the smallest changes demand hours of research. We want to make it possible to answer these questions in seconds, with both legal context and real-world impact analysis.
What it does
CityBrain is an AI-powered planning assistant for New York City. You can ask it:
- “What happens if we pedestrianize Broadway from 14th to 34th?”
- “What’s the zoning history of this lot in SoHo?”
- “How much traffic does 5th Avenue see during rush hour?”
How we built it
- Scraped and chunked the NYC zoning resolution, generated embeddings using HF sentence embedder, and stored them in Pinecone for fast semantic search
- Stored traffic data locally
- Built custom regex pattern matchers
- Created scenario packet by indexing the Pinecone DB and searching through local traffic data
- Used Modal to perform LLM inference with the query and added context
- Render the response on a nice frontend that looks like most LLM interfaces (chatgpt, claude, gemini, etc)
Challenges we ran into
- Fast querying of local data. In hindsight, something like DuckDB would have been better
- Designing regex patterns that can account for all types of questions. I had chatgpt generate 50 regex patterns which are matched to queries but in reality, there are hundreds or thousands even in this domain ## Accomplishments that we're proud of
- Built a full retrieval-augmented generation pipeline in under 24 hours
- Created a flexible query parser that works for both hypothetical adn factual questions
What we learned
- Hybrid retrieval is very powerful for domain-specific assistants
What's next for CityBrain
- Adding geospatial joins so you can select regions instead of typing street names
- Incorporating historical accident, pollution, and public transit data for richer impact analysis
- Allowing multi-city expansion so CityBrain can be deployed in any urban area
Built With
- javascript
- modal
- pinecone
- python
Log in or sign up for Devpost to join the conversation.