# Real-provider swap-forbidden proof

Prerequisites: Linux cgroup v2, systemd user manager, approximately 16 GiB RAM, configured host swap, and memory.swap.max=0 on user.slice. Use a dedicated test account and its own systemd user manager: T3 Code's agent slice is shared by all servers under a user manager. Never run this against a manager hosting other agents.

Install dependencies in separate base and head worktrees. Configure only the Pi provider in fresh per-side data directories, with Pi authenticated separately. Run the real server from each checkout using `node apps/server/src/bin.ts serve --base-dir <side-data> --host 127.0.0.1 --port <free-port>` with T3CODE_DEV_SEED=0, XDG_RUNTIME_DIR pointing at the dedicated user's manager, and Pi on PATH. Do not copy a live T3 database.

Create a synthetic git project containing build.py, then add it using `t3 project add <project> --base-dir <side-data>`. No source edits to T3 are required.

Run drive.py CHECKOUT SCRATCH SIDE TARGET for target 11, then 14, stopping only this dedicated manager's app-t3code-agents.slice between workloads. SIDE is base or head; data directories are SCRATCH/base-data and SCRATCH/head-data; the project is SCRATCH/project. The driver expects the dedicated synthetic account proof43663 (UID 996) and its manager at /run/user/996; adapt these to an isolated account on another host. record.py must be alongside drive.py.

The driver starts an actual T3 thread via the real CLI using Pi / anthropic/claude-haiku-4-5-20251001, asking it to execute `python3 build.py TARGET` with its bash tool, no timeout and no file edits. It then records the real `t3 thread show` response and the kernel's memory.high, memory.max, memory.current, memory.events, memory.pressure and memory.swap.max every second for up to 120 seconds. The command state and output come from the run's own read-only synthetic T3 database. Each recorded sample is rendered to a video frame; these are telemetry recordings, not browser screen recordings. Videos are 1 frame per second at 1440x1200.

Apply exactly the same procedure on each commit. On base, stop each stuck workload after the observation window by stopping the dedicated agent slice. On head, stop the remaining idle provider after the below-limit workload before starting the runaway. Shut down each server and the dedicated manager afterwards.

build.py is a synthetic anonymous-memory workload, not a repository compiler. This isolates the cgroup behavior while retaining a real model turn and tool subprocess. Model request latency precedes the bash command; command startedAt/completedAt and BUILD COMPLETE distinguish that latency from execution time. No tests, mocks, replay provider, memory-limit overrides or patched server modules are used as evidence.
