Logo Lanfrica

bisre1921/Ethiopian-Political-Posts

Domain:

natural language processing

Record type:

software
Creator:
bis
Host:
# Ethiopian Political Posts System Full-stack application for collecting, classifying, and displaying Ethiopian political and election-related posts. ## System Architecture ``` Python Ingestion (5 modes) → MySQL Database → Laravel API → React Frontend ``` ## Features - ✅ **5-Mode Data Collection** - Facebook Graph API + Facebook File Import + Twitter API + RSS Feeds + Sample Fallback - ✅ **Bilingual Classification** - Amharic & English keyword matching - ✅ **Laravel REST API** - Swagger documented, full CRUD with filters - ✅ **Professional Frontend** - DiplomatIQ design with bookmarks - ✅ **Duplicate Prevention** - Database constraints + application logic - ✅ **Free & Legal** - No paid services, respects Terms of Service ## Quick Start ### 1. Database Setup ```bash # Option A: Laravel migrations cd laravel-api php artisan migrate # Option B: SQL dump with sample data mysql -u root -pbisrat1234 ethiopian_posts # Clear Laravel cache cd laravel-api rm -rf bootstrap/cache/* rm -rf storage/framework/cache/* php artisan cache:clear php artisan config:clear php artisan route:clear # Check PHP version (need 8.1+) php -v # Reinstall dependencies composer install # Restart server php artisan serve --host=localhost --port=8000 # Or use: ./dev ``` ### Python Scraper Errors ```bash # Activate virtual environment cd python-scraper source venv/bin/activate # Windows: venv\Scripts\activate # Reinstall dependencies pip install --upgrade -r requirements.txt # Check database connection python -c "from database import Database; db = Database(); print('Connected!')" # Check .env file exists cat .env # If Facebook Graph API credentials are unavailable python scraper.py --source facebook-file --input data/sample_facebook_posts.json # If Twitter API fails # 1. Check TWITTER_BEARER_TOKEN is set # 2. Verify token at: developer.twitter.com # 3. Use fallback: python scraper.py --source rss or --source sample # If RSS fails (blocked by sites) pyth …

Languages