鱼皮AI导航
鱼皮AI导航
  • 主页
  • 社区
  • AI工具
  • AI知识库
  • AI提示词
  • MCP
  • Skills
  • AI学习资源
  • AI资讯
  • GitHub开源
登录/注册

dsh-outline-auto

在 DSH 对话中搜索、读取并安全读写用户自己的 Outline 知识库文档,写操作受白名单保护与审批约束。

文档渲染
访问 GitHub
文档README

dsh-outline-auto

简体中文

A DeepSeek Harness plugin that searches and reads an Outline knowledge base from your conversation. Give it a keyword — it returns matching documents with titles, snippets, and links; ask for one of them and it returns the full content in Markdown. Approved write tools can create, update, and delete documents, with an approval prompt before every write.

Project status: 0.4.1. The current feature set is covered by unit tests, a Mock-server smoke, and a settings-chain integration check. The supported DSH baseline is 0.1.1-rc.2; older Harness builds are not certified.

The core idea

  • The knowledge base is one search away: you give a keyword, it gives you document links.
  • Read operations are available without write access; write operations are separately approved by the user.
  • Each user brings their own credentials: fill in the card in the GUI, no config files.
  • Setup per team member is the same three steps: install → restart → configure.

Features

  • Ten tools — search, read, count, list collections, resolve paths, list children, return a document template, create, update, and delete.
  • Clickable results — document links are resolved to absolute URLs against your baseUrl (Outline returns relative paths); snippets and titles are cleaned of HTML tags so results render cleanly in chat.
  • Configurable read cache (default 60s TTL, capped entries) — re-reading the same document within a session does not hit the API again; write tools invalidate the cache so edits are visible immediately; the TTL is configurable via cacheTtlMs and the cache has an entry cap to bound memory.
  • 429 retry with backoff — rate-limited requests automatically retry up to 3 times (respecting Retry-After, otherwise exponential backoff capped at 5s).
  • HTTPS enforcement — public URLs must use https:// (localhost and private intranet addresses are exempt) so the API token is never sent in clear text.
  • GUI configuration card — Settings → Plugins → plugin configuration, an Outline Knowledge Base card matching the official card UI; fill in baseUrl and API token, click save, done.
  • Per-user credentials — every user configures their own token in the GUI (stored under $DSH_HOME/settings.yaml, never in git); ideal for team distribution.
  • Safe when unconfigured — the plugin loads normally and tools return clear Chinese error messages; the GUI is never blocked.
  • Live updates — saving the card applies immediately, no restart; configuration priority: GUI card → environment variables → plugin config row.
  • Enable/disable — listed in Settings → Plugins → Plugin list after the host entry is active; the configuration card is under Settings → Plugins → Plugin configuration.
  • Ready to distribute — install from the public GitHub repository or archive after the release checklist below passes. Recipients should use the DSH plugin installer instead of manually editing profile bundles.

Requirements

ComponentBaseline
PlatformWindows / macOS / Linux
Node.js22.19 or newer
DeepSeek Harness0.1.1-rc.2 (required baseline)
Outline instancereachable from your machine (intranet / VPN), with an API token (Outline → Settings → API keys)

Installation

Recommended: DSH-managed install

Install from the public GitHub repository, pinned to the latest release tag:

▼
bash
复制代码
dsh plugin --profile web add git+https://github.com/huangfuren/dsh-outline-auto.git#v0.4.0

The #v0.4.0 suffix pins the exact release; omit it to track the latest commit on main.

Restart dsh web after installation. The published package contains the built lib/ directory, so a normal Git install does not depend on a local build step. Its install hook only removes stale references to this plugin's old package name (dsh-outline-ai) from the selected DSH profile; it does not remove or rewrite unrelated plugins.

For an AI-assisted installation, use the DSH plugin manager command above and do not manually add a second cordis.patch.yml entry or edit dsh.profile.bundles. If startup still fails and the error names another plugin, repair or disable that named plugin separately.

For a local checkout or extracted archive:

▼
bash
复制代码
dsh plugin --profile web add link:/absolute/path/to/dsh-outline-auto

The directory must contain package.json, lib/index.js, client.js, cordis.patch.yml, and dsh.plugin.json. Build the package before distributing an archive:

▼
bash
复制代码
pnpm build

Legacy hot-install script

The scripts/hot-install.mjs flow is intended for local development only. It creates a profile link and a patch row, so keep the checkout in a stable directory. Do not use it as the public distribution instructions.

Recovery after a failed install

▼
bash
复制代码
dsh plugin --profile web why dsh-outline-auto

If startup reports that it cannot resolve dsh-outline-ai, an older renamed entry remains in %USERPROFILE%/.dsh/profiles/web/package.json or the profile cordis.patch.yml. Reinstall this package in the affected profile; the install hook migrates the stale references when package lifecycle scripts are enabled. For a profile where scripts were disabled, run this explicit repair:

▼
powershell
复制代码
node node_modules/dsh-outline-auto/scripts/repair-profile.mjs --profile-dir "$env:USERPROFILE/.dsh/profiles/web"

Then run the DSH plugin manager once to refresh the profile lockfile before restarting dsh web. Do not rename the current package back to the old id.

If the package loads but the card is absent, restart dsh web, open Settings → Plugins, check Plugin list for dsh-outline-auto, then check Plugin configuration. A failed host entry will not expose its settings namespace.

Configuration

The recommended way is the GUI card (Settings → Plugins → plugin configuration → Outline Knowledge Base):

FieldDescription
Service URL (baseUrl)Outline instance root, e.g. https://outline.example.com
API Tokencreate one at Outline → Settings → API keys
Writable paths (empty = read-only)comma-separated directory paths, e.g. Collection A,Knowledge Base/Dir 1; only these directories and their children are writable

Click Save — applies immediately. Alternatively, configure via environment variables (OUTLINE_BASE_URL / OUTLINE_API_TOKEN) or the plugin config row in cordis.patch.yml. Advanced options in the plugin config row: timeoutMs (request timeout, default 15000) and cacheTtlMs (read-cache lifetime in ms, default 60000, range 1000–300000).

Read-only by default (v0.3.0): with no writable paths configured, all write tools (outline_create / outline_update_document / outline_delete) refuse to run — no approval prompt is even shown. To allow writes, list the directories that may be modified. A path like Knowledge Base/Dir 1 covers every child under Dir 1; a bare Collection A covers the whole collection. Any path that cannot be resolved (missing collection, invisible directory, moved document) is refused — writes always fail closed.

The public package must not contain organization-specific collection names, URLs, tokens, or document examples. Deployment-specific values are configured per installation — never publish an internal collection name as a schema default or UI placeholder.

Migrating from 0.2.x

0.3.0 removes the protectedCollections deny-list in favor of the writablePaths allow-list. After upgrading, every write is refused until you configure writable paths. If you previously protected a collection via the deny-list, simply leave it out of writablePaths — a collection that is not listed is not writable. Delete the old protectedCollections setting from your plugin config row, then set writablePaths to the directories you actually write to.

Tools

ToolDescription
outline_search(query, limit?, offset?, collectionId?, userId?, updatedAfter?)Keyword search; returns the match total, plus title, snippet, document id and link per hit. Optional filters: collection, author (userId), updated-after; offset skips the first N hits for pagination.
outline_get_document(id, maxLength?)Fetch a document's full Markdown by id; maxLength caps the returned text (default 20000).
outline_count()Total number of documents in the knowledge base (documents.list total, exact; excludes trashed/deleted — the true total may be slightly higher).
outline_list_collections()List visible collections (id, name, permission, document count).
outline_resolve_path(path)Resolve a human path like Knowledge Base/Directory A/Subdirectory into collectionId + parentDocumentId; returns the resolved full path.
outline_list_children(parentId)List direct child documents of a directory (parent document).
outline_doc_template()Return the standard requirement-document template (Markdown) + required section list — call it before writing a requirement doc.
outline_create(collectionId, title, text, publish?, parentDocumentId?)Write — create a document (default published; nest under a directory via parentDocumentId). Requires approval showing the resolved full path.
outline_update_document(id, title?, text?)Write — update a document's title/body. Requires approval showing the document path.
outline_delete(id)Write, irreversible — delete a document. Double approval: a first prompt, then a second confirmation before deletion.

Writes are restricted to the writable paths configured per deployment (read-only when empty). The public package ships with no organization-specific default.

Workflow: writing a requirement document (common task)

See the full SOP: docs/workflow-requirement-doc.zh.md — locate the directory (outline_resolve_path) → fetch the template (outline_doc_template) → draft → create with approval → verify.

Release checklist

  • Verify the package with the exact supported DSH baseline and Node.js baseline.
  • Run pnpm typecheck, pnpm build, pnpm test, and node scripts/smoke.mjs.
  • Inspect the archive contents: include built lib/, client.js, both manifests, the patch, and public documentation; exclude node_modules, .git, settings files, tokens, internal URLs, and internal document names.
  • Install the archive or GitHub URL into a clean web profile and confirm both Settings -> Plugins -> Plugin list and Plugin configuration.
  • Search the release tree for organization-specific names before publishing. A failed check blocks the release.

Development

▼
bash
复制代码
pnpm typecheck # strict tsc check pnpm build # emit lib/ pnpm test # vitest unit tests (mock fetch: success/empty/401/403/404/429/network/bad response) node scripts/smoke.mjs # local Mock Outline server, end-to-end smoke (prints SMOKE PASS) node scripts/verify.mjs # real settings → search → count chain (add --create for the create+cleanup chain)

The client half (client.js) is a dependency-free single-file module — no build step. The real-search verification script requires OUTLINE_BASE_URL / OUTLINE_API_TOKEN env vars.

License

MIT

文档渲染

快捷安装

复制到终端去安装插件

dshplugin--profilewebaddgithub:huangfuren/dsh-outline-auto

温馨提示

装插件等于在本机跑第三方代码,权限与你相同,能读文件、用凭据、访问网络,工具审批管不到。请只装可信来源,并尽量锁定 commit。

站长:程序员鱼皮 老鱼简历 商务合作 增值电信业务经营许可证
2026 鱼皮AI导航 | 沪ICP备19026706号-6
站长:程序员鱼皮 老鱼简历 商务合作 增值电信业务经营许可证
2026 鱼皮AI导航 | 沪ICP备19026706号-6
🔥热门工具
朱雀AI检测朱雀AI检测
朱雀AI检测助手朱雀AI检测助手
LovartLovart
老鱼简历老鱼简历
WritePass官网WritePass官网
面多多面多多
CursorCursor
星月写作星月写作
零感AI零感AI
墨得问题墨得问题
dsh 插件推荐
dsh-markdown-reader
在独立全屏阅读器中渲染工作区 Markdown 文件,支持 GFM、KaTeX、Mermaid、目录导航、文件更新同步以及浏览器打印和 PDF 导出。
dsh-xia-plugins#packages/gameassist-knowledge
树状 Markdown 知识库:为 DSH Agent 提供 kb_list/kb_read/kb_write 工具、目录/正文 HTTP 接口,并配套浏览器面板。
dsh-workbuddy-ppt
在 DSH 中使用包内编排 Skill、确定性 PPTD 场景检查和原生 PowerPoint 对象生成可编辑 PPTX,并在本地交付 PPTD 源项目。
dsh-industry-research
面向 DeepSeek Harness 的确定性行业研究报告:公司与行业研究流程基于分阶段证据产出结构化、可核验的报告。
dsh-mermaid-smooth
将 dsh Web 对话中的 mermaid 代码围栏默认渲染为 SVG 图表,支持以指针为锚点的丝滑缩放拖拽、按围栏记忆的图/文案切换(localStorage 持久化)、明暗主题跟随,以及完全本地打包的离线渲染引擎。