A Telegram scraper to collect text, images, and metadata
## π `README.md` for KAIM Week 4 Project
# π¦ Amharic E-commerce NER System for EthioMart
This project is part of **10 Academy KAIM Week 4**, focused on developing a transformer-based **Named Entity Recognition (NER)** system for extracting structured business data (Product, Price, Location) from unstructured **Amharic Telegram messages**.
The end goal is to help **EthioMart**:
- Centralize e-commerce product listings from Telegram
- Score vendors for **micro-lending opportunities**
---
## π Project Highlights
- β
Custom **Telegram scraper** (via Telethon)
- β
Amharic text **preprocessing and normalization**
- β
CoNLL-format **NER dataset creation** (manual labeling)
- β
Model fine-tuning using Hugging Face (`XLM-R`, `BERT-Amharic`, etc.)
- β
**SHAP/LIME** for model interpretability
- β
Vendor scoring system for **FinTech insights**
---
## π Project Structure
βββ data/
β βββ raw/ # Raw scraped Telegram data
β βββ processed/ # Cleaned text data
β βββ labeled/ # CoNLL-labeled NER data
β βββ telegram_media/ # Downloaded product images
β
βββ notebooks/ # Jupyter notebooks per task
β βββ 01_data_ingestion.ipynb
β βββ 02_preprocessing.ipynb
β βββ 03_labeling.ipynb
β βββ ...
β
βββ src/
β βββ scraping/telegram_scraper.py
β βββ preprocessing/clean_text.py
β βββ fintech/scorecard.py
β
βββ scripts/ # Helper scripts (e.g., CoNLL labeling)
βββ models/ # Fine-tuned model files and metrics
βββ reports/ # Interim and final PDF reports
βββ streamlit_app.py # (Optional) Web app UI
βββ config.yaml # API keys, model config
βββ README.md
βββ requirements.txt
---
## π NER Entity Types
| Entity | Example |
| ---------- | ------------------------ |
| `Product` | "vaporfoam", "cake rack" |
| `Price` | "3000 α₯α", "Price 2000" |
| `Location` | "α α²α΅ α α α£", "α¦α" |
Annotated with the BIO format: `B-Product`, `I-PRICE`, `O`, etc.
---
## π₯ Data Collection
We scraped 1000+ messages from real e-commerce Telegram channels like:
- `@Shageronlinestore` β¦