Skip to content
Docs

Get recommendations and apply a fix

TokenNibbler asks your own Claude Code or Codex to review a project’s recent sessions, then suggests what to change so future sessions use fewer tokens and get better results. Free includes one analysis a month across your projects; Pro and the 14-day trial add unlimited analyses, one-click fixes and implementation prompts.

  • Claude Code or Codex is installed and signed in on this computer.
  • The project has sessions from the last 30 days. Find it on the Projects page.
  1. Select Projects in the sidebar and open the project.
  2. Open the Recommendations tab. The card reads Get recommendations for this project.
  3. Under Analyse with, choose Claude or ChatGPT. Claude is the default when Claude Code is installed.
  4. Leave Let it read project files on for file-level advice, such as where to split a large file, or turn it off to review from the numbers only. Reading is read-only.
  5. Select Analyse project. The review uses your own plan and usually takes 1–3 minutes.

You can keep using TokenNibbler while it runs, or select Cancel. When the report is ready, TokenNibbler says “Recommendations are ready.”

The analysis runs your own Claude Code or Codex, only when you click. Open What is shared with the AI on the card to see the list before you start:

  • Counts and sizes from your sessions: tokens, tool output by kind, the files read most and how often.
  • Session titles, file names and the shell commands’ first words.
  • The project’s CLAUDE.md or AGENTS.md, if it has one.
  • Your skills’ names, costs and use in this project.
  • With Let it read project files on, the files it chooses to read in this project (read-only).

Your prompts, the conversation and command output are never shared. Claude Code runs in safe mode with only read-only tools (Read, Grep and Glob), and Codex runs in its read-only sandbox, where it can still open files read-only even with Let it read project files off. Nothing in the project changes unless you add a suggestion.

The report starts with a short summary, then findings ranked by impact. Each finding shows:

  • Its impact (High impact, Medium impact or Low impact) and its area, such as Instructions, Context or Model & effort.
  • The effort to make it: Quick win, Medium effort or Larger change.
  • The evidence from your sessions, and what to change.
  • The files it applies to. Select a file to open it in your editor. A file the finding proposes that does not exist yet is marked new.

The last ten reports per project are kept. Choose an earlier one from the list at the top of the report, or select New analysis to run another.

When the report suggests instructions, it ends with Instructions for future sessions: a short section for the project’s instruction file. Claude Code reads CLAUDE.md and Codex reads AGENTS.md at the start of every session in the project. Adding it in one click is part of Pro and the 14-day trial; on Free, use Copy (see below).

  1. On the Instructions for future sessions card, select Add to CLAUDE.md or Add to AGENTS.md.
  2. Read the confirmation. It shows the file’s path and what will happen.
  3. Select Add section. TokenNibbler backs up the current file, then adds the section. Future sessions use it automatically.
High impactInstructionsQuick win

Map the codebase in CLAUDE.md so sessions stop re-reading orders.ts

◔src/api/orders.ts (2,140 lines) was read 64 times this week, ~380k tokens.

Add a short map of where things live, and read large files by section after searching.

Expected saving: ~300k fewer tokens a week (estimate)

CLAUDE.mdsrc/api/orders.ts

Instructions for future sessions

Claude Code reads CLAUDE.md and Codex reads AGENTS.md at the start of every session in this project.

CLAUDE.md · after✓ Updated CLAUDE.md · backed up first

A fix adds one marked section. To undo, delete the section or restore the backup.

Example data. A finding, then its instructions added to CLAUDE.md with a backup first.

The section goes between two TokenNibbler markers, and everything already in the file stays:

<!-- tokennibbler:start -->
...the suggested instructions...
<!-- tokennibbler:end -->

A later fix replaces only this section, so you never get two copies. The backup goes to the backups folder in TokenNibbler’s data folder. By default the newest 10 backups of each file are kept; change this in Settings › Data › Backups per file.

You stay in control of the file. Undo a fix in either of two ways:

  • Delete the section: open CLAUDE.md or AGENTS.md and delete everything from <!-- tokennibbler:start --> to <!-- tokennibbler:end -->, markers included.
  • Restore the backup: open Settings › Data › Local files › Open folder, then the backups folder. Backups are named after the file with the time they were made, such as CLAUDE-…-<time>.md. Copy the one you want back over the project’s file. If the fix created the file, there is no earlier version to back up: delete the section or the file.

Prefer to have your agent make the change, or to review it first? Copy it instead:

  • Copy on the Instructions for future sessions card copies the section, ready to paste into CLAUDE.md or AGENTS.md yourself. This works on every plan.
  • Copy as a prompt on a finding copies a prompt for that one change (Pro).
  • Create implementation prompt builds one prompt for several findings, with the evidence, numbered steps, ground rules and how to check each change. Select Copy prompt, or Open Claude Code or Open Codex to copy it and open the agent in the project folder (Pro).
  • The card shows “Unlimited analyses are part of Pro.” in place of Analyse project: Free includes one analysis a month, and this month’s is used. Select Start free trial or Upgrade on that line.
  • Analyse project is greyed out: the project has no sessions in the last 30 days, or the chosen agent was not found. See Claude Code troubleshooting or Codex troubleshooting.
  • Something else: see Troubleshooting.