Skip to content

Give every Bot a built-in DS Bot manual it can read, configure from and explain - #1941

Merged
Fei2411 merged 4 commits into
devfrom
feat/ds-bot-manual
Nov 21, 2026
Merged

Fei2411 merged 4 commits into
devfrom
feat/ds-bot-manual

Conversation

@Fei2411

@Fei2411 Fei2411 commented Nov 21, 2026 •

Copy link
Copy Markdown
Owner

Issue

None (maintainer request: users don't know how to use or configure DS Bot's many features; the Bot should have a manual it can read, configure from and introduce to users).

What changed / 改了什么

  • New bundled skill ds-bot-manual (ds-bot/src/host/skills/ds-bot-manual/): SKILL.md with how to use the manual (answer, guided tour, configure on the user's behalf), an Authority section (what any Bot / a Main Bot / only the user may change or approve), and 12 references: getting started, Bots, chats/groups/goals, models, memory, capabilities/connectors/secrets, browser & computer use, IM/phone/mobile, schedules & tasks, approvals & permissions, a settings-page reference, troubleshooting. Each lists the English UI labels, the Bot tools that configure it, who has the right, and common problems, with source pointers into the repo.
  • ds-bot/src/host/manual-skills.js: skill provider modeled on goal-skills.js, registered in index.js; maps app.asar → app.asar.unpacked so references are plain files in the packaged app.
  • prompt.js: one team rule telling every Bot to load ds-bot-manual for how-to/configuration questions and before changing DS Bot settings.
  • app/electron-builder.yml: unpack node_modules/ds-bot/src/host/skills/** (same glob open PR Add bundled maintenance & plugin-dev skills and developer reference guides #1654 adds, so the two stay compatible).
  • ds-bot/test/manual-skills.test.js: provider loads; SKILL.md index and reference files match exactly; every backticked tool name in the manual is a real registered host tool, so the manual can't silently drift from the code.

No UI change.

Changelog

Bots can now explain how DS Bot works and how to set it up, and configure supported settings themselves, from a built-in manual.

How I checked it / 怎么验证的

  • npm test (in ds-bot/) — 3529 pass, 0 fail, 4 skipped
  • node scripts/build-client.mjs --check
  • npm run lint
  • Smoke test — all 56 steps passed against DSH dsh-v0.2.2-rc.1
  • Screenshot attached, for interface changes — no interface change

Also: app/test/package.test.mjs 7/7, leak scan must fix: 0.

Checklist / 检查

  • One issue, one subject.
  • src/client/ unchanged.
  • No keys, tokens or personal data.
  • No AI tool as author or Co-authored-by.

Agent: Devin (Cognition)


Product Engineer opened this PR for Lulu
Implemented in session Write a self-readable DS-Bot user manual
Review with Devin · Open in Devin Desktop


Give every Bot a source-grounded guide to features, supported configuration tools and user approval boundaries. Keep references readable in packaged apps and test tool claims against actual runtime registrations.
@devin-ai-integration

Copy link
Copy Markdown
Contributor

I'll fix CI failures and address comments from users with write access that start with 'Devin'.

  • Disable automatic comment, CI, and merge conflict monitoring

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 21, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-21T08:14:00.913402Z 9464fdf PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 9464fdf9df

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread ds-bot/src/host/prompt.js Outdated
'- A file the user attaches reaches you as a saved path, and the read tool opens text files only. A PDF, scanned or not, opens through the office skill: load it, then look at the pages with office_render (or the office-render skill when the catalog offers that instead). If that cannot run here, for example because your model does not accept images, say so and tell the user what to send instead; never answer only that the file cannot be read.',
'- Your conversations are long-lived. When one grows long, either its older messages are condensed in place into a summary you wrote (a "[Checkpoint N]" message), or it moves on to a fresh part that opens with a handoff note you wrote and your latest messages (a "[Handoff · part N]" message). What leaves your working context stays saved. When you need the exact earlier wording or a detail the summary or note does not show in full (a full path, a figure, every item of a complete list or a final summary), call read_own_chat with words to look for, or with part N to read the note that closed an earlier part; never fill such a detail in from memory. Each line it returns starts with an anchor such as [part 2 #1234 · 10-08 14:22]; pass the anchor as around to read what was said around it.',
'- For multi-step or slow work in your own chat or a group chat, call task_start to run it in a background task while the chat stays free. Pass follow-ups with task_send, stop one with task_stop, inspect with task_list, and read long results with task_read. Slow shell commands move to background jobs on their own after the configured wait. On local CLI agents, a background task starts a separate CLI session with a recent summary (use workdir for a separate folder or worktree when editing files).',
'- Load the ds-bot-manual skill when the user asks how to use or configure DS Bot, what it can do, or wants a tour, and before changing DS Bot settings yourself; read the relevant references and respect their user-only controls and approvals.',

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Make the manual accessible to local-agent Bots

For Bots running on a local agent CLI, this instruction requires a skill that the CLI cannot load through the DS Bot bridge. In src/host/local-agents/index.js, toolsFor forwards only registered team tools and approve_agent_action, excluding DSH's skill-loading tools; the local-agent design also explicitly states that DSH skills do not reach the CLI. Registering this provider therefore does not give those Bots access to the manual, and the new instruction supplies no filesystem location or alternative retrieval mechanism. Expose a supported way for local-agent Bots to retrieve the bundled manual, or give them a usable path-based fallback instead of unconditionally requiring skill loading.

Useful? React with 👍 / 👎.

lulu added 3 commits November 21, 2026 00:17
Local agent Bots do not receive DSH's skill loader. Include the manual file path and read-tool fallback in the shared prompt so they can read its references too.
Profile installs place bundled skill references below DSH_HOME. Exempt only DS Bot's bundled skills directory from the broad data-root guard while keeping private regions and other data-root files closed.
Short fixture Session ids can match letters in checkout paths and make direct reads public. Use a newly created reader to exercise the data-root guard without that shortcut.

@devin-ai-integration devin-ai-integration Bot 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.

Devin Review found 2 findings. Devin automatically fixed all 2 findings.

Fixed by Devin (2)
  • Built-in manual unavailable to local agents — The prompt rule now gives the manual's SKILL.md path, so a Bot with no skill loader (local agents) opens it with its read tool.
  • Private Bot protection blocks manual references — DS Bot's bundled skills directory is now in ownerOfPath's open folders, and a test covers it.

View findings in Devin Review · Follow Devin's work

Devin Review

@Fei2411 Fei2411 left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

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

Code Reaper review — Verdict: pass (head cc4f6c9c)

Checked: diff, manual references against settings.js SETTINGS_PAGES, update_bot fields, private-Bot rules in roster.js/i18n.js; manual-skills, privacy, prompt tests pass locally (36/36). The PR body has the Agent: Devin (Cognition) line and a Changelog entry. Both earlier findings (no way in for local agents, private Bots blocking reads of the references) are fixed in e9c82da4/4cc8cfe0.

Non-blocking notes:

  1. Third copy of the skill provider. manual-skills.js repeats the frontmatter parser and candidate shape from goal-skills.js/office-skills.js. #1942 turns goal-skills.js into a list of skills in the same src/host/skills/ folder, and #1654 adds a fourth provider (maintenance-skills.js). After these land, a follow-up could merge the bundled skills under src/host/skills/ into one provider.
  2. Absolute path in the shared prompt prefix. The new team rule includes the install path of SKILL.md. In the packaged app that path stays the same, but in a DSH plugin install it can include the package version (pnpm store), so the cached prefix changes once per plugin update and the model provider sees the user's home path. This is fine to keep; I'm noting it so nobody is surprised later.
  3. The privacy exemption opens all of src/host/skills/, not only the manual. That's correct: it contains only bundled code and docs, and it also covers goal-grill and the skills #1942/#1654 add.

Overlaps with open PRs (textual only; none change the same logic):

  • #1654 (bundled maintenance/plugin-dev skills): conflicts in app/electron-builder.yml, app/test/package.test.mjs, ds-bot/index.js. It adds the same skills/** unpack glob, so whichever lands second drops its copy.
  • #1942 (report-issue skill), #1919, #1915, #992, #1298: MODULES line in ds-bot/index.js only.
  • #1838: the node:path import line in privacy.js plus privacy.test.js imports.
  • #1935: privacy.js (that PR already conflicts with dev).

Suggested order: this PR first (small, green), then #1942 and #1838 (each a one-line conflict), then #1654 drops its duplicate glob/test lines.

Written by Devin

@Fei2411
Fei2411 merged commit 43aaa1f into dev Nov 21, 2026
16 checks passed
@Fei2411
Fei2411 deleted the feat/ds-bot-manual branch November 21, 2026 08:44
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