Update dataset card
Browse files
README.md
CHANGED
|
@@ -1,34 +1,122 @@
|
|
| 1 |
---
|
| 2 |
-
|
| 3 |
-
|
| 4 |
-
|
| 5 |
-
|
| 6 |
-
|
| 7 |
-
|
| 8 |
-
|
| 9 |
-
|
| 10 |
-
|
| 11 |
-
|
| 12 |
-
|
| 13 |
-
|
| 14 |
-
|
| 15 |
-
|
| 16 |
-
|
| 17 |
-
|
| 18 |
-
splits:
|
| 19 |
-
- name: validation
|
| 20 |
-
num_bytes: 264608
|
| 21 |
-
num_examples: 125
|
| 22 |
-
- name: test
|
| 23 |
-
num_bytes: 262349
|
| 24 |
-
num_examples: 125
|
| 25 |
-
download_size: 263389
|
| 26 |
-
dataset_size: 526957
|
| 27 |
-
configs:
|
| 28 |
-
- config_name: default
|
| 29 |
-
data_files:
|
| 30 |
-
- split: validation
|
| 31 |
-
path: data/validation-*
|
| 32 |
-
- split: test
|
| 33 |
-
path: data/test-*
|
| 34 |
---
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
---
|
| 2 |
+
language:
|
| 3 |
+
- ar
|
| 4 |
+
license: apache-2.0
|
| 5 |
+
task_categories:
|
| 6 |
+
- question-answering
|
| 7 |
+
- text-generation
|
| 8 |
+
pretty_name: Fatwa Q&A Evaluation Dataset
|
| 9 |
+
tags:
|
| 10 |
+
- islamic-jurisprudence
|
| 11 |
+
- fatwa
|
| 12 |
+
- sharia
|
| 13 |
+
- fiqh
|
| 14 |
+
- evaluation
|
| 15 |
+
- benchmark
|
| 16 |
+
- arabic
|
| 17 |
+
- sahm-benchmark
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 18 |
---
|
| 19 |
+
|
| 20 |
+
# Fatwa Q&A Evaluation Dataset
|
| 21 |
+
|
| 22 |
+
## Dataset Description
|
| 23 |
+
|
| 24 |
+
Evaluation dataset for Islamic jurisprudence Q&A, extracted from the Fatwa MCQ evaluation dataset. This dataset contains validation and test splits for evaluating language models on Islamic legal rulings and religious guidance.
|
| 25 |
+
|
| 26 |
+
### Dataset Summary
|
| 27 |
+
|
| 28 |
+
- **Language:** Arabic
|
| 29 |
+
- **Size:** 250 evaluation examples (125 validation, 125 test)
|
| 30 |
+
- **Domain:** Islamic jurisprudence, Sharia law, Fiqh
|
| 31 |
+
- **Format:** Simple prompt-answer pairs
|
| 32 |
+
- **Task:** Fatwa generation evaluation
|
| 33 |
+
|
| 34 |
+
## Dataset Structure
|
| 35 |
+
|
| 36 |
+
### Data Fields
|
| 37 |
+
|
| 38 |
+
- `id`: Unique identifier for each example
|
| 39 |
+
- `prompt`: The full prompt with Islamic context and question
|
| 40 |
+
- `question`: The original question text
|
| 41 |
+
- `answer`: Ground truth fatwa/religious ruling
|
| 42 |
+
- `category`: Category of the fatwa (murabaha, ijara, takaful, sukuk, etc.)
|
| 43 |
+
- `question_length`: Length of the question in characters
|
| 44 |
+
- `answer_length`: Length of the answer in characters
|
| 45 |
+
|
| 46 |
+
### Data Splits
|
| 47 |
+
|
| 48 |
+
- **Validation**: 125 examples (50%)
|
| 49 |
+
- **Test**: 125 examples (50%)
|
| 50 |
+
|
| 51 |
+
## Categories
|
| 52 |
+
|
| 53 |
+
The dataset covers various Islamic finance and jurisprudence topics:
|
| 54 |
+
- Murabaha (Islamic financing)
|
| 55 |
+
- Ijara (Islamic leasing)
|
| 56 |
+
- Takaful (Islamic insurance)
|
| 57 |
+
- Sukuk (Islamic bonds)
|
| 58 |
+
- General Islamic jurisprudence
|
| 59 |
+
|
| 60 |
+
## Example
|
| 61 |
+
|
| 62 |
+
```json
|
| 63 |
+
{
|
| 64 |
+
"id": "fatwa_eval_00009",
|
| 65 |
+
"prompt": "بناءً على أحكام الشريعة الإسلامية والفقه الإسلامي، أجب على السؤال التالي بفتوى شرعية مفصلة ومدعمة بالأدلة عند الإمكان.\n\nالسؤال: [question text]\n\nالفتوى الشرعية:",
|
| 66 |
+
"question": "[Original question]",
|
| 67 |
+
"answer": "[Ground truth fatwa]",
|
| 68 |
+
"category": "murabaha",
|
| 69 |
+
"question_length": 234,
|
| 70 |
+
"answer_length": 567
|
| 71 |
+
}
|
| 72 |
+
```
|
| 73 |
+
|
| 74 |
+
## Usage
|
| 75 |
+
|
| 76 |
+
```python
|
| 77 |
+
from datasets import load_dataset
|
| 78 |
+
|
| 79 |
+
# Load the evaluation dataset
|
| 80 |
+
dataset = load_dataset("SahmBenchmark/fatwa-qa-evaluation")
|
| 81 |
+
|
| 82 |
+
# Access splits
|
| 83 |
+
val_data = dataset['validation']
|
| 84 |
+
test_data = dataset['test']
|
| 85 |
+
|
| 86 |
+
# Evaluation example
|
| 87 |
+
for example in test_data:
|
| 88 |
+
model_output = model.generate(example['prompt'])
|
| 89 |
+
ground_truth = example['answer']
|
| 90 |
+
|
| 91 |
+
# Evaluate the generated fatwa
|
| 92 |
+
score = evaluate_fatwa(model_output, ground_truth)
|
| 93 |
+
```
|
| 94 |
+
|
| 95 |
+
## Evaluation Considerations
|
| 96 |
+
|
| 97 |
+
When evaluating models on this dataset:
|
| 98 |
+
- Consider theological accuracy and adherence to Islamic principles
|
| 99 |
+
- Evaluate the quality of evidence and references provided
|
| 100 |
+
- Assess clarity and comprehensiveness of the fatwa
|
| 101 |
+
- Be aware that fatwas may vary based on different schools of Islamic thought
|
| 102 |
+
- Consider using semantic similarity metrics in addition to exact matching
|
| 103 |
+
|
| 104 |
+
## Related Datasets
|
| 105 |
+
|
| 106 |
+
- Training dataset: `SahmBenchmark/fatwa-training_standardized`
|
| 107 |
+
- MCQ evaluation: `SahmBenchmark/fatwa-mcq-evaluation`
|
| 108 |
+
|
| 109 |
+
## Citation
|
| 110 |
+
|
| 111 |
+
```bibtex
|
| 112 |
+
@dataset{fatwa_qa_evaluation_2025,
|
| 113 |
+
title={Fatwa Q&A Evaluation Dataset},
|
| 114 |
+
author={SahmBenchmark},
|
| 115 |
+
year={2025},
|
| 116 |
+
publisher={Hugging Face}
|
| 117 |
+
}
|
| 118 |
+
```
|
| 119 |
+
|
| 120 |
+
## Disclaimer
|
| 121 |
+
|
| 122 |
+
This dataset is for academic and research purposes. Religious rulings should be sought from qualified Islamic scholars for practical application.
|