# ravindra2377/poi architecture

> Architecture diagram of the GitHub repository ravindra2377/poi, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-13). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/ravindra2377/poi
- Repository: https://github.com/ravindra2377/poi

## Overview

FileKholo is a civic-record intelligence and participation platform: people browse source-linked public records and area briefings, distinguish official evidence from calculations and community reports, and can read published community material. Its public-data workflow combines reviewed catalogues with ingestion, provenance and database-backed API access; participation is read-only by default, with moderated submissions available only under an enabled pilot. Major record domains and governance surfaces are represented, but several implementation links remain unverified because their source was not sampled.

Main entry points: [`apps/web/src/app/layout.tsx`](https://github.com/ravindra2377/poi/blob/main/apps/web/src/app/layout.tsx) (Web application), [`apps/api/app/main.py`](https://github.com/ravindra2377/poi/blob/main/apps/api/app/main.py) (FastAPI service), [`apps/web/src/app/api/budget/route.ts`](https://github.com/ravindra2377/poi/blob/main/apps/web/src/app/api/budget/route.ts) (Web API routes), [`apps/api/app/api/v1/community.py`](https://github.com/ravindra2377/poi/blob/main/apps/api/app/api/v1/community.py) (Community endpoints)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_web["Citizen experience"]
  node_webapp["Web application<br/>[layout.tsx]"]
  node_record_browsing["Record directories<br/>[ExploreData.tsx]"]
  node_area_briefing["Area briefing<br/>[MyArea.tsx]"]
  node_community_ui["Community views"]
  node_professional["Research offers"]
  node_web_api["Web API routes<br/>[route.ts]"]
end

subgraph group_api["Public API"]
  node_fastapi["FastAPI service<br/>[main.py]"]
  node_domain_routes["Record endpoints<br/>[government.py]"]
  node_community_routes["Community endpoints<br/>[community.py]"]
  node_ingestion_status["Feed status<br/>[ingestion.py]"]
  node_catalog["Catalog repository<br/>[repositories.py]"]
end

subgraph group_data["Records and ingestion"]
  node_database[("PostgreSQL / PostGIS<br/>[db.py]")]
  node_provenance["Source provenance<br/>[provenance.py]"]
  node_geography["Geography records<br/>[geography.py]"]
  node_government_records["Government records<br/>[government.py]"]
  node_snapshot_store[("Snapshot storage<br/>[storage.py]")]
  node_ingestion_worker["News feed worker"]
  node_news_ingestion["News extraction<br/>[daily_news.py]"]
  node_state_feeds["State feed registry<br/>[state_feeds.py]"]
end

subgraph group_civic["Civic participation"]
  node_moderation["Moderation and audit<br/>[community.py]"]
  node_community_records["Published community records<br/>[community.py]"]
  node_professional_api["Professional accounts<br/>[professional.py]"]
end

node_citizens(("Residents"))

node_citizens -->|"browse"| node_webapp
node_webapp -->|"offers"| node_record_browsing
node_webapp -->|"offers"| node_area_briefing
node_webapp -->|"offers"| node_community_ui
node_webapp -->|"offers"| node_professional
node_record_browsing -.->|"requests data"| node_web_api
node_area_briefing -.->|"requests data"| node_web_api
node_community_ui -.->|"requests data"| node_web_api
node_web_api -.->|"forwards requests"| node_fastapi
node_fastapi -->|"mounts routes"| node_domain_routes
node_fastapi -->|"mounts routes"| node_community_routes
node_fastapi -->|"mounts routes"| node_ingestion_status
node_domain_routes -->|"uses catalog"| node_catalog
node_ingestion_status -->|"reads feed status"| node_catalog
node_catalog -.->|"queries"| node_database
node_community_routes -->|"reads and writes"| node_database
node_ingestion_worker -->|"selects feeds"| node_state_feeds
node_ingestion_worker -->|"ingests feeds"| node_news_ingestion
node_news_ingestion -.->|"stores snapshots"| node_snapshot_store
node_news_ingestion -->|"records provenance"| node_provenance
node_community_routes -->|"handles review"| node_moderation
node_moderation -.->|"manages records"| node_community_records
node_professional -.->|"uses accounts"| node_professional_api

click node_webapp "https://github.com/ravindra2377/poi/blob/main/apps/web/src/app/layout.tsx"
click node_record_browsing "https://github.com/ravindra2377/poi/blob/main/apps/web/src/app/explore-data/ExploreData.tsx"
click node_area_briefing "https://github.com/ravindra2377/poi/blob/main/apps/web/src/app/my-area/MyArea.tsx"
click node_community_ui "https://github.com/ravindra2377/poi/blob/main/apps/web/src/app/community/CommunityContent.tsx"
click node_professional "https://github.com/ravindra2377/poi/blob/main/apps/web/src/app/professional/ProfessionalOffering.tsx"
click node_web_api "https://github.com/ravindra2377/poi/blob/main/apps/web/src/app/api/budget/route.ts"
click node_fastapi "https://github.com/ravindra2377/poi/blob/main/apps/api/app/main.py"
click node_domain_routes "https://github.com/ravindra2377/poi/blob/main/apps/api/app/api/v1/government.py"
click node_community_routes "https://github.com/ravindra2377/poi/blob/main/apps/api/app/api/v1/community.py"
click node_ingestion_status "https://github.com/ravindra2377/poi/blob/main/apps/api/app/api/v1/ingestion.py"
click node_catalog "https://github.com/ravindra2377/poi/blob/main/apps/api/app/repositories.py"
click node_database "https://github.com/ravindra2377/poi/blob/main/apps/api/app/db.py"
click node_provenance "https://github.com/ravindra2377/poi/blob/main/apps/api/app/models/provenance.py"
click node_geography "https://github.com/ravindra2377/poi/blob/main/apps/api/app/models/geography.py"
click node_government_records "https://github.com/ravindra2377/poi/blob/main/apps/api/app/models/government.py"
click node_snapshot_store "https://github.com/ravindra2377/poi/blob/main/apps/api/app/storage.py"
click node_ingestion_worker "https://github.com/ravindra2377/poi/blob/main/workers/ingestion/daily_news_ingestor.py"
click node_news_ingestion "https://github.com/ravindra2377/poi/blob/main/apps/api/app/ingestion/daily_news.py"
click node_state_feeds "https://github.com/ravindra2377/poi/blob/main/apps/api/app/ingestion/state_feeds.py"
click node_moderation "https://github.com/ravindra2377/poi/blob/main/apps/api/app/api/v1/community.py"
click node_community_records "https://github.com/ravindra2377/poi/blob/main/apps/api/app/models/community.py"
click node_professional_api "https://github.com/ravindra2377/poi/blob/main/apps/api/app/api/v1/professional.py"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_webapp,node_record_browsing,node_area_briefing,node_community_ui,node_professional,node_web_api toneBlue
class node_fastapi,node_domain_routes,node_community_routes,node_ingestion_status,node_catalog toneAmber
class node_database,node_provenance,node_geography,node_government_records,node_snapshot_store,node_ingestion_worker,node_news_ingestion,node_state_feeds toneMint
class node_moderation,node_community_records,node_professional_api toneRose
class node_citizens toneIndigo
```

## Components

### Citizen experience

- [Web application](https://github.com/ravindra2377/poi/blob/main/apps/web/src/app/layout.tsx): `apps/web/src/app/layout.tsx`
- [Record directories](https://github.com/ravindra2377/poi/blob/main/apps/web/src/app/explore-data/ExploreData.tsx): `apps/web/src/app/explore-data/ExploreData.tsx`
- [Area briefing](https://github.com/ravindra2377/poi/blob/main/apps/web/src/app/my-area/MyArea.tsx): `apps/web/src/app/my-area/MyArea.tsx`
- [Community views](https://github.com/ravindra2377/poi/blob/main/apps/web/src/app/community/CommunityContent.tsx): `apps/web/src/app/community/CommunityContent.tsx`
- [Research offers](https://github.com/ravindra2377/poi/blob/main/apps/web/src/app/professional/ProfessionalOffering.tsx): `apps/web/src/app/professional/ProfessionalOffering.tsx`
- [Web API routes](https://github.com/ravindra2377/poi/blob/main/apps/web/src/app/api/budget/route.ts): `apps/web/src/app/api/budget/route.ts`

### Public API

- [FastAPI service](https://github.com/ravindra2377/poi/blob/main/apps/api/app/main.py): `apps/api/app/main.py`
- [Record endpoints](https://github.com/ravindra2377/poi/blob/main/apps/api/app/api/v1/government.py): `apps/api/app/api/v1/government.py`
- [Community endpoints](https://github.com/ravindra2377/poi/blob/main/apps/api/app/api/v1/community.py): `apps/api/app/api/v1/community.py`
- [Feed status](https://github.com/ravindra2377/poi/blob/main/apps/api/app/api/v1/ingestion.py): `apps/api/app/api/v1/ingestion.py`
- [Catalog repository](https://github.com/ravindra2377/poi/blob/main/apps/api/app/repositories.py): `apps/api/app/repositories.py`

### Records and ingestion

- [PostgreSQL / PostGIS](https://github.com/ravindra2377/poi/blob/main/apps/api/app/db.py): `apps/api/app/db.py`
- [Source provenance](https://github.com/ravindra2377/poi/blob/main/apps/api/app/models/provenance.py): `apps/api/app/models/provenance.py`
- [Geography records](https://github.com/ravindra2377/poi/blob/main/apps/api/app/models/geography.py): `apps/api/app/models/geography.py`
- [Government records](https://github.com/ravindra2377/poi/blob/main/apps/api/app/models/government.py): `apps/api/app/models/government.py`
- [Snapshot storage](https://github.com/ravindra2377/poi/blob/main/apps/api/app/storage.py): `apps/api/app/storage.py`
- [News feed worker](https://github.com/ravindra2377/poi/blob/main/workers/ingestion/daily_news_ingestor.py): `workers/ingestion/daily_news_ingestor.py`
- [News extraction](https://github.com/ravindra2377/poi/blob/main/apps/api/app/ingestion/daily_news.py): `apps/api/app/ingestion/daily_news.py`
- [State feed registry](https://github.com/ravindra2377/poi/blob/main/apps/api/app/ingestion/state_feeds.py): `apps/api/app/ingestion/state_feeds.py`

### Civic participation

- [Moderation and audit](https://github.com/ravindra2377/poi/blob/main/apps/api/app/api/v1/community.py): `apps/api/app/api/v1/community.py`
- [Published community records](https://github.com/ravindra2377/poi/blob/main/apps/api/app/models/community.py): `apps/api/app/models/community.py`
- [Professional accounts](https://github.com/ravindra2377/poi/blob/main/apps/api/app/api/v1/professional.py): `apps/api/app/api/v1/professional.py`

### Other components

- **Residents**

## Connections

- Residents → Web application: browse (evidence: `README.md`)
- Web application → Record directories: offers (evidence: `README.md`)
- Web application → Area briefing: offers (evidence: `README.md`)
- Web application → Community views: offers (evidence: `README.md`)
- Web application → Research offers: offers (evidence: `README.md`)
- Record directories → Web API routes: requests data
- Area briefing → Web API routes: requests data
- Community views → Web API routes: requests data
- Web API routes → FastAPI service: forwards requests
- FastAPI service → Record endpoints: mounts routes (evidence: `apps/api/app/main.py`)
- FastAPI service → Community endpoints: mounts routes
- FastAPI service → Feed status: mounts routes
- Record endpoints → Catalog repository: uses catalog
- Feed status → Catalog repository: reads feed status (evidence: `apps/api/app/api/v1/ingestion.py`)
- Catalog repository → PostgreSQL / PostGIS: queries
- Community endpoints → PostgreSQL / PostGIS: reads and writes (evidence: `apps/api/app/api/v1/community.py`)
- News feed worker → State feed registry: selects feeds (evidence: `workers/ingestion/daily_news_ingestor.py`)
- News feed worker → News extraction: ingests feeds (evidence: `workers/ingestion/daily_news_ingestor.py`)
- News extraction → Snapshot storage: stores snapshots (evidence: `apps/api/app/ingestion/daily_news.py`)
- News extraction → Source provenance: records provenance (evidence: `apps/api/app/ingestion/daily_news.py`)
- Community endpoints → Moderation and audit: handles review (evidence: `apps/api/app/api/v1/community.py`)
- Moderation and audit → Published community records: manages records (evidence: `apps/api/app/api/v1/community.py`)
- Research offers → Professional accounts: uses accounts
