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

prompt-shell-cli

v1.0.0

Published

Terminal UI for working with prompt-shell prompts.

Readme

prompt-shell-cli

A terminal interface for working with prompt-shell context stacks.


What is it?

prompt-shell-cli is a local-first, keyboard-driven terminal UI for managing the modular prompt files defined by prompt-shell.

It allows you to:

  • Browse, preview, and edit context files
  • Add or delete files with one keystroke
  • Reorder prompt sections visually
  • Build the final prompt with live token count

No mouse, no boilerplate — just pure CLI clarity.


Why use it?

If you’re using local LLMs, your prompts need to be:

  • Modular
  • Inspectable
  • Reusable
  • Quick to evolve

prompt-shell-cli gives you a structured interface to manipulate that context stack without switching between editors, folders, and JSON configs.


Features

  • 🧾 View the current context stack (shell.json)
  • ✍️ Edit any section with your preferred $EDITOR
  • ➕ Create new .md context files and auto-insert into the build
  • ❌ Delete sections with confirmation
  • 🔀 Reorder prompt parts interactively
  • ⚙️ Build the final prompt (uses prompt-shell under the hood)
  • 🔢 Displays live token count after build

How it works

On first run, it creates a local copy of your context and config from the prompt-shell package:

prompt-shell-cli/
├── user-context/
│   ├── context/
│   │   ├── rules.md
│   │   ├── identity.md
│   │   └── ...
│   └── config/
│       └── shell.json

You interact with this safe copy — edits, deletions, reorderings, and builds all apply to your local state.


Getting started

  1. Install dependencies:
npm install
  1. Start the interface:
npm start

You'll see a list of context files defined in shell.json, with one selected and previewed.


Keyboard shortcuts

| Key | Action | |------------|---------------------------------------------| | ↑ / ↓ | Navigate files | | e | Edit selected file in $EDITOR | | b | Build final prompt (with token count) | | n | Create new file and append to config | | x | Delete selected file (with confirmation) | | r | Reorder context stack (enter reorder mode) | | Enter | Save reordered order | | Esc | Cancel reorder | | q | Quit |


Build process

Press b to run the bundled builder from prompt-shell.

  • The final prompt is saved to:

    user-context/output/final_prompt.txt
  • Token count is printed on success

You can pipe this into any local LLM interface:

ollama run mistral < user-context/output/final_prompt.txt

Editor support

prompt-shell-cli respects the $EDITOR environment variable.
If none is set, it defaults to nano.

Examples:

export EDITOR=vim
export EDITOR="code --wait"

Who is it for?

  • Power users of local LLMs
  • Developers building agent frameworks
  • Anyone tired of hand-editing Markdown + JSON
  • Those who want to compose prompts like code

Author

Michal Roth

💛 If this tool helps you think or build better:
Buy me a coffee →


License

MIT — terminal-first, hackable, and yours.