Configuration Process
Below is a typical “memory write” scenario for variable assigner configuration:1. Define Session Variable Structure
Define a session variable namedmemories:
- Type:
array[object] - Purpose: Record facts, preferences, and historical data from user input.
2. Check for New Information
After user input, use a Conditional Node with LLM reasoning:- If new information is detected, take the upper branch.
- If no new information, take the lower branch and generate a response using existing memories.
3. Extract New Information
In the upper branch, add an LLM Node to extract user input into structured facts, e.g.:4. Variable Assigner/Memory Write
Use the Variable Assigner Node to append LLM output to thememories array:
- Operation: Select variable type as
array, operation asappend. - Content: Extract object from LLM output using variable reference (e.g.,
{llm.result}). - If LLM output is a string, convert to standard object structure before writing.
5. Read Memory in Subsequent Nodes
In subsequent LLM Nodes, concatenatememories content into a string for context input, e.g.: