Skip to content

fix(plugin): wire recallExcludeUris into the claude-code and codex entries - #5436

Open
chaucerj wants to merge 32 commits into
volcengine:mainfrom
chaucerj:fix/claude-codex-recall-exclude-uris
Open

chaucerj wants to merge 32 commits into
volcengine:mainfrom
chaucerj:fix/claude-codex-recall-exclude-uris

Conversation

@chaucerj

@chaucerj chaucerj commented Sep 28, 2026 •

Copy link
Copy Markdown

Description

recallExcludeUris was only honored on the context-face path (the request body's exclude_uris). The legacy raw-retrieval fallback (searchAllSources) never saw the list, so a configured subtree URI could still surface through /find results and reach the host prompt.

This PR adds the client-side mirror of the server's exclude semantics in the canonical shared library: a configured subtree URI drops both the root and everything under it, and an exact URI drops that document — so the fallback path cannot reintroduce what the request body excludes (#5402).

Scope update (rebase onto current main)

Human Involvement

Changes Made

  • examples/memory-plugin-shared/lib/recall-core.mjs: client-side subtree/exact-URI exclusion in searchAllSources (canonical source).
  • Regenerate the committed copies via the official generator (node examples/memory-plugin-shared/sync.mjs): claude-code, codex, openclaw.
  • Move the exclusion tests to the shared suite (examples/memory-plugin-shared/recall-exclude.test.mjs): request-body exclude_uris plumbing plus three raw-fallback cases (subtree root + children, no-exclusion pass-through, exact URI → nothing recalled).
  • Version bumps for all six distributed plugins (shared-lib change reaches every consumer per the release gate): claude-code 0.6.10 (plugin + package manifest), codex 0.10.11, agent-hook 0.5.9 (root + five host manifests), opencode 0.5.5, dsh 0.5.14 (package, lock, PLUGIN_VERSION), pi 0.4.10 (package, lock).

Testing

  • I have added tests that prove my fix is effective
  • New and existing unit tests pass locally

Local validation against official main 9d9bc85e:

  • recall-exclude.test.mjs + recall-core.test.mjs: 40 passed / 0 failed; the two fallback-exclusion cases fail when the filter is removed (mutation-checked) and pass with it.
  • Shared suites (agent-hook-runtime, recall-session-wiring, plugin-config, ov-http, sync): 119 passed / 0 failed.
  • node sync.mjs then git diff --exit-code: clean (committed copies match the generator, twice).
  • check-plugin-version-bumps.sh origin/main: all six plugins ok, exit 0.

Upstream CI snapshot

Current head 1d4ec8a6 (2026-10-04): plugin tests include a pre-existing OpenClaw skill-list mismatch (718/1, existing #3866) and the API/CLI integration job had not completed at last observation — not introduced by this PR.

Additional Notes

No new configuration; the existing recallExcludeUris knob gains coverage on the path that previously ignored it. Does not add subtree filtering server-side, change the context-face path, or alter cached blocks.

…tries

The shared config schema declares recallExcludeUris (env
OPENVIKING_RECALL_EXCLUDE_URIS) and buildContextSearchBody already
maps options.excludeUris to the search body's exclude_uris, but the
claude-code and codex auto-recall entries never passed it, so the
knob was silently ignored — the same gap volcengine#5312 fixed for the DSH
plugin and volcengine#5368 for the pi extension.

Both entries now pass cfg.recallExcludeUris in the recall options,
and the vendored recall-core applies the same subtree prefixes in the
client-side fallback path (searchAllSources), so the fallback cannot
reintroduce what the search body excludes.

Fixes volcengine#5402

Co-Authored-By: Claude Code <noreply@anthropic.com>
@ZaynJarvis ZaynJarvis added the agent-plugins Agent harness and plugin integrations label Sep 29, 2026

@ktz03 ktz03 left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Rechecked 7e2b0d72 against inspected main 401c1f7e. Claude is now 0.7.16 versus main's 0.7.15; the other five releases still equal main: Codex 0.11.13, agent-hook 0.5.23, DSH 0.5.28, OpenCode 0.5.19, and Pi 0.4.22. The canonical shared-library change reaches all six consumers under the version gate, so please advance those five releases above the inspected main and keep paired manifests/configuration/locks aligned.

On this exact author head, the 40 recall/exclusion tests pass in a Windows/Node24 source snapshot. All three committed generated recall modules equal the canonical bytes plus the generator header. I found no additional runtime issue in that tested scope.

I did not run the generator, the version-gate command, a local merge, the full server, Linux, or live host/model/auth checks for this head. I can recheck the paired release metadata when the version-only follow-up is pushed; earlier results below remain limited to their named heads.

Previous review retained as historical evidence

Rechecked release metadata for bfb1c9b8 against inspected main 03b9aecf. Claude is now 0.7.14 versus main's 0.7.13.

The other five versions still equal main: Codex 0.11.11, agent-hook 0.5.21, DSH 0.5.26, OpenCode 0.5.17 and Pi 0.4.20. This PR changes the canonical shared library, so the version-bump script applies to all six plugins. Please advance those five versions above main and keep paired manifests/configuration/locks and generated copies aligned.

This update is limited to changed-file scope and release metadata. I did not rerun runtime tests, the version-gate command, generation, or a local merge for this head. Earlier test and merge results below apply only to their stated older heads.

Previous review retained as historical evidence

Reviewed author head d182fd50 against current main f64fb5ba. The read-only merge-tree check is clean. The 61 author-head recall/HTTP unit tests pass on Windows with Node 24.

The six touched releases currently equal main: Claude 0.7.12, Codex 0.11.11, agent-hook 0.5.21, DSH 0.5.26, OpenCode 0.5.17 and Pi 0.4.20. The actual HEAD version check exits 1. Please advance the touched versions strictly beyond main, retain the paired manifests/config/locks, and keep generated copies synchronized.

The tests cover the stated local unit paths; the full merged server, live host/model/auth, Linux and performance were not tested. Current approval-required workflows are not product-test success.

Previous review retained as historical evidence

Update 2026-10-14, rechecked a4299b4915d4df63546971953bc8ae2e8038310f against main 4f712cc9473e0150af87ad861ec47ba5feeea126:

The read-only merge is clean; the author head passes 40 recall/exclusion checks and 52 HTTP/doctor checks.
The version gate rejects Claude Code 0.7.11, Codex 0.11.10, and DSH 0.5.25, each equal to this tested main; please choose versions above main and keep their paired metadata/configuration aligned.
Generator checks report 7 passes and 2 ENOENT failures for the missing opencode-plugin/lib/shared generated directory in the fresh checkout, so that validation remains incomplete.
These are bounded Windows/Node results; the full merged server, Linux, live host/model, authentication and performance remain unverified, and the earlier review below is retained as history.


Update 2026-10-13, rechecked 12fd6903959d4eaefaf7962de83fe52ba6c7c903 against main 79ecf74f9333883c7820f4dd40558ddbf35a0125:

The earlier release-version finding is addressed for this tested main. All six plugin versions are strictly higher than main, the official version-bump gate passes, and the generated copies remain unchanged after synchronization. The original exclusion implementation and regression patch are preserved.

On the author head, generator tests (9), recall tests (40), and the Claude Code/Codex public exclusion tests (4) pass. The read-only merge is clean; 70 focused recall/capture tests pass on its actual merged tree. These test groups overlap and are not added. This is a focused Node regression check; the complete server build and live host/model integration were not run.

I found no further blocking issue within this reviewed scope. The earlier review below is retained as history; its version finding referred to the previous head and base.


Rechecked author head 74ac6bbe87e3e54d94025f8900280c668e69cc37 against main 2e706d7193aa47c05d986e68b61b3b994d41fa55.

The owned canonical fallback-filter and five-test regression patches are byte-identical to the previous f6de0d048 revision when each is compared with its own upstream base. The canonical module and its Claude/Codex/OpenClaw generated copies stay synchronized. Focused controls confirm subtree roots and children are excluded, similarly named siblings remain, exact document exclusions work, and malformed/non-array lists preserve the existing controls. Claude and Codex still forward configured exclusions into the context request.

The earlier version note needs a fresh bump against this main. All six version-gated plugins now equal main: Claude 0.7.9, Codex 0.11.8, agent-hook 0.5.17, OpenCode 0.5.11, DSH 0.5.23, and pi 0.4.16. A canonical shared-library runtime change reaches all six, and the official version gate against this exact main exits 1 for each equal version. Please choose available versions strictly above main and synchronize the corresponding host manifests/config/lock entries, then refresh the applicable checks. The strings did move relative to this branch's older base; that does not establish a newer release than today's referenced main.

The actual merge is clean, with tree 1cfab0c9199eed2f21ccf49029704bb97d66d31d; it also incorporates main's later shared capture changes. Focused Windows / Node 24.21.0 validation passed: recall-core plus the five exclusion regressions 40, Claude/Codex exclusion-wiring cases 4, public controls across canonical and three generated modules 16, shared generator 9, and all 5 changed module syntax checks. The actual merge snapshot passed 70 focused recall/exclusion/shared-capture tests. Regeneration changed no exported tracked bytes. Counts overlap and are not an aggregate total.

I found no additional scoped runtime blocker. This pass did not execute a full source-tree build, live hosts, deployed OpenViking, authenticated online models, GPU or performance tests. Final acceptance remains with the maintainers.


Historical review below refers to its stated heads and bases:

First-pass review (Integration / Claude+Codex — recallExcludeUris wiring)

Verdict: Correct plumbing follow-through for the shared exclude path. LGTM from a first-pass, with one CI hygiene note.

What checks out

  • Claude / Codex auto-recall now pass excludeUris: cfg.recallExcludeUris into the recall options (aligned with DSH / Pi).
  • Client-side fallback filter mirrors server exclude_uris (prefix + exact), so the multi-source flatten path cannot reintroduce excluded subtrees.
  • New recall-exclude.test.mjs pins body shape, non-array ignore, and the 200-cap.

Note

  • Diff does not bump host-visible plugin versions. If plugin-versions treats these entry/scripts changes as bump-worthy (same gate as other plugin PRs), please patch-bump Claude/Codex manifests (+ lock/metadata if present) on top of current main before merge.

Happy to re-check once CI reports.

The recallExcludeUris wiring changes entry scripts in both plugins;
the plugin-versions gate requires changed plugins to move their
version string (same as the DSH volcengine#5312 and pi volcengine#5368 precedents).

Co-Authored-By: Claude Code <noreply@anthropic.com>
@chaucerj

Copy link
Copy Markdown
Author

Version bumps pushed in 9840b85: claude-code .claude-plugin/plugin.json 0.6.4 → 0.6.5, codex .codex-plugin/plugin.json 0.10.5 → 0.10.6 — both manifest files are exactly what the plugin-versions gate tracks. Happy to re-check once CI reports.

🤖 Generated with Claude Code

Take upstream's 0.6.9 / 0.10.10 and re-bump to 0.6.10 / 0.10.11 so the
version-bump gate passes for the auto-recall/recall-core changes after
the rebase. Main did not touch the files this PR modifies.
The client-side subtree filter for recallExcludeUris was written into
the generated claude-code/codex copies; the sync gate regenerates those
from lib/recall-core.mjs, so the fix belongs in the canonical source.
Port it there and regenerate every committed copy (openclaw included).

Drop the auto-recall option wiring — upstream volcengine#5407 already forwarded
excludeUris in both hooks (one of the two lines here had become a
duplicate key after that merge).

Move the exclusion tests to the shared suite and cover the raw fallback
path (subtree root + children, exact URI, and the no-exclusion pass-
through), which neither volcengine#5407 nor volcengine#5616 touches.

Bump all six distributed plugins: a shared-lib change reaches every
consumer per the release gate. Targets deliberately match ktz03's
volcengine#5616 (both PRs ride the same lib); whichever lands second re-bumps.
d9352f2 (volcengine#5647) moved dsh to 0.5.15; this PR's shared-lib change still
requires a dsh bump relative to the new base, so it lands on 0.5.16.
Other plugin manifests are untouched by the new commits and keep their
targets.
volcengine#5653/volcengine#5663/volcengine#5664 moved claude-code to 0.7.1; this PR's shared-lib
change still requires a bump relative to the new base, so it lands on
0.7.2. No content conflicts — the usage-card work touches different
files than the recall exclude fallback.
volcengine#5699 moved codex to 0.11.2; the shared-lib fallback change still
requires a bump relative to the new base.
volcengine#5677/volcengine#5467 moved the agent-hook family to 0.5.11; the shared-lib
fallback change still requires a bump relative to the new base.
volcengine#5731/volcengine#5737/volcengine#5717 landed the same lib-driven bump targets this branch
carries (0.7.4 / 0.11.3 / 0.5.12 / 0.5.6 / 0.4.11); each takes one more
patch so the release gate sees movement. dsh rides upstream 0.5.18 and
lands on 0.5.19.
@chaucerj
chaucerj force-pushed the fix/claude-codex-recall-exclude-uris branch from 4484ae7 to 8e76332 Compare October 8, 2026 05:26
…umps

volcengine#5737/volcengine#5790/volcengine#5661/volcengine#5459 series landed the same lib-driven bump targets
this branch carries; each takes one more patch so the release gate sees
movement relative to the new base.
# Conflicts:
#	examples/agent-hook-plugin/hosts/cursor/openviking.integration.json
#	examples/agent-hook-plugin/hosts/kimicode/kimi.plugin.json
#	examples/agent-hook-plugin/hosts/kimicode/openviking.integration.json
#	examples/agent-hook-plugin/hosts/trae/openviking.integration.json
#	examples/agent-hook-plugin/hosts/zcode/openviking.integration.json
#	examples/agent-hook-plugin/plugin.json
#	examples/claude-code-memory-plugin/.claude-plugin/plugin.json
#	examples/claude-code-memory-plugin/package.json
#	examples/codex-memory-plugin/.codex-plugin/plugin.json
#	examples/dsh-memory-plugin/config.mjs
#	examples/dsh-memory-plugin/package-lock.json
#	examples/dsh-memory-plugin/package.json
#	examples/opencode-plugin/package.json
#	examples/pi-coding-agent-extension/package-lock.json
#	examples/pi-coding-agent-extension/package.json
# Conflicts:
#	examples/agent-hook-plugin/hosts/cursor/openviking.integration.json
#	examples/agent-hook-plugin/hosts/kimicode/kimi.plugin.json
#	examples/agent-hook-plugin/hosts/kimicode/openviking.integration.json
#	examples/agent-hook-plugin/hosts/trae/openviking.integration.json
#	examples/agent-hook-plugin/hosts/zcode/openviking.integration.json
#	examples/agent-hook-plugin/plugin.json
#	examples/claude-code-memory-plugin/.claude-plugin/plugin.json
#	examples/claude-code-memory-plugin/package.json
#	examples/codex-memory-plugin/.codex-plugin/plugin.json
#	examples/dsh-memory-plugin/config.mjs
#	examples/dsh-memory-plugin/package-lock.json
#	examples/dsh-memory-plugin/package.json
#	examples/opencode-plugin/package.json
#	examples/pi-coding-agent-extension/package-lock.json
#	examples/pi-coding-agent-extension/package.json
# Conflicts:
#	examples/agent-hook-plugin/hosts/cursor/openviking.integration.json
#	examples/agent-hook-plugin/hosts/kimicode/kimi.plugin.json
#	examples/agent-hook-plugin/hosts/kimicode/openviking.integration.json
#	examples/agent-hook-plugin/hosts/trae/openviking.integration.json
#	examples/agent-hook-plugin/hosts/zcode/openviking.integration.json
#	examples/agent-hook-plugin/plugin.json
#	examples/opencode-plugin/package.json
#	examples/pi-coding-agent-extension/package-lock.json
#	examples/pi-coding-agent-extension/package.json
# Conflicts:
#	examples/opencode-plugin/package.json
# Conflicts:
#	examples/claude-code-memory-plugin/.claude-plugin/plugin.json
#	examples/claude-code-memory-plugin/package.json
# Conflicts:
#	examples/claude-code-memory-plugin/.claude-plugin/plugin.json
#	examples/claude-code-memory-plugin/package.json
# Conflicts:
#	examples/claude-code-memory-plugin/.claude-plugin/plugin.json
#	examples/claude-code-memory-plugin/package.json
# Conflicts:
#	examples/agent-hook-plugin/hosts/cursor/openviking.integration.json
#	examples/agent-hook-plugin/hosts/kimicode/kimi.plugin.json
#	examples/agent-hook-plugin/hosts/kimicode/openviking.integration.json
#	examples/agent-hook-plugin/hosts/trae/openviking.integration.json
#	examples/agent-hook-plugin/hosts/zcode/openviking.integration.json
#	examples/agent-hook-plugin/plugin.json
# Conflicts:
#	examples/agent-hook-plugin/hosts/codebuddy/plugin.json
#	examples/agent-hook-plugin/hosts/cursor/openviking.integration.json
#	examples/agent-hook-plugin/hosts/kimicode/kimi.plugin.json
#	examples/agent-hook-plugin/hosts/kimicode/openviking.integration.json
#	examples/agent-hook-plugin/hosts/trae/openviking.integration.json
#	examples/agent-hook-plugin/hosts/zcode/openviking.integration.json
#	examples/agent-hook-plugin/plugin.json
# Conflicts:
#	examples/agent-hook-plugin/hosts/codebuddy/plugin.json
#	examples/agent-hook-plugin/hosts/cursor/openviking.integration.json
#	examples/agent-hook-plugin/hosts/kimicode/kimi.plugin.json
#	examples/agent-hook-plugin/hosts/kimicode/openviking.integration.json
#	examples/agent-hook-plugin/hosts/trae/openviking.integration.json
#	examples/agent-hook-plugin/hosts/zcode/openviking.integration.json
#	examples/agent-hook-plugin/plugin.json
…): take upstream version bumps + re-bump all 7 plugins (+1 over upstream) for gate compliance
…): take upstream magpie 0.2.0 + re-bump dsh 0.5.35 / magpie 0.2.1 for gate compliance
…): dsh takes upstream 0.5.36; re-bump claude-code/codex/opencode/dsh/pi (+1 over upstream) for gate compliance
…): take upstream agent-hook Qoder description; re-bump all 7 plugins (+1 over upstream, incl. new qoder host manifest) for gate compliance
…): take upstream Antigravity description; re-bump all 7 plugins (+1 over upstream, 8 agent-hook manifests incl. qoder) for gate compliance
…): take upstream version bumps (all 7 plugins ahead); re-bump all 7 plugins (+1 over upstream, 8 agent-hook manifests) for gate compliance
Upstream advanced every shared-lib consumer's version (agent-hook 0.5.38,
claude-code 0.7.28, codex 0.11.27, opencode 0.5.32, dsh 0.5.42, pi 0.4.34,
magpie 0.2.5). Our PR branch touches memory-plugin-shared/lib/recall-core.mjs,
which the version gate counts as a shared-library change, so all consumers
must sit strictly above the upstream value.
Upstream advanced the shared-lib consumers again (agent-hook 0.5.40,
claude-code 0.7.32, codex 0.11.29, opencode 0.5.34, dsh 0.5.44,
pi 0.4.36, magpie 0.2.7); our branch touches the shared
recall-core.mjs, so all consumers must sit strictly above upstream.

This branch has not been deployed

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

Labels

agent-plugins Agent harness and plugin integrations

Projects

Status: Backlog

Development

Successfully merging this pull request may close these issues.

3 participants