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

@staticpayload/zai-code

v2.0.0

Published

Z.ai-native AI code editor - CLI-first, interactive editor shell with keyboard-driven settings, plan-diff-apply workflow, and safety-first design

Downloads

4,197

Readme

Z.ai Code

 ███████╗ █████╗ ██╗     ██████╗ ██████╗ ██████╗ ███████╗    /\_/\
 ╚══███╔╝██╔══██╗██║    ██╔════╝██╔═══██╗██╔══██╗██╔════╝   ( o.o )
   ███╔╝ ███████║██║    ██║     ██║   ██║██║  ██║█████╗      > ^ <
  ███╔╝  ██╔══██║██║    ██║     ██║   ██║██║  ██║██╔══╝  
 ███████╗██║  ██║██║    ╚██████╗╚██████╔╝██████╔╝███████╗
 ╚══════╝╚═╝  ╚═╝╚═╝     ╚═════╝ ╚═════╝ ╚═════╝ ╚══════╝

A Z.ai-native AI code editor -- CLI-first, interactive TUI with cosmic orange theme.

DISCLAIMER: This project is NOT affiliated with, endorsed by, or sponsored by Z.ai or Anthropic.


What's New in v2.0.0

  • Cosmic Orange Theme - Fresh new color scheme
  • Animated Mascot - Cute cat companion in the header
  • Smart Task Routing - Auto-detects task complexity
  • Improved Output - Markdown rendering, structured formatting
  • Better Settings - Keyboard-driven settings panel

Features

  • Interactive TUI with command palette and keyboard shortcuts
  • Multiple modes: edit, ask, auto, explain, review, debug
  • Safe workflow: Plan > Generate > Diff > Apply
  • Smart task analysis - auto-detects complexity and routes accordingly
  • Z.ai GLM models (GLM-4.7 default)
  • Git-aware with branch info and dirty state warnings
  • Undo/rollback support for all file operations
  • Cross-platform: macOS, Linux, Windows

Installation

npm install -g @staticpayload/zai-code

Authentication

zcode auth

Or set via environment variable:

export Z_KEY="your-api-key"

Quick Start

zcode

Type a task naturally:

add error handling to auth.ts

Or use quick commands:

/do add input validation       # plan + generate
/run fix the typo in README    # plan + generate + apply (auto)
/ask what does this function do?

Commands

Quick Actions

| Command | Description | Shortcut | |---------|-------------|----------| | /do <task> | Plan + generate in one step | ^D | | /run <task> | Full auto: plan > generate > apply | ^R | | /ask <question> | Quick question | ^A | | /fix <issue> | Debug and fix | ^F |

Workflow

| Command | Description | Shortcut | |---------|-------------|----------| | /plan | Generate execution plan | ^P | | /generate | Create file changes | ^G | | /diff | Review pending changes | | | /apply | Apply changes | | | /undo | Rollback | ^Z |

Files

| Command | Description | |---------|-------------| | /open <path> | Add file to context | | /close <path> | Remove from context | | /files | List open files | | /search <q> | Search workspace | | /read <path> | View file | | /tree | Directory tree |

System

| Command | Description | |---------|-------------| | /settings | Settings panel (F2) | | /mode <name> | Switch mode | | /model <name> | Select model | | /git | Git operations | | /commit | AI commit message | | /help | Show commands |


Modes

| Mode | Description | |------|-------------| | auto | YOLO - execute directly | | edit | Plan/generate/apply workflow | | ask | Read-only Q&A | | debug | Fix issues | | review | Code review | | explain | Explain code |

Switch: /mode auto or Shift+Tab


Workflow

Type task  >  /plan  >  /generate  >  /diff  >  /apply

Or quick:

/do <task>   # plan + generate
/run <task>  # full auto

Configuration

~/.zai/
├── auth.json       # API key
├── settings.json   # Preferences
└── config.json     # API config

.zai/               # Project-level
├── workspace.json  # Session
└── context.md      # AI rules

Requirements

  • Node.js 18+
  • Z.ai API key

License

GPL-3.0


Links

  • npm: https://www.npmjs.com/package/@staticpayload/zai-code
  • GitHub: https://github.com/staticpayload/zai-code

Independent open-source project. Not affiliated with Z.ai or Anthropic.