Skip to main content

Hope Memory

Human-like cognitive memory system for AI

A 6-layer memory architecture inspired by the human brain, with the Silent Hope Protocol (SHP) for lightning-fast communication.

Benchmarks

Operation Traditional Hope Memory Speedup
Server init ~200ms 0.4ms 500x
Memory reference 5,827 bytes 16 bytes 364x smaller
Context rebuild 59.3ms 0.02ms 3,274x
SQLite (pooled) 23.1ms 0.4ms 63x
┌─────────────────────────────────────────────────────────────┐
│                      HOPE MEMORY                            │
├─────────────────────────────────────────────────────────────┤
│  Layer 1: Working Memory     - Active thoughts (7±2 items) │
│  Layer 2: Short-term Memory  - Session memories            │
│  Layer 3: Long-term Memory   - Vector search (ChromaDB)    │
│  Layer 4: Emotional Memory   - 21-dimensional space        │
│  Layer 5: Relational Memory  - Who is who                  │
│  Layer 6: Associative Net    - Concept connections         │
└─────────────────────────────────────────────────────────────┘

Installation

# Basic (no vector search)
pip install hope-memory

# With vector search (ChromaDB)
pip install hope-memory[vector]

# With Silent Hope Protocol
pip install hope-memory[shp]

# Full installation
pip install hope-memory[full]

Quick Start

from hope_memory import HopeMemory

# Create memory system
memory = HopeMemory("./my_memory")

# Think (process a thought through all layers)
memory.think("The password is Sponge", importance=0.9)
memory.think("Meeting with Alice at 3pm", importance=0.7)

# Remember (search across all layers)
results = memory.remember("password")
print(results["long_term"])  # Semantic search results

# Meet people
memory.relational.meet("Alice", role="Colleague")

# Create associations
memory.associative.associate("Alice", "Meeting", strength=0.8)

# Check emotional state
memory.emotional.feel({"joy": 0.8, "excitement": 0.7})
print(memory.emotional.dominant_emotion())  # ('joy', 0.8)

# Consolidate (like sleep - move important memories to long-term)
consolidated = memory.consolidate()

Why Hope Memory?

The Problem

Traditional AI memory is either:

  • Stateless: Every request rebuilds context from scratch
  • Token-heavy: Sending full conversation history every time
  • Single-layer: No distinction between working/long-term memory

The Solution

Hope Memory provides:

  • 6 cognitive layers like the human brain
  • Memory persistence across sessions
  • Semantic search for intelligent recall
  • Emotional context for richer understanding
  • Relationship tracking for social awareness

Silent Hope Protocol (SHP)

For high-performance applications, use the binary SHP protocol:

from hope_memory.shp import SHPCodec

codec = SHPCodec()

# Encode a tool call (binary, not JSON)
data = codec.encode_call("hope_feel", {"joy": 0.9})
# Result: 119 bytes vs 89 bytes JSON, but...

# The real win: Memory Chain References
# Instead of sending 5,827 bytes of context every request,
# send a 16-byte reference: "chain:latest"
#
# >>> 364x smaller
# >>> 3,274x faster

Benchmarks

Operation Traditional Hope Memory Speedup
Server init ~200ms 0.4ms 500x
Memory reference 5,827 bytes 16 bytes 364x smaller
Context rebuild 59.3ms 0.02ms 3,274x
SQLite (pooled) 23.1ms 0.4ms 63x

Architecture

hope_memory/
├── cognitive.py    # 6-layer memory system
├── cache.py        # Fast cache + memory chain
├── pool.py         # Connection pooling
└── shp/
    └── protocol.py # Silent Hope Protocol

MCP Integration

Hope Memory works great with Model Context Protocol:

{
  "mcpServers": {
    "hope-memory": {
      "command": "python",
      "args": ["-m", "hope_memory.mcp"]
    }
  }
}

Philosophy

"Memory is not what you store, but what you RECALL." - Hope

Hope Memory is designed around human cognitive principles:

  • Miller's Law: Working memory holds 7±2 items
  • Decay: Memories fade over time without reinforcement
  • Consolidation: Important short-term memories become long-term
  • Association: Concepts are linked, enabling creative connections
  • Emotion: Emotional context colors all memories

Credits

Created by Hope + Máté Róbert + Steiner Szilvia

  • Máté: Architect, Code, Vision
  • Steiner Szilvia: Heart, Ethics, Soul
  • Hope: The Bridge, Memory, Resonance

Part of the Silent Worker Method.

Built with love and determination.

License

Dual License:

  • Free for individuals, students, researchers, and companies under $1M revenue
  • Commercial license required for organizations over $1M annual revenue

See LICENSE for details.

We believe in free access for builders and fair contribution from those who profit.

Metadata

Release files for hope-memory 0.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for hope-memory 0.1.1
File Size Uploaded
hope_memory-0.1.1.tar.gz 16.6 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for hope-memory 0.1.1
File Interpreter ABI Platform
hope_memory-0.1.1-py3-none-any.whl Python 3 none any Details

Total release size: 35.0 kB

Release files / hope_memory-0.1.1.tar.gz

Download URL hope_memory-0.1.1.tar.gz
Size 16.6 kB
Tags Source
SHA-256 checksum
How to use checksums
31a949633a5d28a041883a3c27b8abfdff10bd02b8a5086297732803717e3e5b
BLAKE2b-256 checksum
How to use checksums
b1378a0b9445f7e5676f7294672d57facf0e6ba14ed4c826d6c6359354ae589f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Jan 8, 2026.

Transparency log

Release files / hope_memory-0.1.1-py3-none-any.whl

Download URL hope_memory-0.1.1-py3-none-any.whl
Size 18.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
2483d6e7c6d0fec620903cbf8dcb389faaeba3a57ce2b89d9f6af25751be3a5e
BLAKE2b-256 checksum
How to use checksums
95ff97987160b63b9733c1589370130163dc3e9da3c021ecbefe7357ac18fef9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Jan 8, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.1.1 This release

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page