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

@zhuan-ai/zhuanspec

v2.19.1

Published

AI-native system for spec-driven development

Readme

ZhuanSpec

ZhuanSpec aligns humans and AI coding assistants with spec-driven development so you agree on what to build before any code is written. No API keys required.

Why ZhuanSpec?

AI coding assistants are powerful but unpredictable when requirements live in chat history. ZhuanSpec adds a lightweight specification workflow that locks intent before implementation, giving you deterministic, reviewable outputs.

Key outcomes:

  • Human and AI stakeholders agree on specs before work begins.
  • Structured change folders (proposals, tasks, and spec updates) keep scope explicit and auditable.
  • Shared visibility into what's proposed, active, or archived.
  • Works with the AI tools you already use: custom slash commands where supported, context rules everywhere else.

How ZhuanSpec compares (at a glance)

  • Lightweight: simple workflow, no API keys, minimal setup.
  • Brownfield-first: works great beyond 0→1. ZhuanSpec separates the source of truth from proposals: zhuanspec/specs/ (current truth) and zhuanspec/changes/ (proposed updates). This keeps diffs explicit and manageable across features.
  • Change tracking: proposals, tasks, and spec deltas live together; archiving merges the approved updates back into specs.
  • Compared to spec-kit & Kiro: those shine for brand-new features (0→1). ZhuanSpec also excels when modifying existing behavior (1→n), especially when updates span multiple specs.

See the full comparison in How ZhuanSpec Compares.

How It Works

┌────────────────────┐
│ Draft Change       │
│ Proposal           │
└────────┬───────────┘
         │ share intent with your AI
         ▼
┌────────────────────┐
│ Review & Align     │
│ (edit specs/tasks) │◀──── feedback loop ──────┐
└────────┬───────────┘                          │
         │ approved plan                        │
         ▼                                      │
┌────────────────────┐                          │
│ Implement Tasks    │──────────────────────────┘
│ (AI writes code)   │
└────────┬───────────┘
         │ ship the change
         ▼
┌────────────────────┐
│ Archive & Update   │
│ Specs (source)     │
└────────────────────┘

1. Draft a change proposal that captures the spec updates you want.
2. Review the proposal with your AI assistant until everyone agrees.
3. Implement tasks that reference the agreed specs.
4. Archive the change to merge the approved updates back into the source-of-truth specs.

Getting Started

Supported AI Tools

These tools have built-in ZhuanSpec commands. Select the ZhuanSpec integration when prompted.

| Tool | Commands | |------|----------| | Amazon Q Developer | @zhuanspec-proposal, @zhuanspec-apply, @zhuanspec-archive (.amazonq/prompts/) | | Antigravity | /zhuanspec-proposal, /zhuanspec-apply, /zhuanspec-archive (.agent/workflows/) | | Auggie (Augment CLI) | /zhuanspec-proposal, /zhuanspec-apply, /zhuanspec-archive (.augment/commands/) | | Claude Code | /zhuanspec:proposal, /zhuanspec:apply, /zhuanspec:archive | | Cline | Workflows in .clinerules/workflows/ directory (.clinerules/workflows/zhuanspec-*.md) | | CodeBuddy Code (CLI) | /zhuanspec:proposal, /zhuanspec:apply, /zhuanspec:archive (.codebuddy/commands/) — see docs | | Codex | /zhuanspec-proposal, /zhuanspec-apply, /zhuanspec-archive (global: ~/.codex/prompts, auto-installed) | | CoStrict | /zhuanspec-proposal, /zhuanspec-apply, /zhuanspec-archive (.cospec/zhuanspec/commands/) — see docs| | Crush | /zhuanspec-proposal, /zhuanspec-apply, /zhuanspec-archive (.crush/commands/zhuanspec/) | | Cursor | /zhuanspec-proposal, /zhuanspec-apply, /zhuanspec-archive | | Factory Droid | /zhuanspec-proposal, /zhuanspec-apply, /zhuanspec-archive (.factory/commands/) | | Gemini CLI | /zhuanspec:proposal, /zhuanspec:apply, /zhuanspec:archive (.gemini/commands/zhuanspec/) | | GitHub Copilot | /zhuanspec-proposal, /zhuanspec-apply, /zhuanspec-archive (.github/prompts/) | | iFlow (iflow-cli) | /zhuanspec-proposal, /zhuanspec-apply, /zhuanspec-archive (.iflow/commands/) | | Kilo Code | /zhuanspec-proposal.md, /zhuanspec-apply.md, /zhuanspec-archive.md (.kilocode/workflows/) | | OpenCode | /zhuanspec-proposal, /zhuanspec-apply, /zhuanspec-archive | | Qoder (CLI) | /zhuanspec:proposal, /zhuanspec:apply, /zhuanspec:archive (.qoder/commands/zhuanspec/) — see docs | | Qwen Code | /zhuanspec-proposal, /zhuanspec-apply, /zhuanspec-archive (.qwen/commands/) | | RooCode | /zhuanspec-proposal, /zhuanspec-apply, /zhuanspec-archive (.roo/commands/) | | Windsurf | /zhuanspec-proposal, /zhuanspec-apply, /zhuanspec-archive (.windsurf/workflows/) |

Kilo Code discovers team workflows automatically. Save the generated files under .kilocode/workflows/ and trigger them from the command palette with /zhuanspec-proposal.md, /zhuanspec-apply.md, or /zhuanspec-archive.md.

These tools automatically read workflow instructions from zhuanspec/AGENTS.md. Ask them to follow the ZhuanSpec workflow if they need a reminder. Learn more about the AGENTS.md convention.

| Tools | |-------| | Amp • Jules • Others |

Install & Initialize

Prerequisites

  • Node.js >= 20.19.0 - Check your version with node --version

Step 1: Install the CLI globally

npm install -g @fission-ai/zhuanspec@latest

Or install from a local tarball (e.g. distributions/fission-ai-zhuanspec-1.0.0.tgz): see Installing ZhuanSpec.

Verify installation:

zhuanspec --version

Step 2: Initialize ZhuanSpec in your project

Navigate to your project directory:

cd my-project

Run the initialization:

zhuanspec init

What happens during initialization:

  • You'll be prompted to pick any natively supported AI tools (Claude Code, CodeBuddy, Cursor, OpenCode, Qoder,etc.); other assistants always rely on the shared AGENTS.md stub
  • ZhuanSpec automatically configures slash commands for the tools you choose and always writes a managed AGENTS.md hand-off at the project root
  • A new zhuanspec/ directory structure is created in your project

After setup:

  • Primary AI tools can trigger /zhuanspec workflows without additional configuration
  • Run zhuanspec list to verify the setup and view any active changes
  • If your coding assistant doesn't surface the new slash commands right away, restart it. Slash commands are loaded at startup, so a fresh launch ensures they appear

Optional: Populate Project Context

After zhuanspec init completes, you'll receive a suggested prompt to help populate your project context:

Populate your project context:
"Please read zhuanspec/project.md and help me fill it out with details about my project, tech stack, and conventions"

Use zhuanspec/project.md to define project-level conventions, standards, architectural patterns, and other guidelines that should be followed across all changes.

Create Your First Change

Here's a real example showing the complete ZhuanSpec workflow. This works with any AI tool. Those with native slash commands will recognize the shortcuts automatically.

1. Draft the Proposal

Start by asking your AI to create a change proposal:

You: Create a ZhuanSpec change proposal for adding profile search filters by role and team
     (Shortcut for tools with slash commands: /zhuanspec:proposal Add profile search filters)

AI:  I'll create a ZhuanSpec change proposal for profile filters.
     *Scaffolds zhuanspec/changes/add-profile-filters/ with proposal.md, tasks.md, spec deltas.*

2. Verify & Review

Check that the change was created correctly and review the proposal:

$ zhuanspec list                             # Confirm the change folder exists
$ zhuanspec validate add-profile-filters     # Validate spec formatting
$ zhuanspec show add-profile-filters         # Review proposal, tasks, and spec delta

3. Refine the Specs

Iterate on the specifications until they match your needs:

You: Can you add acceptance criteria for the role and team filters?

AI:  I'll update the spec delta with scenarios for role and team filters.
     *Edits zhuanspec/changes/add-profile-filters/specs/profile/spec.md and tasks.md.*

4. Implement the Change

Once specs look good, start implementation:

You: The specs look good. Let's implement this change.
     (Shortcut for tools with slash commands: /zhuanspec:apply add-profile-filters)

AI:  I'll work through the tasks in the add-profile-filters change.
     *Implements tasks from zhuanspec/changes/add-profile-filters/tasks.md*
     *Marks tasks complete: Task 1.1 ✓, Task 1.2 ✓, Task 2.1 ✓...*

5. Archive the Completed Change

After implementation is complete, archive the change:

AI:  All tasks are complete. The implementation is ready.

You: Please archive the change
     (Shortcut for tools with slash commands: /zhuanspec:archive add-profile-filters)

AI:  I'll archive the add-profile-filters change.
    *Runs: zhuanspec archive add-profile-filters --yes*
     ✓ Change archived successfully. Specs updated. Ready for the next feature!

Or run the command yourself in terminal:

$ zhuanspec archive add-profile-filters --yes  # Archive the completed change without prompts

Note: Tools with native slash commands (Claude Code, CodeBuddy, Cursor, Codex, Qoder, RooCode) can use the shortcuts shown. All other tools work with natural language requests to "create a ZhuanSpec proposal", "apply the ZhuanSpec change", or "archive the change".

Command Reference

zhuanspec init

Initialize ZhuanSpec in your project. Creates the directory structure, template files, and configures AI tool integrations.

zhuanspec init [path] [options]

Arguments:

| Argument | Description | Default | |----------|-------------|---------| | [path] | Target project directory | . (current directory) |

Options:

| Option | Description | Example | |--------|-------------|---------| | --tools <tools> | Configure AI tools non-interactively. Accepts all, none, or a comma-separated list of tool IDs | --tools claude,cursor | | --business-direction <direction> | Specify a business direction to use the corresponding microservice architecture document as project.md | --business-direction oms |

Usage examples:

# Interactive mode (default) — prompts you to select AI tools
zhuanspec init

# Initialize a specific directory
zhuanspec init ./my-project

# Non-interactive mode — configure specific tools without prompts
zhuanspec init --tools claude,cursor

# Configure all available tools
zhuanspec init --tools all

# Initialize with a business direction — uses the architecture doc as project.md
zhuanspec init --business-direction oms

# Combine options
zhuanspec init --tools claude --business-direction oms

What --business-direction does:

When specified, ZhuanSpec looks for a microservice architecture document named {direction}_project_architect.md (e.g., oms_project_architect.md) and uses it to directly replace the generated zhuanspec/project.md. This is useful for teams that have pre-built service architecture documents and want the AI assistant to understand the full microservice topology from the start.

Without this option, project.md is generated from the default template with placeholder sections for you to fill in.

What happens during initialization:

  1. Creates the zhuanspec/ directory structure (specs/, changes/, changes/archive/)
  2. Generates template files (AGENTS.md, project.md)
  3. Configures AI tool integrations and slash commands for the tools you selected
  4. Writes a managed AGENTS.md stub at the project root

Extend mode: If zhuanspec/ already exists, init runs in extend mode — it preserves existing files and only adds missing ones or refreshes tool configurations.

Other Commands

zhuanspec list               # View active change folders
zhuanspec view               # Interactive dashboard of specs and changes
zhuanspec show <change>      # Display change details (proposal, tasks, spec updates)
zhuanspec validate <change>  # Check spec formatting and structure
zhuanspec archive <change> [--yes|-y]   # Move a completed change into archive/ (non-interactive with --yes)

Example: How AI Creates ZhuanSpec Files

When you ask your AI assistant to "add two-factor authentication", it creates:

zhuanspec/
├── specs/
│   └── auth/
│       └── spec.md           # Current auth spec (if exists)
└── changes/
    └── add-2fa/              # AI creates this entire structure
        ├── proposal.md       # Why and what changes
        ├── tasks.md          # Implementation checklist
        ├── design.md         # Technical decisions (optional)
        └── specs/
            └── auth/
                └── spec.md   # Delta showing additions

AI-Generated Spec (created in zhuanspec/specs/auth/spec.md):

# Auth Specification

## Purpose
Authentication and session management.

## Requirements
### Requirement: User Authentication
The system SHALL issue a JWT on successful login.

#### Scenario: Valid credentials
- WHEN a user submits valid credentials
- THEN a JWT is returned

AI-Generated Change Delta (created in zhuanspec/changes/add-2fa/specs/auth/spec.md):

# Delta for Auth

## ADDED Requirements
### Requirement: Two-Factor Authentication
The system MUST require a second factor during login.

#### Scenario: OTP required
- WHEN a user submits valid credentials
- THEN an OTP challenge is required

AI-Generated Tasks (created in zhuanspec/changes/add-2fa/tasks.md):

## 1. Database Setup
- [ ] 1.1 Add OTP secret column to users table
- [ ] 1.2 Create OTP verification logs table

## 2. Backend Implementation  
- [ ] 2.1 Add OTP generation endpoint
- [ ] 2.2 Modify login flow to require OTP
- [ ] 2.3 Add OTP verification endpoint

## 3. Frontend Updates
- [ ] 3.1 Create OTP input component
- [ ] 3.2 Update login flow UI

Important: You don't create these files manually. Your AI assistant generates them based on your requirements and the existing codebase.

Understanding ZhuanSpec Files

Delta Format

Deltas are "patches" that show how specs change:

  • ## ADDED Requirements - New capabilities
  • ## MODIFIED Requirements - Changed behavior (include complete updated text)
  • ## REMOVED Requirements - Deprecated features

Format requirements:

  • Use ### Requirement: <name> for headers
  • Every requirement needs at least one #### Scenario: block
  • Use SHALL/MUST in requirement text

How ZhuanSpec Compares

vs. spec-kit

ZhuanSpec’s two-folder model (zhuanspec/specs/ for the current truth, zhuanspec/changes/ for proposed updates) keeps state and diffs separate. This scales when you modify existing features or touch multiple specs. spec-kit is strong for greenfield/0→1 but provides less structure for cross-spec updates and evolving features.

vs. Kiro.dev

ZhuanSpec groups every change for a feature in one folder (zhuanspec/changes/feature-name/), making it easy to track related specs, tasks, and designs together. Kiro spreads updates across multiple spec folders, which can make feature tracking harder.

vs. No Specs

Without specs, AI coding assistants generate code from vague prompts, often missing requirements or adding unwanted features. ZhuanSpec brings predictability by agreeing on the desired behavior before any code is written.

Team Adoption

  1. Initialize ZhuanSpec – Run zhuanspec init in your repo.
  2. Start with new features – Ask your AI to capture upcoming work as change proposals.
  3. Grow incrementally – Each change archives into living specs that document your system.
  4. Stay flexible – Different teammates can use Claude Code, CodeBuddy, Cursor, or any AGENTS.md-compatible tool while sharing the same specs.

Run zhuanspec update whenever someone switches tools so your agents pick up the latest instructions and slash-command bindings.

Installing ZhuanSpec

From npm (recommended)

npm install -g @fission-ai/zhuanspec@latest

Local installation

If you need to install from a local tarball or git repository, see INSTALLATION.md for detailed instructions.

For pre-built packages, use the .tgz file from the distributions/ folder:

npm install -g ./distributions/fission-ai-zhuanspec-1.0.0.tgz

Updating ZhuanSpec

  1. Upgrade the package
    npm install -g @fission-ai/zhuanspec@latest
  2. Refresh agent instructions
    • Run zhuanspec update inside each project to regenerate AI guidance and ensure the latest slash commands are active.

Contributing

  • Install dependencies: pnpm install
  • Build: pnpm run build
  • Test: pnpm test
  • Develop CLI locally: pnpm run dev or pnpm run dev:cli
  • Conventional commits (one-line): type(scope): subject

License

MIT