memtomem-stmBLOCK
Short-term memory proxy gateway with proactive memory surfacing for AI agents
Overview
From the repository's own README, as read at the audited commit. Badges and raw HTML are left out.
Official website & docs: [https://memtomem.com](https://memtomem.com)
[](https://pypi.org/project/memtomem-stm/) [](https://python.org) [](LICENSE) [](CLA.md)
🚧 Alpha — APIs and defaults may change between 0.x minor releases. Feedback and issue reports are especially welcome: Issues · Discussions.
Spend fewer tokens. Remember more. Ship faster.
memtomem-stm is an MCP proxy that can substantially reduce the model-visible size of large tool responses and surface cross-session memory from a configured memtomem LTM — with no changes to your upstream MCP servers. The actual reduction depends on response shape, compression strategy, and whether the call travels through MCP; verify it against your workload with the repository's deterministic bench_qa suite.
It sits between your AI agent and its upstream MCP servers, compressing tool responses, caching repeated calls, and automatically surfacing relevant context from prior sessions via a memtomem LTM server.
What memtomem-stm does:
- Cuts token spend on repeated reads — compresses and caches tool responses, so the agent doesn't re-pay for the same file or search result. Works with Claude Code, Cursor, Claude Desktop, or any MCP client.
- Carries context across sessions — surfaces prior decisions from memtomem LTM automatically, so the agent picks up where it left off rather than re-discovering what it already knew.
- Drops in front of any MCP server — adds compression, caching, and observability as a proxy layer, without changes to upstream code.
flowchart TB Agent["Agent(Claude Code, Cursor, ...)"]
ff7574d9f9f8OBSERVED · 2026-10-11Connect
Built from this server's own package name, version and transport as found in its source — not copied from anyone's documentation, so it cannot drift against a page we do not control. Replace the environment placeholders with a token scoped to the least it needs.
claude mcp add memtomem-stm --env ANTHROPIC_API_KEY=${ANTHROPIC_API_KEY} --env MEMTOMEM_STM_SURFACING__MIN_QUERY_TOKENS=${MEMTOMEM_STM_SURFACING__MIN_QUERY_TOKENS} --env OPENAI_API_KEY=${OPENAI_API_KEY} -- uvx memtomem-stm{
"mcpServers": {
"memtomem-stm": {
"command": "uvx",
"args": [
"memtomem-stm"
],
"env": {
"ANTHROPIC_API_KEY": "${ANTHROPIC_API_KEY}",
"MEMTOMEM_STM_SURFACING__MIN_QUERY_TOKENS": "${MEMTOMEM_STM_SURFACING__MIN_QUERY_TOKENS}",
"OPENAI_API_KEY": "${OPENAI_API_KEY}"
}
}
}
}Exposed tools (14)
14 read · 0 write · 0 destructive.
| Tool | Risk | Description |
|---|---|---|
describe | read | Return a short description of what this fixture exposes. |
eligible_tools | read | Canned ``eligible_tools`` consult mirroring the real structured shape. |
get_document | read | Return the full structured document as a JSON object. |
greet | read | return f |
mem_do | read | Stand-in for the ``mem_do`` meta-tool. |
mem_search | read | Return two canned search hits in core |
rank_features | read | Canned ``rank_features`` consult mirroring the real per-candidate shape. |
say | read | Return the input text prefixed with a greeting. |
stm_compression_feedback | read | Report missing information from a compressed proxy response. |
stm_proxy_describe_tool | read | Read bounded pages of a registered tool |
stm_proxy_read_more | read | Read more content from a progressive delivery response. |
stm_proxy_select_chunks | read | Retrieve selected sections from a TOC response. |
stm_surfacing_feedback | read | Provide feedback on proactively surfaced memories. |
unrelated_tool | read | return |
Trust audit
BLOCKgrade D · trust 61/100 Do not install this without reading the findings. The audit found something that could harm you or your machine.
| Layer | What it checks | Result |
|---|---|---|
| L0 | Provenance & inventory | PASS |
| L1 | Static analysis of the code | FAIL |
| L2 | Instruction surface (what it tells the agent) | PASS |
| L3 | Class-specific surface | PASS |
| L4 | Behavioural (sandbox) | SKIPPED |
What the source does
- Filesystem
- none-observed
- Network
- declared (5 observation(s))
- Shell
- declared (1 observation(s))
- Dependencies
- pinned
- Secrets in source
- found
Findings (25)
# "sk-ant-api03-release-notes-2026-migration-guide". The terminal guard is
loaded = getattr(importlib.import_module(module_name), attr)
"sk-ant-api03-release-notes-2026-migration-guide", # Anthropic kebab slug
"env": {"DATABASE_URL": "postgres://u:pw-DO-NOT-PRINT@h/db"},"gh ghp_ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789",
assert contains_sensitive_content("-----BEGIN RSA PRIVATE KEY-----")"-----BEGIN RSA PRIVATE KEY-----",
"-----BEGIN DSA PRIVATE KEY-----",
"-----BEGIN PGP PRIVATE KEY-----",
"-----BEGIN RSA PRIVATE KEY-----",
"xoxb-123456-abcdef", # Slack bot
"xoxp-123456-abcdef", # Slack user
httpx_mod = importlib.import_module(module_name)
mod = importlib.import_module(module)
mod = importlib.import_module(module_path)
return hashlib.md5(
== hashlib.md5(
"aws_session_token = FAKEFwoGZXIvYXdzFAKE", # ~/.aws/credentials form
server="../../tmp/evil",
server="../../tmp/evil",
_PARTIAL_URL = "http://127.0.0.1:9/mcp?token=cnryPartQuery#cnryPartFrag"
"'http://127.0.0.1:9/mcp?token=cnryPartQuery#cnryPartFrag'; "
("http://127.0.0.1:9/mcp?token=cnryQ#cnryF", "http://127.0.0.1:9/mcp"),"embedding_base_url": "http://127.0.0.1:9",
assert "verify the local Ollama at http://127.0.0.1:9" in result.output
Gates applied: critical_finding, no_behavioural_pass.
ff7574d9f9f8full audit observations/trust-audit/mcp-server/memtomem__memtomem-stm.json · Report an issue / request a re-scanAudit history
Every audit this server has had. A grade with a past is a grade somebody is still checking.
| Date | Source | Verdict | Grade | Score | Change |
|---|---|---|---|---|---|
| 2026-10-11 | ff7574d9f9f8 | BLOCK | D | 61 | first audit |
Questions
What is the memtomem-stm MCP server?
Short-term memory proxy gateway with proactive memory surfacing for AI agents
What tools does memtomem-stm expose?
14 in total: 14 read-only, 0 that write, and 0 that can delete or overwrite. Every one is listed on this page with its risk.
Is memtomem-stm safe to connect to an agent?
No — not without reading the findings first. The audit graded it D (61/100) and found 1 critical or high issue in the source. Each one is listed on this page with the file and line it is on.
What credentials does memtomem-stm need?
It reads ANTHROPIC_API_KEY, MEMTOMEM_STM_SURFACING__MIN_QUERY_TOKENS and OPENAI_API_KEY from the environment. Give it a token scoped to the least it needs — an agent that can be talked into calling a tool can be talked into calling it with your credentials.
How does memtomem-stm run?
It speaks sse, stdio and streamable-http, so it runs as a local process your client starts. It is published on PyPI as memtomem-stm.
How current is this page?
The grade is for one exact copy of the source (ff7574d9f9f8), read on 2026-10-11. The repository is watched and re-audited when it changes.