HippoMCP

v0.2.2
io.github.cstksniper/hippocampus-mcp Checked 3 days ago Published 27 days ago

MCP-native long-term memory for AI agents: local-first, pip-installable, native Chinese support

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

recall

Hybrid retrieval: vector + BM25 (RRF fusion) + MMR + entity bonus, hard relevance floor; shared scoring pipeline (R1). HIPPOCAMPUS_RECALL_FUSION=0 restores the legacy additive path. Call BEFORE asserting anything about the past; no hit is not proof of absence. Args: query: natural sentence (Chinese OK). top_k: max entries (default 5). filter_tags: JSON object, narrows BEFORE retrieval, e.g. {"chapter": 43}. occurred_after / occurred_before: 'YYYY-MM-DD', inclusive window. scope: project (default) | user | all; libraries='a,b' fans out to <=4 na…

ParameterTypeDescription
filter_tagsstring
librariesstring
librarystring
occurred_afterstring
occurred_beforestring
querystring
sampleboolean
scopestring
top_kinteger
use_lnnboolean

update_memory

Update only the provided fields of one memory (locate the id via recall). To retire an outdated fact: write the new version via ingest, then state='superseded' + superseded_by=<new id> (the result echoes this chain). clear_quarantine is a home-session-managed promotion. Args: memory_id; content; importance (-1 keep); memory_type; state active|superseded|archived; superseded_by.

ParameterTypeDescription
memory_id *string
clear_quarantineboolean
contentstring
importancenumber
librarystring
memory_typestring
statestring
superseded_bystring

forget_memory

Delete one memory by id: cascade (entity index, L3 derivatives, tombstone). DESTRUCTIVE - confirm the id via recall first; prefer state='superseded' for corrections. Args: memory_id, reason.

ParameterTypeDescription
memory_id *string
librarystring
reasonstring

ingest

RECOMMENDED write entry: raw text -> L0 archive + extracted L1 facts + entity links; dedup, supersede detection, idem_key retries. Use for "remember this". Args: text: verbatim. speaker: user|assistant|role. importance: -1 = auto. cognitive_type: experience|world|opinion (blank = auto). entities: comma list. source: origin label. tags: JSON object. idem_key: same key on retry = no duplicate.

ParameterTypeDescription
text *string
auto_tagsboolean
cognitive_typestring
entitiesstring
idem_keystring
importancenumber
librarystring
sourcestring
speakerstring
tagsstring

get_memory_context

Five-slot assembled context (hits / open todos / timeline / entity state / unfinished topics) under a char budget. For "what should I know right now"; point lookups use recall. Args: query: empty = pinned brief. top_k: hit count. token_budget: whole-block chars (coarse). item_max_chars: per-line clip, 0 = off (numeric tails survive). filter_tags: JSON object. scope: project | user only (no all).

ParameterTypeDescription
filter_tagsstring
item_max_charsinteger
librarystring
querystring
scopestring
token_budgetinteger
top_kinteger

session_start

Open a session; return the pre-activation package (pins, profile, open topics, intents, task recall, receipt). Call at session start or after compaction - on compaction keep ONLY the receipt identity and call again. Check active_sessions before editing files. Args: task: drives pre-recall and write attribution. working_on: module/file. recent_limit / task_top_k / pin_limit / user_scope / task_directory: 0 = env default, negative = off.

ParameterTypeDescription
clientstring
filter_tagsstring
librarystring
pin_limitinteger
recent_limitinteger
taskstring
task_directoryinteger
task_top_kinteger
user_scopeinteger
working_onstring

session_end

Close THIS session: L2 summary, profile update, consolidate trigger, forced save. Args: summary: one line. open_topics: unfinished topics (array or comma string). close_topics: topics to close (exact text). client: caller id. Skip entirely when this session never touched a hippocampus tool.

ParameterTypeDescription
clientstring
close_topics
librarystring
open_topics
session_idstring
summarystring

library_whoami

Which library this session reads/writes (binding self-report). Call when the target library is uncertain; near-zero cost.

hippo_help

List extension actions hidden in this session but callable via hippo_extra, with their arguments (export / lexicon / entity graph / ops / state access, etc.). When unsure whether a memory capability exists or you cannot find the tool you need, call this first.

hippo_extra

Call a tool not directly exposed in this session by action name (export / lexicon / entity graph / ops, etc.). Call hippo_help first for the action list and argument names, then invoke via hippo_extra(action="...", args='{"argument": value}')

ParameterTypeDescription
action *string
argsstring