Logo Lanfrica

semereherruy/ai-agri-advisor-rag

Domaine:

agriculturenatural language processing

Type de record:

softwareproject
Créateur:
sem
Hôte:
AI-powered agriculture advisory chatbot using Retrieval-Augmented Generation (RAG) to deliver localized, multilingual farming guidance for Ethiopian farmers. # 🌾 AI Agriculture Advisor (RAG-based MVP) An AI-powered agriculture question-answering system focused on Teff and Maize, designed for Ethiopia → Africa → Global use. This project uses Retrieval-Augmented Generation (RAG) to answer farmers' questions based on trusted agricultural documents. ## 🚀 Quick Start ### Backend Setup 1. Navigate to the backend directory: ```bash cd backend ``` 2. Install dependencies: ```bash pip3 install -r requirements.txt ``` **Note:** Use `pip3` and `python3` (macOS default python is 2.7) 3. Run the FastAPI server: ```bash python3 -m uvicorn app.main:app --reload --host 0.0.0.0 --port 8000 ``` Or use the helper script: ```bash ./start-backend.sh ``` The API will be available at `localhost` ### Frontend Setup 1. Navigate to the frontend directory: ```bash cd frontend ``` 2. Install dependencies: ```bash npm install ``` 3. Start the development server: ```bash npm start ``` The app will open at `localhost` ## 📋 Project Structure ``` agri-advisor-rag/ ├── backend/ # FastAPI backend │ ├── main.py # Main FastAPI application │ ├── services/ # Service modules │ │ ├── rag_service.py # Mock RAG service │ │ ├── translation_service.py # Translation with Ge'ez detection │ │ ├── logging_service.py # JSONL logging │ │ └── cache_service.py # In-memory cache │ ├── requirements.txt # Python dependencies │ └── README.md # Backend documentation ├── frontend/ # React frontend │ ├── src/ │ │ ├── components/ # React components │ │ └── App.tsx # Main app component │ ├── package.json # Node dependencies │ └── README.md # Frontend documentation ├── data/ # Agricultural documents ├── logs/ # Application logs (JSONL) └── README.md # This file ``` ## 🎯 Features ### Backend - **FastAPI** async endpoints - **RAG service** data retrieval - **Translation …