memory_stores
- a flexible tag-based system to track memories across conversations and participants into different buckets.
If a memory_stores
value is provided in the conversation creation request, memories will automatically be created and associated to the tag provided.
When defining
memory_stores
values, we recommend incorporating static values that will not change with persona updates, like persona ID.For example, using a persona’s name as part of your memory_stores
values could result in memories being miscategorized if you were to change their name.Basic Example
For example, if a participant named Anna starts a conversation with the persona (Charlie, with the persona IDp123
), we can specify memory_stores=["anna_p123"]
in the conversation creation request.
By doing so, Charlie will:
- Remember what was mentioned in a conversation and form new memories with Anna.
- Reference memories from previous conversations that Charlie had with Anna in new conversations.
Managing Memories Between Participants and Conversations
To prevent different personas from mixing up information for the same participant, we generally recommend you to create separate
memory_stores
values for each user when they talk to different personas.For example,`- When Anna talks to Charlie (persona ID of
p123
), you can use thememory_stores
value of["anna-p123"]
. - when she talks with Gloria (persona ID of
p456
), you can use thememory_stores
value of["anna-p456"]
.
memory_stores
system can be used flexibly to cover your use cases - they do not have to map 1:1 with your participants and instead can be designed for your unique use cases.
For example,
- If you were setting up an online classroom, you could use a
memory_stores
tag value of"classroom-1"
so any participant of this group could reference and create new memories to enhance and deepen learning and connections. - You can control whether you want personas to share memory or not (and if so, which personas) by passing them different
memory_stores
values.