draft is my attempt at a fix. before getting into how it works — a lot of memory/context plugins solve this by calling an external api or running their own model, which either charges you separately or quietly inflates your usage. draft runs entirely within your existing claude subscription.
it's a codex/claude code plugin a few core pieces:
1. session-init hook
on every session start, a hook fires and injects a structured context summary into claude's working memory. specifically, it reads the `name` and `description` frontmatter from each context index file — company, product, priorities, team, decisions — and assembles them into a single compressed summary under ~5k tokens.
2. learning — inference-driven and manual
learning is inference-driven rather than hook-based. the main claude agent reads its instructions and decides when something is worth persisting — a decision made, a direction abandoned — and calls `/draft:learn` as a subagent to write it back to the appropriate context file. there's no session-end hook or background process; the agent is exercising judgment about what's durable. you can also invoke `/draft:learn` manually at any time.
over time, claude accumulates enough context to flag contradictions — if you go in a direction that conflicts with a decision you made two weeks ago, it'll surface it. that's been the most unexpectedly useful part for me as a solo founder.
3. cross-agent architecture
the workspace lives at `~/.draft/workspace/`, claude code and cursor share the workspace natively. codex requires a separate install (curl setup script, since there's no plugin marketplace yet) but reads from the same files.
---
would love if folks tried it out, cloned it and ran locally or gave me some examples of their coding agent setups!
its 100% free and open source. mit licensed. no account, no api key.