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

engrammemory-ai

v0.2.0

Published

Memory infrastructure for AI agents. Your Qdrant, your hardware, our intelligence.

Downloads

989

Readme

Memory infrastructure for AI agents. Your Qdrant, your hardware, our intelligence.

PyPI · Dashboard · API Docs · Community Edition

npm pypi license

npm install engrammemory-ai

Quick Start

import { Engram } from 'engrammemory-ai';

const engram = new Engram({
  apiKey: 'eng_live_xxx',
  qdrantUrl: 'http://localhost:6333'
});

// Store — embedded & deduplicated by Engram, stored in YOUR Qdrant
await engram.store('User prefers TypeScript and dark mode', {
  category: 'preference'
});

// Search — three-tier recall (hot → hash → vector)
const results = await engram.search('What does the user prefer?');
for (const r of results) {
  console.log(`[${r.tier}] ${r.content} (${r.score.toFixed(2)})`);
}

// Forget
await engram.forget('mem_abc123');

CommonJS:

const { Engram } = require('engrammemory-ai');

Why Engram?

| | Engram | Mem0 | Supermemory | Zep | |---|---|---|---|---| | Data ownership | Your Qdrant, your hardware | Their cloud | Their cloud | Their cloud | | Three-tier recall | Hot → Hash → Vector | Single-tier | Single-tier | Two-tier | | Stateless intelligence | Embeds + classifies, never stores | Stores everything | Stores everything | Stores everything | | Edge/fleet support | Per-device agents, zone isolation | No | No | Limited | | Local-first + overflow | Store locally, overflow to cloud | Cloud only | Cloud only | Cloud only | | Open community edition | OpenClaw skill, full recall engine | No | Partial | No |

Three-Tier Recall

Every search flows through three tiers automatically:

const results = await engram.search('database config');
for (const r of results) {
  console.log(`[${r.tier}] ${r.content} (${r.score.toFixed(2)})`);
  // [hot]    PostgreSQL 15 with read replicas (0.94)   — sub-ms, cached
  // [hash]   Migrated from MongoDB last quarter (0.81)  — O(1) LSH lookup
  // [vector] Old DB credentials in vault (0.67)         — full ANN fallback
}

Auto-Recall for Agent Prompts

// Inject relevant memories into your agent's system prompt
const memories = await engram.recall('User is asking about their database setup');
const systemPrompt = `You know: ${memories.map(m => m.content).join(', ')}`;

Multi-Agent / Fleet

const engram = new Engram({
  apiKey: 'eng_live_xxx',
  project: 'icu-floor-3'
});

// Store with agent tracking
await engram.store('Patient allergic to penicillin', {
  category: 'fact',
  agent: 'tablet-icu-3a'
});

// Search scoped to project
const results = await engram.search('allergies', {
  agent: 'tablet-icu-3a'
});

API Reference

Constructor

new Engram({
  apiKey: string;                          // Your Engram API key
  qdrantUrl?: string;                      // Default: "http://localhost:6333"
  baseUrl?: string;                        // Default: "https://api.engrammemory.ai"
  collection?: string;                     // Default: "agent-memory"
  project?: string;                        // Memory isolation namespace
  maxRetries?: number;                     // Default: 3
  timeout?: number;                        // Default: 30000 (ms)
})

Methods

| Method | Returns | Description | |---|---|---| | store(content, options?) | Promise<StoreResult> | Store a memory (embedded + deduplicated + compressed) | | search(query, options?) | Promise<SearchResult[]> | Three-tier recall: hot → hash → vector | | recall(context, options?) | Promise<SearchResult[]> | Auto-inject relevant memories for agent prompts | | get(memoryId) | Promise<Memory> | Get a specific memory by ID | | forget(memoryId) | Promise<boolean> | Remove from all three tiers | | forgetByQuery(query) | Promise<number> | Forget memories matching a search, returns count | | list(options?) | Promise<Memory[]> | List memories with filtering | | health() | Promise<HealthStatus> | Check Engram + Qdrant connectivity |

Types

import type { Memory, SearchResult, StoreResult, HealthStatus } from 'engrammemory-ai';

| Type | Fields | |---|---| | Memory | id, content, category, metadata, createdAt, accessCount | | SearchResult | id, content, score, tier ("hot" | "hash" | "vector"), category, metadata | | StoreResult | id, stored, deduplicated | | HealthStatus | status, qdrantConnected, version |

Exceptions

import { EngramError, AuthenticationError, RateLimitError, NotFoundError, ValidationError } from 'engrammemory-ai';

| Exception | HTTP Code | When | |---|---|---| | AuthenticationError | 401 | Invalid or missing API key | | RateLimitError | 429 | Too many requests (auto-retries with Retry-After) | | NotFoundError | 404 | Memory ID doesn't exist | | ValidationError | 400/422 | Invalid request body | | EngramError | Other | Base class for all errors |

Community Edition

Don't need cloud? The community edition runs the full three-tier recall engine locally as an OpenClaw skill with no API dependency.

Links