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

dsh-code-complete

v0.1.0

Published

DSH code completion plugin (FIM, agent-autonomous; multi-channel: DeepSeek official FIM / DashScope qwen-coder-turbo / SiliconFlow; zero runtime deps)

Downloads

218

Readme

dsh-code-complete · DSH 代码补全(FIM)

DeepSeek Harness 插件:给 agent 挂一个 FIM(fill-in-the-middle)代码补全工具 code_complete——读目标文件指定位上下文 → 调线上 FIM 模型 → 返回补全候选。与 LSP 符号补全互补(本件是模型生成候选)。

特性

  • 多通道自动降级:DeepSeek 官方 FIM(原生 prompt/suffix)→ DashScope qwen-coder-turbo(模板拼接)→ SiliconFlow(extra_body);主→备链路自动切换,channel 参数可指定。
  • 窗口裁剪:FIM 前缀 80% / 后缀 20%·≤200 行窗口·输入 ≤10000 字符(长文件自动截取有效上下文)。
  • 零运行时依赖:纯 Node 标准库 + 原生 fetch。
  • 内置节流+凭证走 DSH CredentialProvider(ctx.credentials.resolve)。

安装

dsh plugin --profile <你的 profile> add dsh-code-complete

手动挂载(host 组合 cordis.patch.yml insert 行)亦可——插件注册工具 code_complete(path, line, column?, maxTokens?, channel?)。

配置

apply(ctx, config) 第二参(可选):

| 键 | 默认 | 说明 | | --- | --- | --- | | timeoutMs | 30000 | 单次 FIM 请求超时 | | maxTokensDefault | 128 | 补全长默认(上限 512) | | channelOrder | auto 次序 | 覆盖默认降级链 |

凭证

按通道自动解析(存在哪个走哪个):DeepSeek 官方 → DEEPSEEK_API_KEY;DashScope → GLM_EMBEDDING_KEY 之外的百炼系 key;SiliconFlow → 对应渠道 key。均可通过 DSH 凭证库管理。

License

MIT