Skip to main content

Task-level loading

ATIF trajectories

Place an ATIF file named trajectory.json in the same directory as instruction.md. For a multi-step task, place it in the first step’s directory. Harbor loads it when the agent supports ATIF loading. Task-level ATIF example

Run-level loading

Run-level loading overrides task-level loading. .json selects ATIF. Other suffixes select the agent’s native loader. The claude-code and codex native loaders expect .jsonl and validate filenames. load_trajectory cannot be combined with a simulated user_agent.

Native trajectories

Native trajectories are agent-specific .jsonl session files. Loading one is lossless and requires the same agent. Harbor stores them under agent/sessions/: Run-level native example
Keep the filename when moving the file; the agent uses it to identify the session.

ATIF trajectories

Harbor stores ATIF output at agent/trajectory.json. ATIF is portable: Harbor converts it to the loading agent’s native format, allowing one agent’s trajectory to seed another. Run-level ATIF example
Conversion preserves supported messages, tool calls, and tool results. It may omit agent-specific details, system messages, and non-text content. Agents declare support for each format with capabilities.load_native_trajectory and capabilities.load_atif_trajectory. Unsupported formats, missing files, invalid ATIF, and invalid native filenames fail before startup. Invalid native contents may fail during resume. The examples above use the CLI. To use a job config instead:

What is restored

Native loading restores the native session. ATIF loading restores portable conversation content. Neither restores sandbox files. For multi-step tasks, loading occurs before the first step. With --resume-trajectory, sessions are (load, resume, resume, ...); otherwise, (load, fresh, fresh, ...).