Academy → Developer guideOfficial documentation · clear explanation

Trajectory Format

Trajectory Format

Developer11 minutes3 questions2026-08-09
The idea in one minute

Start with meaning, then move to detail.

This lesson explains Trajectory Format as part of Hermes internals and extension points. You will learn what it does, when it matters, and the smallest safe test that proves it works.

If you are new

If you are new, do not memorize names. Focus on three questions: what problem does this solve, what access does it need, and how can you verify the result?

For hands-on use

For practice, inspect the first example, identify its effects, run it on test data, and compare the result with the source claim.

For specialists

For advanced readers, inspect File Naming Convention, JSONL Entry Format, CLI/Interactive Format (from savetrajectory), then verify failure modes and version compatibility.

What do you need first?

Know Python, Git, and basic project structure before changing code.

What will you know?

A clear outcome before you read.

  • Understand Trajectory Format without assumed prior knowledge.
  • Separate the source description from what still needs testing in your environment.
  • Read the first command and identify its inputs and outputs before copying it.
Lesson terms

Short definitions before the details.

Tool
A structured action the agent can call to read or change something.
Topic map

What does the source say, and in what order?

  1. 01
    File Naming Convention

    Start here to understand the core idea or structure.

  2. 02
    JSONL Entry Format

    Read this after the foundation, then connect it to the previous step.

  3. 03
    CLI/Interactive Format (from savetrajectory)

    Read this after the foundation, then connect it to the previous step.

  4. 04
    Batch Runner Format (from batchrunner.py)

    Read this after the foundation, then connect it to the previous step.

  5. 05
    Conversations Array (ShareGPT Format)

    Read this after the foundation, then connect it to the previous step.

  6. 06
    Complete Example

    Read this after the foundation, then connect it to the previous step.

  7. 07
    Normalization Rules

    Read this after the foundation, then connect it to the previous step.

  8. 08
    Reasoning Content Markup

    Read this after the foundation, then connect it to the previous step.

  9. 09
    Tool Call Normalization

    Read this after the foundation, then connect it to the previous step.

  10. 10
    Tool Response Normalization

    Finish here to verify the result and special cases.

Examples from the official page

Copy only after you understand the effect.

{ "conversations": [ ... ], "timestamp": "2026-03-30T14:22:31.456789", "model": "anthropic/claude-sonnet-4.6", "completed": true }
{ "prompt_index": 42, "conversations": [ ... ], "metadata": { "prompt_source": "gsm8k", "difficulty": "hard" }, "completed": true, "partial": false, "api_calls": 7, "toolsets_used": ["code_tools", "file_tools"], "tool_stats": { "terminal": {"count": 3, "success": 3, "failure": 0}, "read_file": {"count": 2, "success": 2, "failure": 0}, "write_file": {"count": 0, "success": 0, "failure": 0} }, "tool_error_counts": { "terminal": 0, "read_file": 0, "write_file": 0 } }
{ "conversations": [ { "from": "system", "value": "You are a function calling AI model. You are provided with function signatures within <tools> </tools> XML tags. You may call one or more functions to assist with the user query. If available tools are not relevant in assisting with user query, just respond in natural conversational language. Don't make assumptions about what values to plug into functions. After calling & executing the functions, you will be provided with function results within <tool_response> </tool_response> XML tags. Here are the available tools:\n<tools>
Try it now

Read the first command and identify its inputs and outputs before copying it.

Match every command to your installed Hermes version, review the files and accounts it can reach, and use non-sensitive data for the first test. If this explanation differs from the source, the official source wins.

Knowledge check

Three decisions before completion.

1. What is the source of truth when “Trajectory Format” changes?
2. What is the best way to apply this lesson?
3. What should happen before a step can modify files or an external account?