Skip to content

xlm.tasks.tinygsm.make_local_csv

Write a small streamed sample of TinyGSM/TinyGSM to a local CSV.

Streaming avoids downloading the full train split. The CSV has question and code columns and is consumed by the tinygsm_local_sample dataset configs (LocalDatasetManager, ds_type csv).

Usage

DATA_DIR=/tmp/xlm_data python -m xlm.tasks.tinygsm.make_local_csv

write_tinygsm_sample_csv(out_path, num_examples=10, split='train', repo_id='TinyGSM/TinyGSM')

Stream the first num_examples rows of a TinyGSM split into a CSV.

quoting is QUOTE_ALL so multi-line code survives the Hugging Face csv loader.