How niharxd/heritageai works
Heritage AI is a local cultural-heritage image analysis and conservation assistant. A conservator selects manuscript or monument images, submits one or a batch, and receives damage findings, enhancement, text or structured labels, risk, age estimates, explanations, and restoration recommendations. The same analysis can be reviewed and exported, then retained in an archive for notes, groups, trends, comparison, statistics, urgency, and map views. The graph includes README-documented capabilities whose implementation was not sampled; their internal wiring is omitted where evidence is unavailable.
Main entry points: pipeline.py Analysis pipeline · api.ts API client · app.py HTTP API · App.tsx Application views
Components 27
Conservator interface
- Application views
frontend/src/App.tsx - API client
frontend/src/api.ts - Archive gallery
frontend/src/pages/Gallery.tsx - Comparison
frontend/src/pages/Compare.tsx - Statistics
frontend/src/pages/StatsPage.tsx - Map view
frontend/src/pages/MapView.tsx - Urgency queue
frontend/src/pages/UrgencyQueue.tsx - Image annotation
frontend/src/components/AnnotationTool.tsx - Batch results
frontend/src/components/BatchResults.tsx - Trend chart
frontend/src/components/TrendChart.tsx - Image quality
frontend/src/components/ImageQuality.tsx
Image analysis
- Analysis pipeline
backend/pipeline.py - Preprocessing
backend/preprocessing.py - Damage detection
backend/damage_detection.py - Image enhancement
backend/enhancement.py - OCR and labels
backend/ocr_engine.py - Risk prediction
backend/risk_prediction.py - Age estimation
backend/age_estimation.py - Explainability
backend/explainability.py - Restoration advice
backend/restoration_suggestions.py - Material detection
backend/material_detection.py - Duplicate detection
backend/duplicate_detector.py
Archive and reporting
- HTTP API
app.py - History store
backend/history_store.py - PDF reports
backend/pdf_report.py
External services
- Place geocoding
Other components
- Conservator
Connections 27
- Conservator → Application views: uses
README.md - Application views → API client: requests analysis
frontend/src/App.tsx - API client → HTTP API: calls endpoints
README.md - HTTP API → Analysis pipeline: runs analysis
app.py - Analysis pipeline → Preprocessing: estimates domain
backend/pipeline.py - Analysis pipeline → Damage detection: detects damage
backend/pipeline.py - Analysis pipeline → Image enhancement: enhances image
backend/pipeline.py - Analysis pipeline → OCR and labels: extracts semantics
backend/pipeline.py - Analysis pipeline → Risk prediction: scores risk
backend/pipeline.py - Analysis pipeline → Age estimation: estimates age
backend/pipeline.py - Analysis pipeline → Explainability: explains findings
backend/pipeline.py - Analysis pipeline → Restoration advice: suggests restoration
backend/pipeline.py - HTTP API → History store: reads and writes
app.py - HTTP API → PDF reports: generates reports
app.py - Application views → Batch results: shows batch
frontend/src/App.tsx - Application views → Image quality: checks uploads
frontend/src/App.tsx - Application views → Image annotation: offers annotation
frontend/src/App.tsx - Archive gallery → API client: loads archive
frontend/src/pages/Gallery.tsx - Archive gallery → Trend chart: renders trends
frontend/src/pages/Gallery.tsx - Statistics → API client: loads statistics
frontend/src/pages/StatsPage.tsx - Statistics → Trend chart: renders trends
frontend/src/pages/StatsPage.tsx - Map view → API client: loads map pins
frontend/src/pages/MapView.tsx - Urgency queue → API client: loads queue
frontend/src/pages/UrgencyQueue.tsx - Comparison → API client: loads analyses
frontend/src/pages/Compare.tsx - Conservator → Place geocoding: searches locations
README.md - HTTP API → Material detection: may classify material
- HTTP API → Duplicate detection: checks duplicates
app.py