Documentation
¶
Overview ¶
Package claudetranscript reads a Claude Code session transcript to learn how large the main session's context is. The transcript format is internal to Claude Code and undocumented, so this reader recognizes only the versions listed in supportedVersions and reports nothing for anything else.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ContextTokens ¶
ContextTokens returns the main session's current context size: the input, cache-creation and cache-read tokens of its latest assistant entry, output tokens excluded and subagent (sidechain) entries ignored. ok is false when the file is unreadable, holds no main-session assistant entry in its tail, or that latest entry is from an unrecognized version or lacks the usage fields.
func Recognized ¶
Recognized reports whether version is one this reader was checked against.
Types ¶
This section is empty.