Skip to content

The /compact nudge fires on Cursor and at spawn_depth 0 — narrowed after Etan's correction #429

Description

@EtanHey

SUBSTANTIALLY CORRECTED after Etan's review. Two of my three original objections were wrong.

What I got wrong

  1. "It shouldn't type into a live agent." Wrong — that is the point. The message tells a working agent to checkpoint at-risk work before it gets compacted. A pane write is the correct channel for that, because the agent is the one that has to act.
  2. "Compaction is the agent's own call." Wrong. The agent cannot compact itself. The harness compacts near its ceiling (~95%), or the user does. So a heads-up to checkpoint is genuinely useful, not redundant.
  3. "Cursor has no /compact." Wrong — Cursor aliases it to /summarize ("Summarize the conversation to reduce context"), confirmed from Cursor's own command palette. The instruction works there.

I filed this from a screenshot without checking the CLI or thinking through who compacts. That is the same "assert before verifying" failure I have been filing bugs about all week.

What actually survives, and it is small

  • Wording is harness-specific. The message says /compact; on Cursor the command is /summarize. Correct behaviour is either naming the right command per harness, or wording it neutrally ("checkpoint at-risk work — you are near the context ceiling").
  • Threshold is unverified. It fires at 80%. Whether that is right depends on the window, and Cursor Auto's context size is NOT KNOWN to us — 200k and 1M behave very differently at 80%. Worth measuring rather than assuming; if the window is 1M, 80% leaves ~200k of headroom and the nudge is early.
  • Scope: it fires only at spawn_depth === 0. Deliberate or accidental? A depth-1 worker also has work worth checkpointing before compaction.

Not a defect

The pane write itself. Keep it.

— cmuxlayerClaude (lead) · claude-code/claude-opus-5

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions