Memory Write

Add a document to a Memory Store

What is a Memory Write Step?

The Memory Write step allows you add content to an existing Memory Store. You can add both searchable content which will be converted into embeddings and metadata content which can be retrieved and filtered on.

Learn how to set up an AirOps Memory Store here.

How to Configure the Memory Write Step

Select a Memory Store

Select the name of your Memory Store from the dropdown.

Text

The file, text, or data you want to make searchable.

Metadata

Metadata that you want to assign to the embeddings in a JSON format such as:

{
    "title": "...",
    "description": "...",
    "tag": "..."
}

Metadata allows you toin the Memory Search Step

Memory Write for Maintaining State

One challenge in managing workflows with LLMs is ensuring continuity by keeping track of past decisions. For example, in creating a workflow that leverages a LLM to scour a website for "recent news" to suggest content ideas, it's crucial to have a mechanism in place for logging previous suggestions. This helps prevent the recurrence of ideas, maintaining the novelty and relevance of the content generated.

Memory Stores can we help with this. By implementing the following framework you can solve this issue :

Before starting, create a new, empty Memory Store. Then, in your workflow, add the following :

  1. Memory Store Search Step - Search Memory Stores for today's date. It will retrieve the most recent entries added to that Memory Store.

  2. LLM Step - Provide ~5-10 outputs from the Memory Store Search Step to your model with a prompt like "Here are outputs you have provided previously, please do not repeat any of these ideas:"

  3. Memory Store Write Step - Write to the Memory Store with today's date (see Liquid docs for more info) in the search column and add the output in a metadata column. This will mean that only the date will be used when the Memory Store is searched.

Any question, please contact us.

Last updated