Loading ACP sessions from disk
First complete Setting up Claude Code through ACP or Setting up Codex through ACP.
Inspect GtLACPClaudeCodeSessionStore
or GtLACPCodexSessionStore
to browse saved sessions and copy a session ID:
claudeStore := GtLACPClaudeCodeSessionStore new read. claudeStore
codexStore := GtLACPCodexSessionStore new read. codexStore
The default storage roots are ~/.claude and ~/.codex. Set CLAUDE_CONFIG_DIR or CODEX_HOME in GT's environment to use another location.
Replace the ID below to load a Claude Code session with GtLACPExternalSessionStore>>#loadSession:configureClient:
. The store finds the project directory and creates the matching client:
sessionId := 'your-session-id'.
session := claudeStore
loadSession: sessionId
configureClient: [ :client |
client configuration requestTimeout: 180 ].
session
For Codex, use codexStore in the same expression. Send GtLACPExternalSessionStore>>#read
again to refresh the list.
When only the ID is known, traverse both stores using GtLACPExternalSessionStore>>#sessionWithId:ifPresent:
:
sessionId := 'your-session-id'.
session := nil.
stores := {
GtLACPClaudeCodeSessionStore new read.
GtLACPCodexSessionStore new read }.
stores do: [ :store |
store
sessionWithId: sessionId
ifPresent: [ :storedSession |
session := store
loadSession: storedSession sessionId
configureClient: [ :client |
client configuration requestTimeout: 180 ] ] ].
session
The result is nil when neither store contains the ID. If both match, both sessions are loaded and the last result is retained.
Inspect Read problems if a session is missing. Loading requires a known project directory that still exists and an adapter that supports resuming the session.