Skip to main content

Module report

Module report 

Source
Expand description

Tokenless report file consumer.

Reads the per-session JSONL report file produced by tokenless hooks incrementally: each API request reads only the new lines since the last consumption, keeping the file on disk so every request gets its fair share of project/user context and incremental savings.

§Report file format (JSONL)

Each line is a JSON object with these fields:

FieldTypeExampleDescription
sessionIdstring"abc123"Claude Code session ID
agentIdstring"claude"Agent identifier
projectPathstring|null"my-project"Project path
opTypestring"compress-schema"Operation type (see below)
methodstring|null"ToonHrv"Compression strategy (see below)
beforeTokensu641500Estimated tokens before compression
afterTokensu64700Estimated tokens after compression
savedTokensu64800Tokens saved
beforeBytesu646000Bytes before compression
afterBytesu642800Bytes after compression
savedBytesu643200Bytes saved
timestampstringRFC 3339When the hook ran

§opType values

ValueMeaning
compress-schemaTool schema definition compression (BeforeModel hook)
compress-responseTool response output compression (PostToolUse hook)
rewrite-commandShell command rewriting via RTK (PreToolUse hook)
compress-toonTOON format encoding

§method values (by opType)

compress-schema:

ValueMeaning
CompressorOnlyBasic schema compressor (truncate descriptions, drop titles)
ToonHrvUniform object arrays → HRV encoding (>= 5 items)
EnhancedToonDeep nesting or enum constraints → enhanced TOON
CjsonCompactCJSON compact encoding (fallback)

compress-response:

ValueMeaning
StandardStandard response compression (truncate strings/arrays, drop nulls)
HighFidelityBash output compression (wider truncation limits)
SemanticSemantic-aware field filtering (--semantic flag)

rewrite-command:

ValueMeaning
RtkStandardRTK command rewriting

compress-toon:

ValueMeaning
ToonDefaultBasic TOON encoding