Skip to content

feat: refresh the / Skill menu live while a conversation is open - #4264

Open
DoodleBears wants to merge 6 commits into
claude/skills-s2-groupfrom
claude/skills-s3-live
Open

DoodleBears wants to merge 6 commits into
claude/skills-s2-groupfrom
claude/skills-s3-live

Conversation

@DoodleBears

Copy link
Copy Markdown
Contributor

#4234 | hub #4231 | stacked on #4259 | Agent tasks: claude-code/local/b7955cb7-65c2-4b41-bafd-b18256e4a38b (Client, integration, review), codex/local/01a1e105-c85e-73a3-a607-dbb8007b9911 (Host refresh, events)

Closes #4234

Why the change

The / menu read the Skill catalog once when a conversation opened, so a Skill added, edited or deleted while the DM or Group was open stayed invisible until the Human reopened it. S4 (PersonaBots install their own Skills) needs a newly written Skill to show up right away.

Special things to note

  • Stacked on feat: / Skill Invocation in Group Channels #4259 → feat: invoke a Bot's Skills from / in a Human DM #4252. Retarget to main after those merge.
  • Merge risk: two-way door, revert the PR; no schema change. Medium blast radius: it adds filesystem watchers per PersonaBot Memory Repository, a Host listener on DSH skills/change, a no-op DSH Skill provider used only for its control.invalidate(), and a new event on the existing roster SSE carrier.
  • No polling. The Host watches <memory>/.agents/skills and <memory>/.dsh/skills (recursive, plus shallow parent watches for missing or replaced roots) and reconciles watchers on Bot create, delete, preset change and Memory move.
  • Only the affected catalog is recomputed: Project and Host portions are cached per Bot; a Memory change invalidates that Bot's Project portion, and a Host Skill change refreshes the Host portion once and is broadcast only when its content actually changed.
  • The event is filtered by the Human's Channel access before it reaches a Client.
  • skills-list uses the same channelSkillCatalog RPC, so the CLI reads the same fresh catalog.
  • Review focus: installHostSkillInvalidation in native-agent-compat.ts (it registers an empty provider to obtain DSH's public registry invalidation) and watcher cleanup in skills/refresh.ts.

Change outline

Before: with Ada's DM open, typing /demo shows nothing that matches.

Before: /demo in Ada's DM, no matching Skill

Add while open: writing <memory>/.agents/skills/demo-live/SKILL.md makes /demo-live appear in the same open menu about 3 s later, with no reload.

After: /demo-live appears in the open menu

Edit while open: changing its description updates the row in place.

After: /demo-live description updated in the open menu

Isolated Host, one headless browser session per capture that stays open while the file is written (--wait-text on the new text), viewport 1440×900 cropped to the conversation pane, light theme, English.

fs.watch(<memory>/.agents|.dsh/skills) ─► SkillCatalog.invalidateMemory(bot) ─┐
DSH skills/change ─► refreshHost() (only if Host content changed) ────────────┤
                                                                               ▼
                         live hub: skills/catalog-changed {botSlugs, channelIds}  (filtered by Channel access)
                                                                               ▼
Client: subscribeSkillCatalog(channelId, reload) → channelSkillCatalog → newest response wins

Tests: packages/core/test/skill-catalog-refresh.test.ts (invalidation scope by registry call counts, add/modify/delete in both trees, Host change, Memory move, cleanup), packages/client/test/skill-catalog-live.test.ts (SSE parsing, channel filtering, reconnect baseline, unsubscribe). Codex ran 641 ci-plan affected suites (7,151 tests) plus a DSH 0.2.2-rc.1 runtime probe for the delete case and .dsh/skills; pnpm lint and tsc are clean on the integrated head. Delete-while-open was not captured in the browser: --wait-text can only wait for text to appear, so the delete case rests on the runtime probe.

🤖 Generated with Claude Code

DoodleBears and others added 3 commits November 16, 2026 07:11
Issue: #4234
Agent-Task: codex/local/01a1e105-c85e-73a3-a607-dbb8007b9911
Subscribe to Skill catalog changes for the open conversation and refetch
the catalog on each change, keeping only the latest response.

Issue: #4234
Agent-Task: claude-code/local/b7955cb7-65c2-4b41-bafd-b18256e4a38b

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@coderabbitai

coderabbitai Bot commented Nov 15, 2026 •

Copy link
Copy Markdown

Warning

Review limit reached

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Next included review available in 25 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used all 4 included reviews currently available.

Learn how review limits work.

Review configuration:

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 96ed755b-5728-4623-bb29-f76d66fcde75
Commits

Reviewing files that changed from the base of the PR and between c551975 and 758c3fa.

Files selected for processing: 20

  • .agents/skills/verify-deepseekbot/features/skill-invocation.md
  • apps/docs/test/docs-reference.test.ts
  • apps/mobile/src/host/wire.ts
  • changes/4234-live-skill-catalog.md
  • docs/architecture/botharness-architecture.md
  • packages/client/src/client/actions.ts
  • packages/client/src/client/bot-main.tsx
  • packages/client/src/client/bridge.ts
  • packages/client/src/client/live-snapshots.ts
  • packages/client/src/client/messaging-defaults-live.ts
  • packages/client/test/inert-submissions.ts
  • packages/client/test/skill-catalog-live.test.ts
  • packages/core/src/channels/live.ts
  • packages/core/src/plugin.ts
  • packages/core/src/runtime/native-agent-compat.ts
  • packages/core/src/skills/catalog.ts
  • packages/core/src/skills/events.ts
  • packages/core/src/skills/refresh.ts
  • packages/core/test/skill-catalog-refresh.test.ts
  • packages/core/test/skill-invocation.test.ts
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

@DoodleBears

Copy link
Copy Markdown
Contributor Author

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Nov 15, 2026 •

Copy link
Copy Markdown
Action not completed

Review rate limited.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

DoodleBears and others added 2 commits November 16, 2026 08:48
Bot-main tests build actions from a Proxy whose unknown members return a
rejected promise; the live Skill catalog subscription needs a real
unsubscribe function there.

Issue: #4234
Agent-Task: claude-code/local/b7955cb7-65c2-4b41-bafd-b18256e4a38b

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@DoodleBears

Copy link
Copy Markdown
Contributor Author

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Nov 15, 2026 •

Copy link
Copy Markdown
Action not completed

Review rate limited.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

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

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant