Skip to content

fix(dsh): use producer-owned source kind for Session format v4 compatibility - #2455

Closed
bobbyreader wants to merge 1 commit into
MemTensor:mainfrom
bobbyreader:fix/dsh-v4-producer-owned-source-kind
Closed

bobbyreader wants to merge 1 commit into
MemTensor:mainfrom
bobbyreader:fix/dsh-v4-producer-owned-source-kind

Conversation

@bobbyreader

Copy link
Copy Markdown

Summary

Fixes SessionFormatError: format v4 message requires a producer-owned source kind in DeepSeek Harness (DSH >= 0.10.0 / Session format v4).

Problem

In DSH 0.10.0 (Session format v4), message sources with kind: 'plugin' have been deprecated and rejected in favor of producer-owned source kinds (plugin:<plugin-name>). When @memtensor/memos-local-plugin injected memory recall context or created auxiliary user messages for host LLM calls with source: { kind: 'plugin', plugin: 'memos-local-memory' }, DSH's session format validator rejected the message and crashed the session turn during projection/persistence.

Fix

  • Updated createRecallMessage in adapters/deepseek-harness/index.ts to use source: { kind: \plugin:${DEEPSEEK_HARNESS_PLUGIN}`, form: 'recall' }`.
  • Updated toDshMessage in adapters/deepseek-harness/host-llm.ts to use source: { kind: \plugin:${HOST_LLM_MESSAGE_SOURCE}` }`.
  • Updated corresponding test assertions and fixtures in deepseek-harness-bridge.test.ts and deepseek-harness-host-llm.test.ts.

Validation

  • Tested and verified live in DSH Desktop 0.10.0 with automatic recall and multi-turn turns.
  • Aligned with DSH Session format v4 schema requirements.

🤖 Generated with Claude Code

…ibility

In DeepSeek Harness >= 0.10.0 (Session format v4), message sources with
kind: 'plugin' are retired and rejected with:
SessionFormatError: format v4 message requires a producer-owned source kind

Update deepseek-harness adapter to use producer-owned source kind
plugin:${DEEPSEEK_HARNESS_PLUGIN} for recall messages and host LLM helper
messages, and update unit tests accordingly.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@endxxxx

endxxxx commented Oct 29, 2026

Copy link
Copy Markdown
Collaborator

Thank you for the fix and the live DSH validation.

The changes in this PR—updating both recall and auxiliary host-LLM messages to producer-owned source kinds, together with the corresponding test expectations—have been covered by #2519, which is merged and released in @memtensor/memos-local-plugin 2.0.21.

The merged implementation also includes regression coverage using the official V4 admission validator and Windows Desktop automatic-recall verification.

Closing this PR as superseded by #2519. Thank you for helping identify and validate the compatibility fix.

@endxxxx endxxxx closed this Oct 29, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:plugin OpenClaw & Hermes status:in-progress Someone or AI is working on it | 人工或 AI 正在处理

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants