nodes / builtin / ai / aidependencies / chatmemories
Chat Memory
Lets an agent remember the conversation, across runs or within one run
Lets an agent remember the conversation, across runs or within one run.
What it does
Section titled “What it does”Chat Memory gives an agent a conversation history. Plug it into the Memory slot of a Tools Agent, a RAG Agent or a Chat Trigger. Before calling the model, the agent reads the earlier messages from the memory; after answering, it saves your message and its reply.
Conversations are stored in your browser, on this device. Every saved conversation is listed on the Memory page, where you can read, search, export or clear it.
- With a Chat Trigger, connect the same Chat Memory to the trigger and to its agent. The chat window then shows the history and reopening it continues the conversation. With This run only, or a Key that is an expression, the conversation isn’t known before a run, so the chat window keeps no history.
- When you publish or share the workflow, the picked Conversation is cleared (it only exists on your device). Whoever installs it gets a fresh, empty conversation. Keys are kept.
- When you delete a workflow, AWFlow offers to delete its own conversations. Shared keys, and conversations another workflow uses, are kept.
It replaces Local Memory, Persistent Chat Memory and Window Buffer Memory. Workflows that use them keep working and are turned into Chat Memory when you save them:
| Old node | Becomes Chat Memory with |
|---|---|
| Local Memory | Conversation storage, the same conversation. |
| Persistent Chat Memory | Key storage, the same key, Shared scope. |
| Window Buffer Memory | This run only, Last N messages with N = 2 × the old window size. |
When to use it
Section titled “When to use it”- A chatbot built with a Chat Trigger.
- An agent that runs again and again (on a schedule, on page load) and should remember earlier runs.
- One conversation per user or per thread, with a key such as
{{ $input.userId }}. - An agent that calls several tools in one run and should remember the exchange only for that run.
Inputs and settings
Section titled “Inputs and settings”6 choices · pick storage and history sent to the model to see its settings
Settings for Conversation · As much as fits
| Setting | Type | What it does |
|---|---|---|
| Conversation | Memory picker | The saved conversation to use. Leave empty to give this node its own conversation in this workflow. |
| Summarise older messages | Toggle | Messages that no longer fit are folded into a short summary the model still sees. Costs an extra model call now and then. Default: On |
| Remember tool results | Toggle | Keep what the agent’s tools returned with each reply, so later turns can use it without calling the tools again. Default: On |
Settings for Conversation · Last N messages
| Setting | Type | What it does |
|---|---|---|
| Conversation | Memory picker | The saved conversation to use. Leave empty to give this node its own conversation in this workflow. |
| Messages | Number | How many of the newest messages to send (a question and its answer are two). Default: 20 |
| Summarise older messages | Toggle | Messages that no longer fit are folded into a short summary the model still sees. Costs an extra model call now and then. Default: On |
| Remember tool results | Toggle | Keep what the agent’s tools returned with each reply, so later turns can use it without calling the tools again. Default: On |
Settings for Key · As much as fits
| Setting | Type | What it does |
|---|---|---|
| Key | Text | Runs with the same key share one conversation. Use an expression for one conversation per user or thread. |
| Key scope | Choice | Whether other workflows using the same key share this conversation. Options: This workflow, Shared. Default: This workflow |
| Summarise older messages | Toggle | Messages that no longer fit are folded into a short summary the model still sees. Costs an extra model call now and then. Default: On |
| Remember tool results | Toggle | Keep what the agent’s tools returned with each reply, so later turns can use it without calling the tools again. Default: On |
Settings for Key · Last N messages
| Setting | Type | What it does |
|---|---|---|
| Key | Text | Runs with the same key share one conversation. Use an expression for one conversation per user or thread. |
| Key scope | Choice | Whether other workflows using the same key share this conversation. Options: This workflow, Shared. Default: This workflow |
| Messages | Number | How many of the newest messages to send (a question and its answer are two). Default: 20 |
| Summarise older messages | Toggle | Messages that no longer fit are folded into a short summary the model still sees. Costs an extra model call now and then. Default: On |
| Remember tool results | Toggle | Keep what the agent’s tools returned with each reply, so later turns can use it without calling the tools again. Default: On |
Settings for This run only · As much as fits
| Setting | Type | What it does |
|---|---|---|
| Summarise older messages | Toggle | Messages that no longer fit are folded into a short summary the model still sees. Costs an extra model call now and then. Default: On |
| Remember tool results | Toggle | Keep what the agent’s tools returned with each reply, so later turns can use it without calling the tools again. Default: On |
Settings for This run only · Last N messages
| Setting | Type | What it does |
|---|---|---|
| Messages | Number | How many of the newest messages to send (a question and its answer are two). Default: 20 |
| Summarise older messages | Toggle | Messages that no longer fit are folded into a short summary the model still sees. Costs an extra model call now and then. Default: On |
| Remember tool results | Toggle | Keep what the agent’s tools returned with each reply, so later turns can use it without calling the tools again. Default: On |
Showing settings for Conversation · As much as fits
The fields change with Storage and History sent to the model.
Storage decides where the conversation is kept:
| Storage | The conversation… | Good for |
|---|---|---|
| Conversation (default) | is one saved conversation: the one you pick in Conversation, or this node’s own when you pick none. | A single chatbot, a recurring agent. |
| Key | is named by Key. Every run with the same key continues the same conversation. | One conversation per user, per ticket, per page. |
| This run only | lives only while the workflow runs. Nothing is saved. | Multi-step reasoning inside one run. |
Key scope (with Key): This workflow (default) keeps the key private to this workflow, so two workflows using inbox don’t mix. Shared lets several workflows continue the same conversation.
History sent to the model:
- As much as fits (default): the newest messages that fit the connected model’s context window, keeping room for the reply.
- Last N messages: at most Messages messages (20 by default; a question and its answer are two).
Summarise older messages (on by default): messages that no longer fit are folded into a short summary the model still sees. It costs an extra model call now and then.
Remember tool results (on by default): the agent’s tool calls and results are saved with its replies, so a later message can refer to them (“what was the price you found?”) without running the tools again.
Outputs
Section titled “Outputs”This node has no output port. It plugs into a slot on another node instead of passing items along.
- Memory slot of Chat Trigger, Tools Agent, RAG Agent
Chat Memory has no output. It hands its memory to the node it is connected to.
Dependencies and credentials
Section titled “Dependencies and credentials”None. This node needs no connection and has no slots for other nodes.
Example workflow
Section titled “Example workflow”- A Chat Trigger with Assistant name
Shopping helper. - A Tools Agent with Prompt
{{ $input.chatInput }}, a chat model such as Chat OpenAI in its Model slot, and Web Search in its Tools slot. - One Chat Memory, Storage
Conversation, connected to both the Chat Trigger’s and the agent’s Memory slot. - Chat with it: ask for a product, then “which one was cheapest?”. The agent remembers the earlier answer and its search results.
Common issues
Section titled “Common issues”- The agent forgets between runs. Storage is This run only, which forgets everything when the run ends. Use Conversation or Key.
- “Pick a conversation, or save the workflow to give this memory its own.” With Conversation storage and none picked, the node needs a saved workflow. Save it, or pick a conversation.
- “Conversation Key is required”. Storage is Key but Key is empty, or its expression gave nothing. Fill it in.
- “This workflow is not saved yet, so the key cannot be scoped to it: memory lasts for this run only.” Save the workflow so a This workflow key can be kept.
- The chat window stays empty. The trigger and the agent must use the same Chat Memory node, with Conversation storage or a fixed Key.
Related nodes
Section titled “Related nodes”- Chat Trigger: a chat window that runs your workflow.
- Tools Agent and RAG Agent: the agents that accept it.
- Memory page: read, slim, export or clear saved conversations.
- Memory & Context: how memory and context windows work.