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

@stfade/moth

v0.1.0

Published

A lightweight MCP server for project-local bug-fix analysis and verified fix memory.

Readme

Moth

Moth is a lightweight MCP server for project-local bug-fix analysis and verified fix memory.

What Moth Does

Moth receives error output through MCP, redacts likely secrets, normalizes the failure, detects the likely stack, checks project-local fix memory, and returns a structured fix brief.

Moth does not edit code, run shell commands, crawl repositories, require a backend, or maintain a global bug database.

Why Moth?

Bug-fix context is often local to a project: the command that failed, the framework in use, nearby configuration, and fixes that have already worked or failed in that repo.

Moth keeps that workflow small and explicit. It analyzes provided error context, suggests a best first fix, and records only verified fix outcomes in project-local memory.

Quick Start

Requires Node.js 18+.

Run directly:

npx -y @stfade/moth moth-mcp

Or install globally:

npm install -g @stfade/moth
moth-mcp

Generic MCP config

{
  "mcpServers": {
    "moth": {
      "command": "npx",
      "args": ["-y", "@stfade/moth", "moth-mcp"]
    }
  }
}

Usage Example

When using Moth with a supported AI agent, you can include a simple prompt like this along with your error:

"Use Moth to analyze this error before fixing it."

Supported Clients

| Client | Status | Setup | | --- | --- | --- | | Codex | Local plugin-ready | Setup | | Claude Code | Local plugin-ready | Setup | | Cursor | Plugin scaffold | Setup | | Gemini CLI | Extension scaffold | Setup | | Gemini Antigravity | MCP config-ready | Setup | | OpenCode | MCP config-ready | Setup | | Generic MCP | Config-ready | Setup |

“Local plugin-ready” means the integration wrapper is included and can be tested locally. Marketplace submission and approval are not included yet.

Tools

Moth exposes exactly two MCP tools.

analyze_error

Analyzes provided error output before a fix is attempted.

Input fields:

  • error_output
  • command?
  • cwd?
  • package_context?
  • relevant_files?
  • environment?

Output fields:

  • analysis_id
  • fingerprint
  • stack
  • likely_cause
  • best_first_fix
  • verification
  • prior_project_fixes
  • avoid
  • confidence

remember_fix_result

Records verified project-local fix memory.

Input fields:

  • analysis_id
  • fingerprint
  • stack
  • fix_attempted
  • verification_command
  • verification_result: "passed" | "failed"
  • notes?

The public worked input is rejected. worked is derived from verification_result.

Verified Memory Lifecycle

analyze_error
→ apply/attempt fix
→ run verification command
→ remember_fix_result

Call remember_fix_result only when:

  1. a fix/change was actually attempted
  2. the verification command actually ran
  3. the result is clearly passed or failed

Do not call it for suggestions, skipped changes, missing verification, ambiguous results, or guesses.

Local Memory

Verified project-local fix memory is stored at:

.moth/fix-memory.jsonl

Moth keeps a small Moth-owned analysis registry outside the project so remember_fix_result can map analysis_id back to the correct project path after an MCP server restart.

Skills

Moth includes concise skills for compatible agents:

  • moth-debug-first-fix
  • moth-source-backed-research
  • moth-verify-fix

The MCP server itself does not perform live web research. Compatible agents may use their own search tools, guided by Moth skills, when external sources are needed.

Safety

  • read-only by default
  • no source edits
  • no shell execution
  • no repo-wide scan
  • no background watcher
  • no external service required
  • redacts likely secrets before analysis, responses, and memory writes

Development

pnpm install
pnpm test
pnpm build
pnpm dev
npm pack --dry-run

License

MIT