MEDIA PREVIEW

Overview & result
Context Diet is a Codex plugin that asks Jev which bulky tool results the session still needs. Local gates skip small or protected outputs; if Jev judges a result stale, code replaces it with a bounded head and note while retaining a digest for later decisions.
From the original post
Codex re-reads its whole desk before every reply. This plugin keeps the pages that still matter and clears the ones you can reprint.
A Codex plugin that asks TypeSafe's Jev which bulky tool results the session still needs, then replaces the rest with a bounded head and a one-line note.
How Jev fits in the loop
- Intercept a PostToolUse result after a tool runs.
- Skip small results, protected tools, and the first result of a session.
- Ask Jev five literal questions about larger results in one request.
- If stale, replace the body with a bounded head and a note; the agent can rerun the tool.
How to reproduce
- Inspect the source implementation at https://github.com/konstantinosbotonakis/codex-context-diet.
- Configure local Jev API credentials and register required tool/model bindings.
- Execute test prompts and observe decision latency and routing outputs.
Why this build matters
Extends active coding session longevity and reduces API token expenditure.
Limitations
- Small results, apply_patch output, tools on the never-diet list and the first result of a session are left alone.
- A dropped result is replaced by a capsule of its head, error lines, stack frames and summary lines, not kept in full.
- Bulky tool results are sent to Jev to be judged.