Switch trajectory storage from YAML to JSONL format#204
Merged
Conversation
45e03c8 to
4a1e99b
Compare
a6fe2a3 to
4a1e99b
Compare
bradhilton
approved these changes
Jul 7, 2025
This change migrates our trajectory logging from YAML to JSONL format, achieving a 160x speedup in loading (1.9s vs 300s) and ~6% smaller files. Changes: - Update trajectory_logging.py to serialize as JSONL (one JSON object per line) - Update backend to save files with .jsonl extension - Add backward compatibility to read both YAML and JSONL formats - Consolidate duplicate load_trajectories implementations - Add new aggregate_trajectories module for step-level aggregation My bad for originally suggesting YAML - the human readability wasn't worth the performance cost. We'll add better observability tools to compensate for the reduced readability of JSONL files. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
4a1e99b to
46e9aea
Compare
surajpatildev
pushed a commit
to meetkiara/ART
that referenced
this pull request
May 20, 2026
Switch trajectory storage from YAML to JSONL format
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Why this change?
Kyle originally suggested using YAML for human readability, but the performance cost turned out to be too high. This PR switches to JSONL (newline-delimited JSON) format while maintaining full backward compatibility.
Changes
trajectory_logging.pyto serialize as JSONL (one JSON object per line).jsonlextensionload_trajectoriesimplementations (removed art-e specific version)aggregate_trajectoriesmodule for step-level metric aggregationBackward Compatibility
.yamland.jsonlfilesTrade-offs
Test plan
🤖 Generated with Claude Code