Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
30 commits
Select commit Hold shift + click to select a range
1f3e013
Record the watch-mode design and refresh render-format-once's status
daaain Aug 30, 2026
9b20d77
Write generated output atomically
daaain Aug 30, 2026
c43b712
Record the source file size in the cache, and check it for freshness
daaain Aug 30, 2026
f0cc656
Correct the --output freshness follow-up: it is already fixed
daaain Aug 30, 2026
1ffc41b
Reach the session-scoped render path after an append-only cache refresh
daaain Aug 30, 2026
9af4531
Add the watch engine: poll, debounce, deliver
daaain Aug 30, 2026
6247c06
Add the `watch` subcommand
daaain Aug 30, 2026
a196f4a
Record Stage 1's outcome in the watch-mode design
daaain Aug 30, 2026
6f7850d
Add `serve --watch`: keep the served pages current
daaain Aug 30, 2026
69392ab
Record the real-archive measurements, and why the synthetic one lied
daaain Aug 30, 2026
1ec29ed
Wrap the message tree in an addressable #transcript container
daaain Aug 30, 2026
f48de95
Update the served page in place as its session grows
daaain Aug 30, 2026
759cfd3
Document watch mode
daaain Aug 30, 2026
14f4e5b
Use monkeypatch.setattr in the watch CLI tests, and narrow by raising
daaain Aug 30, 2026
dca6911
Stop the staleness sweep scaling with the session count
daaain Aug 30, 2026
86913d7
Reuse the entries a tick has already parsed, instead of rebuilding them
daaain Aug 30, 2026
d8ccf4d
Resume a watch tick's parse and cache write from where the last one s…
daaain Aug 30, 2026
dcc5ca3
Record what Fix B actually looked like, against what was planned
daaain Aug 30, 2026
282a167
Compress cached entries at zlib level 3
daaain Aug 30, 2026
a696bbd
Stop the refresh's per-tick lookups scanning the whole project
daaain Aug 31, 2026
eabb4c7
Stop the TUI and archived rendering scanning the project to load a se…
daaain Aug 31, 2026
49a468d
Patch the page instead of swapping it, and fix what living with it ex…
daaain Aug 31, 2026
651c0c8
Address PR review, and fix two things using the feature exposed
daaain Aug 31, 2026
63610ea
Fix five review findings against the watch branch
daaain Aug 31, 2026
127d767
Hover the resume toast beside its button, not above the stack
daaain Aug 31, 2026
77533ca
Fix the Windows CI failures and three more review findings
daaain Aug 31, 2026
8686f86
Close the poll stamp's last blind spot, and steady a search flake
daaain Aug 31, 2026
c11e807
Enable thinking in foldyard
daaain Aug 31, 2026
b917ea6
Repair corrupted cache db
daaain Aug 31, 2026
2299e73
CR feedback
daaain Aug 31, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 23 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,29 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).


## [Unreleased]

### Added

- **Watch mode (`claude-code-log watch`)** — re-converts transcripts as they are
written, so Markdown open in an editor or an Obsidian vault stays current.
Defaults to the current directory's project.
- **Live page updates (`claude-code-log serve --watch`)** — an open session page
grows as messages arrive, in place: scroll position, folded sections and open
disclosures survive, new messages fade in, and a follow pill pins the page to
the newest message. Only over the server; `file://` pages are unchanged.

### Changed

- Generated output is now written atomically (temp file + rename), so a reader
can never observe a truncated page or document.
- The cache records each source file's size as well as its mtime (migration
011). The 1-second mtime tolerance could hide a write landing inside it,
which stranded the last message of a turn until something else touched the
file.
- The session-scoped render path is now reachable after an append-only cache
refresh, which is what makes a watch tick cheap.

## [1.5.0] - 2026-07-09

### Changed
Expand Down
25 changes: 25 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -333,6 +333,31 @@ full-load refresh. Set `CLAUDE_CODE_LOG_INCREMENTAL_CACHE=0` to force
the full refresh when bisecting. See
[dev-docs/application_model.md § 2.14](dev-docs/application_model.md).

That refresh parses each modified file from source, and the loads that
follow it — the closure load and the session-scoped render — used to
rebuild those same entries from the rows it had just written, twice.
A per-conversion parsed-entry store
(`claude_code_log/entry_store.py`) serves the refresh's list to both
instead, taking a watch tick on an 803MB archive from 1.03s to 0.72s.
Only the incremental refresh fills it, and only with the files that
changed, so a cold conversion and the streaming path (whose bounded
residency depends on dropping each page) carry no extra memory.

Held *across* ticks — which `watch` does, owning one for the life of the
loop — the same store also resumes. It pins its entries to a byte offset
plus a hash of the bytes below it, so a tick hashes that prefix (32ms
over 39.7MB, against 143ms to re-parse it), reads only what was
appended, and appends just the new cache rows rather than rewriting the
file's. That takes the same tick to **0.26s**. It applies only where the
rows are provably the file's own lines: a trunk's rows carry its
subagents' spliced transcripts, so a running subagent grows a block
mid-sequence and those files take the unchanged full rewrite.

Set `CLAUDE_CODE_LOG_ENTRY_STORE=0` to disable all of it when bisecting;
a per-file memory valve declines to hold a file when available memory is
under ~6× its bytes, and an explicit `=1` overrides that valve. See
[dev-docs/application_model.md § 2.16](dev-docs/application_model.md).

To re-measure on your own hardware (core count changes the answer for
the fan-out), point the benchmark at a real project:

Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ uvx claude-code-log@latest --open-browser
## Key Features

- **Interactive TUI (Terminal User Interface)**: Browse and manage Claude Code sessions with real-time navigation, summaries, and quick actions for HTML export and session resuming
- **Watch Mode**: `claude-code-log watch` re-converts as a session is written, so Markdown in an editor or Obsidian stays current; `claude-code-log serve --watch` makes an open session page grow as messages arrive, keeping your scroll position and folded sections
- **Project Hierarchy Processing**: Process entire `~/.claude/projects/` directory with linked index page
- **Individual Session Files**: Generate separate HTML files for each session with navigation links
- **Single File or Directory Processing**: Convert individual JSONL files or specific directories
Expand Down
Loading
Loading