Skip to content

Commit b31d883

Browse files
committed
docs(active-memory): document chat id filters
1 parent 8baaa08 commit b31d883

2 files changed

Lines changed: 32 additions & 0 deletions

File tree

‎CHANGELOG.md‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ Docs: https://docs.openclaw.ai
77
### Changes
88

99
- Channels: add Yuanbao channel docs entrance so the Tencent Yuanbao bot appears in the channel listing and sidebar navigation. (#73443) Thanks @loongfay.
10+
- Active Memory: add optional per-conversation `allowedChatIds` and `deniedChatIds` filters so operators can enable recall only for selected direct, group, or channel conversations while keeping broad sessions skipped. (#67977) Thanks @quengh.
1011

1112
### Fixes
1213

‎docs/concepts/active-memory.md‎

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -256,6 +256,34 @@ allowedChatTypes: ["direct", "group"]
256256
allowedChatTypes: ["direct", "group", "channel"]
257257
```
258258

259+
For narrower rollout, use `config.allowedChatIds` and
260+
`config.deniedChatIds` after choosing the allowed session types.
261+
262+
`allowedChatIds` is an explicit allowlist of resolved conversation ids. When it
263+
is non-empty, Active Memory only runs when the session's conversation id is in
264+
that list. This narrows every allowed chat type at once, including direct
265+
messages. If you want all direct messages plus only specific groups, include
266+
the direct peer ids in `allowedChatIds` or keep `allowedChatTypes` focused on
267+
the group/channel rollout you are testing.
268+
269+
`deniedChatIds` is an explicit denylist. It always wins over
270+
`allowedChatTypes` and `allowedChatIds`, so a matching conversation is skipped
271+
even when its session type is otherwise allowed.
272+
273+
The ids come from the persistent channel session key: for example Feishu
274+
`chat_id` / `open_id`, Telegram chat id, or Slack channel id. Matching is
275+
case-insensitive. If `allowedChatIds` is non-empty and OpenClaw cannot resolve a
276+
conversation id for the session, Active Memory skips the turn instead of
277+
guessing.
278+
279+
Example:
280+
281+
```json5
282+
allowedChatTypes: ["direct", "group"],
283+
allowedChatIds: ["ou_operator_open_id", "oc_small_ops_group"],
284+
deniedChatIds: ["oc_large_public_group"]
285+
```
286+
259287
## Where it runs
260288

261289
Active memory is a conversational enrichment feature, not a platform-wide
@@ -534,6 +562,9 @@ The most important fields are:
534562
| `enabled` | `boolean` | Enables the plugin itself |
535563
| `config.agents` | `string[]` | Agent ids that may use active memory |
536564
| `config.model` | `string` | Optional blocking memory sub-agent model ref; when unset, active memory uses the current session model |
565+
| `config.allowedChatTypes` | `("direct" \| "group" \| "channel")[]` | Session types that may run Active Memory; defaults to direct-message style sessions |
566+
| `config.allowedChatIds` | `string[]` | Optional per-conversation allowlist applied after `allowedChatTypes`; non-empty lists fail closed |
567+
| `config.deniedChatIds` | `string[]` | Optional per-conversation denylist that overrides allowed session types and allowed ids |
537568
| `config.queryMode` | `"message" \| "recent" \| "full"` | Controls how much conversation the blocking memory sub-agent sees |
538569
| `config.promptStyle` | `"balanced" \| "strict" \| "contextual" \| "recall-heavy" \| "precision-heavy" \| "preference-only"` | Controls how eager or strict the blocking memory sub-agent is when deciding whether to return memory |
539570
| `config.thinking` | `"off" \| "minimal" \| "low" \| "medium" \| "high" \| "xhigh" \| "adaptive" \| "max"` | Advanced thinking override for the blocking memory sub-agent; default `off` for speed |

0 commit comments

Comments
 (0)