Contents

Memory Tools

memory_tools · Nodes · AI

Exposes memory operations as tools for AI steps.

Memory Tools#

Gives an AI node selected memory tools.

Config:

  • namespaces: the namespaces these tools may read and write: {"kind":"all"} for every namespace, including ones created later, or {"kind":"only","namespace_ids":["01…"]} for chosen ones. A chosen id whose namespace was deleted is ignored. Defaults to all.
  • tool_name: optional AI-visible tool name prefix. Enabled tools become {tool_name}_get, {tool_name}_search, {tool_name}_insert, {tool_name}_update, {tool_name}_delete, {tool_name}_link_add, and {tool_name}_link_remove.
  • properties: default filter for search and update
  • call_filter_mode: how default and call-time filters combine
  • insert_properties: default concrete properties applied on insert, as key/value rows
  • get: enable memory_get, which reads one specific memory by ULID memory id
  • search: enable memory_search, which searches memory by text query
  • insert: enable memory_insert, which stores a new memory
  • update: enable memory_update, which updates one specific memory by ULID memory id
  • delete: enable memory_delete, which deletes one specific memory by ULID memory id
  • link_add: enable memory_link_add, which records provenance, relates two memories, or supersedes an older memory
  • link_remove: enable memory_link_remove, which removes a link by value
  • namespace_list: enable memory_namespace_list, which lists the namespaces in namespaces with their ids and descriptions
  • namespace_create: enable memory_namespace_create, which creates a namespace. A namespace it creates outside a chosen namespaces list stays outside it

Every switch defaults off on the node. memory_namespace_list and memory_namespace_create keep their fixed names; tool_name never prefixes them.

Tool calls cannot change provider, model, connection, or the configured namespaces. They embed with the workspace's embedding model, chosen in Memory › Embedding model. With no model chosen, a call that embeds fails with No embedding model configured. Choose one in Memory › Embedding model; a model or namespace_id field in an older saved config is ignored. A memory id outside namespaces or the properties filter fails with the same memory unit not found error as an id that does not exist. memory_search searches every namespace in namespaces. Use tool_name when connecting multiple memory tool nodes with different namespaces to the same AI node.

AI-facing memory terms:

  • links: where the memory came from and how it relates to other memories.
  • initial_relevancy: write-time signal quality/usefulness. This is not search confidence.
  • half_life_seconds: durability. Shorter for volatile knowledge; longer or omitted for stable knowledge.
  • current_relevancy: computed relevancy after decay.
  • semantic_score: query match score returned by search.

Tool calls may add property filters. memory_insert merges configured insert_properties with call-time properties. insert_properties values accept JSON scalars or scalar arrays. memory_update.properties replaces the full property object.

Tool Call Contracts#

memory_get requires id: the ULID id of a specific memory unit returned by memory_search or memory_insert. It is not a namespace, topic, slug, label, or natural-language query. Use memory_search first when you do not already have a memory id.

{
  "id": "01J00000000000000000000000"
}

memory_search requires query.

{
  "query": "alpha",
  "limit": 10,
  "min_semantic_score": 0.3,
  "min_current_relevancy": 0.5,
  "include_superseded": false,
  "properties": {
    "mode": "all",
    "all": [{ "op": "eq", "key": "kind", "value": "note" }],
    "any": []
  }
}

Superseded memories are hidden from search by default because a newer memory has replaced them. Set include_superseded to reach the older record deliberately. memory_get always resolves, superseded or not.

memory_insert requires namespace_id, title and text. namespace_id is the ULID of a namespace in namespaces, from memory_namespace_list. With no namespace in the workspace the call fails with No namespaces exist. Create one before inserting a memory; a namespace outside namespaces fails with an error naming it. title is a short label for the memory, trimmed, non-blank, and at most 255 characters. links is optional and accepts source links only; related and supersedes name a memory that does not exist yet at insert time, so add those afterwards with memory_link_add.

{
  "namespace_id": "01J00000000000000000000002",
  "title": "Alpha notes",
  "text": "alpha",
  "links": [
    { "relation": "source", "source": { "kind": "table_row", "value": { "table_id": "01J00000000000000000000000", "row_id": "row-1" } } }
  ],
  "initial_relevancy": 1,
  "half_life_seconds": 86400,
  "properties": { "kind": "note" }
}

memory_link_add and memory_link_remove require memory and link. A link is a value, so removal takes the whole link rather than an identifier.

{
  "memory": "01J00000000000000000000000",
  "link": { "relation": "supersedes", "source": { "kind": "memory", "value": "01J00000000000000000000001" } }
}

Use supersedes when new information corrects an older memory. The older memory stops appearing in memory_search and in recall, but stays readable through memory_get, and becomes active again if the link is removed. Both endpoints of a link must be inside the configured namespaces and property scope.

memory_get and memory_search return the memory under memory, with superseded_by and links beside it. superseded_by names the newer memory when one replaces this one; follow it with memory_get to read the correction.

memory_update requires id. title replaces the title; changing text keeps the existing title.

{
  "id": "01J00000000000000000000000",
  "title": "Alpha notes v2",
  "text": "alpha v2",
  "initial_relevancy": 0.8,
  "half_life_seconds": null,
  "properties": { "kind": "note", "source_id": "doc-1" },
  "filter_properties": {
    "mode": "all",
    "all": [{ "op": "eq", "key": "kind", "value": "note" }],
    "any": []
  }
}

memory_delete requires id.

{
  "id": "01J00000000000000000000000"
}

Use memory_recall when you want deterministic context. Use this node when the AI should pick memory tools itself.

Inputs

  • inputRequired

Outputs

  • tools

Configuration

FieldTypeRequiredDescription
namespacesnamespace_scopeNoMemory namespaces the tools may read and write
tool_namestringYesOptional AI-visible tool name prefix. Enabled tools become {prefix}_get, {prefix}_search, etc.
propertiesrecordNoDefault property filter for search and update tools
call_filter_modeenum(all, any)NoHow default and call-time property filters combine
insert_propertiesarray<record>NoDefault concrete properties merged into inserted memories
getbooleanNoEnable memory_get: read one specific memory by ULID memory id
searchbooleanNoEnable memory_search: search memory by text query
insertbooleanNoEnable memory_insert: store a new memory
updatebooleanNoEnable memory_update: update one specific memory by ULID memory id
deletebooleanNoEnable memory_delete: delete one specific memory by ULID memory id
link_addbooleanNoEnable memory_link_add: record provenance, relate two memories, or supersede an older memory
link_removebooleanNoEnable memory_link_remove: remove a link by value
namespace_listbooleanNoEnable memory_namespace_list: list the namespaces these tools reach. Its name never takes the tool name prefix
namespace_createbooleanNoEnable memory_namespace_create: create a namespace. Its name never takes the tool name prefix
base_configrecordNoShared node configuration. failure_mode decides what a failure of this node does to the workflow; leave it at the default stop unless the workflow handles the failure itself on the node's error output (route_to_error) or the node is a rare emergency kill switch (stop_workflow).