AgentStack
Browse Sign in
Browse Why AgentStack Sell Docs
Sign in
MCP verified MIT Self-run

Smrti

mcp-cyqlelabs-smrti · by cyqlelabs

Memory engine for self-evolving AI agent ecosystems. Multi-tenant, multi-space isolation with Bayesian truth maintenance, emotional valence, automatic consolidation, and configurable per-agent personality.

No reviews yet
0 installs
23 views
0.0% view→install

Install

$ agentstack add mcp-cyqlelabs-smrti

✓ scanned · ✓ verified, works with Claude Code, Cursor, and more.

Security review

✓ Passed

No issues found. Passed automated security review. · v0.1.0 How review works →

  • Prompt-injection patterns
  • Secret / credential exfiltration
  • Dangerous shell & filesystem operations
  • Untrusted network calls
  • Known-malicious package signatures

What it can access

  • Network access Used
  • Filesystem access No
  • Shell / process execution No
  • Environment & secrets No
  • Dynamic code execution No

From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.

View the full security report →

Verified badge

Passed review? Show it. Paste this badge into your README, it links to the public security report.

AgentStack Verified badge Links to your public security report.
[![AgentStack Verified](https://agentstack.voostack.com/badges/verified.svg)](https://agentstack.voostack.com/security/report/mcp-cyqlelabs-smrti)

Reliability & compatibility

Security review passed
0 installs to date
no reviews yet
5mo ago

Declared compatibility

Claude CodeClaude DesktopCursorWindsurf

Compatibility is declared by the source manifest. End-to-end runtime verification is coming, see below.

Preview Execution monitoring

We're building live execution health for every listing: tool-call success rate, median latency, uptime, and last-checked timestamps, measured, not self-reported. It isn't live yet, so we don't show numbers we can't stand behind.

How agent discovery & health will work →
Are you the author of Smrti? Claim this listing to set pricing, connect Stripe payouts, and keep 70% of every sale.
Sign up to claim

About

smrti

[](https://pypi.org/project/smrti/) [](https://pypi.org/project/smrti/) [](LICENSE) [](https://github.com/cyqlelabs/smrti/actions/workflows/publish.yml) [](https://codecov.io/gh/cyqlelabs/smrti)

AtomSpace-inspired memory engine for AI agents. Stores beliefs as graph nodes with Bayesian truth values, emotional valence, and attention weights in a single SQLite file with vector indexing. No extra infra to maintain. Just Plug & Play.

Not just vector search. Embedding similarity is only an entry point — a fast index to seed graph traversal. What gets returned and why is governed by graph topology (typed relation edges), Bayesian truth values (PLN), attentional economics (STI/LTI), and emotional valence. Similarity is one signal among five, not the ranking.

How It Works

> [Pipeline diagram →](docs/pipeline.md)

remember() — Embeds and stores text as a typed atom (concept, belief, episode, or goal) with a Bayesian truth value, attention weight, and valence score. Evidence is append-only; truth values update via PLN revision. A hybrid GLiNER2 + LLM pipeline auto-extracts entities and relation edges; the LLM is only called when ≥2 entities are found (~40–60% fewer LLM calls). Pronouns are resolved against the live graph using persisted entity context, not raw conversation history.

recall() — Embeds the query → KNN seeds (top-50) → 1-hop graph expansion → salience re-ranking: w_sim × similarity + w_sti × STI + w_conf × confidence + w_lti × LTI + w_val × |valence| × intensity. When valence remember · recall · believe · reflect · forget · status"] end

subgraph Servers MCP["mcp.pyMCP stdio"] REST["rest.pyFastAPI :8420"] PROXY["proxy.pyOpenAI proxy :8421"] end

subgraph Core AS["AtomSpace"] DB["Database"] EMB["Embedder"] MOD["Models"] end

subgraph Retrieval FAN["fan_out"] SAL["salience"] CLS["classify"] end

subgraph Evolution EPO["epoch"] TRU["truth"] CON["connections"] HEA["healing"] end

subgraph Spaces SOP["set_ops"] EMG["emergence"] end

subgraph Extraction EXT["extract"] RES["resolve"] ALI["aliases"] end

subgraph Storage SQL["SQLite + sqlite-vecmultilingual-MiniLM-L12-v2 · 384d · ONNX CPU"] end

MCP & REST & PROXY --> S S --> Core & Retrieval & Evolution & Extraction & Spaces Core & Retrieval & Evolution & Extraction & Spaces --> SQL


**Retrieval pipeline:** Embed query → KNN over tenant partition → filter to read spaces → 1-hop graph expansion → salience scoring → top-k

**Salience formula:**

S = wsim × similarity + wsti × sti + wconf × confidence + wlti × lti + w_val × |valence| × intensity

When valence < -0.5, weight shifts dynamically from wsti to wval so critical errors outrank recent trivia.


**Consolidation epoch** (runs automatically every `SMRTI_REFLECT_INTERVAL` seconds, or manually via `reflect()`):

1. Process pending evidence via Bayesian update
2. Decay STI and confidence
3. Propagate STI and valence to 1-hop neighbors
4. Heal orphaned episodes (link to most salient person)
5. Promote high-STI atoms to LTI
6. Resolve contradictions (weaken less confident belief)
7. Discover cross-domain connections (every 10th epoch)
8. Materialize cross-space bridge atoms (every 10th epoch)
9. Prune atoms below confidence/LTI floors

## Data Model

| Atom Type  | Purpose                  | Example                          |
| ---------- | ------------------------ | -------------------------------- |
| `concept`  | Reusable entities        | "Alice", "Python", "OpenAI"      |
| `belief`   | Probabilistic facts      | "Alice prefers TypeScript"       |
| `episode`  | Timestamped observations | "User asked about deployment"    |
| `goal`     | Desired states           | "Finish the migration by Friday" |
| `relation` | Edges between atoms      | Alice → works_at → Acme Corp     |

Each atom carries:

- **TruthValue** — `probability` [0,1] and `confidence` [0,1], merged via PLN revision
- **AttentionValue** — `sti` (short-term importance, decays fast) and `lti` (long-term, accumulates)
- **Valence** — emotional tone [-1,1] and intensity [0,1]

## Testing

```bash
pytest tests/ -v

License

MIT

Source & license

This open-source MCP server is cataloged on AgentStack and links to its original source — we do not rehost the code.

Install and usage instructions live in the source repository linked above.

Reviews

No reviews yet, be the first.

Versions

  • v0.1.0 Imported from the upstream source.