Edit Memory
edit_memoryReplace content in memory files using literal strings or regex patterns to update stored information.
Instructions
Replaces content matching a regular expression in a memory.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"memory_file_name": "<memory_file_name>",
"needle": "<needle>",
"repl": "<repl>",
"mode": "<mode>"
},
"name": "edit_memory"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| memory_file_name | Yes | The name of the memory. | |
| needle | Yes | The string or regex pattern to search for. If `mode` is "literal", this string will be matched exactly. If `mode` is "regex", this string will be treated as a regular expression (syntax of Python's `re` module, with flags DOTALL and MULTILINE enabled). | |
| repl | Yes | The replacement string (verbatim). | |
| mode | Yes | Either "literal" or "regex", specifying how the `needle` parameter is to be interpreted. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |