Files
deepseek-harness/packages/e2b
creatixchu 97a9ec5a0e fix(review): bound E2B readBytes at the seam, prove conditional-registration disposal, and align read_image contracts
- E2BFileSystem.readBytes now short-circuits on the stat size before any
  content transfer and streams the remote object, cancelling at the first
  chunk past the cap, honoring the seam's bounded-buffering contract; the
  fs-e2b README pair documents the new primitive.
- The tool-fs HMR test now proves the attachments-scoped registration:
  disposing the store withdraws read_image while read/write/edit stay,
  remounting restores it, and disposing the plugin withdraws everything.
- read_image caps reads at the smaller of maxImageBytes and
  maxMessageImageBytes, records an absent observation for a missing
  target like its sibling read, widens the mismatch remedy to cover
  out-of-family formats, and renames the gate's parameter to
  requestedPath; module/apply/registration JSDoc now match the shipped
  composition. zh terminology aligned; the examples manifest keeps its
  literal arrow.
2026-08-10 15:35:33 +08:00
..

e2b/ — E2B remote runtime family

English | 中文

An experimental provider-composition POC that places one filesystem/process execution world in an E2B Linux sandbox. E2B supplies only sandbox lifecycle and the two fundamental OS adapters; provider-neutral consumers build higher capabilities above them.

Package ctx key Role
e2b (@deepseek-ai/dsh-e2b) ctx.e2b Create one sandbox, prepare its working/runtime directories, expose the shared SDK handle, and delete it on timeout or disposal
fs-e2b (@deepseek-ai/dsh-fs-e2b) ctx.fs Implement the filesystem seam over E2B Filesystem APIs
subprocess-e2b (@deepseek-ai/dsh-subprocess-e2b) ctx.subprocess Implement executable lookup, managed process groups and stdio, remote spill files, and terminal sessions over E2B Commands and PTY APIs

The existing dsh-bash-local, dsh-pty-local, and dsh-lsp-local need no E2B-specific forks. They delegate every execution-world operation to ctx.fs and ctx.subprocess, so mounting the two E2B adapters places their mutable work in the same sandbox.

This boundary does not move the harness process, Cordis objects, model calls, agent/session state, session persistence, skills, higher-level protocol state, or E2B SDK buffers. The portable execution-world decision owns both the generic composition and this POC boundary.