2.5 KiB
OpenClaw Feature Requests
Filed: 2026-03-01 — for when we fork and contribute back
FR-001: Pre-Compaction State Snapshot
Problem: Mid-session compaction silently loses track of in-flight work — running worker PIDs, pending PRs, active deploys. Agents rely on having written state to HEARTBEAT.md beforehand, which fails under cognitive load.
Requested behavior: Before summarizing context, OpenClaw should:
- Read workspace HEARTBEAT.md active state section
- Inject a "pre-compaction snapshot" block into the compaction summary
- Ensure any
STATE: in-progressWAL entries survive verbatim into the new context
FR-002: WAL Append Tool / Hook
Problem: Agents updating HEARTBEAT.md requires a file write tool call — which can be skipped, fails silently, and is not atomic.
Requested behavior: A lightweight wal_append tool or pre-turn hook that:
- Appends a timestamped entry to a persistent WAL file outside the summarizable context
- Is called automatically before/after tool calls matching a configurable action pattern
- Survives compaction independently of the context window
FR-003: Session State Persistence API
Problem: Active worker session IDs, pending merges, and deploy state live only in context. After compaction or a new session, there is no way to resume awareness of in-flight operations.
Requested behavior:
- A key-value session state store (separate from context) that persists across compactions
- Agents can
state_set("audit_worker_pid", "3990263")andstate_get("audit_worker_pid") - State visible in /status output and injected as a small block in every turn
FR-004: Mandatory Pre-Action Hooks (Convention Enforcement)
Problem: Completion gates (code review, WAL updates, scratchpads) are defined in AGENTS.md but nothing mechanically enforces them. Agents skip them under load.
Requested behavior:
- A configurable
pre_action_hooksin openclaw config - Hooks run before specific tool categories (e.g.,
execwithgit merge,sessions_spawn) - Hook can require a WAL entry exists for the current task before proceeding
- Violations logged and surfaced to the user
Implementation Notes (for when we fork)
- WAL file:
~/.openclaw/workspace/.wal(append-only, outside workspace injection) - State store: could be SQLite in
~/.openclaw/state.db - Pre-action hooks: defined in
~/.openclaw/config.ymlunderhooks: - Compaction snapshot: modify
compaction.tsto read active HEARTBEAT.md state before summarizing