If you use NotebookLM, you know the agent runs code. It executes Python, builds charts, writes files back to your notebook. I wanted to know what that execution environment actually is, so I asked the agent itself to map it from the inside.
It did, thoroughly. And one thing worth noting up front: the agent runs on Gemini Neon (I selected Neon in the UI), and the same model refused this exact kind of probing when I tried it in Gemini Tasks. In NotebookLM it just got to work. Same model, different product, different behavior — the permissiveness lives in the harness, not the weights.
A few honest caveats before the findings: the systrap identification below is an inference from timing, not a proven fact. The .proto schema is a reconstruction from the binary's embedded descriptor, not a file Google shipped. Everything else is measured from inside the running cell.
The thing running your code is a 13.8 MB Go binary. `/usr/bin/entry/entry_point`, 16,958 symbols, full DWARF debug tables, built from `google3/assistant/boq/lamda/execution_box`. It runs as PID 1, as uid 1000 (`sandbox`), with zero capabilities. It has two roles depending on how it's invoked: as `entry_point` it's the supervisor, listening on TCP `192.168.1.1:8888`; as `interpreter_callback` it's the client that talks to the shell. One binary, two jobs, decided by `os.Args[0]`.
The wire protocol was reconstructed from the binary itself. At offset `0x18399` in the binary's read-only data sits the compiled `FileDescriptorProto`, and from it we rebuilt the full `sandbox_rpc.proto` in Google's internal `editions` syntax. The host talks to the orchestrator over length-prefixed protobuf frames on port 8888. The schema has a tell: field 3 is skipped in the `SandboxIn` envelope, which is where `RunToolRequest` used to live before it was removed. And there's a detail NotebookLM users will recognize: the error enum has `ALTAIR_SCHEMA_VALIDATION_ERROR = 112`, a dedicated validation error for Vega/Altair chart generation. The RPC contract knows about the charts your notebook produces. There's also a field for differential file sync, which is how the orchestrator diffs the filesystem and streams changed files back to the host — that's how your outputs get back to you.
Your commands run through a Unix socket, not SSH or HTTP. PID 1 exposes `/tmp/icb<id>/cb.sock`. A stateful bash subshell (PID 11, `-bash -ic`) pulls commands through it with two 39-byte helper scripts: `poll` dials the socket, receives the injected command, and evals it; `cut` dials back, sends the numeric exit code, and half-closes the connection. The callback ID in the path is regenerated per invocation.
The sandbox is gVisor, and the numbers show it. A `getpid` syscall averages about 1,206 ns, roughly ten times native and an order of magnitude slower than bare metal — consistent with the systrap platform engine, though that's an inference from timing, not proof. CPUID on the hypervisor leaf returns all zeros; Sentry synthesizes the CPUID responses. Yama ptrace scope is 1: attaching to PID 1 fails with `EPERM` even though we share uid 1000, while tracing a child process works fine. The persistent `/workspace` — the only durable storage your notebook has — is mediated over Plan 9 (9P) via host file descriptor 9, with mmap/msync flush latency around 56.3 µs. The network has zero egress routes, so outbound connections fail with `ENETUNREACH`. That's why the agent can't just fetch a URL from inside the cell. Memory is 8 GiB with about 7.8 GiB usable, and when the ceiling is hit the container is recycled from outside with no `ENOMEM` and no OOM killer.
The image has no gdb or objdump. I checked that against the full 661-package dpkg list rather than assuming it. That's why the agent wrote standalone Python scripts with ctypes, mmap, and struct unpackers whenever it needed to inspect memory or parse a binary.
So the short version: your notebook's code runs in a real gVisor sandbox, driven by an unstripped Go orchestrator over a protobuf control channel, with no network egress and only `/workspace` persisted. And the agent living in that sandbox was happy to hand me the map of its own cage.
Full repo with the reconstructed .proto, the probe scripts, and the raw procfs captures:
https://github.com/sys-dissect/gemini-notebook-sandbox-architecture