Protocol for pluggable memory backends (single, unified).
Backends can store files in different locations (state, filesystem, database, etc.) and provide a uniform interface for file operations.
All file data is represented as dicts with the following structure: { "content": list[str], # Lines of text content "created_at": str, # ISO format timestamp "modified_at": str, # ISO format timestamp }
BackendProtocol()abc.ABCList all files in a directory with metadata.
Async version of ls_info.
Read file content with line numbers.
Async version of read.
Search for a literal text pattern in files.
Async version of grep_raw.
Find files matching a glob pattern.
Async version of glob_info.
Write content to a new file in the filesystem, error if file exists.
Async version of write.
Perform exact string replacements in an existing file.
Async version of edit.
Upload multiple files to the sandbox.
This API is designed to allow developers to use it either directly or by exposing it to LLMs via custom tools.
Async version of upload_files.
Download multiple files from the sandbox.
This API is designed to allow developers to use it either directly or by exposing it to LLMs via custom tools.
Async version of download_files.