openclaw - 💡(How to fix) Fix Control UI: 消息脚标增加上下文缓存状态与压缩水位显示 / Configurable message footer with cache & compaction info

Official PRs (…)
ON THIS PAGE

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…

Code Example

Agent: main | Model: deepseek-v4-flash | Provider: deepseek

---

Agent: main | Model: deepseek-v4-flash | Cache: 14.2K/32K (44%) | Compact: 68%

---

Agent: main | Model: deepseek-v4-flash | Provider: deepseek | Cache: 14.2K/32K | Compact: 68%
RAW_BUFFERClick to expand / collapse

Feature Request: 可配置的 Control UI 消息脚标

问题描述

当前 OpenClaw Control UI 的聊天界面,每条消息底部固定显示:

Agent: main | Model: deepseek-v4-flash | Provider: deepseek

但缺少两项对日常使用非常重要的信息:

  1. 上下文缓存状态(Context Cache Status)——当前会话是否命中 prompt cache、缓存大小、TTL 状态
  2. 上下文自动压缩额度(Compaction Quota)——当前上下文窗口使用率、距离自动压缩还有多少余量

使用场景

  • 使用长会话进行数据采集和规整任务时,需要实时知道上下文窗口还剩多少,避免因超窗导致历史被意外压缩
  • 使用支持 prompt caching 的 provider(如 Anthropic / DeepSeek)时,需要了解缓存命中情况,优化成本
  • 多轮工具调用密集型工作流中,脚标比手动输入 /status/usage tokens 更直观、持续可见

期望行为

方案 A:脚标字段可配置

在 Control UI 设置或 Gateway 配置中,允许用户选择脚标显示的字段列表。示例:

Agent: main | Model: deepseek-v4-flash | Cache: 14.2K/32K (44%) | Compact: 68%

可配置字段包括:

  • agent — 当前 agent ID
  • model — 当前模型
  • provider — 当前 provider
  • cache — 上下文缓存用量与状态
  • compaction — 上下文压缩水位线
  • tokens — 当前会话 token 用量
  • cost — 累计估算费用

方案 B:脚标固定扩充(更简单)

直接在现有脚标末尾追加两个字段:

Agent: main | Model: deepseek-v4-flash | Provider: deepseek | Cache: 14.2K/32K | Compact: 68%

技术备注

  • /usage tokens/status 已经能提供这些信息,但以命令输出的形式,不是持久可见的
  • /context list 能显示 session cache tokens,但同样不是脚标级别的持续显示
  • 如果能将 chat.history 返回的 usage/cache 元数据投射到 Control UI 的回复渲染层,实现成本应该可控

优先级建议

可用性改进。不影响核心功能,但对高频使用 Control UI 的用户提升明显。

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

openclaw - 💡(How to fix) Fix Control UI: 消息脚标增加上下文缓存状态与压缩水位显示 / Configurable message footer with cache & compaction info