--- title: Smriti β€” Temporal Event Memory for Business Workflows emoji: πŸ•°οΈ colorFrom: red colorTo: gray sdk: docker pinned: false ---

Live MCP Free Memory

πŸ•°οΈ Smriti β€” Temporal Event Memory

> **Give your business workflows, ops teams, and AI agents an auditable ledger of what happened, when, and with whom.** > Smriti decomposes operational events into concrete Subject-Verb-Object (SVO) tuples, stores them in a Bi-Temporal PostgreSQL architecture, and lets workflows reason precisely across time without hallucination. --- ## πŸ“– What is Smriti? **The Problem:** Traditional "agent memory" relies on fuzzy vector databases that struggle with temporal drift and ambiguous chat facts. When tracking deals, deployments, contracts, or multi-step operational workflows, you don't need a chatbot to remember a favorite colorβ€”you need an auditable, deterministic event ledger. **The Solution:** Smriti is a **temporal event memory layer**. It gives AI agents and business infrastructure a bi-temporal hippocampus that tracks state changes perfectly across systems and sessions. | Feature | Smriti (Event Memory) | Traditional RAG (Chat Memory) | |---|---|---| | **Structure** | **SVO Tuples:** Tracks concrete actions (`Agent β†’ Deployed β†’ Build42`) | **Vector Sludge:** Dumps unstructured text into a vector DB | | **Time** | **Bi-Temporal:** Tracks both *when it happened* and *when it was recorded* | **Timeless:** Cannot distinguish old facts from current state | | **Updates** | **Supersession:** Safely overrides state without deleting history | **Overwrite:** Hard deletes or creates confusing duplicates | --- ## πŸš€ Quick Start (5 Minutes) **1. Get a Free API Key** ```bash curl -X POST "https://spy9191-chronos-api-backend.hf.space/billing/keys?tier=explorer" ``` **2. Store a Memory** ```bash curl -X POST https://spy9191-chronos-api-backend.hf.space/ingest \ -H "X-API-Key: chrn_your_key" \ -d '{"source_id": "demo", "events": [{"text": "Alice joined as Lead Engineer on July 15"}]}' ``` **3. Recall It** ```bash curl -X POST https://spy9191-chronos-api-backend.hf.space/query \ -H "X-API-Key: chrn_your_key" \ -d '{"query": "Who joined the team recently?"}' ``` ### What You Get Back ```json { "results": [ { "subject": "Alice", "verb": "joined", "object": "the team as Lead Engineer", "timestamp": "2026-07-15T00:00:00Z", "confidence_score": 0.94 } ] } ``` --- ## 🐘 Bring Your Own Database (BYODB) β€” Supabase Want to keep your memory data in your own infrastructure? Smriti supports **Bring Your Own Database (BYODB)** using Supabase (PostgreSQL + pgvector). With zero code changes, you can route all extracted memories, vectors, and conversation turns directly to your own Supabase project. The data never touches Smriti's cloud storage. ### How it works Just add the `X-Supabase-Url` header to your API requests (using the Session Pooler URL): ```bash curl -X POST https://spy9191-chronos-api-backend.hf.space/ingest \ -H "X-API-Key: chrn_your_key" \ -H "X-Supabase-Url: postgresql://postgres.xxxx:pw@aws-0-REGION.pooler.supabase.com:5432/postgres" \ -d '{"source_id": "my-app", "events": [{"text": "Alice joined the team"}]}' ``` The Smriti pipeline runs exactly the same, but the final data lands in your database! πŸ‘‰ **[Read the full 3-step setup guide here](./supabase/README.md)** --- ## πŸ”Œ MCP Server (Claude, Cursor, VS Code) Smriti ships with a built-in **Model Context Protocol (MCP)** server, giving your local AI tools instant memory without you writing a single API call. ### 1. Install & Configure ```bash pip install -r mcp/requirements.txt ```
Setup for Claude Desktop Add this to your `claude_desktop_config.json`: ```json { "mcpServers": { "smriti": { "command": "python", "args": ["-m", "smriti.mcp"], "cwd": "/path/to/smriti", "env": { "SMRITI_API_KEY": "chrn_your_key_here", "SMRITI_SOURCE_ID": "claude-desktop" } } } } ```
Setup for Cursor Add this to `.cursor/mcp.json` in your project root: ```json { "mcpServers": { "smriti": { "command": "python", "args": ["-m", "smriti.mcp"], "cwd": "/path/to/smriti", "env": { "SMRITI_API_KEY": "chrn_your_key_here", "SMRITI_SOURCE_ID": "cursor-project" } } } } ```
### 2. Available MCP Tools | Tool | What It Does | |------|-------------| | `smriti_remember` | Store text; auto-extracts causal SVO events | | `smriti_recall` | Hybrid search (semantic + temporal) across all memories | | `smriti_timeline` | Generate a chronological timeline of events | | `smriti_forget` | Supersede outdated memories cleanly | | `smriti_health` | View service health status | --- ## πŸ—οΈ The 4-Layer Architecture Pipeline When you send text to Smriti, it passes through four discrete layers: 1. **Ingest Gate** β€” Accepts raw, chaotic text from chat logs, emails, or code. 2. **Decomposition** β€” The Groq LLM strips fluff and extracts structured `Subject β†’ Verb β†’ Object` tuples. 3. **Temporal Binding** β€” Assigns exact temporal boundaries to track state changes over time. 4. **Dual-Store Indexing** β€” Saves to PostgreSQL (for exact chronological queries) and pgvector (for fuzzy semantic search). --- ## πŸ“– REST API Reference **Base URL:** `https://spy9191-chronos-api-backend.hf.space` **Auth:** Include header `X-API-Key: chrn_your_key` | Endpoint | Method | Purpose | |----------|--------|---------| | `/billing/keys` | POST | Generate a new API key | | `/ingest` | POST | Send raw text to be converted into structured memories | | `/query` | POST | Natural language memory retrieval | | `/agent/run` | POST | Chat directly with our memory-aware LangGraph agent | | `/health` | GET | System uptime and DB status | --- ## πŸ’» Integration Examples ### Node.js / JavaScript ```javascript const headers = { "X-API-Key": "chrn_...", "Content-Type": "application/json" }; // Remember await fetch("https://spy9191-chronos-api-backend.hf.space/ingest", { method: "POST", headers, body: JSON.stringify({ source_id: "app", events: [{ text: "Upgraded to Pro" }] }) }); // Recall const res = await fetch("https://spy9191-chronos-api-backend.hf.space/query", { method: "POST", headers, body: JSON.stringify({ query: "Who upgraded?" }) }); console.log(await res.json()); ``` ### Python ```python import httpx API = "https://spy9191-chronos-api-backend.hf.space" HEADERS = {"X-API-Key": "chrn_..."} # Remember httpx.post(f"{API}/ingest", headers=HEADERS, json={ "source_id": "my-app", "events": [{"text": "User completed onboarding on July 15"}] }) # Recall result = httpx.post(f"{API}/query", headers=HEADERS, json={ "query": "What did the user do?" }) print(result.json()["results"]) ``` --- ## βš™οΈ Environment Configuration | Variable | Required | Description | |---|---|---| | `GROQ_API_KEY` | βœ… | Required for local hosting. Free from [console.groq.com](https://console.groq.com) | | `SMRITI_API_KEY` | MCP only | Your Smriti API key (`chrn_...`) | | `CHRONOS_DB_URL` | No | Override default PostgreSQL URL | | `PGVECTOR_DB_URL` | No | Override default pgvector URL | --- ## πŸ“Š Dashboard & Pricing Manage your memories, keys, and view timelines via the Dashboard: **[smriti-kaal.vercel.app](https://smriti-kaal.vercel.app)** | Tier | Price | Limits | |---|---|---| | **Explorer** | Free | 10,000 events/mo, 3 connected tools | | **Builder** | $49/mo | 500,000 events/mo, 25 tools | | **Scale** | $249/mo | 5,000,000 events/mo, unlimited tools | ---

πŸ•°οΈ Memory that persists. Context that continues.
Β© 2026 Smriti / Chronos Labs