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

dhive-cli

v0.3.0

Published

D-HIVE — Claude Code progressive trust enhancement layer. Add H-I-V-E behavioral constraints to Claude Code, and D-H-I-V-E shackles to embedded AI models.

Downloads

306

Readme

D-HIVE

Claude Code 的渐进式信任增强层。 不是独立软件,不是替代品——四层可堆叠模块,每一层给 Claude Code 增加一项信任能力。

安装

npm install -g dhive-cli

30 秒开始

npx dhive-cli init my-project

你的项目现在就拥有了:

  • Layer 1: CLAUDE.md — Claude Code 行为约束(H-I-V-E 原则)
  • Layer 2: hooks — 危险操作自动拦截
  • Layer 3: kernel-state.json — 跨会话记忆和决策追踪

检测到 AI 嵌入?

npx dhive-cli detect                 # 扫描当前项目
npx dhive-cli init my-app --with-ai  # 创建 + Layer 4

# 或在现有项目中:
npx tsx scripts/hive-cli.ts scaffold-layer4

Layer 4 为嵌入的 AI 大模型施加 D-H-I-V-E 五条枷锁。

四层架构

| 层 | 内容 | 安装成本 | 得到什么 | |----|------|---------|---------| | Layer 1 | CLAUDE.md 模板 | 30 秒 | AI 行为约束 | | Layer 2 | + hooks | 1 分钟 | 自动执法 | | Layer 3 | + kernel-state.json | 2 分钟 | 跨会话记忆 | | Layer 4 | + D-H-I-V-E | 参考 companion/ | 嵌入 AI 的可信约束 |

可以停在任何一层。每层独立可用,叠加能力增强。

IDE 支持

dhive init 自动检测当前 IDE 并生成对应规则文件:

| IDE | 生成文件 | 说明 | |-----|---------|------| | Claude Code | .claude/settings.json | PreToolUse/Stop hooks 全覆盖 | | Cursor | .cursor/rules/hive.md | HIVE 行为约束注入 | | Windsurf | .windsurfrules | HIVE 原则注入 | | CodeBuddy | .codebuddy/rules/hive.md | HIVE 行为约束注入 |

命令

npx dhive-cli init                  # 交互式向导
npx dhive-cli init <name>           # 快速模式
npx dhive-cli init <name> --with-ai # + Layer 4
npx dhive-cli detect                # AI 嵌入检测
npx dhive-cli status                # 层状态

信任协议

D-HIVE 定义了三方信任协议(详见 PROTOCOL.md):

  • A 协议: Claude Code ↔ 人 — AI 建议,人决定
  • B 协议: 嵌入的 AI ↔ 人 — 记忆带置信度,人可质疑
  • C 协议: 框架 ↔ Claude Code — 检测到 AI 嵌入时主动提议

更多