Skip to main content

ADK Perseus Vault Memory

๐Ÿ“ฆ Package rename history. This distribution replaced the archived adk-mimir-memory project. Install adk-perseus-vault-memory for the current Perseus Vault integration.

Persistent, local, encrypted cross-session memory for Google ADK agents โ€” backed by Perseus Vault.

Why Perseus Vault?

Backend Dependencies Encryption Hybrid Search Local
InMemoryMemoryService None โŒ โŒ โœ…
VertexAiMemoryBankService GCP + Gemini โŒ Gemini-driven โŒ
VertexAiRagMemoryService GCP + RAG โŒ GCP vector โŒ
PerseusVaultMemoryService Single binary โœ… AES-256 โœ… BM25+FTS5+Dense โœ…
  • Zero cloud dependencies โ€” a single Rust binary, SQLite database, fully local
  • AES-256-GCM encryption at rest โ€” your memory data stays private
  • Hybrid search โ€” BM25 keyword + FTS5 + dense vector search
  • Persistent-memory MCP tools โ€” remember, recall, synthesize, benchmark, federate, and more
  • Ebbinghaus confidence decay โ€” memories fade naturally, important ones persist

Installation

pip install adk-perseus-vault-memory

This package requires the perseus-vault binary. Download it from: https://github.com/Perseus-Computing-LLC/perseus-vault/releases

Or build from source:

cargo install perseus-vault

Quick Start

from google.adk.agents import Agent
from google.adk.runners import Runner
from google.adk.sessions import InMemorySessionService
from adk_perseus_vault_memory import PerseusVaultMemoryService

agent = Agent(
    name="my_agent",
    model="gemini-2.5-flash",
    instruction="You are a helpful assistant with persistent memory.",
)

# The memory service is configured on the Runner, not on the Agent.
runner = Runner(
    agent=agent,
    app_name="my_app",
    session_service=InMemorySessionService(),
    memory_service=PerseusVaultMemoryService(db_path="~/.adk/vault.db"),
)

That's it. Sessions, events, and explicit memories are now persisted across restarts.

Configuration

# Custom database location
PerseusVaultMemoryService(db_path="/data/agent_memory.db")

# Custom perseus-vault binary path (if not on $PATH)
PerseusVaultMemoryService(vault_binary="/usr/local/bin/perseus-vault")

# Both
PerseusVaultMemoryService(
    db_path="/data/agent_memory.db",
    vault_binary="/usr/local/bin/perseus-vault",
)

Perseus Live Context (Optional)

This package also includes a drop-in agent with live workspace awareness via Perseus:

from google.adk.runners import Runner
from google.adk.sessions import InMemorySessionService
from adk_perseus_vault_memory.perseus_context import perseus_context_agent

# The agent resolves @file, @search, @memory directives at inference time.
# Bind it on the Runner; run_async takes no `agent` argument.
runner = Runner(
    agent=perseus_context_agent,
    app_name="my_app",
    session_service=InMemorySessionService(),
)
runner.run_async(
    user_id="user",
    session_id="session",
    new_message=types.Content(role="user", parts=[types.Part.from_text(
        text="What does the README say about deployment?"
    )]),
)
pip install adk-perseus-vault-memory[perseus]  # installs perseus-ctx

Set directives via session state:

session = await runner.session_service.create_session(
    app_name="my_app",
    user_id="user",
    state={
        "_perseus_directives": "@file AGENTS.md @file README.md @memory deployment",
        "_perseus_workspace": "/path/to/project",
    },
)

How It Works

โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”     JSON-RPC (MCP stdio)     โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚  ADK Agent  โ”‚ โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ–ถ  โ”‚  Perseus Vault โ”‚
โ”‚  (Python)   โ”‚ โ—€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€  โ”‚  (Rust)        โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜                              โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
                                                      โ”‚
                                                 SQLite + FTS5
                                                 (AES-256-GCM)

The PerseusVaultMemoryService spawns a perseus-vault subprocess and communicates via JSON-RPC over stdin/stdout (MCP stdio transport). Each add_session_to_memory, add_memory, and search_memory call translates to a Perseus Vault MCP tool invocation.

License

MIT โ€” see Perseus Vault and Perseus for the backing services.

Download files

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

Source Distribution

adk_perseus_vault_memory-0.3.1.tar.gz (12.2 kB view details)

Uploaded Source

Built Distribution

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

adk_perseus_vault_memory-0.3.1-py3-none-any.whl (11.8 kB view details)

Uploaded Python 3

File details

Details for the file adk_perseus_vault_memory-0.3.1.tar.gz.

File metadata

  • Download URL: adk_perseus_vault_memory-0.3.1.tar.gz
  • Upload date:
  • Size: 12.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for adk_perseus_vault_memory-0.3.1.tar.gz
Algorithm Hash digest
SHA256 1baea9b350c9581dbe450dfb18f65040598543c7e98d85eab25ac61fbb21b916
MD5 55956f04ab7948fac2c9b4153a70434d
BLAKE2b-256 88bbe7c73f89b64e8035a29b656077bc3fd65558ea10919337f50c5749470fcb

See more details on using hashes here.

Provenance

The following attestation bundles were made for adk_perseus_vault_memory-0.3.1.tar.gz:

Publisher: publish.yml on Perseus-Computing-LLC/adk-perseus-vault-memory

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file adk_perseus_vault_memory-0.3.1-py3-none-any.whl.

File metadata

File hashes

Hashes for adk_perseus_vault_memory-0.3.1-py3-none-any.whl
Algorithm Hash digest
SHA256 ea89f5198b3ea0ae05b151facd1a9eb8aec44586ccfba65360de4cb29416d64c
MD5 8df4dbbd342c8061f4be69a195ec9ba6
BLAKE2b-256 0af5a72cf7b09bd4a31177040ea1c3c4f363334af0e425c9e456f01d317c65fa

See more details on using hashes here.

Provenance

The following attestation bundles were made for adk_perseus_vault_memory-0.3.1-py3-none-any.whl:

Publisher: publish.yml on Perseus-Computing-LLC/adk-perseus-vault-memory

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

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