Upload README.md with huggingface_hub
Browse files
README.md
ADDED
|
@@ -0,0 +1,52 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
license: openrail
|
| 3 |
+
language:
|
| 4 |
+
- ar
|
| 5 |
+
- en
|
| 6 |
+
tags:
|
| 7 |
+
- hadith
|
| 8 |
+
- islam
|
| 9 |
+
- religion
|
| 10 |
+
- arabic
|
| 11 |
+
size_categories:
|
| 12 |
+
- 100K<n<1M
|
| 13 |
+
---
|
| 14 |
+
|
| 15 |
+
# 📚 Comprehensive Hadith Dataset
|
| 16 |
+
|
| 17 |
+
Welcome to the **Comprehensive Hadith Dataset**. This repository contains a highly structured and categorized collection of Hadiths (Prophetic traditions), optimized for developers and AI researchers.
|
| 18 |
+
|
| 19 |
+
## 🗂 Dataset Structure
|
| 20 |
+
|
| 21 |
+
The dataset is divided into flexible structures to accommodate all use cases:
|
| 22 |
+
|
| 23 |
+
### 1. The Core Dataset (`all_hadiths.jsonl`)
|
| 24 |
+
- Contains all Hadiths in a single, flattened JSONL format.
|
| 25 |
+
- Perfect for NLP tasks, machine learning, and semantic search engines.
|
| 26 |
+
- Hugging Face automatically parses this for the Dataset Viewer.
|
| 27 |
+
|
| 28 |
+
### 2. By Category (`by_category/`)
|
| 29 |
+
- Contains Hadiths grouped by their specific topics (e.g., Purification, Prayer, Fasting).
|
| 30 |
+
- Ideal for developers building apps focused on specific Islamic topics.
|
| 31 |
+
|
| 32 |
+
### 3. Metadata and Indexes
|
| 33 |
+
- `categories_index.json` and `manifest.json` provide a complete tree of available categories.
|
| 34 |
+
|
| 35 |
+
## 🚀 How to Use (Python / AI)
|
| 36 |
+
|
| 37 |
+
You can load all Hadiths effortlessly using the datasets library:
|
| 38 |
+
```python
|
| 39 |
+
from datasets import load_dataset
|
| 40 |
+
|
| 41 |
+
dataset = load_dataset("Islamiccontent/Hadith-Dataset")
|
| 42 |
+
print(dataset['train'][0])
|
| 43 |
+
```
|
| 44 |
+
|
| 45 |
+
## 💻 How to Use (Web & Mobile Developers)
|
| 46 |
+
You can easily fetch specific category files directly via REST API:
|
| 47 |
+
```javascript
|
| 48 |
+
// Example: Fetch a specific category by its ID
|
| 49 |
+
const response = await fetch("https://huggingface.co/datasets/Islamiccontent/Hadith-Dataset/resolve/main/by_category/1.json");
|
| 50 |
+
const categoryData = await response.json();
|
| 51 |
+
console.log(categoryData);
|
| 52 |
+
```
|