npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@collect-flow2/skills-drawer

v0.4.0

Published

Browse the DeepSeek Harness skill catalog from the Web UI: a top-right header button and a 查看技能 item in the Workspace folder dropdowns open a right-side drawer with each skill's trigger conditions and description.

Readme

Skills Drawer

Browse the DeepSeek Harness skill catalog from the Web GUI. A 查看技能 / View skills button sits in the conversation header's top-right button row, and the same action is added to every Workspace (project folder) dropdown menu. Either entry opens a right-side drawer with a skill table — name, category, trigger conditions and description — split into 业务技能 / 通用技能 with per-category filters and text search. Any row expands into the full SKILL.md instructions.

┌──────────────────────────────────────┐  ┌──────────────────────────────────────────────┐
│ … conversation header  [技能] [▣] [⇥]│  │ 技能 · opensource                    ⟳   ✕  │
│                                      │  │ [ 搜索技能… ]                        共 39 个 │
│                                      │  │ (全部 39) (业务技能 0) (通用技能 39)          │
│                                      │  │ 技能        分类      触发条件       描述     │
│                                      │  │ ── 通用技能 39 ─────────────────────────────── │
│                                      │  │ /tdd      通用技能  模型按描述…    Test-…    │
│                                      │  │ /brand    通用技能  模型按描述…    Create…   │
└──────────────────────────────────────┘  └──────────────────────────────────────────────┘

What it adds

| Surface | Where | Behavior | | --- | --- | --- | | Header launcher | Overlay button aligned to the right of the conversation header, left of the utilities/corner group | Opens the drawer for the current Session's Workspace (or the Workspace the composer's folder picker shows) | | Workspace dropdown | The … menu of every sidebar Workspace row | 查看技能 opens the drawer for that Workspace | | Composer folder dropdown | The footer of the composer's 选择工作区 picker, after 添加工作区… | 查看技能 opens the drawer for the Workspace currently selected in the picker |

The drawer is one table (技能 · 分类 · 触发条件 · 描述) plus category filters:

| Surface | Behavior | | --- | --- | | Category chips | 全部 / 业务技能 / 通用技能, each with a live count. Picking one filters the table; picking 全部 shows the rows under category section headers | | Search | Case-insensitive match over skill name, description and trigger text; combines with the selected category | | Skill column | /kebab-case name plus model-only / user-only invocation badges | | 分类 column | Two-way split driven by the project's common-skill inventory: names listed in .agents/skill-sources/catalog.json (or in a global-scope inventory of .agents/skill-registry.json) are 通用技能; every other discovered skill is 业务技能. Without any inventory the source scope decides | | 触发条件 column | The explicit whenToUse frontmatter value when a skill declares one; otherwise how the skill actually triggers (matched automatically by the model from its description and/or invoked manually with /name) | | 描述 column | The routing description providers publish (clamped in the table) | | Expandable row | Click the skill name to load and show the full SKILL.md, source/provider and instruction file path beneath the row | | Refresh | Re-reads the catalog without closing the drawer |

Rows are sorted by category (业务 / 通用) and then by name; the whole table scrolls horizontally on narrow viewports and the drawer widens to 760px.

How 业务技能 / 通用技能 are decided

A project directory usually mixes two kinds of skills: imported reusable programming skills (tdd, code review, CNB/design helpers…) and skills authored for the business itself (collect/announcement/runtime skills…). The Host resolves that split from the project's own manifest instead of guessing by directory:

  1. It walks the requested directory and every skill's real directory upward and collects the names declared by .agents/skill-sources/catalog.json.
  2. It also reads .agents/skill-registry.json and adds the inventories of global-scope sources (scope: global + inventory), so a workspace that only consumes imported skills still resolves the owning repository's list.
  3. A skill whose name is in that list is 通用技能 (the project's reusable programming set); every other discovered skill is 业务技能.
  4. With no inventory anywhere, it falls back to discovery scope: project roots are 业务技能, user/model/plugin roots are 通用技能.

Example in this workspace: crawl-next reports 54 skills → 16 业务技能 (announcement-intake, captcha-host-analysis, collect-, company-information, crawler-runtime-, position-submit…) and 38 通用技能 (tdd, code-review, cnb-*, design, …). opensource reports 39 → 1 业务技能 and 38 通用技能.

Screenshots

| Top-right button (started Session) | Workspace … menu | Composer folder menu | | --- | --- | --- | | header button | workspace menu | hero menu |

| Skill table with categories and counts | Expanded skill instructions | | --- | --- | | table | skill detail |

| 业务技能 category (business-authored) | 通用技能 category (project common inventory) | | --- | --- | | business category | general category |

Install

From npm:

dsh plugin --profile web add @collect-flow2/skills-drawer

dsh plugin add installs the package and appends @collect-flow2/skills-drawer to the profile's dsh.profile.bundles; both steps are visible in ~/.dsh/profiles/web/package.json. The profile's patchReload is live, so a running Host recomposes after the manifest change; refresh the Web page. The Host serves the browser bundle from /plugins/@collect-flow2/skills-drawer/client.js.

Uninstall:

dsh plugin --profile web remove @collect-flow2/skills-drawer

and drop the bundle entry from dsh.profile.bundles if it remains.

How it works

Host half (index.js)

The browser cannot read the Host ctx.skills registry directly, so the Host half registers two authenticated, read-only routes on the Connection Fetch seat (same cookie/Host fence as every other Web API route):

| Route | Response | | --- | --- | | GET /api/skills-drawer.skills?workspaceId=<id>&cwd=<path> | { cwd, title, skills: [{ name, description, whenToUse, modelInvocable, userInvocable, source, provider, path }] } | | GET /api/skills-drawer.skill?workspaceId=<id>&cwd=<path>&name=<skill> | { skill: { …summary, content } } |

  • workspaceId is resolved through ctx.workspaceRegistry, which is the authoritative source for the project directory; the browser-supplied cwd is a fallback when the Workspace was deleted or the composition has no registry.
  • The shipped filesystem skill provider is mounted inside Agent presets, so the global registry layer is empty. The route retains the default preset's scope (ctx.get('agentPresets').acquireScope()) for the read — the same resolution sessionSkillCatalog uses for a Session without a live Agent — and releases it afterwards. A broken/absent preset falls back to the global layer rather than failing the drawer.
  • Each summary is classified 通用技能 / 业务技能 from the project's common-skill inventory (catalog.json + global-scope registry inventories), read from the requested directory and each skill's real directory; the classification is part of both route payloads.
  • Routes live exactly as long as the plugin (ctx.effect), and both support HEAD.

Client half (client.js)

  • Launcher: a shell.overlay component positions a 28×28 ghost button at the header's top-right. It measures [data-conversation-header-corner] and the utilities group in front of it, keeps an 8px gap, and keeps a 36px slot free for other overlay launchers. It hides itself when no conversation header is on screen (for example the Plugins panel) and re-measures on resize, header resizes, and body mutations.
  • Workspace dropdown items: neither the sidebar Workspace menu nor the composer folder picker is a slot-composed list, so the Client half appends a node that mirrors the shipped menu item's markup (same classes, icon box, and styling), after confirming the exact menu is open (the Workspace row carries menuOpen, or the picker's trigger has aria-expanded="true"). Clicking it dismisses the menu through the menu component's own Escape path and opens the drawer. All listeners/observers are removed when the plugin unloads.
  • Drawer: portaled to document.body, role="dialog", Escape/backdrop close, body scroll lock, focus moved into the drawer on open and returned to the launcher on close. Catalog and instruction reads use the Host routes with the session cookie (credentials: 'same-origin').

Nothing model-facing is registered: the plugin adds no tools, no prompt sections, and no Session writes.

Locale

The dictionaries live in client.js (skillViewer locale namespace) and the Plugin Manager metadata lives in locale/en.json / locale/zh.json. The drawer, launcher, and injected menu item follow the active Web UI language.

Publish

npm publish

publishConfig.access: public makes the scoped package public on the first release. After changing the source, bump version and publish again; installed profiles pick the new version up with dsh plugin --profile web add @collect-flow2/skills-drawer (or through the Plugin Manager page).

Verification

npm run check   # node --check over index.js, client.js, scripts/smoke-test.mjs
npm test        # host route contract with a mocked Cordis context

The smoke test drives both routes with real Request objects and asserts: route registration and methods, cwd/workspaceId resolution precedence, workspace-registry failure fallback, preset-scope retention/release, relative cwd rejection, invocation/source/whenToUse mapping, provider-failure 500s, detail lookup by exact name, and HEAD behavior.

Browser verification: refresh the Web page, then either click the header button or open a Workspace … menu (查看技能). The drawer should list the workspace's skills, filter as you type, refresh, and expand any skill into its instructions. node scripts/smoke-test.mjs needs Node 20+ for global Request/Response.

Files

| File | Role | | --- | --- | | package.json | Bundle manifest plus the dsh.client declaration | | cordis.patch.yml | Inserts the skills-drawer row | | index.js | Host half: workspace resolution + two authenticated skill routes | | client.js | Browser bundle: launcher, dropdown injection, drawer | | locale/en.json, locale/zh.json | Plugin Manager title and description | | scripts/smoke-test.mjs | Host route smoke test |

Known limits

  • Skills are read for the default Agent preset; a Session running a custom preset may see a slightly different bundled set. Project and user skills are identical for every preset.
  • The sidebar Workspace menu and the composer folder picker are not slot-composed upstream; the injected item mirrors their current markup. If a future upstream release changes those menu internals, the item needs the same class hooks (itemWrap / itemLabel / itemIcon / footer).
  • Categories are exclusive and inventory-based: the project's .agents/skill-sources/catalog.json / global-scope registry inventories define 通用技能; every other discovered skill is 业务技能. A project with no inventory falls back to source scope. Model-only / user-only invocation still shows as a badge inside either category.
  • The drawer lists every visible skill, including model-only ones (badged), because it is a catalog view rather than the / invocation menu.