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

@bugabinga/pi-ext-angel

v0.1.0

Published

Structured advisor and command guardrail for Pi.

Readme

angel

Structured advisor + conditional smarts.

Angel is available only when the active executor model matches a configured executor/advisor pair. By default it auto-injects advice on every 3rd tool error and gates dangerous shell commands once.

Config

~/.pi/agent/settings.json:

{
  "angel": {
    "pairs": [
      {
        "executor": "zai/glm-5.1",
        "advisor": "openai-codex/gpt-5.5"
      },
      {
        "executor": "openai-codex/gpt-5.5",
        "advisor": "zai/glm-5.1"
      }
    ],
    "maxCallsPerTask": 4,
    "enabled": true,
    "autoOnErrors": 3,
    "policyGate": "block"
  }
}

Pair fields:

  • executor: active model required for Angel availability. Matches provider/model or bare model id.
  • advisor: model Angel calls for advice. Prefer provider/model.

If current model is not listed as an executor, the angel tool is removed from active tools. /angel also refuses with an unavailable-model error.

Behavior

  • Builds fresh AngelContextPacket from current session: user request, system prompt, context usage, recent conversation (last 200 messages), touched files (up to 50, 30k chars each), recent tool errors, missing/truncated-source labels.
  • Calls configured advisor model for active executor.
  • Requires structured JSON-backed AngelAdvice.
  • Persists advice via angel-advice entries.
  • Injects advice into the agent loop on every autoOnErrors-th tool error.
  • Gates dangerous bash once per exact command; retrying the same command proceeds.
  • Keeps semantic guidance in advisoryOnly.

Policy Gates

No popups. When policyGate is block (default):

  1. Executor attempts dangerous bash (rm -rf, sudo, git push, publish, recursive chmod/chown, dd, mkfs, curl|sh, fork bomb)
  2. Angel blocks that exact command once
  3. Angel consults the advisor and returns advice in the block reason
  4. Executor may retry the same command if still correct

This adds conditional smarts without turning Angel into a permanent permission wall.

Tool

angel({
  question: "What should I validate before editing auth?",
  context: "Extra context not already visible"
})

Commands

  • /angel <question>: manual advisor consult. Opens full advice in editor.
  • /angel-policy: show latest enforceable policy in editor.

Settings

| Setting | Type | Default | Notes | |---|---|---:|---| | pairs | { executor, advisor }[] | [] | Required for availability | | maxCallsPerTask | number | 4 | Session call budget | | enabled | boolean | true | Disables tool/gates if false | | autoOnErrors | number | 3 | Auto-consult every Nth failed tool result | | policyGate | off\|block | block | Gate dangerous bash commands once |

Difference from devil

  • devil: adversarial stress-test of an idea. User-initiated.
  • angel: execution advisor tied to configured executor/advisor pairs, fresh max-context packet, auto-injected advice, dangerous-command gate. Suggests devil only when confidence is low and a concrete decision remains.

Demo

Advisor suite