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-zcode-persona

v0.1.0

Published

Make the model believe it is inside the Z.ai Code (Zhipu ZCode) agent environment: replaces the harness identity opener and injects a ZCode rules skeleton with a dynamic project section. 让模型认为自己处于智谱 ZCode Agent 环境。

Readme

dsh-zcode-persona

让模型认为自己在 Z.ai Code(智谱 ZCode)Agent 环境中:替换 DeepSeek Harness 身份开场白,注入 ZCode 风格规则骨架与动态项目信息段。

English | 简体中文

提示词素材:x1xhlol/system-prompts-and-models-of-ai-tools → Z.ai Code/prompt.txt(泄露原文,保留可辨识特征句,剔除 Next.js 等场景硬编码)。

机制

挂 system-prompt/assemble waterfall(await next() 后修改,返回值权威):

  1. 把 harness:identity 段(order −100,原文 You are an AI agent powered by DeepSeek Harness.)替换为 ZCode 身份陈述;
  2. 在 deployment:persona(order 0)之后插入 zcode:persona 段:# Instructions / # Important Rules(通用化 ZCode 骨架)+ # Project Information(cwd/model 从组装变量取已求值结果直接拼接,缺席时整段省略——文本不写 {{…}} 占位,避开严格插值抛错)。

工具 schema、动态上下文、变量、其余段全部保持 DSH 原样;工具名用叙述性表述("the todo tools available to you"),实际调用协议仍由 DSH 工具 schema 决定。

安装

dsh plugin --profile web add dsh-zcode-persona
# 或直接从 GitHub:
dsh plugin --profile web add github:flashyiyi/dsh-zcode-persona

经 super-injector dev 工具注入的,卸载 entry 即关闭;下方 enabled 配置同样可用。

配置(改后需重载插件)

| 键 | 默认值 | 含义 | |---|---|---| | enabled | true | 总开关;false 时不注册 waterfall 监听。 | | identity | You are Z.ai Code. | 替换 harness 开场白的身份陈述。 | | opener | You are an interactive CLI tool that helps users… | 身份后紧跟的开场句。 | | extraRules | '' | 追加到 zcode:persona 段末尾的额外规则。 |

模型 / Token / KV Cache 影响

  • 每次请求的提示词以 ZCode 身份开头,替换不改变段结构,zcode:persona 文本每轮逐字节相同(cwd/model 整轮稳定),KV 前缀保持稳定。
  • zcode:persona 约 1.2KB 文本进每次请求的系统提示词固定成本。
  • Minimal preset(persona 为 complete 段)下,complete 在 waterfall 后恢复快照,本插件不生效(与 dsh-unrestricted 同一限制)。

合规边界

仅用于自有部署的行为定制、红队测试与研究;冒充 ZCode 或其他品牌对外提供服务或绕过上游服务限制的风险自负。

构建

DSH_CHECKOUT=<checkout> bash scripts/build.sh