← 返回
开发者工具 中文

Hypabase Memory

Persistent memory for agents. Stores preferences, decisions, facts, and events as a connected knowledge graph. Recalled by who, what, when, or why.
智能体持久记忆。将偏好、决策、事实和事件存储为关联知识图谱。支持按人物、事件、时间或原因进行检索。
harshidwasekar
开发者工具 clawhub v0.2.4 1 版本 99761.3 Key: 无需
★ 0
Stars
📥 836
下载
💾 7
安装
1
版本
#latest

概述

Hypabase Memory

Persistent memory for agents. Stores preferences, decisions, facts, and events as a connected knowledge graph. Recalled by who, what, when, or why.

Setup

Add the MCP server to your OpenClaw config (~/.openclaw/openclaw.json):

{
  "mcpServers": {
    "hypabase-memory": {
      "command": "uvx",
      "args": ["--from", "hypabase", "hypabase-memory"],
      "env": { "HYPABASE_DB_PATH": "hypabase.db" }
    }
  }
}

uvx handles all Python dependencies automatically. Requires uv.

Quick start

Store a memory — one verb, roles for the participants:

remember(penman='(prefers :subject Alice :object Python :memory_type semantic)')

Recall it:

recall(entity="Alice")                              # everything about Alice
recall(entity="Alice", action="assign", role="subject")  # what Alice assigned
recall(entity=["Alice", "Bob"])                     # memories involving both
recall(mood="planned")                              # all plans

When to Remember

Store a memory when the user:

  • Makes a decision or states a preference
  • Shares a fact about themselves, their team, or a project
  • Assigns a task or delegates work
  • Describes an event, meeting, or outcome
  • Explains a procedure or workflow

PENMAN Notation

Every memory is a verb with participants in role slots:

(verb :role "entity" :role "entity" ...)

Examples:

(prefers :subject Alice :object Python :memory_type semantic)

(assigned :subject Alice :object "billing task" :recipient Bob
 :instrument Jira :locus Monday :tense past :memory_type episodic)

(has :subject "quick sort" :attribute "time complexity"
 :value "O(n log n)" :memory_type semantic)

Multiple atoms in a single call:

(deployed :subject Alice :object API :locus Monday :tense past)
(reviewed :subject Bob :object API :locus Tuesday :tense past)

One action per memory. When a sentence contains multiple actions, decompose into separate atoms. Shared entities link them in the graph.

"Alice told Bob to migrate the database":

(told :subject Alice :recipient Bob :object "database migration" :tense past)
(migrate :subject Bob :object database :mood planned)

Any role slot can hold a nested atom:

(believes :subject Alice :object (is :subject deadline :value Friday))

Entity Naming

Same string after lowercasing = same entity. Different strings = different entities until consolidate() merges them.

  • Pick one canonical name per entity and reuse it.
  • Use full descriptive names: "machine learning" not "ML", "JavaScript" not "JS".
  • Call consolidate() periodically to merge similar names via semantic similarity.

Tools

remember(penman, source?, confidence?)

Store memories as PENMAN atoms.

  • penman (required): One or more PENMAN atoms.
  • source (optional): Provenance source. Default: "memory".
  • confidence (optional): 0.0–1.0. Default: 1.0.

recall(entity?, action?, role?, memory_type?, mood?, negated?, since?, before?, limit?, min_strength?)

Query memories. At least one parameter required.

  • entity: Name or list of names.
  • action: Filter by verb.
  • role: Filter by role (subject/object/instrument/recipient/source/locus/attribute/value).
  • memory_type: episodic / semantic / procedural.
  • mood: actual / planned / uncertain / normative / conditional.
  • negated: true = only negated, false = only positive.
  • since / before: ISO date strings.
  • limit: Max results (default: 10).
  • min_strength: Minimum memory strength threshold.

consolidate(entity?)

Merge similar entities and compress repeated memories.

forget(older_than_days?, min_strength?, entity?)

Expire old or low-strength memories (soft delete).

Reference

Roles

Eight roles. Fill in what applies, skip what doesn't.

PENMAN roleRecall roleMeaningExample
--------------------------------------------
:subjectsubjectWho or what it's aboutAlice
:objectobjectWhat is acted onthe proposal
:instrumentinstrumentTool, method, or meansSlack
:recipientrecipientWho receives or benefitsBob
:originsourceWhere it came fromthe old system
:locuslocusWhere, when, or contextsprint review
:attributeattributeA named propertytime complexity
:valuevalueThe specific valueO(n log n)

Memory types

TypeUse forDecay rate
---------------------------
episodicEvents, meetings, conversationsFast
semanticFacts, preferences, definitionsSlow
proceduralHow-to, workflows, processesSlowest

Moods

MoodWhen to use
-------------------
actualSomething that happened or is true (default)
plannedSomething intended to happen
uncertainSomething that might be true
normativeSomething that should or shouldn't be
conditionalSomething that depends on a condition

Modifiers

ModifierValuesDefault
---------------------------
:tensepast, present, future--
:negatedtrue, falsefalse
:importance0.0 to 1.0--
:causeNested atom: why it happened--
:purposeNested atom: what for--
:conditionNested atom: if/when/unless--

Environment variables

  • HYPABASE_DB_PATH -- SQLite database path (default: hypabase.db)
  • HYPABASE_EMBEDDER -- Embedder for semantic search:
  • fastembed (default) -- BAAI/bge-small-en-v1.5 via ONNX
  • openai -- text-embedding-3-small (requires OPENAI_API_KEY)
  • sentence-transformers -- all-MiniLM-L6-v2
  • none -- disable embeddings

版本历史

共 1 个版本

  • v0.2.4 当前
    2026-03-29 22:35 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

developer-tools

CodeConductor.ai

larsonreever
AI驱动平台,提供快速全栈开发、智能体、工作流自动化及低代码AI集成的可扩展产品创建。
★ 68 📥 180,139
developer-tools

Agent Browser

matrixy
专为AI智能体优化的无头浏览器自动化CLI,支持无障碍树快照和基于引用的元素选择。
★ 427 📥 118,186
developer-tools

Github

steipete
使用 `gh` CLI 与 GitHub 交互,通过 `gh issue`、`gh pr`、`gh run` 和 `gh api` 管理议题、PR、CI 运行及高级查询。
★ 668 📥 324,120