Skip to content

Feature: compactionNotices config option for compaction-only notifications #58758

@brendongl

Description

@brendongl

Problem

When auto-compaction triggers during a conversation, the agent goes silent on messaging surfaces (Discord, Telegram, etc.) with no indication of what's happening. The user sends a message, context limit is hit, compaction runs, and there's just... silence. No feedback that anything is happening.

Current Behavior

Compaction visibility is currently tied to two broader settings:

  1. verboseDefault: "on" — shows compaction notices, but also shows new session IDs, model fallback notices, fallback cleared notices, etc. Too noisy for most users.

  2. blockStreamingDefault: "on" — enables the "🧹 Compacting context..." start notice via onBlockReply, but also fundamentally changes how responses are delivered (streamed in chunks). Too disruptive as a side effect.

There's no way to get only compaction notifications without opting into unrelated UX changes.

Proposed Solution

A dedicated config option like:

{
  "agents": {
    "defaults": {
      "compactionNotices": true
    }
  }
}

Or alternatively under the compaction config:

{
  "agents": {
    "defaults": {
      "compaction": {
        "notices": true
      }
    }
  }
}

When enabled, this would:

  1. Send a message like "🧹 Compacting context, one moment..." when compaction starts
  2. Send "🧹 Compaction complete" when it finishes
  3. Not require verbose mode or block streaming to be enabled

Why This Matters

On messaging surfaces (Discord, Telegram, WhatsApp), silent compaction is a terrible UX. The user thinks the bot is broken or ignoring them. A simple status message makes a huge difference. This is especially important because compaction can take 10-30+ seconds depending on context size and model.

Environment

  • OpenClaw 2026.3.24
  • Surfaces affected: Discord, Telegram (any messaging channel)

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