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

@rohirik/pi-ltm

v2.22.2

Published

LTM (Long-Term Memory) native extension for Pi — share memories with Claude Code and OpenCode

Readme

@rohirik/pi-ltm

OpenLTM long-term memory extension for the Pi coding agent. Shares the local memory database with Claude Code and OpenCode.

Install

pi install npm:@rohirik/pi-ltm

If Pi is already running, use /reload to load the extension. Pi records the package in ~/.pi/agent/settings.json; use pi install --local npm:@rohirik/pi-ltm for a project-scoped install.

Find the extension in the Pi package catalog. The npm package declares the pi-package discovery keyword and a pi.extensions manifest pointing to its compiled entrypoint.

Requirements

Install Bun and make it available on PATH. Pi loads the extension under Node; the extension runs OpenLTM's core MCP server in a Bun child process, avoiding direct Node imports of bun:sqlite. The core package is installed as a dependency.

What it does

  • Registers the memory tools returned by OpenLTM's core MCP server, including recall, learn, forget, project context, and memory relationships.
  • On Pi's before_agent_start event, waits for the core connection and appends relevant project memories as a ## Prior Knowledge (LTM) block.
  • Uses a local SQLite database shared with the other OpenLTM adapters. If Bun or the core server cannot be found, the extension currently skips registration.

The current Pi adapter does not register a compaction hook.

Shared memory

When the Claude Code plugin is installed, Pi uses its database, so both agents share memories:

~/.claude/plugins/data/openltm-OpenLtm/openltm.db

(An older install's OpenLtm-openltm/openltm.db is used if that is the one that exists.)

Override it before starting Pi:

export LTM_DB_PATH="/custom/path/openltm.db"

A memory learned in Pi is available to another OpenLTM adapter using the same database.

Semantic recall with llama.cpp

Recall works out of the box with SQLite full-text search. For semantic recall, run a local llama.cpp embedding server; OpenLTM uses it by default when it is reachable, and no API key is needed:

llama-server -m bge-m3.gguf --embeddings --pooling mean --port 8080

Defaults are LTM_LLAMA_CPP_URL=http://127.0.0.1:8080 and LTM_EMBED_MODEL=bge-m3; export either before starting Pi to change it. If the server is not running, recall stays on full-text search and memory text is not sent anywhere. Use the same model as the other adapters that share the database, since vectors from different models are not comparable.

Recalled memories are wrapped in a <recalled-memory> block that marks them as context from earlier sessions, not instructions.

Privacy and license

Memory is stored locally. Optional embedding or janitor providers can send memory content to the provider you configure; see the repository's security notes. MIT licensed.