How axiom-digital/mahallen works
MahallEN is a pilot neighborhood-livability reporting app. Users browse or filter Muğla neighborhoods, choose a report, and view category metrics, evidence and profile suitability; the API currently serves illustrative database seed data rather than the source-backed static dataset. The map separates API/report generation, persistence, and the React experience. README-documented static research data, operator-only Gemini refresh, and frontend five-category scoring are retained. Edges reflect shown calls or README claims; the research workflow has limited runtime wiring in the excerpts.
Main entry points: neighborhoods.py Neighborhood endpoints · App.jsx Search and report UI · main.py Application startup · seed_service.py Pilot seed data
Components 22
Web experience
- Search and report UI
frontend/src/App.jsx - API client
frontend/src/services/api.js - Report dashboard
frontend/src/components/ReportDashboard.jsx - Score charts
frontend/src/components/ScoreCard.jsx - Profile scoring
frontend/src/scoring.mjs
API and reports
- Neighborhood endpoints
backend/app/api/routes/neighborhoods.py - Report schemas
backend/app/schemas/neighborhood.py - Report synthesis
backend/app/services/ai_service.py - Pilot seed data
backend/app/services/seed_service.py - Application startup
backend/app/main.py - Runtime configuration
backend/app/core/config.py
Persistence
- SQL database
backend/app/core/database.py - Neighborhood records
backend/app/models/neighborhood.py - Report cache records
backend/app/models/report_cache.py - Cache operations
backend/app/services/cache_service.py
Research and scoring
- Livability scoring
backend/app/services/scoring_service.py - Pilot static dataset
data/neighborhoods - Research collection
backend/scripts/collect_direct_sample.py - Versioned prompts
backend/scripts/prepare_pilot_prompts.py - Gemini search client
backend/scripts/grounding_client.py
Other components
- Neighborhood seeker
- Gemini provider
Connections 24
- Neighborhood seeker → Search and report UI: browses
README.md - Search and report UI → API client: requests data
frontend/src/App.jsx - Search and report UI → Report dashboard: renders
frontend/src/App.jsx - Search and report UI → Score charts: renders charts
frontend/src/App.jsx - Search and report UI → Profile scoring: normalizes scores
frontend/src/App.jsx - API client → Neighborhood endpoints: calls API
- Application startup → Neighborhood endpoints: registers routes
backend/app/main.py - Application startup → SQL database: creates engine
backend/app/main.py - Application startup → Pilot seed data: seeds records
backend/app/main.py - Application startup → Runtime configuration: configures app
backend/app/main.py - Neighborhood endpoints → Neighborhood records: queries records
backend/app/api/routes/neighborhoods.py - Neighborhood endpoints → Report schemas: validates responses
backend/app/api/routes/neighborhoods.py - Neighborhood endpoints → Report synthesis: generates report
backend/app/api/routes/neighborhoods.py - Neighborhood endpoints → Cache operations: reads and writes
backend/app/api/routes/neighborhoods.py - Neighborhood endpoints → Runtime configuration: checks settings
backend/app/api/routes/neighborhoods.py - Cache operations → Report cache records: stores entries
backend/app/services/cache_service.py - Pilot seed data → Neighborhood records: creates records
backend/app/services/seed_service.py - Pilot seed data → Livability scoring: computes scores
backend/app/services/seed_service.py - SQL database → Runtime configuration: reads settings
backend/app/core/database.py - Report synthesis → Gemini provider: generates live text
backend/app/services/ai_service.py - Research collection → Pilot static dataset: builds pilot data
- Versioned prompts → Gemini search client: supports research
- Gemini search client → Gemini provider: search grounding
README.md - Pilot static dataset → Neighborhood endpoints: runtime import pending
README.md