File size: 3,120 Bytes
219a257 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 |
---
title: Arabic RAG Question Answering
emoji: π€
colorFrom: blue
colorTo: green
sdk: gradio
sdk_version: 4.0.0
app_file: app.py
pinned: false
license: apache-2.0
---
# π€ Arabic RAG Question Answering System
An intelligent Arabic question answering system powered by LFM2-1.2B-RAG fine-tuned with **AdaLoRA** - enabling accurate, context-aware responses for general Arabic queries.
## π Why This Model?
### β‘ Fast & Efficient (LiquidAI Architecture)
- **Edge-optimized**: Runs efficiently on CPU, GPU, or NPU
- **Lightning-fast inference**: 2x faster than comparable models
- **Device-agnostic**: Deploy on smartphones, laptops, or servers
- **Low memory footprint**: Perfect for resource-constrained environments
### π― Advanced Fine-tuning (AdaLoRA)
This model uses **AdaLoRA (Adaptive Low-Rank Adaptation)** - an advanced parameter-efficient fine-tuning technique that:
- Dynamically allocates model capacity based on importance
- **Outperforms standard LoRA** across multiple metrics
- Achieves better F1 scores and answer correctness
- More efficient parameter usage for superior results
### π Arabic RAG Excellence
- General-purpose Arabic question answering
- Context-aware responses grounded in provided information
- Modern Standard Arabic optimization
- Real-world RAG applications ready
## π― How to Use
1. **Paste Context**: Add any Arabic text containing information
2. **Ask Question**: Write your question in Arabic
3. **Get Answer**: Receive an accurate, extracted answer instantly
Perfect for: document analysis, information extraction, educational tools, customer support, and research applications.
## π§ Model Details
- **Base Model**: [LiquidAI/LFM2-1.2B-RAG](https://huggingface.co/LiquidAI/LFM2-1.2B-RAG)
- **Fine-tuning**: AdaLoRA (Adaptive Low-Rank Adaptation)
- **Dataset**: [ARCD](https://huggingface.co/datasets/hsseinmz/arcd) β 693 Arabic QA examples
- **Language**: Modern Standard Arabic
- **Architecture**: Hybrid model with multiplicative gates and convolutions
> β‘ The model can be further enhanced and evaluated on larger or similar Arabic QA datasets to improve generalization and robustness.
## β‘ Features
- π Real-time answer generation
- ποΈ Adjustable generation parameters
- π Pre-loaded example questions
- π Full RTL support for Arabic
- π Copy-to-clipboard functionality
- π» Works on any device (CPU/GPU)
## π Resources
- **Model Card**: [azeddinShr/LFM2-1.2B-RAG-ARABIC-AdaLoRA](https://huggingface.co/azeddinShr/LFM2-1.2B-RAG-ARABIC-AdaLoRA)
- **Training Dataset**: [ARCD](https://huggingface.co/datasets/hsseinmz/arcd)
- **Base Model**: [LiquidAI/LFM2-1.2B-RAG](https://huggingface.co/LiquidAI/LFM2-1.2B-RAG)
- **Comparison**: Also available - [LoRA variant](https://huggingface.co/azeddinShr/LFM2-1.2B-RAG-ARABIC-LoRA)
## π§ Contact
Questions or feedback? Visit the [model repository](https://huggingface.co/azeddinShr/LFM2-1.2B-RAG-ARABIC-AdaLoRA) or email me directly at [azdinsahir11@gmail.com](mailto:azdinsahir11@gmail.com) !
---
**Built with β€οΈ using LiquidAI, AdaLoRA, and Gradio** |