Logo Lanfrica

yehdih/mauritania-chatbot

Domaine:

natural language processingdigital infrastructure

Type de record:

software
Créateur:
yeh
Hôte:
A bilingual (French/Arabic) AI-powered chatbot that helps citizens access information about Mauritania's public services. The system combines RAG (Retrieval Augmented Generation) with Groq's LLM to provide accurate, context-aware answers about national ID cards, passports, electricity bills, hospital appointments, driving licenses, and more # 🇲🇷 Mauritania Government Services Chatbot An intelligent bilingual chatbot (Arabic/French) powered by Groq's Llama 3.3 70B model to help Mauritanian citizens navigate government services and administrative procedures. --- ## 📋 Table of Contents - Features - Architecture - System Flow - Installation - Usage - Services Covered - Technical Stack - API Configuration - Project Structure - Contributing - License --- ## ✨ Features - 🌍 **Bilingual Support**: Full support for Arabic (العربية) and French (Français) - 🤖 **AI-Powered Responses**: Uses Groq's Llama 3.3 70B for intelligent, context-aware answers - 📚 **RAG System**: Retrieval-Augmented Generation with semantic search and keyword matching - 🎯 **Service-Specific Information**: Detailed guides for 5+ government services - ⚡ **Fast Response Times**: Optimized with Groq's lightning-fast inference - 🔄 **Robust Fallback System**: Guaranteed responses even if API fails - 💬 **User-Friendly Interface**: Clean Gradio UI with quick action buttons - 🔍 **Smart Search**: Combines embeddings and keyword matching for accurate results --- ## 🏗 Architecture ```mermaid graph TB A[User Input] --> B{Language Selector} B -->|French| C[Query Processor] B -->|Arabic| C C --> D[RAG System] D --> E[Sentence Embeddings all-MiniLM-L6-v2] D --> F[Keyword Matching] E --> G[Semantic Search] F --> G G --> H{Results Found?} H -->|Yes| I[Service Database Lookup] H -->|No| J[No Match Response] I --> K[Context Builder] K --> L{Groq API Available?} L -->|Yes| M[Groq Llama 3.3 70B Generation] L -->|No| N[Local Fallback Response] M --> O{Language Check} O -->|Pass| P[Final Response] O -->|Fail| N N --> P P --> Q[Gradio UI] Q --> R[User Display] style A fill:#e1f5ff style M fill:#ffeb99 style P fill:#c8e6c9 style Q fill:#f8bbd0 ``` --- ## 🔄 System Flow ```mermaid sequenceDiagram participant U as User participant G as Gradio UI participant C as Chatbot participant R as RAG System participant E as Embedder participant K as Keyword Matc …