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

@davehardy20/pi-mulch

v0.1.1

Published

Pi package that integrates Mulch priming, search, draft review, and session-aware learning workflows.

Downloads

176

Readme

@davehardy20/pi-mulch

Pi package for Mulch-aware priming, search, status, and draft review workflows.

What it adds

  • session-start Mulch detection (mulch or ml)
  • one-time repo-local prompt to run mulch init when .mulch/ is missing
  • hidden before_agent_start priming via mulch prime
  • touched-file tracking from common Pi tool activity
  • LLM-callable tools:
    • mulch_prime
    • mulch_search
    • mulch_query
    • mulch_learn
    • mulch_status
  • user commands:
    • /mulch-init
    • /mulch-prime
    • /mulch-search
    • /mulch-query
    • /mulch-learn
    • /mulch-status
    • /mulch-review
    • /mulch-apply
  • session-end draft generation gated on clean post-turn-linter status

Install

From npm:

pi install npm:@davehardy20/pi-mulch

For one run only:

pi -e npm:@davehardy20/pi-mulch

From a local checkout during development:

pi install /absolute/path/to/pi-mulch

Settings

Configure in ~/.pi/agent/settings.json:

{
  "mulch": {
    "enabled": true,
    "command": null,
    "cliCandidates": ["mulch", "ml"],
    "injectionMode": "manifest",
    "primeBudget": 4000,
    "promptOnMissingInit": true,
    "persistInitDecline": true,
    "draftMode": "session-end",
    "draftDir": ".mulch/drafts",
    "initStateFile": ".pi/mulch-integration.json",
    "maxTrackedFiles": 24,
    "llmTools": [
      "mulch_prime",
      "mulch_search",
      "mulch_query",
      "mulch_learn",
      "mulch_status"
    ]
  }
}

Use top-level mulch settings. Do not put this config under Pi's top-level extensions key, because Pi reserves extensions for extension file paths and package sources, not per-extension config.

If ~/.pi/agent/settings.json is missing, invalid, or does not contain Mulch settings, pi-mulch uses its built-in defaults. Repo-local .pi/settings.json files are ignored for Mulch configuration.

For safety:

  • command and cliCandidates are only honored from global Pi settings
  • draftDir and initStateFile are always confined to the current repo root, even if configured otherwise

Draft workflow

The extension is designed to create draft Mulch learnings at session end. You should not need to run ml learn and ml record ... just to get draft records created when draftMode is set to "session-end".

Normal flow

  1. Pi session runs with the extension enabled.
  2. The extension injects Mulch context at before_agent_start.
  3. When draftMode is "session-end", relevant files were touched, and the post-turn-linter finished cleanly, the extension can generate draft records at session end.
  4. Drafts are written to .mulch/drafts/.
  5. You review drafts with /mulch-review.
  6. You apply drafts with /mulch-apply.
  7. After applying drafts to real Mulch records, run ml sync to validate and commit .mulch/ changes.

Important distinction

  • Automatic when enabled: session-end draft generation into .mulch/drafts/
  • Manual review step: /mulch-review and /mulch-apply
  • Manual persistence/sync step: ml sync

When to use ml learn and ml record

Use ml learn and ml record ... when you want to create or curate Mulch records directly yourself, outside the extension's automatic draft workflow.

Build and test

npm run typecheck
npm run test
npm run build