Filesystem MCP Server#
The Filesystem MCP server is maintained by Anthropic. It provides primitive file-system tools (read, write, list, search) that the Planner Agent uses to handle user uploads, write supplementary SUMO configuration files, and inspect generated artifacts.
Official documentation#
github.com/modelcontextprotocol/servers/tree/main/src/filesystem
Tools used by AgentSUMO#
The server exposes thirteen tools across three categories, matching the layout in Figure 3 of the paper.
Category |
Tool |
Purpose |
|---|---|---|
Read |
|
Read a text file’s contents. |
Read |
|
Read a binary media file (returns base64). |
Read |
|
Batch-read several files in one call. |
Read |
|
List the entries of a directory. |
Read |
|
List entries together with file sizes. |
Read |
|
Recursive JSON tree of a directory. |
Read |
|
Find files by name pattern. |
Read |
|
Retrieve file metadata (size, mtime, permissions). |
Read |
|
List the directories the server is configured to access. |
Write |
|
Write or overwrite a file. |
Write |
|
Apply line-based edits to an existing file. |
Write |
|
Create a directory (idempotent). |
Manage |
|
Move or rename a file. |
How AgentSUMO uses it#
The Filesystem MCP server is launched at AgentSUMO startup with access
restricted to the project working directory: the output/ tree, the
agentsumo/agent/additional_files_guide/ markdown guides, and any
user-supplied data files explicitly placed in the project tree.
Three concrete patterns:
Reading user uploads. When a user provides an OD matrix as a CSV file, the Planner Agent reads it via
read_text_fileto verify column structure and coordinate format before passing the path totrip_generate.Writing supplementary XML configurations. Many SUMO policy interventions are temporal or conditional (e.g., time-based road closures, variable speed limits, fleet composition changes). These are implemented through supplementary XML files loaded alongside the network at simulation time. The agent writes these files via
write_file, guided by three markdown guides bundled with AgentSUMO (rerouter.md,vss.md,vtype.md). The generated files are passed tosumo_runnerthrough itsadditional_filesparameter.Inspecting generated artifacts. After tool execution, the agent uses
list_directoryandread_text_fileto verify output and diagnose errors before reporting back to the user.