OpenClaw: compact improver

ReviewAudited by ClawScan on May 10, 2026.

Overview

The skill is mostly a prompt template for better /compact summaries, but it recommends persistent global system-prompt or hook injection that could affect OpenClaw behavior beyond compacting.

Use caution before applying the persistent config or hook approach. Prefer a per-/compact prompt or a clearly scoped compact-only hook, back up ~/.openclaw/openclaw.json, confirm exactly what changes are made, and redact sensitive content from summaries.

Findings (2)

Artifact-based informational review of SKILL.md, metadata, install specs, static scan signals, and capability signals. ClawScan does not execute the skill or run runtime probes.

What this means

Using this as written could make future OpenClaw sessions follow the compact-summary prompt or hook behavior even when the user did not intend to change general agent behavior.

Why it was flagged

This directs a persistent modification to OpenClaw's default system prompt or hook mechanism. That can affect agent behavior beyond the /compact command unless tightly scoped.

Skill content
将上述格式注入到 `~/.openclaw/openclaw.json` 的 `agents.defaults.systemPrompt` 或通过 HOOK 注入
Recommendation

Use a compact-only configuration or per-command prompt instead of the global default system prompt; back up the config file, review the exact diff, and document how to undo the change.

What this means

Private details, secrets accidentally pasted into chat, or sensitive code may be carried forward in compacted summaries.

Why it was flagged

The compact summary template intentionally preserves raw user messages and complete code snippets, which is aligned with context compaction but may retain sensitive or stale information in future context.

Skill content
6. **All user messages**: 所有非工具调用的用户消息(保留原始表述) ... 3. **Files and Code Sections**: 涉及的文件和代码段(包含完整代码)
Recommendation

Review or redact compact summaries before retaining them, and avoid including secrets or unnecessary full code when a shorter description is sufficient.