Joel Pennell

Writing

What I find out while building, written up with the numbers and with what I haven't tested.

Articles

1 November 2026
Updated 4 November

What my AI loses when it compacts

A long session with an AI coding agent that sits idle for about an hour may be condensed into a summary to save usage. In my sessions the summaries kept my decisions but got the AI's own actions wrong, for example saying a reply hadn't been sent when it had. The full transcript is already on disk, so the fix is to read it back after each compaction.

The hook is public: claude-code-hooks.

Published code

Open source, MIT

claude-code-hooks

Three hooks for Claude Code users, each written after a real incident, each with tests.

Read the code on GitHub.

Open source, MIT

diagnose-defect

A skill for Claude Code that works out the cause of a reported bug and proves it by running the code.

Read the code on GitHub.