Glossary
Agent file system
Persistent, isolated storage of files and folders that an AI agent can read, write, search and organise across sessions.
An agent file system is persistent storage, organised as files and folders, that an AI agent can read, write, search and reorganise through tool calls. It gives the agent somewhere to keep inputs, working notes and finished outputs between steps and between sessions, so the work survives after the context is cleared.
Why agents need persistent storage
A model only sees what is in its context window, and that is cleared at the end of each session. Anything the agent produced, from a draft report to a list of sources, disappears unless it was written somewhere. Agent memory covers facts and preferences about users. A file system covers the work itself: documents, uploaded files, agent artifacts and the notes an agent keeps in an agent scratchpad while it plans.
Files suit models well. Listing a folder, reading a file and writing a new one map onto a small set of tools that an agent can call through function calling or an MCP server. Long-running agents and background agents depend on this most, because their work spans many sessions and nobody watches each step.
What an agent file system needs
Storing bytes is the easy part. In production an agent file system needs four more things.
Isolation comes first. Each user, tenant or agent should get its own tree, so one agent cannot read or overwrite another customer’s files. Tenant isolation enforced by the storage layer is safer than a filter in application code, and it matters most where one product serves many customers through multi-tenancy.
Search comes second. Agents rarely know a filename. They know what a file is about, so the store needs file indexing that makes content searchable by meaning, with file metadata such as names, kinds and dates available for filtering.
Recovery is third. An agent with write access will eventually move, rename or delete the wrong thing. A filesystem snapshot, version history and soft delete make those mistakes visible and reversible, which is the basis of agent rollback. Inspection is the fourth: people need to see what an agent stored and changed without writing queries, so they can debug one run and trust the next.
Agent file system vs object storage and sandboxes
Aspect | Agent file system | Object storage | Sandbox filesystem |
|---|---|---|---|
Lifetime | Persists across sessions | Persists until deleted | Usually lasts as long as the sandbox |
Organisation | Folders, tags and metadata | Flat keys in buckets | Local directories |
Search | Indexed by content and metadata | By key or prefix | Whatever tools the agent runs |
Isolation | Per user, tenant or agent | Per bucket or prefix, set by policy | Per sandbox instance |
Recovery | Snapshots, version history and a bin | Bucket versioning, if enabled | Sandbox snapshots, where offered |
Object storage and blob storage often sit underneath, holding file contents cheaply at scale while a database holds the tree and metadata. A virtual file system presents the two through one interface. An agent sandbox is a different tool: it gives an agent somewhere to run code, and its disk is usually scratch space for that run. Exabase vs E2B walks through that split, and best file system for AI agents compares the main options.
Agent file systems in Exabase
Exabase Bases are isolated cloud filesystems that an application creates on demand, one per tenant, user, project or agent. One call to the create Base endpoint returns a Base with its own file storage, folders, tags, memory, search index and extraction pipeline, and the X-Exabase-Base-Id header scopes every later call to it. The about Bases guide and the Exabase filesystem guide cover the structure.
Inside a Base, files, notes, bookmarks, audio and video are stored as Resources and indexed when they are created, so an agent can find them through Deep Search by describing what it needs. Uploads go through a signed URL from the uploads endpoint, with files up to 5GB depending on plan. Exabase is used through its REST API and TypeScript SDK rather than mounted as a local drive, and it provides no code execution: the agent runs wherever you host it and calls the API for storage.
For recovery, filesystem snapshotting can be turned on per Base on paid plans. It records each resource’s name, location, description and deletion state, hourly for 24 hours and in six-hour windows up to 7 days, but not file content. Deleted resources stay in the bin for 30 days, and Agent undo describes the full pattern. Workers can run inside a Base on a schedule to tag, file and prune content, and the workspace explorer in the Exabase console shows everything an agent has stored. Why we built Bases as filesystems explains the design, and the agent context versioning use case shows it in practice.
FAQs
What is a file system for AI agents?
It is persistent storage organised as files and folders that an AI agent reads and writes through tools. It keeps the agent’s inputs and outputs available across steps and sessions, separately from the model’s context.
Is an agent file system the same as agent memory?
They store different things. Agent memory holds facts, preferences and events extracted from conversations, while a file system holds documents and outputs. Most production agents use both, and Exabase offers Memory alongside Bases in the same environment.
Can I use Amazon S3 as an agent file system?
S3 can hold the files, but you would build the folder model, indexing, search, isolation and recovery yourself. Exabase vs AWS S3 compares the two approaches.
Do agent file systems run code?
Usually not. Running code belongs to a sandbox or the agent’s own runtime. Exabase stores and searches an agent’s files and leaves execution to whatever environment the agent runs in.
How do you keep each customer’s files separate?
Give each customer an isolated tree of their own instead of sharing one tree with a tenant column. In Exabase that unit is a Base; the multi-tenant SaaS use case and the multi-tenant solution show the pattern.
How do you undo an agent’s changes to its files?
Record the file system’s state over time so you can see and restore what changed. Undo is the most important agent feature nobody built makes the wider case.
Related pages: Virtual file system, Agent workspace, Object storage, Blob storage, Agent artifacts, Filesystem snapshot, Bases, Agent undo, Best file system for AI agents, Why we built Bases as filesystems, AI agent.