Skip to content

The fastest, cheapest, most efficient open-source agent harness. Run more than 500 agents on a $10 VPS.

docs(bench): finish the scenario cleanup the restore left half-done\n\nThree leftovers, all from restoring `library-profile` after having written the\nprose for a world where it was deleted.\n\nThe `rss-bench` target comment still said the `library-profile` bins "are gone\nwith it" — written when only `rss-bench` was coming back, and contradicted\nfourteen lines below by the `[[bin]] library-profile` block itself. What went\nis two of its *scenarios*, not the target, and the comment now says that and\npoints at the target's own note rather than repeating it.\n\n`docs/library-benchmarking.md` still called the set "eight scenarios" with four\nrows in the table, and both it and `scripts/profile/README.md` still told the\nreader to run `subagents` — including in the escalation path's `vmmap` /\n`MallocStackLogging` recipes, which are instructions someone follows today, not\na record. Those are `subagent-storm` now, and the counts match the table.\n\nThe measurement tables further down keep every scenario name they were recorded\nunder, `subagents` and `memory-ingest` included. They are a log of what was\nmeasured when; rewriting them to match today's binary would turn a record into\na claim about a run that never happened.\n

Shanu541f633872cb
diff --git a/Cargo.toml b/Cargo.toml
index 547a8c19ab..c6de01cb84 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -58,13 +58,13 @@ required-features = ["http-server", "bin-tools"]
# `rss-bench` feature so no benchmark code enters the shipped build. Build with
# `cargo build --release --features rss-bench --bin rss-bench`.
#
-# It survives the engine removal because it never measured the engine. The
-# `library-profile` bins that shared this gate did — they embedded
-# `tinymemory-core` in-process, which is why the feature used to name the engine
-# crates — and they are gone with it. This one builds an `Agent` roster over its
-# own in-file `NoopMemory` and samples RSS; its own doc comment explains that it
-# hand-rolls that rather than asking the factory, because
-# `create_memory(backend = "none")` never returned a no-op backend.
+# It survives the engine removal because it never measured the engine: it builds
+# an `Agent` roster over its own in-file `NoopMemory` and samples RSS, and its
+# own doc comment explains that it hand-rolls that store rather than asking the
+# factory, because `create_memory(backend = "none")` never returned a no-op
+# backend. What the feature used to name the engine crates for was two
+# `library-profile` *scenarios* — see that target's comment below; the binary
+# itself is still here.
[[bin]]
name = "rss-bench"
path = "src/bin/rss_bench.rs"
diff --git a/docs/library-benchmarking.md b/docs/library-benchmarking.md
index de3899d01a..d191fc18f8 100644
--- a/docs/library-benchmarking.md
+++ b/docs/library-benchmarking.md
@@ -11,14 +11,14 @@ subconscious pass, a memory ingest, a bare embed) that each have their own
startup cost, steady-state footprint, and growth curve.
This document describes the benchmark environment built to measure that: a
-pinned `library-profile` binary with eight scenarios, four driver scripts
+pinned `library-profile` binary with six scenarios, four driver scripts
under `scripts/profile/`, and the comparison point the team cares about
(ZeroClaw). It builds on the manual investigation in
[`docs/resource-profiling-session-2026-07-21.md`](resource-profiling-session-2026-07-21.md);
read that document for the deep memory/CPU attribution work. This document is
about running repeatable benchmarks, not re-deriving those findings.
-## The eight scenarios
+## The scenarios
All scenarios run in `target/release/library-profile <scenario>`, replace
network inference with a deterministic provider (`rss-bench` feature), and
@@ -55,15 +55,15 @@ Six scripts under `scripts/profile/` (each has `-h`/`--help`):
```bash
./scripts/profile/library-bench.sh # default build, all scenarios
./scripts/profile/library-bench.sh --slim # --no-default-features recipe
- ./scripts/profile/library-bench.sh --scenarios "long-agent,subagents" --turns 50 --warm
+ ./scripts/profile/library-bench.sh --scenarios "long-agent,subagent-storm" --turns 50 --warm
```
- **`library-cpu.sh`** — a `samply` wrapper for one scenario's CPU profile,
isolated from persistence/timezone noise by default.
```bash
- ./scripts/profile/library-cpu.sh subagents
- samply load target/profile/rust-library/subagents-cpu.json.gz
+ ./scripts/profile/library-cpu.sh subagent-storm
+ samply load target/profile/rust-library/subagent-storm-cpu.json.gz
```
- **`library-heap.sh`** — builds the `rss-bench-dhat` variant and runs a
@@ -126,7 +126,7 @@ behavior, not linked code size.
| Variable | Effect |
| --- | --- |
| `OPENHUMAN_PROFILE_TURNS` | Turn count for `long-agent` (default 25). |
-| `OPENHUMAN_PROFILE_PREWARM_SUBAGENTS=1` | Run one warm-up turn before measuring (`subagents`/`subconscious`), isolating first-use cost from steady state. |
+| `OPENHUMAN_PROFILE_PREWARM_SUBAGENTS=1` | Run one warm-up turn before measuring (`subagent-storm`), isolating first-use cost from steady state. |
| `OPENHUMAN_PROFILE_DISABLE_MEMORY_WRITES=1` | Disable `memory.auto_save` and episodic capture, isolating orchestration from persistence. |
| `OPENHUMAN_PROFILE_FORCE_UTC=1` | Skip `iana_time_zone`/CoreFoundation timezone resolution. |
| `OPENHUMAN_PROFILE_HOLD_SECS` / `HOLD_BEFORE_SECS` | Pause the process at settled/baseline state for external inspection (`vmmap`, `heap`, `malloc_history`, Instruments). |
@@ -272,12 +272,12 @@ Start cheap, escalate only as needed:
4. **Instruments / `vmmap` / `heap` / `malloc_history`** — deepest macOS-native attribution, using the `OPENHUMAN_PROFILE_HOLD_SECS` / `HOLD_BEFORE_SECS` hooks to pause the process at baseline or settled state:
```bash
- OPENHUMAN_PROFILE_HOLD_SECS=120 target/release/library-profile subagents &
+ OPENHUMAN_PROFILE_HOLD_SECS=120 target/release/library-profile subagent-storm &
vmmap -summary <pid>
heap -sH <pid>
MallocStackLogging=1 OPENHUMAN_PROFILE_HOLD_SECS=120 \
- target/release/library-profile subagents &
+ target/release/library-profile subagent-storm &
malloc_history <pid> -allBySize
```
diff --git a/scripts/profile/README.md b/scripts/profile/README.md
index 58022d06bc..9f4a942e71 100644
--- a/scripts/profile/README.md
+++ b/scripts/profile/README.md
@@ -20,9 +20,9 @@ process, and aggregates median/min/max duration, settled RSS, retained delta,
and peak delta into `summary.json` + `summary.md`.
```bash
-./scripts/profile/library-bench.sh # all 7 scenarios, default build, 5 repeats
+./scripts/profile/library-bench.sh # all 6 scenarios, default build, 5 repeats
./scripts/profile/library-bench.sh --slim --repeat 7 # slim (no-default-features) build
-./scripts/profile/library-bench.sh --scenarios "long-agent,subagents" --turns 50 --warm
+./scripts/profile/library-bench.sh --scenarios "long-agent,subagent-storm" --turns 50 --warm
```
Results land in `target/profile/rust-library/bench-<timestamp>/` (or `--out DIR`).
@@ -33,9 +33,9 @@ Wraps `samply record` around one scenario, isolated from persistence/timezone
noise by default (matching the documented cold-path CPU recipe).
```bash
-./scripts/profile/library-cpu.sh subagents
+./scripts/profile/library-cpu.sh subagent-storm
./scripts/profile/library-cpu.sh long-agent -- OPENHUMAN_PROFILE_TURNS=50
-samply load target/profile/rust-library/subagents-cpu.json.gz
+samply load target/profile/rust-library/subagent-storm-cpu.json.gz
```
### `library-heap.sh` — live heap attribution via dhat
@@ -118,10 +118,10 @@ runners don't false-fail.
./scripts/profile/library-bench.sh
# 2. CPU attribution for the slowest/most interesting scenario
-./scripts/profile/library-cpu.sh subagents
+./scripts/profile/library-cpu.sh subagent-storm
# 3. If a scenario's RSS looks off, drill into live heap
-./scripts/profile/library-heap.sh subagents
+./scripts/profile/library-heap.sh subagent-storm
```
All scripts require `jq` for JSON parsing/aggregation; `library-cpu.sh` also