codex-discover
Find missed token savings by scanning AI coding session files for commands that ran without tokf filtering.
Compress verbose CLI output with tokf before returning results. Activates for git, cargo, npm, docker, go, gradle, kubectl, and other supported commands.
$ npx -y skills add mpecan/tokf --skill codex-run --agent claude-codeHow it fires
How this skill gets triggered: by you, by Claude, or both.
/codex-runContext preview
The summary Claude sees to decide when to auto-load this skill.
Compress verbose CLI output with tokf before returning results. Activates for git, cargo, npm, docker, go, gradle, kubectl, and other supported commands.
name: tokf-run description: Compress verbose CLI output with tokf before returning results. Activates for git, cargo, npm, docker, go, gradle, kubectl, and other supported commands.
tokf compresses verbose command output so you receive concise, structured results instead of raw terminal dumps. It saves context tokens and makes output easier to reason about.
When the tokf Codex hook is installed, run supported commands normally. The hook rewrites matching commands to `tokf run <command>` before execution.
If the hook is unavailable, blocked, or not rewriting a supported command, use the manual fallback:
tokf run <command>
**Examples:**
tokf run git status tokf run cargo test tokf run npm test tokf run docker ps
The following commands have built-in filters. The hook can rewrite them automatically; use `tokf run` manually only as fallback:
Commands not in this list pass through unchanged when prefixed with `tokf run`.
1. **Never double-prefix.** If a command already starts with `tokf run`, do not add it again. 2. **Arguments pass through.** In manual fallback mode, include all flags and arguments after the base command: `tokf run cargo test --release -- my_test`. 3. **Fail-safe.** If `tokf` is not installed or not on PATH, run the command without the prefix. 4. **Environment variables.** Place env vars before `tokf run`: `RUST_LOG=debug tokf run cargo test`. 5. **Pipes.** Do not add redundant filtering pipes (e.g. `| grep`, `| tail`, `| head`) after `tokf run` commands — tokf already compresses the output. Piping tokf's output for other purposes (e.g. `tokf run cargo test | wc -l`) is fine.
tokf.net — reduce LLM context consumption from CLI commands by 60–90%. Commands like git push, cargo test, and docker build produce verbose output packed with progress bars, compile noise, and boilerplate.
Repo: mpecan/tokf
Find missed token savings by scanning AI coding session files for commands that ran without tokf filtering.
Find missed token savings in Claude Code sessions and create filters for unfiltered commands
This skill should be used when the user asks to "create a filter", "write a tokf filter", "add a filter for <tool>", "how do I filter output", or needs…