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

pi-claude-store

v0.1.3

Published

Pi extension that reads and writes Claude Code's auto-memory store, keyed the way Claude Code keys it (canonical git root, Claude Code's sanitizePath)

Readme

pi-claude-store

A pi extension that reads and writes Claude Code's own memory store — the same files, so a memory saved in either agent is immediately visible to the other. Not a parallel store, not a sync job.

Derived from elecnix/pi-claude-memory (MIT, Copyright (c) 2026 Nicolas Marchildon) with the path-resolution layer ported from kuitos/opencode-claude-memory (MIT, Copyright (c) 2025 kuitos). See NOTICE for the derivation record.

What it does

Mirrors Claude Code's two-tier design, so a large store stays cheap:

  • Index injected once per session. The MEMORY.md pointer lines are added to pi's system prompt at the first turn — titles and one-line hooks only, never the bodies.
  • Bodies read on demand. memory_read fetches one memory when the index suggests it is relevant.

Tools

| Tool | Purpose | |---|---| | memory_read | Read one memory by name | | memory_write | Save or update a memory, or delete it with an empty/null body | | memory_list | List every memory with its description |

Tool output is compact by default and expands with ctrl+o (app.tools.expand). memory_write shows the new body — or a diff when updating — and memory_read shows the full body.

Keying: the difference from upstream

Claude Code keys the store by the canonical git root and slugifies it with sanitizePath() (every non-alphanumeric character becomes a dash, with a djb2 hash suffix past 200 characters). pi-claude-memory 0.1.x instead slugified the raw cwd with only / and . replaced, which silently splits the store whenever:

  • the path contains _, spaces, or other non-alphanumerics,
  • pi is launched from a repository subdirectory, or
  • pi runs inside a git worktree (upstream issue #14).

This extension ports Claude Code's exact resolution (sanitizePath, findGitRoot, resolveCanonicalRoot from the kuitos port, which reproduces Claude Code's own implementations byte for byte), so pi, Claude Code, and the opencode plugin all resolve the identical store directory — worktrees included.

The memory-file parser also matches Claude Code's memoryScan.ts rules: frontmatter is only recognised when the closing --- appears within the first 30 lines, and both the current metadata.type nesting and the older top-level type: layout are read.

Scoping

Memories are per-project and do not follow you between directories — the same rule that applies in Claude Code. Outside a git repository the store is keyed by the directory itself.

Install

pi install npm:pi-claude-store

Development

npm test

Tests have zero dependencies beyond Node (v22.6+ for native TypeScript stripping). They port both upstream suites — elecnix's 37 store tests and kuitos's path-resolution fixtures — and are the tripwire for Claude Code changing the on-disk memory format.

License

MIT. Contains code derived from two MIT projects; see NOTICE.