Skip to content

Prime Agent

Prime Agent stores local version-3 JSONL session trees. Hansard imports ordinary conversations, active branches, forks, and recursive language-model children from those session files; provider authentication remains entirely inside Prime Agent.

Source Use it for
prime-agent Root sessions, historical layouts, forks, and linked RLM child sessions.

Hansard scans Prime Agent’s current flat session directory as well as its early working-directory trees and legacy root JSONL layout. Every audited stable release writes the same version-3 tree envelope, with additive lifecycle, repository, service-tier, child-usage, and RLM records. Inherited pi v1/v2 migration readers are not evidence that Prime produced those formats, so the Prime importer accepts only its strict v3 superset.

The normalized conversation and semantic metadata follow the parent chain ending at the last physical entry, matching Prime Agent’s active-leaf resume behavior. User and assistant messages, images, reasoning, tool calls and results, model settings, usage, lifecycle events, and repository/status state are converted on that basis. Abandoned branch rows remain in byte-perfect raw preservation.

Recursive language-model runs are imported as linked child sessions. Their explicit usage stays attributable to the child while the parent preserves the relationship. Resuming an existing Prime Agent session refreshes the same archive entry; creating a fork produces a new linked conversation. The Hansard session importer reads conversation records only: provider credentials, configuration secrets, and general application logs are outside the import surface.

Prime Agent’s cross-session continual harness is archived through the separate memory backup path. hansard memory backup snapshots ~/.prime/agent/harness/harness_state.json and the global refinements.jsonl history as editable global memory records. Session-local harness state remains in its originating session’s raw archive and is not promoted to project-wide or global memory. Ordinary session metadata contains only the harness schema and entry/refinement counts, not its prompt, memory, skill, or subagent content.

Terminal window
hansard import --source prime-agent --since all
hansard memory backup
hansard index rebuild

Hansard discovers the standard ~/.prime/agent store. Use HANSARD_PRIME_AGENT_SESSION_DIR when the sessions live elsewhere.

Install the current release with Prime Intellect’s installer, start the CLI, and use /login to connect a model provider:

Terminal window
curl -fsSL https://app.primeintellect.ai/prime-agent/install.sh | sh
prime-agent
prime-agent model list

The audited Prime Agent model catalog shows the routes bundled with the pinned release. It is a compatibility reference, not an account-entitlement list; prime-agent model list is the live answer for the signed-in machine.

After the import finishes, open Conversations and selectFilter & sort. Set Source toAll sources, choose the backfill window underTime, and use Folder when the same harness appears in several projects. Select a result to inspect its messages, tool calls and results, files, commits, model and usage fields, and source provenance in one conversation view.

For a local source that should stay current, open Settings → Indexing & Imports. Automatic follows detected local harnesses; Custom lets Sources scannedselect an explicit set. Explicit cloud and account-export sources do not turn into background network jobs here. If the expected result is absent after resetting the conversation filters, return to the terminal import in this guide and add --explain-skips where supported.

  • User and assistant text, images, reasoning, tools and results, shell executions, model routes, response IDs, finish state, token direction, and provider-reported cost.
  • Model, reasoning-effort, and service-tier changes applied to later turns.
  • Active-branch summaries, context compaction, lifecycle, task, repository, branch, commit, and bounded extension metadata; abandoned branches remain available in raw preservation.
  • Fork ancestry and linked RLM children, including child token and cost attribution when Prime Agent records it explicitly.
  • Session-local continual-harness state in raw preservation, with only schema and prompt, memory, skill, subagent, and refinement counts in session metadata.
  • User images and extension attachments in the content-addressed attachment sidecar rather than inline base64.

Prime Agent can resume a history in place or fork it:

Terminal window
prime-agent --continue
prime-agent --resume <path-or-id>
prime-agent --fork <path-or-id>

A resume updates the same Hansard conversation on the next import. A fork becomes a separate conversation with its parent reference retained.

  • A route in the bundled model catalog does not guarantee that the signed-in account can use it.
  • Registry, scheduler, and artifact JSONL files without a valid session header are rejected instead of being guessed into conversations.
  • Version-1, version-2, mixed, malformed, changed-during-read, and over-limit session files fail closed rather than sharing pi’s converter implicitly.
  • Session-local continual-harness content is raw provenance rather than a project or global memory item; only the global harness enters memory search.
  • Prime Agent credentials are intentionally excluded. Hansard does not read, copy, or raw-preserve auth.json, API keys, OAuth tokens, configuration, daemon logs, or installed package resources.
Terminal window
hansard import --source prime-agent --since all
hansard index rebuild

Prime Agent parser changes require a source reimport because routed model, service-tier, lifecycle, attachment, lineage, and local continual-harness data comes from the original JSONL and session-owned artifacts. Hansard does not apply an in-place compatibility repair to older normalized archives.