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

@howaboua/pi-memories

v0.1.2

Published

A tiny Pi extension that writes memory candidates when a session ends.

Readme

pi-memories

A tiny Pi extension that writes memory candidates when a session ends.

pi-memories expects you to use Pi's global AGENTS.md as your long-term memory file. If you do not have one yet, see Recommended AGENTS.md setup.

It does not try to maintain a database, vector store, or hidden profile. It runs one short, no-tools/no-skills Pi session after shutdown, asks for a few durable things worth remembering, and appends the result to a plain markdown inbox.

You review the inbox later and decide what, if anything, belongs in AGENTS.md.

How it works

On session_shutdown, pi-memories collects the best context it can find:

  1. OpenAI native compaction blob, if the session has one.
  2. Normal Pi compaction summary, if the session has one.
  3. Recent conversation tail, if there is no compaction.

Then it starts an ephemeral Pi run with:

--no-session --no-skills --no-tools

That run still gets your normal Pi context files, so global/project AGENTS.md can help it decide what is actually new. The output is appended to:

~/.pi/agent/memory-inbox.md

Short no-compaction sessions are skipped by default, so opening Pi for one quick question should not create memory noise.

Install

Clone or install this package, then add it to your Pi packages list.

For a local checkout:

{
  "packages": [
    "/path/to/pi-memories"
  ]
}

Pi will load the extension from the package manifest.

Config

The extension creates this file on first load:

~/.pi/agent/pi-memories.json

Edit it if you want to change the defaults.

Example:

{
  "enabled": true,
  "model": "openai-codex/gpt-5.4-mini",
  "thinking": "low",
  "inboxPath": "/home/you/.pi/agent/memory-inbox.md",
  "timeoutMs": 120000,
  "includeProjectContext": true,
  "minUserMessagesWithoutBlob": 3
}

Options

| Option | Default | What it does | |---|---:|---| | enabled | true | Turn the extension on/off. | | model | gpt-5.4 | Model used for the shutdown memory pass. | | thinking | low | Thinking level for the memory pass. Use off, minimal, low, medium, high, or xhigh. | | inboxPath | ~/.pi/agent/memory-inbox.md | Where memory candidates are appended. | | timeoutMs | 120000 | Max time to wait for the ephemeral Pi run. | | includeProjectContext | true | Keep project AGENTS.md / CLAUDE.md context. Set false to use only the explicit memory prompt. | | minUserMessagesWithoutBlob | 3 | If there is no compaction, skip sessions with fewer user messages than this. |

Recommended AGENTS.md setup

pi-memories is designed around Pi's global AGENTS.md. It can still append candidates to the inbox without one, but /memory-review is meant to promote useful memories into this file.

Pi loads global instructions from:

~/.pi/agent/AGENTS.md

The shutdown worker receives those instructions too. That means it can use your existing preferences when deciding what belongs in the inbox, and /memory-review can use them when deciding what to promote.

A starter section is included here:

templates/AGENTS.memory-template.md

Copy the parts you like into your global AGENTS.md. Keep it short. The inbox is allowed to be messy; AGENTS.md should not be.

Review memories

Run:

/memory-review

This fills the editor with a prompt to review memory-inbox.md and promote only the useful bits into global or project AGENTS.md.

The review step is intentionally manual. The inbox can have duplicates. That is fine. The point is to avoid silently poisoning your long-term instructions.

Notes

  • The shutdown worker runs without tools and without skills.
  • It uses existing compaction context when available, but does not store compaction blobs.
  • If pi-codex-conversion native compaction is present, the opaque OpenAI blob is used only for that one ephemeral run.
  • If there is no compaction, the extension falls back to conversation text and applies the short-session gate.