Skip to content

feat: deep-memory plugin — reasoning-based memory with semantic recall - #6114

Closed
RichardHojunJang wants to merge 1 commit into
NousResearch:mainfrom
RichardHojunJang:feat/deep-memory-plugin
Closed

feat: deep-memory plugin — reasoning-based memory with semantic recall#6114
RichardHojunJang wants to merge 1 commit into
NousResearch:mainfrom
RichardHojunJang:feat/deep-memory-plugin

Conversation

@RichardHojunJang

Copy link
Copy Markdown
Contributor

Summary

Adds deep-memory as an optional plugin toolset. Inspired by Honcho, deep-memory provides structured reasoning over conversations, entity tracking, and hybrid semantic + keyword search — all running locally with zero external hosting (SQLite + FTS5 + sqlite-vec).

New Tools

Tool Description
recall Hybrid semantic + keyword search over past insights
learn Store structured insights (explicit/deductive/inductive/abductive)
entities Track people, projects, concepts with evolving profile cards

Features

  • Post-session reasoning — Automatically extracts insights after each conversation
  • System prompt injection — Surfaces relevant deep memory context each turn
  • Embedding auto-config — Detects best backend: local (sentence-transformers) → OpenAI → FTS-only

Install

pip install hermes-agent[deep-memory]

No config needed — auto-detection handles everything.

Changes (5 files, +126 lines)

File Lines Purpose
pyproject.toml +3 Optional dependency
model_tools.py +5 Plugin import in _discover_tools()
toolsets.py +9 Tool names + toolset definition
run_agent.py +26 Prompt injection + session hook
docs/plugins/deep-memory.md +83 Usage guide

Zero Impact When Not Installed

All imports are guarded by try/except ImportError. If deep-memory is not installed, Hermes behaves exactly as before — no errors, no warnings.

Tests

  • deep-memory: 78 tests passing
  • hermes-agent: 2047 passed (3 pre-existing failures unrelated to this PR)

Add deep-memory as an optional plugin toolset. Inspired by Honcho, provides:
- recall/learn/entities tools for structured reasoning memory
- Post-session automatic insight extraction
- System prompt injection of relevant deep memory context
- Embedding auto-config (local/openai/fts-only)

Install: pip install hermes-agent[deep-memory]
Zero impact when not installed (all imports guarded by try/except).

Changes:
- pyproject.toml: optional dependency
- model_tools.py: plugin import in _discover_tools() (+5 lines)
- toolsets.py: tool names + toolset definition (+9 lines)
- run_agent.py: prompt injection + session hook (+26 lines)
- docs/plugins/deep-memory.md: usage guide
@RichardHojunJang

Copy link
Copy Markdown
Contributor Author

Deep memory plugin repository
https://github.com/RichardHojunJang/deep-memory

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant