Revelin7Revelin7
All work
Lab note

The Benchmark Harness and Its Baseline

Three tiers, a fixed seed and a 10% regression gate on p99. The checked-in baseline, engine only: similarity recall at 273 microseconds p50 on 1,000 memories and 330 on 10,000.

273 µsp50 similarity recall, 1K

273 / 335 microseconds
similarity recall p50 / p99 at 1,000 memories
330 / 405 microseconds
the same at 10,000 memories
991 microseconds
remember p50
1,021 bytes
disk per memory at 10,000

A memory engine sits on the hot path of every agent turn, so a latency regression is a product regression. We keep a standalone benchmark binary, hebbs-bench, and a checked-in baseline that release candidates are compared against.

What it measures

Three suites: latency (p50, p95, p99, p99.9 per operation), scalability (recall latency at growing memory counts) and resources (disk and bytes per memory). Three tiers set the size: quick is 10,000 memories with 1,000 runs per operation and 100 warmup runs; standard is 100,000 with 10,000 runs; full is 1,000,000 with 100,000 runs. Datasets are generated from a fixed seed (42 by default) so two runs see the same memories. With --baseline, the report flags any operation whose p99 regressed by more than 10%, and that blocks a release. Benchmarks run on dedicated hardware; shared CI runners are too noisy to compare.

Checked-in baseline (quick tier, Linux x86_64)

Operationp50p99
get1 microsecond2 microseconds
recall, similarity273 microseconds335 microseconds
revise537 microseconds854 microseconds
recall, temporal553 microseconds606 microseconds
remember991 microseconds1,334 microseconds
prime1,113 microseconds1,204 microseconds
count3,386 microseconds3,606 microseconds
forget (single)116,470 microseconds128,747 microseconds

From 1,000 to 10,000 memories, similarity p99 moves from 335 to 405 microseconds and temporal p99 from 606 to 733. Disk per memory falls from 1,088 bytes at 1,000 to 1,021 at 10,000.

How to read it

  • The latency suite uses a mock embedder, so these numbers are the engine alone: serialization, RocksDB writes, index updates and search. Model inference is extra and is the larger share of a real remember or recall.
  • The baseline is the quick tier. It tells us about regressions and the shape of the curve at small scale, and says nothing about a million memories.
  • Single forget at 116 ms is two orders of magnitude slower than every other write. The baseline makes that visible.
  • count at 3.4 ms is a scan and should not be called per turn.

Where the time goes

A fourth command, degradation-curve, inserts memories and stops at checkpoints (every 50 up to 1,000 by default, 20 probes each) to measure remember and each recall strategy, with deltas against the previous checkpoint. It installs a tracing layer that records the duration of named spans inside the engine, such as remember.embed, remember.hnsw_commit, remember.write_batch, recall.similarity.hnsw_search and recall.merge_and_rank, and can run with the real ONNX model. When p99 drifts, the report names the phase that moved.

Date

4 April 2026

Part of

HEBBS

Source

In-house

Topics

Built in-house. Ask us about it.

Related