Skip to content

FYI: registered agent bodies are idle-resident on current Claude Code (~2k each) — measurement + a registration-free build #860

@ak2k

Description

@ak2k

Following up on #139 and #156 with current numbers.

#139 reasonably treated agent bodies as spawn-time-only ("loaded when spawning, so less critical"), with descriptions (~3k) as the idle cost. On current Claude Code (2.1.150, Opus 4.7) that's changed: interactive /context shows the bodies idle-resident too — a standing slot in the window before the first turn, separate from the Task-tool descriptions #139 measured.

With compound-engineering v3.8.4 installed, a fresh /context:

Custom agents: ~88k tokens   (~2k per registered agent)

The per-agent rate (~2k) is the stable figure; the total scales with how many of v3.8.4's 49 agents register in a given session — I saw ~88k, and all 49 would be ~100k. Either way it's the dominant idle cost. (Aside: in my run, claude plugin details reported only ~5.7k "always-on" for the same plugin — it counts the ~50-token descriptions, not the loaded bodies — so the built-in projection understates what /context shows.)

I've been running a registration-free build of CE that drops the agents/ registrations, moves the persona prompts to references/, and dispatches them on demand — emptying that slot, same specialist coverage. Plugin-attributable idle delta across the window is roughly −94k (−88k custom agents, −13.5k system tools, +7.5k skills descriptions). It's at https://github.com/ak2k/ce-lite as a reference / data point.

Honest trade-off (why this isn't a no-brainer upstream), related to #652: without registrations the harness can't enforce each persona's tools: allowlist — dispatch goes through a general-purpose subagent, so the restrictions become advisory. A PreToolUse hook could restore enforcement at trigger time without re-incurring the idle cost — I haven't needed it. Sharing the measurement either way.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions