{ "id": "hindsight-memory", "name": "Hindsight Memory", "description": "Cross-session memory via Hindsight. Injects LLM-free recall context before each reply (before_prompt_build) and retains each turn asynchronously after it ends (agent_end); Hindsight extracts/consolidates server-side, so there is no client-side cognify sweep. Structural successor to cognee-memory (kb #75, H3).", "activation": { "onStartup": true }, "contracts": { "tools": ["hindsight_recall", "hindsight_reflect"] }, "configSchema": { "type": "object", "additionalProperties": false, "properties": { "enabled": { "type": "boolean" }, "hindsightUrl": { "type": "string" }, "bankId": { "type": "string" }, "humanBanks": { "type": "object", "additionalProperties": { "type": "string" } }, "sharedBankId": { "type": "string" }, "agents": { "type": "array", "items": { "type": "string" } }, "budget": { "type": "string", "enum": ["low", "mid", "high"] }, "recallMaxTokens": { "type": "integer", "minimum": 128, "maximum": 32000 }, "maxContextChars": { "type": "integer", "minimum": 200, "maximum": 20000 }, "recallTimeoutMs": { "type": "integer", "minimum": 500, "maximum": 30000 }, "retainTimeoutMs": { "type": "integer", "minimum": 500, "maximum": 60000 }, "minTextChars": { "type": "integer", "minimum": 1, "maximum": 200 }, "retainMinTurnChars": { "type": "integer", "minimum": 0, "maximum": 2000 }, "types": { "type": "array", "items": { "type": "string" } }, "injectHeader": { "type": "string" } } }, "uiHints": { "enabled": { "label": "Hindsight Memory", "help": "Enable cross-session Hindsight memory (recall inject + async turn retain)." }, "hindsightUrl": { "label": "Hindsight URL", "help": "Base URL of the Hindsight REST API (default http://hindsight:8888)." }, "bankId": { "label": "Bank ID", "help": "Legacy single-bank fallback. Used only when humanBanks is empty (per-human partitioning disabled) — recall/retain both target this one bank for every sender, the pre-A2A-21 (kb#153) behavior." }, "humanBanks": { "label": "Per-Human Private Banks", "help": "Map of interlocutor id (Matrix sender, e.g. \"@admin:mtx.alogins.net\") -> that human's private Hindsight bank id (e.g. \"adolf-alvis\"). Non-empty enables per-human memory partitioning (kb#153/A2A-21 DESIGN §5b): recall/retain resolve the bank by the turn's sender instead of a single static bankId. A sender with no entry here is treated as unknown: recall falls back to sharedBankId only (never a guessed private bank) and retain is skipped entirely — this is the hard cross-human-leakage rule, not a gap to silently work around." }, "sharedBankId": { "label": "Shared Household Bank", "help": "Hindsight bank id for facts explicitly shared across all humans (e.g. \"adolf-shared\"). Recalled alongside the sender's private bank when humanBanks is non-empty. Hooks never write here automatically — promotion from a private bank to shared is a human's explicit action/approval task, never an automatic retain (DESIGN §5b hard rule)." }, "agents": { "label": "Target Agents", "help": "Agent ids that use Hindsight memory. Empty means all agents." }, "budget": { "label": "Recall/Reflect Budget", "help": "Effort level for recall and reflect calls (low/mid/high). Higher costs more latency." }, "recallMaxTokens": { "label": "Recall Max Tokens", "help": "Hindsight's own token budget for a single recall call's results." }, "maxContextChars": { "label": "Max Injected Context Chars", "help": "Hard cap on the size of the injected memory block." }, "recallTimeoutMs": { "label": "Recall Timeout (ms)", "help": "Budget for the LLM-free recall on the reply path. On timeout the turn proceeds with no injected memory." }, "retainTimeoutMs": { "label": "Retain Timeout (ms)", "help": "Budget for the post-turn async retain call to Hindsight (off the reply path; async:true itself makes Hindsight's extraction non-blocking, this only bounds the HTTP request)." }, "minTextChars": { "label": "Minimum Text Chars", "help": "Skip recall/retain for text shorter than this." }, "retainMinTurnChars": { "label": "Retain Min Turn Chars", "help": "Skip the post-turn retain (a full 2nd Kimi call) for turns whose combined User/Assistant text is shorter than this — trivial acks carry no durable facts. 0 retains everything (kb#101 token-burn gate; default 48)." }, "types": { "label": "Recall Types", "help": "Fact types to recall: world, experience, observation. Defaults to world and experience." }, "injectHeader": { "label": "Inject Header", "help": "Header line prepended to the injected memory block." } } }