Tokenjuice Plugin: Condense Noisy Exec and Bash Tool Results

Tokenjuice is an optional plugin that condenses noisy exec and bash tool results after commands finish. It is useful for developers using OpenClaw who want to reduce output clutter in tool results.

Read this when

  • You want shorter `exec` or `bash` tool results in OpenClaw
  • You want to install or enable the Tokenjuice plugin
  • You need to understand what tokenjuice changes and what it leaves raw

tokenjuice is an optional external plugin that condenses noisy exec and bash tool results after the command finishes.

It modifies the returned tool_result, not the command itself. Tokenjuice does not rewrite shell input, re-run commands, or alter exit codes.

Currently this applies to OpenClaw embedded runs and OpenClaw dynamic tools in the Codex app-server harness. Tokenjuice hooks into OpenClaw's tool-result middleware and shortens the output before it re-enters the active harness session.

Enable the plugin

Install once:

openclaw plugins install clawhub:@openclaw/tokenjuice

Then enable it:

openclaw config set plugins.entries.tokenjuice.enabled true

Equivalent:

openclaw plugins enable tokenjuice

If you prefer editing config directly:

{
  plugins: {
    entries: {
      tokenjuice: {
        enabled: true,
      },
    },
  },
}

What tokenjuice changes

  • Condenses noisy exec and bash results before they are returned to the session.
  • Leaves the original command execution unchanged.
  • Uses a safe-inventory policy: exact file-content reads stay raw, standalone repository-inventory commands can be condensed, and unsafe mixed command sequences remain raw.
  • Remains opt-in: disable the plugin if you want full verbatim output everywhere.

Verify it is working

  1. Enable the plugin.
  2. Start a session that can call exec.
  3. Run a noisy command like git status.
  4. Verify that the returned tool result is shorter and more structured than the raw shell output.

Disable the plugin

openclaw config set plugins.entries.tokenjuice.enabled false

Or:

openclaw plugins disable tokenjuice