Skip to main content

AI memory layer with autonomous agents. Open-source Mem0 alternative with memory agents, webhooks, and cognitive insights.

Project description

๐Ÿง  Mengram โ€” AI Memory Layer with Autonomous Agents

Open-source memory layer for AI apps. Not just storage โ€” Mengram has autonomous agents that clean, analyze, and find hidden patterns in your knowledge.

PyPI License: MIT Python 3.10+

Website ยท Dashboard ยท API Docs ยท PyPI


Why Mengram?

Mengram Mem0
Memory Storage โœ… โœ…
Semantic Search โœ… โœ…
Knowledge Graph โœ… โœ…
Autonomous Agents โœ… Curator, Connector, Digest โŒ
Team Shared Memory โœ… Invite codes, privacy controls โŒ
AI Reflections โœ… Patterns, insights, behavioral analysis โŒ
Webhooks โœ… โœ…
MCP Server โœ… Claude Desktop, Cursor, Windsurf โŒ
Self-hostable โœ… โœ…
Price Free $19-249/mo

Quick Start (60 seconds)

1. Get API key

Sign up at mengram.io โ€” free, no credit card.

2. Install

pip install mengram-ai

3. Connect to Claude Desktop

Add to claude_desktop_config.json:

{
  "mcpServers": {
    "mengram": {
      "command": "mengram",
      "args": ["server", "--cloud"],
      "env": {
        "MENGRAM_API_KEY": "your-key-here"
      }
    }
  }
}

Done. Claude now has persistent memory.

Python SDK

from mengram.cloud.client import CloudMemory

m = CloudMemory(api_key="om-...")

# Add memories from conversation
m.add([
    {"role": "user", "content": "I deployed Mengram on Railway with PostgreSQL 15"},
    {"role": "assistant", "content": "Great, noted the deployment setup."}
], user_id="ali")

# Semantic search
results = m.search("deployment setup", user_id="ali")

# Run memory agents
m.run_agents(agent="all", auto_fix=True)

# Get AI insights
insights = m.insights()

# Team memory
team = m.create_team("Backend Team")
m.share_memory("Redis", team_id=team["id"])

# Webhooks
m.create_webhook(url="https://hooks.slack.com/...", name="Slack")

Memory Agents

Three autonomous agents that analyze your memory:

๐Ÿงน Curator โ€” Finds contradictions, stale facts, duplicates. Auto-cleans with auto_fix=True. Reports memory health score.

๐Ÿ”— Connector โ€” Discovers hidden connections, behavioral patterns, skill clusters. Gives strategic suggestions with priorities.

๐Ÿ“ฐ Digest โ€” Weekly summary with headlines, trends, focus areas, and recommendations.

curl -X POST "https://mengram.io/v1/agents/run?agent=all&auto_fix=true" \
  -H "Authorization: Bearer YOUR_KEY"

Team Shared Memory

Share knowledge across your team. Create โ†’ invite โ†’ share:

# Create team โ†’ get invite code
POST /v1/teams {"name": "Backend Team"}

# Colleague joins with code
POST /v1/teams/join {"invite_code": "xK9m2Qw5ab"}

# Share an entity
POST /v1/teams/3/share {"entity": "Redis"}

Search automatically includes shared team knowledge.

Webhooks

m.create_webhook(
    url="https://webhook.site/your-id",
    event_types=["memory_add", "memory_update", "memory_delete"],
    secret="optional-hmac-secret"
)

API Endpoints

Endpoint Description
POST /v1/add Add memories from conversation
POST /v1/search Semantic search
POST /v1/agents/run Run memory agents
GET /v1/insights AI-generated insights
POST /v1/teams Create team
POST /v1/teams/join Join team
POST /v1/webhooks Create webhook
GET /v1/graph Knowledge graph
GET /v1/timeline Temporal search
GET /v1/stats Usage statistics

Full docs: https://mengram.io/docs

Architecture

โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚          Your AI Clients             โ”‚
โ”‚  Claude Desktop ยท Cursor ยท Windsurf  โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
               โ”‚ MCP / REST API
โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ–ผโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚        Mengram Cloud API             โ”‚
โ”‚  Extraction ยท Re-ranking ยท Search    โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚       Memory Agents Layer            โ”‚
โ”‚  ๐Ÿงน Curator ยท ๐Ÿ”— Connector ยท ๐Ÿ“ฐ Digestโ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚       Storage Layer                  โ”‚
โ”‚  PostgreSQL ยท pgvector ยท Teams       โ”‚
โ”‚  Webhooks ยท Reflections ยท Graph      โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜

License

MIT


Built by Ali Baizhanov

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mengram_ai-2.2.0.tar.gz (93.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

mengram_ai-2.2.0-py3-none-any.whl (102.9 kB view details)

Uploaded Python 3

File details

Details for the file mengram_ai-2.2.0.tar.gz.

File metadata

  • Download URL: mengram_ai-2.2.0.tar.gz
  • Upload date:
  • Size: 93.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.7

File hashes

Hashes for mengram_ai-2.2.0.tar.gz
Algorithm Hash digest
SHA256 307c55309307585f92dabb67183c82c8944028f337177f6d9cda32186c7bde86
MD5 6b71e4fec6c601070427a720113b0c27
BLAKE2b-256 2f26d680f565d311381d43902e446f050d9a02dc0496c5aec1f260e730bb0599

See more details on using hashes here.

File details

Details for the file mengram_ai-2.2.0-py3-none-any.whl.

File metadata

  • Download URL: mengram_ai-2.2.0-py3-none-any.whl
  • Upload date:
  • Size: 102.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.7

File hashes

Hashes for mengram_ai-2.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 5c5b17e4b8af70e8d53237f1c0d55d60da6b45b7fc4ba9b309e99e18c74f68cc
MD5 987dc43d834fa5ae62e5b902a9fa7525
BLAKE2b-256 38b74804f57d74ca8510cc191ff125fd9aa1c5ef1dde57d98003276a0c7edf91

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page