|
|
--- |
|
|
language: |
|
|
- ar |
|
|
license: apache-2.0 |
|
|
task_categories: |
|
|
- text-generation |
|
|
- question-answering |
|
|
pretty_name: Fatwa Training Dataset (Standardized) |
|
|
tags: |
|
|
- islamic-jurisprudence |
|
|
- fatwa |
|
|
- sharia |
|
|
- fiqh |
|
|
- arabic |
|
|
- training |
|
|
- standardized |
|
|
- sahm-benchmark |
|
|
--- |
|
|
|
|
|
# Fatwa Training Dataset (Standardized) |
|
|
|
|
|
## Dataset Description |
|
|
|
|
|
This is the standardized conversation-format version of the Fatwa training dataset, containing Islamic jurisprudence Q&A pairs for training language models on Islamic legal rulings and religious guidance. |
|
|
|
|
|
### Dataset Summary |
|
|
|
|
|
- **Language:** Arabic |
|
|
- **Size:** ~11,700 training examples |
|
|
- **Domain:** Islamic jurisprudence, Sharia law, Fiqh |
|
|
- **Format:** Conversational (human-agent pairs) |
|
|
- **Task:** Islamic fatwa generation and religious Q&A |
|
|
|
|
|
## Dataset Structure |
|
|
|
|
|
### Data Fields |
|
|
|
|
|
- `id`: Unique identifier for each example |
|
|
- `conversations`: List containing human-agent dialogue |
|
|
- Human role: Contains the question with Islamic context framing |
|
|
- Agent role: Contains the fatwa/religious ruling |
|
|
- `category`: Category of the fatwa (e.g., murabaha, zakat, riba, etc.) |
|
|
- `is_referral`: Whether the answer mainly refers to other sources |
|
|
- `question_length`: Length of the question in characters |
|
|
- `answer_length`: Length of the answer in characters |
|
|
|
|
|
## Categories |
|
|
|
|
|
The dataset covers various Islamic jurisprudence topics including: |
|
|
- Murabaha (Islamic financing) |
|
|
- Zakat (obligatory charity) |
|
|
- Riba (usury/interest) |
|
|
- Salah (prayer) |
|
|
- Hajj (pilgrimage) |
|
|
- Business transactions |
|
|
- Family law |
|
|
- And many more categories |
|
|
|
|
|
## Example |
|
|
|
|
|
```json |
|
|
{ |
|
|
"id": "fatwa_00446", |
|
|
"conversations": [ |
|
|
{ |
|
|
"role": "human", |
|
|
"content": "بناءً على أحكام الشريعة الإسلامية والفقه الإسلامي، أجب على السؤال التالي بفتوى شرعية مفصلة ومدعمة بالأدلة عند الإمكان.\n\nالسؤال: تحريم الشيء هل يقتضي الفساد؟\n\nالفتوى الشرعية:" |
|
|
}, |
|
|
{ |
|
|
"role": "agent", |
|
|
"content": "قد يقتضي الفساد، وقد لا يقتضي الفساد، فالنهي عن البيع يقتضي فساد البيع..." |
|
|
} |
|
|
], |
|
|
"category": "riba", |
|
|
"is_referral": "NO", |
|
|
"question_length": 45, |
|
|
"answer_length": 234 |
|
|
} |
|
|
``` |
|
|
|
|
|
## Usage |
|
|
|
|
|
```python |
|
|
from datasets import load_dataset |
|
|
|
|
|
# Load the dataset |
|
|
dataset = load_dataset("SahmBenchmark/fatwa-training_standardized") |
|
|
train_data = dataset['train'] |
|
|
|
|
|
# Access an example |
|
|
example = train_data[0] |
|
|
conversation = example['conversations'] |
|
|
print(f"Category: {example['category']}") |
|
|
print(f"Question: {conversation[0]['content']}") |
|
|
print(f"Fatwa: {conversation[1]['content']}") |
|
|
``` |
|
|
|
|
|
## Training Considerations |
|
|
|
|
|
When using this dataset for training: |
|
|
- Ensure the model understands the religious and cultural context |
|
|
- Be aware that fatwas may vary based on different schools of Islamic thought |
|
|
- The dataset represents specific interpretations and should be used accordingly |
|
|
- Consider the sensitivity of religious rulings in production applications |
|
|
|
|
|
## Citation |
|
|
|
|
|
```bibtex |
|
|
@dataset{fatwa_training_standardized_2025, |
|
|
title={Fatwa Training Dataset (Standardized)}, |
|
|
author={SahmBenchmark}, |
|
|
year={2025}, |
|
|
publisher={Hugging Face} |
|
|
} |
|
|
``` |
|
|
|
|
|
## Disclaimer |
|
|
|
|
|
This dataset is for academic and research purposes. Religious rulings should be sought from qualified Islamic scholars for practical application. |
|
|
|