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

@al-bashkir/opencode-caveman

v0.1.0

Published

Caveman mode plugin and commands for OpenCode

Readme

opencode-caveman

caveman rewritten for opencode as an installable plugin that self-registers slash commands.

Original repo: https://github.com/JuliusBrussee/caveman

What it includes

  • src/index.ts: persistent caveman mode plugin for opencode
  • Dynamic /caveman, /caveman-commit, /caveman-review, and /caveman:compress command registration via plugin config() hook

Features

  • Persistent per-session response mode
  • Natural language triggers like talk like caveman and normal mode
  • Intensity levels: lite, full, ultra, wenyan-lite, wenyan, wenyan-ultra
  • Compaction context hook so active mode survives session compaction better
  • Dedicated commit and review slash commands for opencode
  • Memory-file compression command with upstream-style backup, validation, and repair flow
  • No separate markdown command files required

Develop

npm install
npm run typecheck
npm run build

Install into opencode

Create the global plugin directory if it does not exist:

mkdir -p ~/.config/opencode/plugins

Symlink this repo into your opencode config:

ln -sf "/Users/bashkir/Projects/caveman-opencode/src/index.ts" ~/.config/opencode/plugins/caveman.ts

Restart opencode after linking.

The plugin injects its own slash commands at startup, similar to DCP.

Publish to npm

Log in to npm and publish the package:

npm login
npm publish

prepublishOnly runs npm run typecheck && npm run build automatically before publish.

Install from npm

Once published, add package name to ~/.config/opencode/opencode.json:

{
  "$schema": "https://opencode.ai/config.json",
  "plugin": ["@al-bashkir/opencode-caveman"]
}

Restart opencode. The plugin registers /caveman, /caveman-commit, /caveman-review, and /caveman:compress automatically.

Usage

  • /caveman
  • /caveman ultra
  • /caveman wenyan
  • /caveman normal
  • /caveman-commit
  • /caveman-review
  • /caveman:compress CLAUDE.md
  • /caveman-compress CLAUDE.md

Natural language also works:

  • talk like caveman
  • caveman mode
  • stop caveman
  • normal mode

Caveman Compress

Use /caveman:compress <filepath> to shrink natural-language memory files such as CLAUDE.md, preferences docs, or todo notes.

Examples:

  • /caveman:compress CLAUDE.md
  • /caveman:compress docs/preferences.md
  • /caveman-compress todos.md

Behavior:

  • Accepts .md, .txt, .rst, and extensionless natural-language files
  • Rejects code/config files such as .ts, .js, .json, .yaml, .toml, .sh
  • Rejects backup files like CLAUDE.original.md
  • Creates backup on first run: CLAUDE.md -> CLAUDE.original.md
  • Aborts if backup already exists, matching the current upstream implementation
  • Preserves code blocks, inline code, URLs, file paths, commands, headings, numbers, and technical terms
  • Runs local validation after compression
  • If validation fails, asks model for targeted fixes up to two times
  • Restores original file and removes backup if validation still fails

Implementation note

This plugin now follows the DCP pattern:

  • injects commands into opencode config via config()
  • intercepts them in command.execute.before
  • rewrites /caveman-commit and /caveman-review command input into prompt text for the model
  • handles /caveman:compress directly in plugin code using a temporary session, local validation, targeted repair retries, and restore-on-failure logic