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

@haitai-social/pit

v1.0.10

Published

A CLI tool for managing conversation history and chat records

Readme

Pit - AI Conversation History Management Tool

License: MIT Node Version NPM Version

💡pit stand for prompt git.

🕳️ A command-line tool for managing conversation history and chat logs.

🚀 MCP Server Support

NEW! Pit now supports running as an MCP (Model Context Protocol) Server, allowing seamless integration with Claude Desktop and other AI assistants for automatic conversation recording.

Quick MCP Setup

  1. Install Pit globally: npm install -g @haitai-social/pit
  2. Add to Claude Desktop config:
    {
      "mcpServers": {
        "pit": {
          "command": "pit",
          "args": ["mcp"]
        }
      }
    }
  3. Restart Claude Desktop

See MCP_INSTALL.md for detailed setup instructions.

Installation

npm install -g @haitai-social/pit

Usage

CLI Usage

Add Chat Record

Add a single chat record to conversation history:

pit add user "Hello, how are you?"
pit add assistant "I'm doing well, thank you!"
pit add --conversation my-chat tool "Function executed successfully"

View Help

pit help

MCP Server Usage

When running as an MCP server, Pit provides the pit_record_chat_history tool that can be called by AI assistants to automatically record conversations.

See MCP_INSTALL.md for MCP server setup and usage details.

JSON File Format

The input JSON file should have the following structure:

{
  "chat_list": [
    {
      "role": "user",
      "content": "Hello, how are you?"
    },
    {
      "role": "assistant", 
      "content": "I'm doing well, thank you!"
    },
    {
      "role": "tool",
      "content": "Function executed successfully"
    }
  ]
}

Supported Role Types

  • user: User message
  • assistant: Assistant reply
  • tool: Tool execution result

Storage Structure

Data is stored in the .pit/ folder under the user's home directory:

~/.pit/
├── meta.json              # Metadata file
├── conversation1.json     # Conversation file 1
├── conversation2.json     # Conversation file 2
└── ...

meta.json Structure

{
  "conversation_queue": ["conversation1.json", "conversation2.json"]
}

conversation.json Structure

{
  "version": "v0",
  "content": {
    "chat_list": [
      {
        "role": "user",
        "content": "Message content"
      }
    ]
  }
}

Contributing

Issues and Pull Requests are welcome at the GitHub repository.