openclaw/docs/concepts
max 223eee0a20
refactor: unify peer kind to ChatType, rename dm to direct (#11881)
* fix: use .js extension for ESM imports of RoutePeerKind

The imports incorrectly used .ts extension which doesn't resolve
with moduleResolution: NodeNext. Changed to .js and added 'type'
import modifier.

* fix tsconfig

* refactor: unify peer kind to ChatType, rename dm to direct

- Replace RoutePeerKind with ChatType throughout codebase
- Change 'dm' literal values to 'direct' in routing/session keys
- Keep backward compat: normalizeChatType accepts 'dm' -> 'direct'
- Add ChatType export to plugin-sdk, deprecate RoutePeerKind
- Update session key parsing to accept both 'dm' and 'direct' markers
- Update all channel monitors and extensions to use ChatType

BREAKING CHANGE: Session keys now use 'direct' instead of 'dm'.
Existing 'dm' keys still work via backward compat layer.

* fix tests

* test: update session key expectations for dmdirect migration

- Fix test expectations to expect :direct: in generated output
- Add explicit backward compat test for normalizeChatType('dm')
- Keep input test data with :dm: keys to verify backward compat

* fix: accept legacy 'dm' in session key parsing for backward compat

getDmHistoryLimitFromSessionKey now accepts both :dm: and :direct:
to ensure old session keys continue to work correctly.

* test: add explicit backward compat tests for dmdirect migration

- session-key.test.ts: verify both :dm: and :direct: keys are valid
- getDmHistoryLimitFromSessionKey: verify both formats work

* feat: backward compat for resetByType.dm config key

* test: skip unix-path Nix tests on Windows
2026-02-09 09:20:52 +09:00
..
agent-loop.md docs: canonicalize docs paths and align zh navigation (#11428) 2026-02-07 15:40:35 -05:00
agent-workspace.md docs: canonicalize docs paths and align zh navigation (#11428) 2026-02-07 15:40:35 -05:00
agent.md docs: canonicalize docs paths and align zh navigation (#11428) 2026-02-07 15:40:35 -05:00
architecture.md docs: canonicalize docs paths and align zh navigation (#11428) 2026-02-07 15:40:35 -05:00
compaction.md Docs: add nav titles across docs (#5689) 2026-01-31 15:04:03 -06:00
context.md docs: canonicalize docs paths and align zh navigation (#11428) 2026-02-07 15:40:35 -05:00
features.md Docs: landing page revamp (#8885) 2026-02-04 10:37:14 -05:00
markdown-formatting.md Docs: add nav titles across docs (#5689) 2026-01-31 15:04:03 -06:00
memory.md Memory/QMD: warn when scope denies search 2026-02-08 09:21:17 -08:00
messages.md docs: canonicalize docs paths and align zh navigation (#11428) 2026-02-07 15:40:35 -05:00
model-failover.md Docs: add nav titles across docs (#5689) 2026-01-31 15:04:03 -06:00
model-providers.md Docs: enable markdownlint autofixables except list numbering (#10476) 2026-02-06 10:08:59 -05:00
models.md docs: canonicalize docs paths and align zh navigation (#11428) 2026-02-07 15:40:35 -05:00
multi-agent.md refactor: unify peer kind to ChatType, rename dm to direct (#11881) 2026-02-09 09:20:52 +09:00
oauth.md Docs: add nav titles across docs (#5689) 2026-01-31 15:04:03 -06:00
presence.md Docs: add nav titles across docs (#5689) 2026-01-31 15:04:03 -06:00
queue.md Docs: add nav titles across docs (#5689) 2026-01-31 15:04:03 -06:00
retry.md Docs: add nav titles across docs (#5689) 2026-01-31 15:04:03 -06:00
session-pruning.md fix: satisfy lint curly rule (#6310) 2026-02-01 20:04:53 +05:30
session-tool.md Docs: add nav titles across docs (#5689) 2026-01-31 15:04:03 -06:00
session.md refactor: unify peer kind to ChatType, rename dm to direct (#11881) 2026-02-09 09:20:52 +09:00
sessions.md Docs: add nav titles across docs (#5689) 2026-01-31 15:04:03 -06:00
streaming.md Docs: add nav titles across docs (#5689) 2026-01-31 15:04:03 -06:00
system-prompt.md Docs: enable markdownlint autofixables except list numbering (#10476) 2026-02-06 10:08:59 -05:00
timezone.md Docs: add nav titles across docs (#5689) 2026-01-31 15:04:03 -06:00
typebox.md Docs: enable markdownlint autofixables except list numbering (#10476) 2026-02-06 10:08:59 -05:00
typing-indicators.md Docs: add nav titles across docs (#5689) 2026-01-31 15:04:03 -06:00
usage-tracking.md Docs: add nav titles across docs (#5689) 2026-01-31 15:04:03 -06:00