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

gemdex-mcp

v1.0.54

Published

MCP memory layer for AI coding agents — save/recall/update memories via on-device MLX embeddings + embedded LanceDB

Downloads

1,484

Readme

gemdex-mcp

Local memory for AI coding agents: on-device EmbeddingGemma 2 embeddings via MLX, embedded LanceDB, seven stdio MCP tools, and a localhost desktop sidecar. Part of Gemdex.

Install

Requires Node.js ≥24, native arm64 macOS 14+ (Apple Silicon, not Rosetta).

npx gemdex-mcp install
claude mcp add gemdex -- npx -y gemdex-mcp@latest

Installation explicitly downloads managed Python/MLX and pinned mlx-community/embeddinggemma-2-8bit weights, about 1.45 GB to download and 1.9 GB on disk. No preinstalled Python, uv, Homebrew, compiler, or model tooling is needed. Embeddings run offline after installation. There is no API key, provider switch, or remote backend setting. Before installation all seven tools return setup guidance.

Other MCP clients can use:

{
  "mcpServers": {
    "gemdex": {
      "command": "npx",
      "args": ["-y", "gemdex-mcp@latest"]
    }
  }
}

The local pool lives at ~/.gemdex/lance, with attachment bytes at ~/.gemdex/blobs. For a shared self-hosted pool, connect your agent directly to the Streamable HTTP MCP endpoint. The npx package and desktop sidecar manage only the local pool.

Upgrade from earlier releases

From v1.0.53: update clients sharing this library, then run npx gemdex-mcp@latest status. The full runtime from v1.0.52 is reused if present; run npx gemdex-mcp@latest install only if missing. If the status reports pending memories, npx gemdex-mcp@latest migrate restores missing media search entries from their saved bytes. The text-only release did not delete the files. Existing text vectors, new memories and edits are retained. Do not delete the library or replace it with an old export. See the backup and recovery guide.

Earlier releases stored BGE-M3 vectors in memories_mlx_bge_m3_8bit or Gemini vectors in memories. After upgrading, run npx gemdex-mcp install (the EmbeddingGemma 2 model is a new download), then npx gemdex-mcp migrate to re-embed both older tables into memories_mlx_embeddinggemma2_8bit (768 dimensions). Installation alone does not migrate. Progress is reported and migration is safe to rerun.

Recall and hygiene refuse to run while legacy rows remain, avoiding incomplete results. List/get/update/delete/export remain available after installation. Migration preserves text, titles, timestamps and attachment blobs, and embeds legacy images, audio and video from their blobs. Legacy PDFs stay readable but unsearchable.

CLI

| Command | Purpose | |---------|---------| | npx gemdex-mcp install | Download and verify runtime/model | | npx gemdex-mcp migrate | Restore missing media vectors and migrate legacy indexes | | npx gemdex-mcp status | Show model, count of memories needing repair, store and inference readiness | | npx gemdex-mcp backfill-transcripts [--force] [--dry-run] | Attach transcript files referenced by existing digest footers | | npx gemdex-mcp ingest-history [--source claude\|factory\|codex\|antigravity\|PATH]... [--model haiku] [--dry-run] | Digest new local sessions |

Backfill skips missing files with a message. Ingestion defaults to detected preset folders and processes only sessions absent from its successful-ingest ledger. Changed sessions already in the ledger are skipped. --dry-run scans and estimates; it does not call the model.

Chat-history ingestion and hygiene

Install Claude Code and sign in with claude auth login. Gemdex uses that existing login for isolated claude -p --model haiku structured-JSON calls: no tools, user settings, skills, MCP servers, hooks, CLAUDE.md, or session persistence, and a temporary working directory.

Local ingestion and hygiene use concurrency four, at most three total attempts, and a five-minute timeout per inference call. Estimates use Haiku list prices ($1 input / $5 output per million tokens). With a Claude subscription, usage counts against the plan's limits rather than being billed per token. Readiness is ready | missing | unauthenticated | error; the sidecar also reports checking during a probe.

The digest text is embedded locally; its cleaned transcript is stored as a non-embedded attachment. See ingestion paths for the distinction between local ingestion and server-side uploads.

Tools

| Tool | Behavior | |------|----------| | save_memory | Save text and/or image, audio, video and text-file attachments; return id and title | | recall | Text query and/or example media files, fixed top-10 title index, never full bodies | | get_memory | Open a full parent by id; increment recall stats | | update_memory | Replace content or apply literal edits; preserve omitted fields | | report_outcome | Record worked, failed, or stale in the client stats ledger | | read_attachment | Read an attachment as UTF-8 text, a viewable image, or base64 | | delete_memory | Permanently delete a memory and clear its client stats |

Prefer updates for corrections and delete only when the memory should be gone. HTTP MCP is a separate six-tool surface without delete.

Attachments are a local path (preferred) or inline base64 data and mimeType. Images (.png .jpg .webp .gif), audio (.wav .mp3 .m4a .flac .aac .aiff, up to 5 minutes) and video (.mp4 .mov .m4v .webm) are embedded on-device, one row per file, in the same space as text. Text files (.txt .json .jsonl .ndjson) are stored as non-embedded blobs. Per memory: 8 images, 4 audio files, 2 videos, 4 text files, 100 MiB each. A caption is optional and adds keyword matching. PDFs are not supported. recall accepts the same image/audio/video items as attachments to search by example, with or without query. read_attachment returns PNG/JPEG/WebP/GIF images up to 5 MB as MCP image content. Omitting attachments on update preserves them (and re-embeds their media); attachments:[] clears them.

Desktop sidecar

npx gemdex-mcp serve --port 0 starts the local HTTP API, bound to 127.0.0.1. The desktop app spawns it and reads the PORT=<n> TOKEN=<hex> handshake. Model install/migration are explicit asynchronous settings actions; Claude Code readiness gates ingestion/hygiene, not ordinary memory reads. See the sidecar contract for routes and status fields.

For large backups, use authenticated GET /export.jsonl rather than the JSON {records} endpoint at /export. Each line is a portable memory with its original attachments. X-Gemdex-Memory-Count gives the expected line count. Save to a temporary file: replace your backup only if the transfer finishes and all expected lines end in a newline. While exporting, sidecar writes wait and other Gemdex processes must retry writes to the same library. Cancelling or quitting the app releases the backup lock.

Environment

| Variable | Purpose | |----------|---------| | LANCEDB_PATH | Override ~/.gemdex/lance | | GEMDEX_CLAUDE_PATH | Override Claude binary discovery for ingestion/hygiene | | HYBRID_MODE | false disables BM25; default true | | GEMDEX_SERVE_PORT | Sidecar port; default auto/0 | | GEMDEX_WEBVIEW_ORIGIN | Allowed sidecar Origin; default zero://app | | GEMDEX_STATS_PATH | Override ~/.gemdex/stats.json | | GEMDEX_TRUST_RANKING | true enables outcome-weighted title ranking | | GEMDEX_SIMILAR_ON_SAVE | false disables similarity advisories | | GEMDEX_SIMILAR_THRESHOLD | Similarity threshold in (0,1], default 0.93 |

MCP Registry

mcp-name: io.github.nikships/gemdex

License

MIT