Skip to content

[POC] Add native environment io tools#22699

Draft
lt-oai wants to merge 1 commit into
mainfrom
lt/native-io-poc
Draft

[POC] Add native environment io tools#22699
lt-oai wants to merge 1 commit into
mainfrom
lt/native-io-poc

Conversation

@lt-oai
Copy link
Copy Markdown
Contributor

@lt-oai lt-oai commented May 14, 2026

Why

Ground the environment file I/O proposal in the existing Codex environment/filesystem code path instead of introducing a separate MCP server per environment.

What

  • Add an experimental native io namespace gated by model experimental_supported_tools: ["io"].
  • Register filesystem-MCP-shaped P0 tools: read_file, write_file, edit_file, create_directory, list_directory, get_file_info, and list_allowed_directories.
  • Route calls through the selected turn environment ExecutorFileSystem, so local environments use LocalFileSystem and remote environments use RemoteFileSystem / exec-server fs/* methods.
  • Add a remote routing test that writes different local/remote files and verifies io.read_file reads from the selected remote environment.

Testing

  • cargo fmt
  • cargo test -p codex-core io_namespace_registers_for_experimental_supported_tool
  • cargo test -p codex-core io_read_file_routes_to_selected_remote_environment

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant