Inspiration

Municipal planning and urban development are critical for sustainable city growth, yet public sector decision-makers frequently face a severe administrative bottleneck: information fragmentation. Decades of spatial planning blueprints (RTRW/RDTR), strategic municipal development plans (RPJMD/RKPD), sectoral regulations, and regional statutory mandates exist across disconnected PDFs, legacy databases, and bureaucratic silos.

When drafting a new development initiative or assessing compliance for public works, city officials routinely spend days manually cross-referencing multi-agency documentation. A single oversight can lead to statutory non-compliance, misallocated capital expenditures, or delayed execution. We built The Collaborative Partner (Palembang Municipal Planning Gallery) to transform how municipal officials query, analyze, and synthesize spatial regulations and planning archives—delivering verified, audit-ready intelligence in seconds.

What it does

The Collaborative Partner acts as an AI advisory co-pilot engineered for municipal governance and urban planning workflows:

High-Precision Regulatory Synthesis: Translates dense municipal regulations, spatial plans, and zoning constraints into clear, actionable briefs.

Audit-Ready Source Citations: Guarantees zero ungrounded assertions by linking every generated synthesis directly to exact articles, official planning years, and regulatory decree numbers.

Cross-Agency Intelligence Alignment: Resolves conflicting development guidelines across transportation, public works, spatial planning, and fiscal planning agencies.

Spatial & Metric Verification: Evaluates proposed infrastructure parameters (e.g., green open space ratios, building coverage coefficients) against statutory standards

How we built it

Our technical architecture was designed around a latency-optimized, hallucination-resistant Retrieval-Augmented Generation (RAG) pipeline tailored for legal and public policy texts.1. Document Ingestion & Chunking StrategyStandard token-based chunking frequently breaks legal context. We developed a hierarchical semantic parser that respects statutory document boundaries (e.g., Chapters $\rightarrow$ Articles $\rightarrow$ Clauses $\rightarrow$ Explanatory Notes):Document structure is preserved into contextual parent-child trees:$$\text{Chunk}{\text{leaf}} \subset \text{Context}{\text{parent}}$$Metadata extraction automatically tags administrative year, issuing entity, legal hierarchy level, and domain category.2. Hybrid Retrieval EngineTo maximize recall across both exact legal phrasing (decree codes) and conceptual urban planning queries, we combined dense semantic embeddings with sparse keyword matching:$$\text{Score}(d, q) = \alpha \cdot \text{DenseSim}(\mathbf{e}_q, \mathbf{e}_d) + (1 - \alpha) \cdot \text{BM25}(q, d)$$Where:$\mathbf{e}_q, \mathbf{e}_d$ are normalized vector embeddings of query $q$ and document chunk $d$.$\alpha \in [0, 1]$ represents the retrieval weighting factor (calibrated to $\alpha = 0.65$ to balance semantic intent with statutory identifiers).3. Cross-Encoder Re-Ranking & Context CompressionTop-$K$ retrieved candidates pass through a secondary cross-encoder re-ranking model to filter out irrelevant historical amendments. The refined context is compressed using extractive summarization before being injected into the LLM prompt context window.4. Interface & Deployment ArchitectureFrontend: Responsive, Mac-OS inspired dashboard with dark/light themes, structured markdown outputs, and interactive source document viewers.Backend: Asynchronous Python/Node API layer orchestrating vector indexing, retrieval pipelines, and caching.Hosting: Containerized deployment behind an Nginx reverse proxy with TLS encryption, strictly enforcing data sovereignty standards.

Challenges we ran into

Temporal Legal Validity: Local regulations frequently get superseded or amended by newer statutory instruments. Designing metadata filters to distinguish between historical reference data and currently active regulations required dynamic validity-range tagging.

Dense Tabular and Spatial Data: Spatial planning documents contain extensive zoning tables and spatial coefficient matrices. Parsing embedded tables from non-standardized PDFs without corrupting key-value relationships required building custom OCR and document layout recognition pipelines.

Minimizing Hallucination in High-Stakes Policy: In municipal governance, a hallucinated regulation is catastrophic. We enforced strict context constraints, prompt guardrails, and validation thresholds that instruct the model to explicitly state if statutory grounding is missing.

Accomplishments that we're proud of

Sub-2-Second Query Resolution: Achieved real-time retrieval and generation across extensive pages of regional regulatory archives.

100% Verifiable Traceability: Every factual statement, coefficient threshold, and policy directive links back to its verified source document and page number.

Pragmatic Public Sector UX: Created an intuitive workflow that allows non-technical city administrators to extract answers without writing complex search operators or SQL queries.

What we learned

Domain Structure Trumps Raw Model Size: An optimized, domain-aware chunking and re-ranking architecture yields significantly higher policy accuracy than feeding raw documents to larger general-purpose models.

Public Servants Need Explainability, Not Just Answers: Providing the reasoning path and exact legal citations is far more valuable to governance stakeholders than a purely synthesized summary without references.

What's next for Palembang Municipal Planning Gallery

GIS & Geospatial Layer Integration: Integrating vector map overlays (Shapefiles/GeoJSON) to let officials click directly on geographic coordinates or zoning parcels and automatically query active spatial bylaws for that polygon.

Automated Capital Expenditure & Budget Alignment: Linking project feasibility queries to municipal financial budgeting databases (e.g., SIPD/APBD data) to cross-evaluate proposed urban infrastructure plans against real-time fiscal constraints.

Public Participation Gateway: Developing a citizen-facing module allowing public development proposals (Musrenbang) to be automatically evaluated and categorized against current master plans.

Built With

Share this project:

Updates

Submission history