Chat Dataset Format Cleaner
Convert local chat JSONL records into prompt/completion pairs and a reproducible train/validation split.
$12
Works with the AI Agents you already use
Chat Dataset Format Cleaner
Example session with this skill installed
Clean examples/conversations.jsonl and write the train/validation files to /tmp/chat-clean with seed 42.
- Read your context and instructions
- Compiled the chat dataset format
Ran: python3 scripts/chat_dataset_cleaner.py examples/conversations.jsonl --output-dir /tmp/chat-clean --seed 42
Read 3 records; converted 3; rejected 0; filtered 0.
Train: /tmp/chat-clean/train.jsonl (2 records)
Validation: /tmp/chat-clean/validation.jsonl (1 records)
Each saved line is a JSON object with exactly two keys: prompt and completion. This is the actual output of the bundled example file (3 sample records).
Connects securely to your tools. The creator never sees your data.
About this skill
Turn local chat JSONL into portable prompt/completion JSONL files. The command accepts OpenAI-style messages records and direct prompt/completion records, strips common turn wrapper tags, maps human and model aliases, and uses the last assistant turn as the answer. Input files are read only; output goes to a directory you choose.
What it does
- Reads one or more JSONL files, or the immediate
*.jsonlfiles in a folder. - Converts message arrays into a labeled prompt plus the final assistant completion; keeps direct prompt/completion pairs after whitespace and wrapper cleanup.
- Skips malformed JSON lines and unsupported records and reports how many were skipped.
- Splits train and validation sets with a repeatable seed and a configurable ratio.
- Optional minimum prompt and completion length filters, a record limit, and a JSON summary for automation.
Requirements
Python 3.10 or newer, standard library only. No network access, no uploads.
Included
SKILL.md, README, the script (scripts/chat_dataset_cleaner.py), 22 unit tests, a 3-record example file, and a license for personal or commercial projects.
Limitations
It does not judge semantic quality, remove personal information, deduplicate examples, or preserve non-text content blocks. Use a new output directory if you need to keep earlier generated files.
Find more skills like this on the Claude Skills Marketplace, the Codex Skills Marketplace and the Gemini Skills Marketplace, or browse Claude Skills for LLM Ops.
No PII removal or deduplication. Ignores tool-call semantics and non-text blocks. Requires Python 3 environment.
How to use
- 1
Connect your agent to the Agensi MCP
Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup
- 2
Sign in to Agensi
Your agent shows a sign-in link. Sign in and click Allow.
- 3
Ask for what you need
Your agent loads this skill and uses it on your task. It always asks before buying a skill.
Reviews
No reviews yet
Be one of the first to try it. Every listed skill goes through the trust checks below.
Security scanned
Checked by our 8-point scan before listing
Fresh listing
Recently published to Agensi
Money-back guarantee
Doesn't do what its page promises? You get your money back.
Trust & safety
Security scan
Security scan passed 8 days ago
- Software
Python