# 🏺 Hirfatuna : Tunisian Craft Heritage AI Platform
> An AI-powered platform that identifies Tunisian handicrafts from a photo and reveals their history, region of origin, and craftsmanship preserving a cultural heritage that has no public digital footprint.
---
## The problem
Tunisian handicrafts represent centuries of cultural heritage. Yet this knowledge is scattered, undocumented online, and largely invisible to younger generations. No public dataset or digital tool existed to classify, explain, or explore it.
**Hirfatuna** solves this with a full AI pipeline: from a self-collected image dataset to a deployed, interactive platform.
## Features
### 1. VLM guard
A vision-language model checks the photo is actually a craft before classifying it
### 2. Visual classification
AI identifies the craft across 10 categories (ResNet-50, 90.8% accuracy)
### 3. Geographic origin
Pinpoints the craft's region on an interactive map of Tunisia
### 4. Cultural knowledge base
Reveals history, materials, techniques, and fun facts for each craft
### 5. Explainable AI
Grad-CAM visualizes exactly which parts of the image drove the prediction
### 6. RAG-powered chatbot
Ask free-form questions, answered from a curated knowledge base, no hallucinations
### 7. Session history
Browse every craft analyzed during your session
---
## Results
- **10 craft categories**, classified with **90.8% validation accuracy**
- **3,264 labeled images**, self-collected
- **ResNet-50** selected after a comparative study across **5 architectures × 4 fine-tuning depths** (20 configurations) — see `comparative_study/`
- Fully deployed, end-to-end application, no setup required to try it
```
precision recall f1-score
bijoux_berberes 0.92 0.95 0.93
bois_sculpte 0.94 0.88 0.91
broderie_tunisienne 0.83 0.86 0.85
cuivre 0.93 0.90 0.91
djebba 0.85 0.92 0.88
fer_forge 0.91 0.89 0.90
maroquinerie_tunisienne …