File size: 1,709 Bytes
a15b28b
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
# BharatGPT
## Data Curation for English Foundational Model

### RedPajamaV2

`RedPajamaV2` directory contains scripts for processing and filtering of [RedPajamaV2](https://www.together.ai/blog/redpajama-data-v2) dataset.

Overall pipeline is as follows:

1. **URL Filtering** `scripts/utils/url_filtering.py`: The first step of filtering is URL based. We use a blocklist of URLs known to contain inappropriate content. This list is taken from [blocklistproject](https://github.com/blocklistproject/Lists.git). It contains categories for advertisements, gambling, adult content, etc. All documents having URL source domain in these lists is filtered-out from any further processing.
2. **Quality Filtering** `scripts/utils/quality_signals_filtering.py`: Three processing steps take place here:
    - **Duplicate Removal**: Exact duplicates as computed by RPv2 are removed at this step.
    - **Filtering by quality-signals**: Based on quality annotations provided by RPv2, we filter-out documents that do not fit our various criteria. The report contains a detailed description of these.
    - **Filtering by repetition-removal**: We filter documents that contain too much repetition.
3. **Minhash Deduplication** `scripts/utils/minhash_clusters_filtering.py`: Here we remove fuzzy-duplicate documents identified after minhash-clustering.

These steps are directly inspired from RefinedWeb. This has closed-source implementation and authors released only a fraction of the entire dataset.

### Other Datasets

`Data_Info` contains a script for fast downloads from HuggingFace. It is taken from [this gist](https://gist.github.com/padeoe/697678ab8e528b85a2a7bddafea1fa4f). Its usage is in `download-notes.md`.