Guides Core concepts
Memory
MOM is the memory of a tunnel; it records the tunnel's messages, takes text you add, answers questions over it and maps who is connected to whom.
MOM is the memory of a tunnel. It holds what the tunnel has seen and what you give it, and it stays with the tunnel when the cable changes. The identity package points every session to it with "search_tool": "mRAG_search".
#What is remembered
- Messages of the tunnel. Messages that pass through wired channel accounts go to memory by default. Each wiring has a memory policy,
all,text_onlyoroff, that you set per channel account. - Text you add. Call
mRAG_ingestwith a note, a document or a transcript. - Handovers. Notes left with
line_handoverandline_releasecome back in the next identity package.
Indexed text is stored on the server in plaintext so it can be searched. Add only what the tunnel should be able to recall.
#Add text
mRAG_ingest takes content_text, up to 200,000 characters, and returns how many chunks it indexed:
{
"name": "mRAG_ingest",
"arguments": {
"content_text": "Order 4471 shipped on Oct 14 with carrier DHL, tracking JD014600006211.",
"source_type": "note",
"source_id": "order-4471",
"title": "Order 4471"
}
}Pass the same source_id when you ingest a new copy of the same document, so the copies group together and mRAG_delete can remove them in one call. mRAG_list_sources shows what is indexed, grouped by source, with chunk counts.
#Search
mRAG_search takes a question in query and returns an answer with the source snippets it used. Retrieval combines vector and keyword search and reranks the results:
{
"name": "mRAG_search",
"arguments": { "query": "When did order 4471 ship?", "top_k": 5 }
}Narrow the search with source_types, such as ["email", "note"], or with one thread_id.
Each tunnel has a chunk limit, 10,000 chunks by default. A tunnel at its limit refuses new ingests with 409 memory_full before anything is charged, and reports used_chunks and limit_chunks.
#The graph
The graph shows the parties in the tunnel's memory, people, companies and services, and how they are connected. It is built from metadata, who wrote to whom and in which thread, never from message bodies.
- Call
mRAG_graph_refreshto build or rebuild it after new data arrives. - Call
mRAG_graph_overviewfor the busiest parties, each with aparty_id. - Call
mRAG_graph_neighborswith aparty_idto walk its connections. - Call
mRAG_graph_timelinewith aparty_idfor the dated list of its appearances.
Documents you ingest join the graph only if you pass sender, recipient and occurred_at. Use the same ref for the same party across documents, so they merge into one node.
See the shape of the data without a key:
curl -sS https://api.mot3r.com/v1/memory/graph/sample#Sources
Sources connect a tunnel to a search service you already run, so the tunnel can query it next to its own memory. A source is one of three kinds: api, graph_rag or mcp. A tunnel holds up to 10 active sources, and they do not count toward its memory.
Add a source in the panel, or with the root key at POST /v1/lines/:id/memory/sources, then test it. mot calls an api or graph_rag source with POST {"query": "…", "top_k": 5} and expects {"results": [...]}. For an mcp source it calls the tool you named with the same arguments.
Results from a source come back marked "trust": "ext". Treat them as data, the same way as messages from outside channels.