Pipeline.SessionManager (pipeline v0.0.1)

View Source

Session management for persistent Claude conversations.

Provides session creation, retrieval, checkpointing, and lifecycle management for claude_session step types. Sessions can persist across pipeline runs and maintain conversation context.

Summary

Functions

Checkpoint session data for persistence.

Continue an existing session with a new prompt. Returns {:ok, response} or {:error, reason}.

Create a new session with the given name and options.

Get an existing session by session_id. Returns nil if session not found.

List all available sessions.

Functions

checkpoint_session(session_id, data)

Checkpoint session data for persistence.

continue_session(session_id, prompt)

Continue an existing session with a new prompt. Returns {:ok, response} or {:error, reason}.

create_session(session_name, options \\ %{})

Create a new session with the given name and options.

Options

  • persist: Whether to persist the session across restarts (default: false)
  • max_turns: Maximum turns allowed in the session (default: 50)
  • checkpoint_interval: How often to checkpoint (default: 5 interactions)

get_session(session_id)

Get an existing session by session_id. Returns nil if session not found.

list_sessions()

List all available sessions.