Skip to content

feat(qwen): add first-class Cognee memory extension - #354

Open
netbrah wants to merge 5 commits into
topoteretes:mainfrom
netbrah:feat/qwen-cognee-351
Open

feat(qwen): add first-class Cognee memory extension#354
netbrah wants to merge 5 commits into
topoteretes:mainfrom
netbrah:feat/qwen-cognee-351

Conversation

@netbrah

@netbrah netbrah commented Aug 19, 2026

Copy link
Copy Markdown

Summary

  • add a self-contained Qwen Code extension with Gemini-shaped manifests and Qwen's Claude-style hook events
  • capture supported interactive prompts, tool traces, assistant responses, PreCompact anchors, and SessionEnd graph sync through the Cognee HTTP backend
  • isolate Qwen runtime state and backend selection under ~/.cognee-plugin/qwen/ and COGNEE_QWEN_BACKEND
  • use Qwen's millisecond timeout units, external-hook root contract, and injected skill-base path semantics
  • add shared-suite, packaging, host-semantics, HTTP compatibility, Linux, and Windows coverage
  • document the current Qwen prompt-provenance boundary and upstream prerequisite feat(hooks): expose send type on UserPromptSubmit payloads QwenLM/qwen-code#9511

Host-specific hardening

  • PreCompact emits hookSpecificOutput.additionalContext, which Qwen actually consumes
  • prompt capture and recall use submitted_prompt so ToolResult/Hook continuations cannot replace the real user question
  • installed memory skills resolve extension scripts from Qwen's injected skill base instead of an undeclared Claude variable
  • external hook files require ${CLAUDE_PLUGIN_ROOT}; ${extensionPath} is rejected for this loader path

Qwen currently omits submitted_prompt for ACP, headless, serve, SDK, remote-input, restored, and Vim-mode inputs while also omitting send type from command-hook payloads. Those model-bound prompts are intentionally skipped rather than guessed from prompt; tool/assistant/PreCompact/session hooks remain active. The additive host field needed to support those modes is tracked at QwenLM/qwen-code#9511.

Install safety

A fresh Qwen 0.21.10 install into an isolated temporary home:

  • installed and listed Cognee v1.4.4 with origin QwenCode
  • loaded the context file and all four skills
  • did not create ~/.qwen/settings.json
  • did not modify the live Qwen extension, live Qwen settings, or Codex config (before/after hashes and metadata were identical)

Verification

  • cd integrations/tests && uv run pytest tests/ -q1446 passed, 127 skipped, 53 deselected
  • ruff format --check integrations/308 files already formatted
  • ruff check integrations/all checks passed
  • Qwen JSON manifests/hooks validated with jq empty
  • git diff --check origin/main...HEAD — clean
  • independent full review plus scoped fix re-reviews — no remaining Critical or Important integration findings
  • live credit-bearing suite was not run; its Qwen envelope behavior is covered hermetically

Related: #350
Qwen host prerequisite: QwenLM/qwen-code#9511

Closes #351

@netbrah

netbrah commented Aug 19, 2026

Copy link
Copy Markdown
Author

@siillee :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(qwen): add first-class Cognee memory extension

1 participant