Documentation
¶
Overview ¶
Package sessiontranscript reads the vendor session record for an agent session so a member can see their own work (ADR-036).
Each vendor writes a different record, so a format is detected and handed to its own adapter (ADR-039). Files are read locally and bounded from the tail; nothing here copies a transcript to a second durable store. Raw tool results, command output, attachments, and any vendor-encrypted reasoning are dropped during parsing and never become candidates for sharing.
Index ¶
Constants ¶
const ( // MaxTailBytes bounds how much of a long-running session is read. Sessions // routinely reach tens of megabytes; only recent turns are useful. MaxTailBytes = 2 << 20 // MaxMessages bounds how many parsed messages are retained. MaxMessages = 200 // MaxMessageBytes bounds a single rendered message. MaxMessageBytes = 8000 )
const ( KindUser = "user" KindAssistant = "assistant" KindThinking = "thinking" KindSystem = "system" KindTool = "tool" )
Kinds a transcript can yield. "thinking" is reasoning the vendor itself surfaced; Overgent never reads encrypted reasoning or infers hidden chain of thought. "tool" carries a name only and is never shareable content.
Variables ¶
This section is empty.
Functions ¶
func LocateCodexRollout ¶
LocateCodexRollout finds the rollout file for a Codex session. Codex does not pass a transcript path to its hooks, but it names every rollout after the session id, so the file is discoverable from the id the hook already sends. The id is used locally for this lookup only and is never published.
func TranscriptAvailable ¶
TranscriptAvailable reports whether a vendor writes a session record this package can parse. Callers use it to skip a read that can only fail, so an absent transcript is a known vendor limitation rather than a read error that looks like a broken file.