File size: 3,156 Bytes
b85faf5
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
c3f6ae4
 
 
 
 
 
 
 
 
 
 
 
b85faf5
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
---
license: mit
task_categories:
- question-answering
- text-classification
- text-generation
---
# Hindi Web Content Dataset
## Overview
This dataset contains a collection of Hindi text data scraped from various websites. The data was collected using a domain-restricted scraper that extracts paragraphs of text from specified domains. The dataset includes content from news articles, literature, and other web pages. The scraped text has been stored in JSON format and is intended for use in natural language processing (NLP) tasks, such as language modeling, text generation, and sentiment analysis.
## Dataset Details
* Size: At least 30MB of text data
* Language: Hindi
* Format: JSON
* Source Domains:
+ [NDTV Hindi](https://ndtv.in)
+ [Jansatta](https://www.jansatta.com)
+ [Hindwi](https://www.hindwi.org)
## Structure of the Dataset
The dataset is stored in a JSON file named scraped_data.json. Each entry in the JSON file corresponds to a web page and contains the following fields:
* url: The URL of the web page.
* title: The title of the web page.
* paragraphs: A list of paragraphs extracted from the web page.
### Example Entry

```json
{
    "url": "https://example.com/article",
    "title": "Example Article Title",
    "paragraphs": [
        "This is the first paragraph of the article.",
        "This is the second paragraph of the article.",
        // More paragraphs...
    ]
}
```
}
## How to Use Load the Dataset
You can load the JSON file using standard Python libraries such as json or use data processing libraries like pandas.
import json
with open('scraped_data.json', 'r', encoding='utf-8') as file:
data = json.load(file)
Data Processing
Once loaded, you can process the data for your specific NLP tasks. For instance, you can concatenate all paragraphs for text generation models or tokenize the text for sentiment analysis.
Example Usage
Below is an example of how you can iterate through the dataset and process the paragraphs.
for entry in data:
url = entry['url']
title = entry['title']
paragraphs = entry['paragraphs']
# Process the paragraphs
for paragraph in paragraphs:
# Your processing code here
pass
Loading the Dataset with Hugging Face
You can also load this dataset directly using the Hugging Face datasets library. The dataset is available under the identifier Threatthriver/Hindi-story-news.
Example Code
from datasets import load_dataset
ds = load_dataset("Threatthriver/Hindi-story-news")
This will load the dataset into a datasets.Dataset object, which you can then use for various NLP tasks.
License
The data scraped from the mentioned websites is subject to their respective terms of use and copyright policies. Users of this dataset must ensure that their use complies with these terms and respects the intellectual property rights of the content owners.
Acknowledgements
We acknowledge the efforts of the content creators and website owners for providing valuable information in the Hindi language. Their contributions are invaluable for advancing NLP research and applications in regional languages.
Contact
For any questions or issues regarding this dataset, please feel free to reach out to us.