metadata
language:
- en
license: mit
size_categories:
- 100K<n<1M
task_categories:
- text-generation
pretty_name: UltraChat 200k
HuggingFaceH4/ultrachat_200k in ChatML format, ready to use in HuggingFace TRL's SFT Trainer.
Python code used for conversion:
from datasets import load_dataset
from transformers import AutoTokenizer
tokenizer = AutoTokenizer.from_pretrained("Felladrin/Llama-160M-Chat-v1")
dataset = load_dataset("HuggingFaceH4/ultrachat_200k", split="train_sft")
def format(columns):
return { "text": tokenizer.apply_chat_template(columns["messages"], tokenize=False) }
dataset.map(format).select_columns(['text', 'prompt', 'prompt_id']).to_parquet("train.parquet")