promptdojo_

CSV, JSONL, Parquet - which file earns the job — step 7 of 7

Checkpoint

One last thing before we move on. Same surface as a write step — but the lesson doesn't complete until this passes.

Prove the format tradeoff in code. Write csv_round_trip(record) (DictWriter to a StringIO, DictReader back) and jsonl_round_trip(record) (json.dumps then json.loads). Print whether each round-trip preserves the record exactly, then the repr of the CSV-returned amount.

full-screen editor opens — close anytime to keep reading.