High-performance streaming NLP dataset ingestion engine
Project description
NLP Dataset Engine
A high-performance streaming ingestion engine for terabyte-scale NLP datasets. Built for GSoC 2026 preparation.
User Installation
pip install nlp-engine-yuvraj
Features
- Lazy Loading: Processes datasets larger than RAM using Python generators.
- Auto-Validation: Automatically drops empty or short text records.
- Observability: Provides detailed statistical reports on data quality.
- CLI Interface: simple command-line usage.
Installation
# Clone the repo
git clone [https://github.com/rgb-99/nlp-dataset-engine.git](https://github.com/rgb-99/nlp-dataset-engine.git)
# Install in editable mode
cd nlp-dataset-engine
pip install -e .[dev]
Usage
1. Ingest Data (CSV → JSONL)
Convert massive raw CSV files into clean, validated JSONL datasets for AI training. This runs in O(1) memory.
# Basic usage
nlp-engine ingest --input raw_data.csv --output clean_dataset.jsonl --col text
2. Automatic Observability & Filtering
The engine automatically enforces data quality:
- Language Detection: Removes non-English text by default.
- Health Report: Prints a statistical summary (drop rate, speed, count) after every run.
- Noise Filtering: Rejects rows where >30% of characters are symbols or numbers (e.g., "### 12345").
Disable English Filtering:
If you want to keep all languages (e.g., for a multilingual dataset), use the
--no-englishflag:
nlp-engine ingest --input global_data.csv --output clean.jsonl --no-english
3. Recursive Folder Ingestion
Process an entire directory of data files (CSVs and TXTs) at once. The engine will find all compatible files in subfolders, process them, and aggregate the statistics.
# Ingest entire folder recursively
nlp-engine ingest --input ./data/raw_dump/ --output ./data/clean_combined.jsonl
4. Advanced Production Features (Big Data)
For massive datasets (Terabytes), use these flags to manage resources and failures.
Sharding: Automatically split output into smaller chunks (e.g., 10k rows per file).
nlp-engine ingest --input ./data --output clean.jsonl --shard-size 10000
# Output: clean-0000.jsonl, clean-0001.jsonl...
5. Data Integrity & Compression
Ensure your dataset is safe, verifiable, and compact.
Compression: Use --compress to save disk space (GZIP).
nlp-engine ingest --input ./data --output final.jsonl --compress
# Output: final-0000.jsonl.gz, final-0001.jsonl.gz...
6. Benchmarking
Measure the raw throughput (rows/second) of your environment. This runs the pipeline without writing to disk to test CPU/Validation speed.
nlp-engine benchmark --input large_dataset.csv
# Output:
# BENCHMARK RESULTS
# Rows/Sec: 12500.0
# MB/Sec: 15.2 MB/s
# BENCHMARK RESULTS
# Rows/Sec: 12500.0
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file nlp_engine_yuvraj-0.1.1.tar.gz.
File metadata
- Download URL: nlp_engine_yuvraj-0.1.1.tar.gz
- Upload date:
- Size: 13.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
58d7a73562e3c56fbb93ed573d0bca738a664a8318c1817422c3ab1ae375ca77
|
|
| MD5 |
8212649fb5b14fd4d03d8788bc9617dc
|
|
| BLAKE2b-256 |
387aabeef187bc0fde2c5ac36e4d9d3aceb24c9ca209348d2c84d72044df086b
|
File details
Details for the file nlp_engine_yuvraj-0.1.1-py3-none-any.whl.
File metadata
- Download URL: nlp_engine_yuvraj-0.1.1-py3-none-any.whl
- Upload date:
- Size: 13.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
faf8150ce9078f022d3eb68f2c81fb873206bd2b7584b51dc2ba59f132638acf
|
|
| MD5 |
167ccf15ebcf54ddd1bfa03b434c845e
|
|
| BLAKE2b-256 |
0bb426169a446b9e9fab75899a1ae9abbf69d6eb6e0f3728feb7041c98a2d0e7
|