Skip to content

Instantly share code, notes, and snippets.

@voltcrash
Last active November 2, 2026 13:09
Show Gist options
  • Select an option

  • Save voltcrash/265b6c2bf3d14a7b84f391db4f001d11 to your computer and use it in GitHub Desktop.

Select an option

Save voltcrash/265b6c2bf3d14a7b84f391db4f001d11 to your computer and use it in GitHub Desktop.
T3 Code Thread Find bounded rendered-snapshot performance evidence

Thread Find rendered-snapshot evidence (final source-aware budget)

Base: upstream main 47f2c8d29e981c7723467efe137ee19e91df924e. Change: only ThreadFind.ts and ThreadFind.test.ts. Synthetic data only; no installed T3 state or credentials used. The gist's current revision replaces the initial rendered-only budget experiment with the reviewed source-aware budget and fresh measurements. GitHub retains older gist revisions as historical evidence.

Reproduce

Use Node v26.12.1 with repository dependencies installed (vp i, respecting AGENTS setup markers). Download this gist to a new disposable directory outside the checkout. Export T3_FIND_REPO as the absolute patched checkout path. In that new directory:

ln -s "$T3_FIND_REPO/apps/server/node_modules" node_modules
git -C "$T3_FIND_REPO" show 47f2c8d29e981c7723467efe137ee19e91df924e:apps/server/src/orchestration-v2/ThreadFind.ts > ThreadFind.baseline.ts
python3 run-benchmarks.py

Use a fresh evidence directory: the driver creates new SQLite databases. The Node import hook substitutes only baseline ThreadFind.ts; every other production module stays identical. Both processes use production ProjectionStore.searchThreadStream and Sqlite.layerFromPath (migrated file-backed SQLite, WAL, reader worker). They append/apply synthetic events through the real EventStore/ProjectionStore. Seeding and module loading are outside timing.

Each process searches 2,600 messages/plans (859,229 source-text code units), using 21 distinct prefixes. The first query is cold; the other 20 search one unchanged committed revision. Query-dependent results contain 520–2,600 matches. The benchmark asserts expected totals/first match and hashes both streamed frames, including navigation and snapshotSequence, for parity. Five separate process pairs alternate baseline/final order. all-runs.json keeps all per-query measurements/hashes; summary.json aggregates the median of each process's warm-query medians.

Observed host: Linux aarch64, Node v26.12.1, 8 CPUs, shared host with substantial contention. Load average at end: 30.15/26.21/16.81. Timings are descriptive of this workload, not production latency guarantees.

Measurement Baseline Final
Warm changed query, complete (median) 313.67 ms 28.89 ms
Warm changed query, first frame (median) 128.78 ms 3.29 ms
Payload batches per warm query 21 (2,600 rows) 0
SQL statements per warm query 27 2
Cold query, complete (median) 2874.17 ms 3180.98 ms

All 105 before/after streamed response pairs were identical. The two remaining SQL reads check active-thread/cwd and event revision. The cold path still hydrates/decodes every candidate payload before its first frame; no cold-query improvement is claimed (the final cold median is higher, amid wide variation). For full per-process ranges see summary.json.

Heap observations are not allocation-volume measurements: explicit GC before/after all 21 queries, sampling heapUsed after each query. Median retained growth was 15.76 MB baseline and 8.66 MB final; median sampled high-water heap 233.01 MB and 106.89 MB. These do not measure true peak heap or establish a general heap reduction. Source/segment sharing and GC influence these numbers.

Scope and bounds

One most-recent completed snapshot, max 8,192 documents and 2,097,152 summed source plus rendered UTF16 code units. Counting source text matters because V8 substring segments may keep the source alive. The new cache stores no raw payloads or decoded items. Query-result entries strip segments/source-length metadata. Existing parsed-text caches remain unchanged. This is a text/item bound, not an exact process-memory cap. Over-budget threads fall back to the existing path. Any thread or fork-ancestor event invalidates reuse. Continuously changing threads do not receive this benefit; concurrent searches across different threads may evict each other's snapshot. A cancelled scan does not populate the snapshot until a full scan finishes, so continuous fast typing may defer reuse until a query completes.

Focused proof and review

  • red.log: on baseline, two different queries over 520 messages made 10 payload batches instead of the expected 5.
  • source-budget-red.log: the initial rendered-only cache incorrectly reused 65 messages with large hidden data URIs (1 payload batch instead of 2). Source-aware budget fixes that. The combined-source/rendered case now uses a source that fits alone but exceeds the budget together with its segments.
  • green-final.log: 20/20 focused Find tests, including cache bounds, snapshot writes, folded answer changes, plans, cwd/skills, fork ancestry, streamed changes and rollback.
  • check-changed-final.log: final submission check results; format/lint/knip/GraphQL/affected typechecks/adjacent tests. No repo-wide checks or dev server were run.
  • review-ledger.md: two independent Claude Opus 5.5 xhigh review rounds, both APPROVE; all three nits accepted. Implementation GPT-6.1 Sol xhigh in Codex. Usage unavailable.

Server-only in-process evidence. Browser/Electron/mobile, transport/relay/tunnel and paid providers were not exercised. Clients use existing search APIs/results. The parent owns any client verification: with a seeded isolated dev server, open a long thread, change Find prefixes, navigate next/previous, then repeat after streamed text, question-answer and fork-source changes. No client rendering or contract changes in this patch.

{
"baseline-0": {
"node": "v26.12.1",
"items": 2600,
"rows": [
{
"query": "nee",
"totalMs": 2874.1732429999993,
"firstMs": 373.17375899999934,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "need",
"totalMs": 448.24057300000095,
"firstMs": 157.65031699999963,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "needle",
"totalMs": 437.0479350000005,
"firstMs": 221.98078899999928,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "bui",
"totalMs": 429.408453,
"firstMs": 193.43800200000078,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "buil",
"totalMs": 348.0937520000007,
"firstMs": 198.3705860000009,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "build",
"totalMs": 367.7423799999997,
"firstMs": 130.7285439999996,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "builde",
"totalMs": 294.531164,
"firstMs": 95.9284520000001,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "builder",
"totalMs": 343.00249899999835,
"firstMs": 132.30130699999972,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "proto",
"totalMs": 308.71203700000115,
"firstMs": 150.5917989999998,
"payloadBatches": 21,
"statements": 27,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "protoc",
"totalMs": 319.4175039999991,
"firstMs": 71.71786799999973,
"payloadBatches": 21,
"statements": 27,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "protoco",
"totalMs": 212.11257900000055,
"firstMs": 85.41307000000052,
"payloadBatches": 21,
"statements": 27,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "protocol",
"totalMs": 252.79959699999927,
"firstMs": 111.73042200000236,
"payloadBatches": 21,
"statements": 27,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "mem",
"totalMs": 312.31781799999953,
"firstMs": 126.06683699999849,
"payloadBatches": 21,
"statements": 27,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "memo",
"totalMs": 356.09865400000126,
"firstMs": 202.78012300000046,
"payloadBatches": 21,
"statements": 27,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "memor",
"totalMs": 367.065247999999,
"firstMs": 125.25982999999906,
"payloadBatches": 21,
"statements": 27,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "memory",
"totalMs": 331.60073399999965,
"firstMs": 155.8743859999995,
"payloadBatches": 21,
"statements": 27,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "alp",
"totalMs": 341.275235000001,
"firstMs": 109.64027899999928,
"payloadBatches": 21,
"statements": 27,
"hash": "2970d31b6f5a6fe540cef3619d2992f4139a8f02590af16330f2d6c5fc1c4b87",
"totalMatches": 520
},
{
"query": "alph",
"totalMs": 990.3053309999996,
"firstMs": 193.9639640000023,
"payloadBatches": 21,
"statements": 27,
"hash": "2970d31b6f5a6fe540cef3619d2992f4139a8f02590af16330f2d6c5fc1c4b87",
"totalMatches": 520
},
{
"query": "alpha",
"totalMs": 421.1450490000025,
"firstMs": 163.2081990000006,
"payloadBatches": 21,
"statements": 27,
"hash": "2970d31b6f5a6fe540cef3619d2992f4139a8f02590af16330f2d6c5fc1c4b87",
"totalMatches": 520
},
{
"query": "bet",
"totalMs": 221.15011500000037,
"firstMs": 93.55047300000297,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "beta",
"totalMs": 309.14600000000064,
"firstMs": 115.47787100000278,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
}
],
"heapBefore": 59322296,
"heapAfter": 75084312,
"peakHeap": 233006272
},
"baseline-1": {
"node": "v26.12.1",
"items": 2600,
"rows": [
{
"query": "nee",
"totalMs": 5054.2647529999995,
"firstMs": 341.66536300000007,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "need",
"totalMs": 1671.3077460000004,
"firstMs": 879.1157060000005,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "needle",
"totalMs": 1631.682363,
"firstMs": 442.65044299999863,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "bui",
"totalMs": 426.93622299999697,
"firstMs": 236.24774599999728,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "buil",
"totalMs": 513.9295569999995,
"firstMs": 237.37092199999825,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "build",
"totalMs": 681.2192079999986,
"firstMs": 376.9444169999988,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "builde",
"totalMs": 884.1124159999999,
"firstMs": 588.7700780000014,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "builder",
"totalMs": 474.76776099999915,
"firstMs": 79.41893499999787,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "proto",
"totalMs": 384.1816459999973,
"firstMs": 160.86759600000005,
"payloadBatches": 21,
"statements": 27,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "protoc",
"totalMs": 259.03469199999745,
"firstMs": 118.8856089999972,
"payloadBatches": 21,
"statements": 27,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "protoco",
"totalMs": 467.4733639999977,
"firstMs": 138.1217319999996,
"payloadBatches": 21,
"statements": 27,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "protocol",
"totalMs": 496.533615999997,
"firstMs": 278.0442729999995,
"payloadBatches": 21,
"statements": 27,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "mem",
"totalMs": 633.5500890000003,
"firstMs": 325.6251420000008,
"payloadBatches": 21,
"statements": 27,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "memo",
"totalMs": 501.0629459999982,
"firstMs": 361.1350730000013,
"payloadBatches": 21,
"statements": 27,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "memor",
"totalMs": 373.15292599999884,
"firstMs": 254.26252599999862,
"payloadBatches": 21,
"statements": 27,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "memory",
"totalMs": 301.19047200000205,
"firstMs": 67.28062200000204,
"payloadBatches": 21,
"statements": 27,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "alp",
"totalMs": 517.5823380000002,
"firstMs": 71.3006979999991,
"payloadBatches": 21,
"statements": 27,
"hash": "2970d31b6f5a6fe540cef3619d2992f4139a8f02590af16330f2d6c5fc1c4b87",
"totalMatches": 520
},
{
"query": "alph",
"totalMs": 450.5616770000015,
"firstMs": 75.33981700000004,
"payloadBatches": 21,
"statements": 27,
"hash": "2970d31b6f5a6fe540cef3619d2992f4139a8f02590af16330f2d6c5fc1c4b87",
"totalMatches": 520
},
{
"query": "alpha",
"totalMs": 390.5737850000005,
"firstMs": 193.02874800000063,
"payloadBatches": 21,
"statements": 27,
"hash": "2970d31b6f5a6fe540cef3619d2992f4139a8f02590af16330f2d6c5fc1c4b87",
"totalMatches": 520
},
{
"query": "bet",
"totalMs": 826.406210000001,
"firstMs": 458.8465819999983,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "beta",
"totalMs": 337.18740700000126,
"firstMs": 131.232215,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
}
],
"heapBefore": 59288104,
"heapAfter": 71964632,
"peakHeap": 177299432
},
"baseline-2": {
"node": "v26.12.1",
"items": 2600,
"rows": [
{
"query": "nee",
"totalMs": 4648.888676000002,
"firstMs": 874.3518729999996,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "need",
"totalMs": 635.4801940000034,
"firstMs": 449.4725330000001,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "needle",
"totalMs": 310.96717499999795,
"firstMs": 126.10772200000065,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "bui",
"totalMs": 262.133010000005,
"firstMs": 101.98857300000964,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "buil",
"totalMs": 293.00331800000276,
"firstMs": 105.26479999998992,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "build",
"totalMs": 269.2804550000001,
"firstMs": 121.79573199999868,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "builde",
"totalMs": 270.5953060000029,
"firstMs": 123.11225099999865,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "builder",
"totalMs": 264.1216940000013,
"firstMs": 167.21133299999929,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "proto",
"totalMs": 553.9534749999875,
"firstMs": 130.43388699999196,
"payloadBatches": 21,
"statements": 27,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "protoc",
"totalMs": 543.8349920000037,
"firstMs": 235.91548599999805,
"payloadBatches": 21,
"statements": 27,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "protoco",
"totalMs": 276.9662729999982,
"firstMs": 132.9523130000016,
"payloadBatches": 21,
"statements": 27,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "protocol",
"totalMs": 274.847007999997,
"firstMs": 97.34533700000611,
"payloadBatches": 21,
"statements": 27,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "mem",
"totalMs": 327.26663199999894,
"firstMs": 99.32739199999196,
"payloadBatches": 21,
"statements": 27,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "memo",
"totalMs": 316.3726709999901,
"firstMs": 119.84915799999726,
"payloadBatches": 21,
"statements": 27,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "memor",
"totalMs": 358.00464899999497,
"firstMs": 132.4462510000012,
"payloadBatches": 21,
"statements": 27,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "memory",
"totalMs": 209.48512199999823,
"firstMs": 48.1071329999977,
"payloadBatches": 21,
"statements": 27,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "alp",
"totalMs": 343.8494720000017,
"firstMs": 54.66713200000231,
"payloadBatches": 21,
"statements": 27,
"hash": "2970d31b6f5a6fe540cef3619d2992f4139a8f02590af16330f2d6c5fc1c4b87",
"totalMatches": 520
},
{
"query": "alph",
"totalMs": 415.24186499998905,
"firstMs": 106.12457899999572,
"payloadBatches": 21,
"statements": 27,
"hash": "2970d31b6f5a6fe540cef3619d2992f4139a8f02590af16330f2d6c5fc1c4b87",
"totalMatches": 520
},
{
"query": "alpha",
"totalMs": 285.921331000005,
"firstMs": 101.81492499999877,
"payloadBatches": 21,
"statements": 27,
"hash": "2970d31b6f5a6fe540cef3619d2992f4139a8f02590af16330f2d6c5fc1c4b87",
"totalMatches": 520
},
{
"query": "bet",
"totalMs": 343.8160340000031,
"firstMs": 125.68350199999986,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "beta",
"totalMs": 335.16382899999735,
"firstMs": 156.17328299999645,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
}
],
"heapBefore": 59278808,
"heapAfter": 75058560,
"peakHeap": 239205064
},
"baseline-3": {
"node": "v26.12.1",
"items": 2600,
"rows": [
{
"query": "nee",
"totalMs": 2064.365283,
"firstMs": 173.99210099999982,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "need",
"totalMs": 397.77931400000034,
"firstMs": 194.82151199999953,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "needle",
"totalMs": 348.52532900000006,
"firstMs": 68.54702100000031,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "bui",
"totalMs": 253.30529299999944,
"firstMs": 63.956144999999196,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "buil",
"totalMs": 238.51041799999985,
"firstMs": 90.58403199999975,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "build",
"totalMs": 270.45469500000036,
"firstMs": 46.28724200000033,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "builde",
"totalMs": 207.76561199999924,
"firstMs": 55.54195699999946,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "builder",
"totalMs": 242.7967260000005,
"firstMs": 85.95235999999932,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "proto",
"totalMs": 226.3265879999999,
"firstMs": 91.24496099999851,
"payloadBatches": 21,
"statements": 27,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "protoc",
"totalMs": 209.75227500000074,
"firstMs": 73.52367800000138,
"payloadBatches": 21,
"statements": 27,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "protoco",
"totalMs": 187.47341099999903,
"firstMs": 61.994776999999885,
"payloadBatches": 21,
"statements": 27,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "protocol",
"totalMs": 269.533496,
"firstMs": 81.35702700000002,
"payloadBatches": 21,
"statements": 27,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "mem",
"totalMs": 201.60210799999913,
"firstMs": 88.484817999999,
"payloadBatches": 21,
"statements": 27,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "memo",
"totalMs": 240.505079999999,
"firstMs": 77.38320199999907,
"payloadBatches": 21,
"statements": 27,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "memor",
"totalMs": 172.74395699999877,
"firstMs": 50.493836999999985,
"payloadBatches": 21,
"statements": 27,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "memory",
"totalMs": 220.83505499999956,
"firstMs": 52.4129099999991,
"payloadBatches": 21,
"statements": 27,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "alp",
"totalMs": 398.69897299999866,
"firstMs": 261.99358799999936,
"payloadBatches": 21,
"statements": 27,
"hash": "2970d31b6f5a6fe540cef3619d2992f4139a8f02590af16330f2d6c5fc1c4b87",
"totalMatches": 520
},
{
"query": "alph",
"totalMs": 249.15037099999972,
"firstMs": 132.6761809999989,
"payloadBatches": 21,
"statements": 27,
"hash": "2970d31b6f5a6fe540cef3619d2992f4139a8f02590af16330f2d6c5fc1c4b87",
"totalMatches": 520
},
{
"query": "alpha",
"totalMs": 192.08487199999945,
"firstMs": 74.72465199999897,
"payloadBatches": 21,
"statements": 27,
"hash": "2970d31b6f5a6fe540cef3619d2992f4139a8f02590af16330f2d6c5fc1c4b87",
"totalMatches": 520
},
{
"query": "bet",
"totalMs": 231.12460500000088,
"firstMs": 72.39666899999975,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "beta",
"totalMs": 319.58212900000035,
"firstMs": 113.85368400000152,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
}
],
"heapBefore": 59290296,
"heapAfter": 72070136,
"peakHeap": 159131096
},
"baseline-4": {
"node": "v26.12.1",
"items": 2600,
"rows": [
{
"query": "nee",
"totalMs": 2364.077704000001,
"firstMs": 411.69549299999926,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "need",
"totalMs": 518.8940910000019,
"firstMs": 170.80746500000168,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "needle",
"totalMs": 273.4791519999999,
"firstMs": 81.99324600000182,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "bui",
"totalMs": 346.2219729999997,
"firstMs": 181.021342,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "buil",
"totalMs": 535.190590000002,
"firstMs": 146.0997779999998,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "build",
"totalMs": 495.8122460000013,
"firstMs": 188.4801179999995,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "builde",
"totalMs": 292.0231679999997,
"firstMs": 136.58858399999735,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "builder",
"totalMs": 320.2927290000007,
"firstMs": 137.96657200000118,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "proto",
"totalMs": 241.66296599999987,
"firstMs": 78.25106400000004,
"payloadBatches": 21,
"statements": 27,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "protoc",
"totalMs": 263.0008779999989,
"firstMs": 151.10097899999892,
"payloadBatches": 21,
"statements": 27,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "protoco",
"totalMs": 429.68779899999936,
"firstMs": 174.10094299999764,
"payloadBatches": 21,
"statements": 27,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "protocol",
"totalMs": 708.7508220000018,
"firstMs": 401.6657980000018,
"payloadBatches": 21,
"statements": 27,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "mem",
"totalMs": 577.0122179999998,
"firstMs": 356.0025229999992,
"payloadBatches": 21,
"statements": 27,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "memo",
"totalMs": 324.30339000000095,
"firstMs": 120.96772400000191,
"payloadBatches": 21,
"statements": 27,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "memor",
"totalMs": 207.54596900000251,
"firstMs": 68.42826100000093,
"payloadBatches": 21,
"statements": 27,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "memory",
"totalMs": 255.82308299999931,
"firstMs": 97.66823600000134,
"payloadBatches": 21,
"statements": 27,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "alp",
"totalMs": 196.76425500000187,
"firstMs": 58.58124800000223,
"payloadBatches": 21,
"statements": 27,
"hash": "2970d31b6f5a6fe540cef3619d2992f4139a8f02590af16330f2d6c5fc1c4b87",
"totalMatches": 520
},
{
"query": "alph",
"totalMs": 208.9900869999983,
"firstMs": 77.83857299999727,
"payloadBatches": 21,
"statements": 27,
"hash": "2970d31b6f5a6fe540cef3619d2992f4139a8f02590af16330f2d6c5fc1c4b87",
"totalMatches": 520
},
{
"query": "alpha",
"totalMs": 262.6254310000004,
"firstMs": 69.38359000000128,
"payloadBatches": 21,
"statements": 27,
"hash": "2970d31b6f5a6fe540cef3619d2992f4139a8f02590af16330f2d6c5fc1c4b87",
"totalMatches": 520
},
{
"query": "bet",
"totalMs": 197.7728790000001,
"firstMs": 92.03281700000298,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "beta",
"totalMs": 326.99210999999923,
"firstMs": 98.13118899999972,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
}
],
"heapBefore": 59296368,
"heapAfter": 75067696,
"peakHeap": 241243000
},
"final-0": {
"node": "v26.12.1",
"items": 2600,
"rows": [
{
"query": "nee",
"totalMs": 3006.967681,
"firstMs": 249.4457340000008,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "need",
"totalMs": 260.15503499999977,
"firstMs": 42.305530999999974,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "needle",
"totalMs": 156.38601500000004,
"firstMs": 99.87694499999998,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "bui",
"totalMs": 64.82268399999884,
"firstMs": 6.097635999998602,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "buil",
"totalMs": 58.323835999999574,
"firstMs": 3.666905999998562,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "build",
"totalMs": 70.91565399999854,
"firstMs": 58.83705000000009,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "builde",
"totalMs": 28.56112100000064,
"firstMs": 2.60468899999978,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "builder",
"totalMs": 41.71935999999914,
"firstMs": 1.1998439999988477,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "proto",
"totalMs": 70.07631299999957,
"firstMs": 7.041310999999041,
"payloadBatches": 0,
"statements": 2,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "protoc",
"totalMs": 23.90103900000031,
"firstMs": 2.694147999998677,
"payloadBatches": 0,
"statements": 2,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "protoco",
"totalMs": 18.36674199999834,
"firstMs": 1.7512659999993048,
"payloadBatches": 0,
"statements": 2,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "protocol",
"totalMs": 119.89270100000067,
"firstMs": 1.0051340000009077,
"payloadBatches": 0,
"statements": 2,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "mem",
"totalMs": 18.101698000000397,
"firstMs": 3.504822000000786,
"payloadBatches": 0,
"statements": 2,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "memo",
"totalMs": 27.113900000000285,
"firstMs": 9.737500000001091,
"payloadBatches": 0,
"statements": 2,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "memor",
"totalMs": 158.1473220000007,
"firstMs": 41.42344000000048,
"payloadBatches": 0,
"statements": 2,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "memory",
"totalMs": 18.02748900000006,
"firstMs": 6.347429999999804,
"payloadBatches": 0,
"statements": 2,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "alp",
"totalMs": 12.47440000000097,
"firstMs": 1.7760990000006132,
"payloadBatches": 0,
"statements": 2,
"hash": "2970d31b6f5a6fe540cef3619d2992f4139a8f02590af16330f2d6c5fc1c4b87",
"totalMatches": 520
},
{
"query": "alph",
"totalMs": 25.241926000000603,
"firstMs": 2.2991870000005292,
"payloadBatches": 0,
"statements": 2,
"hash": "2970d31b6f5a6fe540cef3619d2992f4139a8f02590af16330f2d6c5fc1c4b87",
"totalMatches": 520
},
{
"query": "alpha",
"totalMs": 23.430076999999073,
"firstMs": 3.232319999999163,
"payloadBatches": 0,
"statements": 2,
"hash": "2970d31b6f5a6fe540cef3619d2992f4139a8f02590af16330f2d6c5fc1c4b87",
"totalMatches": 520
},
{
"query": "bet",
"totalMs": 29.222584999999526,
"firstMs": 5.6827570000004926,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "beta",
"totalMs": 12.49831599999925,
"firstMs": 1.4812629999996716,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
}
],
"heapBefore": 59272640,
"heapAfter": 67935800,
"peakHeap": 106835168
},
"final-1": {
"node": "v26.12.1",
"items": 2600,
"rows": [
{
"query": "nee",
"totalMs": 3180.9776810000003,
"firstMs": 985.3852479999987,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "need",
"totalMs": 23.92058199999883,
"firstMs": 5.3896720000011555,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "needle",
"totalMs": 16.739143999999214,
"firstMs": 2.028351000000839,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "bui",
"totalMs": 24.761546999998245,
"firstMs": 4.636580999998841,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "buil",
"totalMs": 30.498929999997927,
"firstMs": 6.455680999999458,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "build",
"totalMs": 26.551479000001564,
"firstMs": 5.736300000000483,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "builde",
"totalMs": 128.9259869999987,
"firstMs": 57.21424399999887,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "builder",
"totalMs": 42.556782999999996,
"firstMs": 5.124544000002061,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "proto",
"totalMs": 65.20202100000097,
"firstMs": 5.4492559999998775,
"payloadBatches": 0,
"statements": 2,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "protoc",
"totalMs": 103.15255600000091,
"firstMs": 4.471497000002273,
"payloadBatches": 0,
"statements": 2,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "protoco",
"totalMs": 40.82097700000304,
"firstMs": 9.075286999999662,
"payloadBatches": 0,
"statements": 2,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "protocol",
"totalMs": 66.69107499999882,
"firstMs": 6.208511999997427,
"payloadBatches": 0,
"statements": 2,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "mem",
"totalMs": 63.59675700000298,
"firstMs": 4.048452000002726,
"payloadBatches": 0,
"statements": 2,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "memo",
"totalMs": 58.287460999999894,
"firstMs": 9.408456000001024,
"payloadBatches": 0,
"statements": 2,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "memor",
"totalMs": 62.10791099999915,
"firstMs": 3.9870760000012524,
"payloadBatches": 0,
"statements": 2,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "memory",
"totalMs": 57.93050000000221,
"firstMs": 6.626266000002943,
"payloadBatches": 0,
"statements": 2,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "alp",
"totalMs": 39.764218000000255,
"firstMs": 5.81221700000242,
"payloadBatches": 0,
"statements": 2,
"hash": "2970d31b6f5a6fe540cef3619d2992f4139a8f02590af16330f2d6c5fc1c4b87",
"totalMatches": 520
},
{
"query": "alph",
"totalMs": 50.41172599999845,
"firstMs": 13.55490799999825,
"payloadBatches": 0,
"statements": 2,
"hash": "2970d31b6f5a6fe540cef3619d2992f4139a8f02590af16330f2d6c5fc1c4b87",
"totalMatches": 520
},
{
"query": "alpha",
"totalMs": 226.70149599999786,
"firstMs": 3.467570999997406,
"payloadBatches": 0,
"statements": 2,
"hash": "2970d31b6f5a6fe540cef3619d2992f4139a8f02590af16330f2d6c5fc1c4b87",
"totalMatches": 520
},
{
"query": "bet",
"totalMs": 60.1291850000016,
"firstMs": 15.075213000000076,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "beta",
"totalMs": 44.55067599999893,
"firstMs": 5.800258999999642,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
}
],
"heapBefore": 59292904,
"heapAfter": 67947352,
"peakHeap": 111379672
},
"final-2": {
"node": "v26.12.1",
"items": 2600,
"rows": [
{
"query": "nee",
"totalMs": 3764.5449720000015,
"firstMs": 472.87386499999957,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "need",
"totalMs": 57.49078799999916,
"firstMs": 42.6857940000009,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "needle",
"totalMs": 14.863489000003028,
"firstMs": 2.211821000000782,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "bui",
"totalMs": 19.156299999998737,
"firstMs": 1.7968980000005104,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "buil",
"totalMs": 20.050100000000384,
"firstMs": 3.4664689999990514,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "build",
"totalMs": 20.494332999998733,
"firstMs": 2.821947000000364,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "builde",
"totalMs": 93.44335099999807,
"firstMs": 4.261332999998558,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "builder",
"totalMs": 33.959210000000894,
"firstMs": 5.071289999999863,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "proto",
"totalMs": 16.355490999998437,
"firstMs": 2.5284739999988233,
"payloadBatches": 0,
"statements": 2,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "protoc",
"totalMs": 15.412870000000112,
"firstMs": 2.0899959999987914,
"payloadBatches": 0,
"statements": 2,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "protoco",
"totalMs": 52.296087999999145,
"firstMs": 42.83922099999836,
"payloadBatches": 0,
"statements": 2,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "protocol",
"totalMs": 23.54225099999894,
"firstMs": 7.876100999998016,
"payloadBatches": 0,
"statements": 2,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "mem",
"totalMs": 15.18105899999864,
"firstMs": 5.440726000000723,
"payloadBatches": 0,
"statements": 2,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "memo",
"totalMs": 69.39261899999838,
"firstMs": 1.0638639999997395,
"payloadBatches": 0,
"statements": 2,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "memor",
"totalMs": 19.620169000001624,
"firstMs": 2.6972029999997176,
"payloadBatches": 0,
"statements": 2,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "memory",
"totalMs": 21.927757000001293,
"firstMs": 7.402059000000008,
"payloadBatches": 0,
"statements": 2,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "alp",
"totalMs": 28.176940000001196,
"firstMs": 2.3230560000010883,
"payloadBatches": 0,
"statements": 2,
"hash": "2970d31b6f5a6fe540cef3619d2992f4139a8f02590af16330f2d6c5fc1c4b87",
"totalMatches": 520
},
{
"query": "alph",
"totalMs": 16.847335999998904,
"firstMs": 0.7987419999990379,
"payloadBatches": 0,
"statements": 2,
"hash": "2970d31b6f5a6fe540cef3619d2992f4139a8f02590af16330f2d6c5fc1c4b87",
"totalMatches": 520
},
{
"query": "alpha",
"totalMs": 12.302244999998948,
"firstMs": 1.8558519999969576,
"payloadBatches": 0,
"statements": 2,
"hash": "2970d31b6f5a6fe540cef3619d2992f4139a8f02590af16330f2d6c5fc1c4b87",
"totalMatches": 520
},
{
"query": "bet",
"totalMs": 22.662459999999555,
"firstMs": 1.9542870000004768,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "beta",
"totalMs": 13.13967699999921,
"firstMs": 3.6940670000003593,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
}
],
"heapBefore": 59271504,
"heapAfter": 67955520,
"peakHeap": 106892008
},
"final-3": {
"node": "v26.12.1",
"items": 2600,
"rows": [
{
"query": "nee",
"totalMs": 2169.702104,
"firstMs": 454.32347899999877,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "need",
"totalMs": 21.475672000000486,
"firstMs": 7.860768000002281,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "needle",
"totalMs": 12.475852999999915,
"firstMs": 1.154010999998718,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "bui",
"totalMs": 21.598974000000453,
"firstMs": 1.0467939999980445,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "buil",
"totalMs": 16.46038700000281,
"firstMs": 5.372564000001148,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "build",
"totalMs": 12.989353000000847,
"firstMs": 1.0940890000019863,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "builde",
"totalMs": 54.33019200000126,
"firstMs": 1.3887390000018058,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "builder",
"totalMs": 16.75478700000167,
"firstMs": 1.9141980000022158,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "proto",
"totalMs": 13.463434000001143,
"firstMs": 1.4267829999989772,
"payloadBatches": 0,
"statements": 2,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "protoc",
"totalMs": 13.438390999999683,
"firstMs": 1.2589359999983571,
"payloadBatches": 0,
"statements": 2,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "protoco",
"totalMs": 47.90241700000115,
"firstMs": 2.752599999999802,
"payloadBatches": 0,
"statements": 2,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "protocol",
"totalMs": 15.378423999998631,
"firstMs": 2.0673359999964305,
"payloadBatches": 0,
"statements": 2,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "mem",
"totalMs": 17.021849999997357,
"firstMs": 1.5700870000000577,
"payloadBatches": 0,
"statements": 2,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "memo",
"totalMs": 39.14144999999917,
"firstMs": 2.7741019999994023,
"payloadBatches": 0,
"statements": 2,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "memor",
"totalMs": 14.904343999998673,
"firstMs": 2.0868369999989227,
"payloadBatches": 0,
"statements": 2,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "memory",
"totalMs": 14.583275999997568,
"firstMs": 1.8118990000002668,
"payloadBatches": 0,
"statements": 2,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "alp",
"totalMs": 40.82058799999868,
"firstMs": 1.6122150000010151,
"payloadBatches": 0,
"statements": 2,
"hash": "2970d31b6f5a6fe540cef3619d2992f4139a8f02590af16330f2d6c5fc1c4b87",
"totalMatches": 520
},
{
"query": "alph",
"totalMs": 13.356633999999758,
"firstMs": 4.696384000002581,
"payloadBatches": 0,
"statements": 2,
"hash": "2970d31b6f5a6fe540cef3619d2992f4139a8f02590af16330f2d6c5fc1c4b87",
"totalMatches": 520
},
{
"query": "alpha",
"totalMs": 13.736331000000064,
"firstMs": 1.6014219999997295,
"payloadBatches": 0,
"statements": 2,
"hash": "2970d31b6f5a6fe540cef3619d2992f4139a8f02590af16330f2d6c5fc1c4b87",
"totalMatches": 520
},
{
"query": "bet",
"totalMs": 25.191851999999926,
"firstMs": 1.6392590000032214,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "beta",
"totalMs": 21.713067000000592,
"firstMs": 11.84830200000215,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
}
],
"heapBefore": 59307000,
"heapAfter": 67960664,
"peakHeap": 102233080
},
"final-4": {
"node": "v26.12.1",
"items": 2600,
"rows": [
{
"query": "nee",
"totalMs": 5257.120583999997,
"firstMs": 814.6838119999957,
"payloadBatches": 21,
"statements": 27,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "need",
"totalMs": 186.63222300000052,
"firstMs": 156.357686000003,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "needle",
"totalMs": 20.436587999996846,
"firstMs": 2.653597999997146,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "bui",
"totalMs": 30.59106299999985,
"firstMs": 2.689975000001141,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "buil",
"totalMs": 21.527471000001242,
"firstMs": 3.3776579999976093,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "build",
"totalMs": 17.831702000003133,
"firstMs": 1.9581640000033076,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "builde",
"totalMs": 194.691399000003,
"firstMs": 1.8416550000038114,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "builder",
"totalMs": 29.724865999996837,
"firstMs": 1.9011170000012498,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "proto",
"totalMs": 20.62785399999848,
"firstMs": 6.007961999996041,
"payloadBatches": 0,
"statements": 2,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "protoc",
"totalMs": 20.120853000000352,
"firstMs": 7.875285000001895,
"payloadBatches": 0,
"statements": 2,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "protoco",
"totalMs": 26.363916999995126,
"firstMs": 2.5929249999971944,
"payloadBatches": 0,
"statements": 2,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "protocol",
"totalMs": 17.526843999999983,
"firstMs": 1.7296449999994365,
"payloadBatches": 0,
"statements": 2,
"hash": "f626500da56f6e6059bddfa1931012ff8753da77399b7158fb4ead77f48ce711",
"totalMatches": 1300
},
{
"query": "mem",
"totalMs": 21.614978000005067,
"firstMs": 1.0175020000024233,
"payloadBatches": 0,
"statements": 2,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "memo",
"totalMs": 24.076476000002003,
"firstMs": 3.676724999997532,
"payloadBatches": 0,
"statements": 2,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "memor",
"totalMs": 42.252498999994714,
"firstMs": 3.2051849999988917,
"payloadBatches": 0,
"statements": 2,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "memory",
"totalMs": 40.91467799999373,
"firstMs": 6.103010999999242,
"payloadBatches": 0,
"statements": 2,
"hash": "3e939fc627eb146a9a1171b4caca206dbcde8f5ce71863effd7d798a2159d49a",
"totalMatches": 867
},
{
"query": "alp",
"totalMs": 42.091276999999536,
"firstMs": 1.7346449999968172,
"payloadBatches": 0,
"statements": 2,
"hash": "2970d31b6f5a6fe540cef3619d2992f4139a8f02590af16330f2d6c5fc1c4b87",
"totalMatches": 520
},
{
"query": "alph",
"totalMs": 73.00907599999482,
"firstMs": 8.27690199999779,
"payloadBatches": 0,
"statements": 2,
"hash": "2970d31b6f5a6fe540cef3619d2992f4139a8f02590af16330f2d6c5fc1c4b87",
"totalMatches": 520
},
{
"query": "alpha",
"totalMs": 49.28512999999657,
"firstMs": 7.446998999999778,
"payloadBatches": 0,
"statements": 2,
"hash": "2970d31b6f5a6fe540cef3619d2992f4139a8f02590af16330f2d6c5fc1c4b87",
"totalMatches": 520
},
{
"query": "bet",
"totalMs": 58.34747300000163,
"firstMs": 12.69698100000096,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
},
{
"query": "beta",
"totalMs": 73.09862599999906,
"firstMs": 17.987091000002692,
"payloadBatches": 0,
"statements": 2,
"hash": "5cce1ef28fbae0fecff74cf244b0aaec0dfb9ce96e890b6eac6e4524fdbc9513",
"totalMatches": 2600
}
],
"heapBefore": 59271936,
"heapAfter": 67960400,
"peakHeap": 112999128
}
}
import { registerHooks } from "node:module";
import { readFileSync } from "node:fs";
import { pathToFileURL } from "node:url";
const root = process.env.T3_FIND_REPO;
if (!root) throw new Error("Set T3_FIND_REPO");
registerHooks({ load(url, context, next) {
if (url === pathToFileURL(`${root}/apps/server/src/orchestration-v2/ThreadFind.ts`).href) {
return { format: "module-typescript", source: readFileSync(new URL("./ThreadFind.baseline.ts", import.meta.url), "utf8").replaceAll('"./ProjectionStore.ts"', `"${root}/apps/server/src/orchestration-v2/ProjectionStore.ts"`), shortCircuit: true };
}
return next(url, context);
} });
import assert from "node:assert/strict";
import { performance } from "node:perf_hooks";
import * as NodeServices from "@effect/platform-node/NodeServices";
import { createHash } from "node:crypto";
import {
EventId,
MessageId,
PlanId,
RunId,
RuntimeRequestId,
TurnItemId,
type OrchestrationV2TurnItem,
type OrchestrationV2Run,
type OrchestrationV2ThreadHistoryPage,
ProjectId,
ProviderInstanceId,
ThreadId,
type OrchestrationV2DomainEvent,
} from "@t3tools/contracts";
import * as DateTime from "effect/DateTime";
import * as Effect from "effect/Effect";
import * as Layer from "effect/Layer";
import * as SqlClient from "effect/sql/SqlClient";
import * as Stream from "effect/Stream";
import * as Tracer from "effect/Tracer";
const repoRoot = process.env.T3_FIND_REPO;
if (!repoRoot) throw new Error("Set T3_FIND_REPO to the absolute checkout path");
const SqlitePersistence = await import(`${repoRoot}/apps/server/src/persistence/Sqlite.ts`);
const ProjectionStore = await import(`${repoRoot}/apps/server/src/orchestration-v2/ProjectionStore.ts`);
const ProjectStore = await import(`${repoRoot}/apps/server/src/orchestration-v2/ProjectStore.ts`);
const EventStore = await import(`${repoRoot}/apps/server/src/orchestration-v2/EventStore.ts`);
const layerTest = Layer.mergeAll(EventStore.layer, ProjectionStore.layer, ProjectStore.layer).pipe(
Layer.provideMerge(SqlitePersistence.layerFromPath(process.argv[2]).pipe(Layer.provide(NodeServices.layer))),
);
const providerInstanceId = ProviderInstanceId.make("codex");
const at = (minute: number) => DateTime.makeUnsafe(Date.UTC(2026, 8, 27, 0, minute));
const createProject = (projectId: ProjectId) =>
Effect.flatMap(ProjectStore.ProjectStoreV2, (projects) =>
projects.apply({
sequence: 0,
eventId: EventId.make(`created:${projectId}`),
aggregateKind: "project",
aggregateId: projectId,
occurredAt: DateTime.formatIso(at(0)),
commandId: null,
causationEventId: null,
correlationId: null,
metadata: {},
type: "project.created",
payload: {
projectId,
title: projectId,
workspaceRoot: `/work/${projectId}`,
defaultModelSelection: null,
scripts: [],
createdAt: DateTime.formatIso(at(0)),
updatedAt: DateTime.formatIso(at(0)),
},
}),
);
const thread = (
threadId: ThreadId,
projectId: ProjectId,
overrides: { readonly archivedAt?: DateTime.Utc; readonly deletedAt?: DateTime.Utc } = {},
): OrchestrationV2DomainEvent => ({
id: EventId.make(`created:${threadId}`),
type: "thread.created",
threadId,
providerInstanceId,
occurredAt: at(0),
payload: {
createdBy: "user",
creationSource: "web",
id: threadId,
projectId,
title: threadId,
providerInstanceId,
modelSelection: { instanceId: providerInstanceId, model: "gpt-5" },
runtimeMode: "full-access",
interactionMode: "default",
branch: null,
worktreePath: null,
activeProviderThreadId: null,
lineage: { parentThreadId: null, relationshipToParent: null, rootThreadId: threadId },
forkedFrom: null,
createdAt: at(0),
updatedAt: at(0),
archivedAt: overrides.archivedAt ?? null,
settledOverride: null,
settledAt: null,
lastVisitedAt: null,
deletedAt: overrides.deletedAt ?? null,
},
});
const threadId = ThreadId.make("thread:find");
const projectId = ProjectId.make("project:find");
const runId = RunId.make("run:find");
function item(
id: string,
ordinal: number,
text: string,
kind: "user_message" | "assistant_message" | "proposed_plan" = "assistant_message",
owner = threadId,
): Extract<
OrchestrationV2TurnItem,
{ type: "user_message" | "assistant_message" | "proposed_plan" }
> {
const base = {
id: TurnItemId.make(id),
threadId: owner,
runId,
nodeId: null,
providerThreadId: null,
providerTurnId: null,
nativeItemRef: null,
parentItemId: null,
ordinal,
status: "completed" as const,
title: null,
startedAt: at(100 - ordinal),
completedAt: at(100 - ordinal),
updatedAt: at(1),
};
if (kind === "proposed_plan")
return { ...base, type: kind, planId: PlanId.make(id), markdown: text, streaming: false };
if (kind === "user_message")
return {
...base,
type: kind,
messageId: MessageId.make(id),
text,
inputIntent: "turn_start",
attachments: [],
createdBy: "user",
creationSource: "web",
};
return { ...base, type: kind, messageId: MessageId.make(id), text, streaming: false };
}
function run(
owner = threadId,
id = runId,
ordinal = 1,
status: OrchestrationV2Run["status"] = "completed",
): Extract<OrchestrationV2DomainEvent, { type: "run.created" }> {
return {
id: EventId.make(`run:${owner}:${id}:${status}`),
threadId: owner,
occurredAt: at(1),
type: "run.created",
payload: {
id,
threadId: owner,
ordinal,
providerInstanceId,
modelSelection: { instanceId: providerInstanceId, model: "gpt-6" },
providerThreadId: null,
userMessageId: MessageId.make("prompt"),
rootNodeId: null,
activeAttemptId: null,
status,
requestedAt: at(1),
startedAt: at(1),
completedAt: at(2),
checkpointId: null,
contextHandoffId: null,
},
};
}
const commit = Effect.fn("ThreadFindTest.commit")(function* (
events: readonly OrchestrationV2DomainEvent[],
) {
const store = yield* EventStore.EventStoreV2;
const projection = yield* ProjectionStore.ProjectionStoreV2;
yield* store.append({ events });
yield* Effect.forEach(events, projection.apply, { discard: true });
});
const putItems = (items: readonly OrchestrationV2TurnItem[], version = "initial") =>
commit(
items.map((payload) => ({
id: EventId.make(`${payload.threadId}:${payload.id}:${version}`),
threadId: payload.threadId,
occurredAt: at(1),
type: "turn-item.updated" as const,
payload,
})),
);
const setup = Effect.gen(function* () {
yield* createProject(projectId);
yield* commit([thread(threadId, projectId), run()]);
return yield* ProjectionStore.ProjectionStoreV2;
});
const main = Effect.gen(function* () {
const projection = yield* setup;
yield* putItems(Array.from({ length: 2600 }, (_, i) => item(`message:${i}`, i,
`Document ${i}: **needle builder beta${i % 2 === 0 ? " protocol" : ""}${i % 3 === 0 ? " memory" : ""}${i % 5 === 0 ? " alpha" : ""}**. ` +
`Searchable fixture ${i} checks different query prefixes. `.repeat(5),
i % 13 === 0 ? "proposed_plan" : i % 7 === 0 ? "user_message" : "assistant_message")));
const queries = ["nee", "need", "needle", "bui", "buil", "build", "builde", "builder", "proto", "protoc", "protoco", "protocol", "mem", "memo", "memor", "memory", "alp", "alph", "alpha", "bet", "beta"];
const rows = [];
global.gc();
const heapBefore = process.memoryUsage().heapUsed;
let peakHeap = heapBefore;
for (const query of queries) {
let payloadBatches = 0;
let statements = 0;
let firstMs = 0;
const tracer = Tracer.make({
span(options) {
if (options.name === "ThreadFind.load") payloadBatches++;
const span = new Tracer.NativeSpan(options);
const end = span.end.bind(span);
span.end = (time, exit) => { end(time, exit); if (span.attributes.has("db.query.text")) statements++; };
return span;
},
});
const start = performance.now();
const frames = yield* projection.searchThreadStream({ threadId, query }).pipe(
Stream.tap(() => Effect.sync(() => { if (firstMs === 0) firstMs = performance.now() - start; })),
Stream.runCollect,
Effect.withTracer(tracer),
);
const totalMs = performance.now() - start;
const result = frames[frames.length - 1];
const divisor = query.startsWith("pro") ? 2 : query.startsWith("mem") ? 3 : query.startsWith("alp") ? 5 : 1;
assert.equal(result.totalMatches, Math.ceil(2600 / divisor));
assert.equal(result.match.entryId, "message:0");
const hash = createHash("sha256").update(JSON.stringify(frames)).digest("hex");
peakHeap = Math.max(peakHeap, process.memoryUsage().heapUsed);
rows.push({ query, totalMs, firstMs, payloadBatches, statements, hash, totalMatches: result.totalMatches });
}
global.gc();
console.log(JSON.stringify({ node: process.version, items: 2600, rows, heapBefore, heapAfter: process.memoryUsage().heapUsed, peakHeap }));
});
await Effect.runPromise(main.pipe(Effect.provide(layerTest)));
$ node scripts/check-changed.ts ⊘ cache disabled
check:changed: 2 files since 47f2c8d29e98 (origin/main)
> vp format pass 1.6s
Checking formatting...
All matched files use the correct format.
Finished in 770ms on 2 files using 8 threads.
> vp lint pass 2.5s
> vp knip 1/2 pass 186.1s
> vp knip 2/2 pass 397.1s
> vp graphql (apps/server) pass 2.8s
~/apps/server$ graphqlgen --check ⊘ cache disabled
> vp typecheck (3 packages) pass 2.6s
~/scripts$ tsc --noEmit ◉ cache hit, replaying
~/evals$ tsc --noEmit ◉ cache hit, replaying
~/apps/server$ tsc --noEmit ◉ cache hit, replaying
---
vp run: 3/3 cache hit (100%), 3/3 successful, 331.94s saved. (Run `vp run --last-details` for full details)
> vp test (2 files) pass 73.0s
RUN v5.0.5 <checkout>
Test Files 2 passed (2)
Tests 21 passed (21)
Start at 18:37:07
Duration 62.59s (transform 51%, import 29%, setup 11%, tests 9%)
check:changed summary
pass format 1.6s
pass lint 2.5s
pass knip 1/2 186.1s
pass knip 2/2 397.1s
pass graphql (apps/server) 2.8s
pass typecheck (3 packages) 2.6s
pass test (2 files) 73.0s
CI also runs: full test suites, build
unused patch check skipped: no dependency files changed
note: You are running `vp test` as a Vite+ built-in command. If you meant to run the test npm script, use `vpr test` instead.
RUN v5.0.5 /home/sonance/.t3/worktrees/t3code/t3-9a52ceba
Test Files 1 passed (1)
Tests 20 passed (20)
Start at 18:22:58
Duration 35.37s (transform 45%, tests 26%, import 15%, setup 14%)
note: You are running `vp test` as a Vite+ built-in command. If you meant to run the test npm script, use `vpr test` instead.
RUN v5.0.5 <checkout>
stdout | src/orchestration-v2/ThreadFind.test.ts > V2 thread find > finds matches beyond the recent history window
[18:10:06.365] ERROR (#1): Error [AssertionError]: expected 10 to equal 5
at <checkout>/apps/server/src/orchestration-v2/ThreadFind.test.ts:472:14 {
actual: 10,
expected: 5,
showDiff: true,
operator: 'strictEqual',
[cause]: undefined
}
❯ |t3| src/orchestration-v2/ThreadFind.test.ts (17 tests | 1 failed | 16 skipped) 269ms
❯ V2 thread find (14)
× finds matches beyond the recent history window 266ms
⎯⎯⎯⎯⎯⎯⎯ Failed Tests 1 ⎯⎯⎯⎯⎯⎯⎯
FAIL |t3| src/orchestration-v2/ThreadFind.test.ts > V2 thread find > finds matches beyond the recent history window
AssertionError: expected 10 to equal 5
- Expected
+ Received
- 5
+ 10
❯ src/orchestration-v2/ThreadFind.test.ts:472:14
470| assert.equal(changed.totalMatches, 518);
471| assert.equal(changed.match?.entryId, "message:0");
472| assert.equal(payloadBatches, 5);
| ^
473| const last = yield* projection.searchThread({ threadId, query: "…
474| assert.equal(first.totalMatches, 2);
❯ ~effect/Effect/successCont ../../node_modules/.pnpm/[email protected]/node_modules/effect/src/internal/effect.ts:1422:28
❯ ~effect/Effect/evaluate ../../node_modules/.pnpm/[email protected]/node_modules/effect/src/internal/core.ts:585:30
❯ FiberImpl.runLoop ../../node_modules/.pnpm/[email protected]/node_modules/effect/src/internal/effect.ts:654:41
❯ FiberImpl.evaluate ../../node_modules/.pnpm/[email protected]/node_modules/effect/src/internal/effect.ts:595:23
❯ FiberImpl.evaluate ../../node_modules/.pnpm/[email protected]/node_modules/effect/src/internal/effect.ts:589:27
❯ Array.<anonymous> ../../node_modules/.pnpm/[email protected]/node_modules/effect/src/internal/effect.ts:1025:13
❯ MixedSchedulerDispatcher.runTasks ../../node_modules/.pnpm/[email protected]/node_modules/effect/src/Scheduler.ts:254:17
⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯[1/1]⎯
Test Files 1 failed (1)
Tests 1 failed | 16 skipped (17)
Start at 18:09:54
Duration 12.10s (transform 73%, import 13%, setup 11%, tests 2%)

Review ledger

Reviewer selected from orchestrator_capabilities: Claude Opus5.5 (claudeAgent/claude-opus-5-5), effort xhigh. Implementation GPT6.1Sol/Codex xhigh.

Round1: APPROVE, only nits. Diff147insertions/19deletions across2files. Reviewer independently reran20focused tests.

  • S1 nit: rendered segments can retain larger source slices than their visible text size. Accepted; sourceLength now participates in2097152text-code-unit budget alongside rendered segments. No raw payloads or decoded item objects stored. Source-length metadata is stripped from query-result cache. New hidden-data-URI regression failed before fix (1payload batch vs expected2), passes with fix (20/20 Find tests).
  • S2 nit:8193-row item-limit test too expensive for trivial length guard. Accepted; removed that case. Existing text-budget case retained and extended with meaningful hidden-source retention case (65rows each).

Round2: APPROVE on current behavior diff. S1 and S2 resolved. N1 nit accepted: reduce rendered-text fixture to2500 repetitions so source alone fits budget but source+segments exceeds it, pinning the combined budget. Test-only assertion fixture adjustment; no behavior changes since approval and no further round needed. Final diff remains2files. No implementation reviewer delegation or parallel reviewers. Usage not exposed.

import json, pathlib, subprocess, os, statistics
folder = pathlib.Path(__file__).resolve().parent
results = {}
for pair in range(5):
for mode in (('baseline', 'final') if pair % 2 == 0 else ('final', 'baseline')):
cmd = ['node', '--expose-gc']
if mode == 'baseline': cmd += ['--import', str(folder / 'baseline-hook.mjs')]
cmd += [str(folder / 'benchmark.ts'), str(folder / f'{mode}-{pair}.sqlite')]
with (folder / f'{mode}-{pair}.log').open('w') as out, (folder / f'{mode}-{pair}.stderr').open('w') as err:
subprocess.run(cmd, stdout=out, stderr=err, check=True)
data = json.loads((folder / f'{mode}-{pair}.log').read_text().splitlines()[-1])
(folder / f'{mode}-{pair}.json').write_text(json.dumps(data, indent=2)+'\n')
results[(mode, pair)] = data
a,b = results[('baseline',pair)],results[('final',pair)]
assert [(r['query'], r['hash']) for r in a['rows']] == [(r['query'],r['hash']) for r in b['rows']]
print(f'pair {pair + 1}: all 21 streamed responses identical', flush=True)
summary = {'environment': {'node': subprocess.check_output(['node','--version'],text=True).strip(), 'platform': os.uname().sysname, 'arch': os.uname().machine, 'load_average_at_end': os.getloadavg()},'pairs':5,'items':2600,'queries_per_process':21,'parity':'all 105 baseline/final streamed response pairs identical'}
for mode in ('baseline','final'):
data=[results[(mode,p)] for p in range(5)]
per_process=[]
for d in data:
rows=d['rows'][1:]
per_process.append({'firstMs':statistics.median(r['firstMs'] for r in rows), 'totalMs':statistics.median(r['totalMs'] for r in rows),'warm_payload_batches':sum(r['payloadBatches'] for r in rows),'warm_sql_statements':sum(r['statements'] for r in rows),'coldTotalMs':d['rows'][0]['totalMs'],'coldFirstMs':d['rows'][0]['firstMs'],'retainedHeapGrowth':d['heapAfter']-d['heapBefore'],'sampledPeakHeap':d['peakHeap']})
summary[mode] = {'runs':per_process,'medians':{k:statistics.median(r[k] for r in per_process) for k in per_process[0]}}
(folder/'summary.json').write_text(json.dumps(summary,indent=2)+'\n')
print(json.dumps(summary,indent=2))
note: You are running `vp test` as a Vite+ built-in command. If you meant to run the test npm script, use `vpr test` instead.
RUN v5.0.5 <checkout>
stdout | src/orchestration-v2/ThreadFind.test.ts > V2 thread find > does not retain rendered snapshots over the source text budget
[18:22:37.421] ERROR (#1): Error [AssertionError]: expected 1 to equal 2
at <checkout>/apps/server/src/orchestration-v2/ThreadFind.test.ts:240:16 {
actual: 1,
expected: 2,
showDiff: true,
operator: 'strictEqual',
[cause]: undefined
}
❯ |t3| src/orchestration-v2/ThreadFind.test.ts (20 tests | 1 failed | 19 skipped) 387ms
❯ V2 thread find (17)
× does not retain rendered snapshots over the source text budget 385ms
⎯⎯⎯⎯⎯⎯⎯ Failed Tests 1 ⎯⎯⎯⎯⎯⎯⎯
FAIL |t3| src/orchestration-v2/ThreadFind.test.ts > V2 thread find > does not retain rendered snapshots over the source text budget
AssertionError: expected 1 to equal 2
- Expected
+ Received
- 2
+ 1
❯ src/orchestration-v2/ThreadFind.test.ts:240:16
238| .pipe(Effect.withTracer(loads.tracer));
239| assert.equal(second.totalMatches, first.totalMatches);
240| assert.equal(loads.batches(), initialBatches * 2);
| ^
241| }).pipe(Effect.provide(layerTest)),
242| );
❯ ~effect/Effect/successCont ../../node_modules/.pnpm/[email protected]/node_modules/effect/src/internal/effect.ts:1422:28
❯ ~effect/Effect/evaluate ../../node_modules/.pnpm/[email protected]/node_modules/effect/src/internal/core.ts:585:30
❯ FiberImpl.runLoop ../../node_modules/.pnpm/[email protected]/node_modules/effect/src/internal/effect.ts:654:41
❯ FiberImpl.evaluate ../../node_modules/.pnpm/[email protected]/node_modules/effect/src/internal/effect.ts:595:23
❯ FiberImpl.evaluate ../../node_modules/.pnpm/[email protected]/node_modules/effect/src/internal/effect.ts:589:27
❯ Array.<anonymous> ../../node_modules/.pnpm/[email protected]/node_modules/effect/src/internal/effect.ts:1025:13
❯ MixedSchedulerDispatcher.runTasks ../../node_modules/.pnpm/[email protected]/node_modules/effect/src/Scheduler.ts:254:17
⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯[1/1]⎯
Test Files 1 failed (1)
Tests 1 failed | 19 skipped (20)
Start at 18:22:11
Duration 25.92s (transform 61%, setup 26%, import 11%, tests 2%)
{
"environment": {
"node": "v26.12.1",
"platform": "Linux",
"arch": "aarch64",
"load_average_at_end": [
30.14892578125,
26.20556640625,
16.81494140625
]
},
"pairs": 5,
"items": 2600,
"queries_per_process": 21,
"parity": "all 105 baseline/final streamed response pairs identical",
"baseline": {
"runs": [
{
"firstMs": 131.51492549999966,
"totalMs": 342.13886699999966,
"warm_payload_batches": 420,
"warm_sql_statements": 540,
"coldTotalMs": 2874.1732429999993,
"coldFirstMs": 373.17375899999934,
"retainedHeapGrowth": 15762016,
"sampledPeakHeap": 233006272
},
{
"firstMs": 236.80933399999776,
"totalMs": 485.65068849999807,
"warm_payload_batches": 420,
"warm_sql_statements": 540,
"coldTotalMs": 5054.2647529999995,
"coldFirstMs": 341.66536300000007,
"retainedHeapGrowth": 12676528,
"sampledPeakHeap": 177299432
},
{
"firstMs": 122.45399149999866,
"totalMs": 313.669922999994,
"warm_payload_batches": 420,
"warm_sql_statements": 540,
"coldTotalMs": 4648.888676000002,
"coldFirstMs": 874.3518729999996,
"retainedHeapGrowth": 15779752,
"sampledPeakHeap": 239205064
},
{
"firstMs": 76.05392699999902,
"totalMs": 239.50774899999942,
"warm_payload_batches": 420,
"warm_sql_statements": 540,
"coldTotalMs": 2064.365283,
"coldFirstMs": 173.99210099999982,
"retainedHeapGrowth": 12779840,
"sampledPeakHeap": 159131096
},
{
"firstMs": 128.77815399999963,
"totalMs": 306.1579485000002,
"warm_payload_batches": 420,
"warm_sql_statements": 540,
"coldTotalMs": 2364.077704000001,
"coldFirstMs": 411.69549299999926,
"retainedHeapGrowth": 15771328,
"sampledPeakHeap": 241243000
}
],
"medians": {
"firstMs": 128.77815399999963,
"totalMs": 313.669922999994,
"warm_payload_batches": 420,
"warm_sql_statements": 540,
"coldTotalMs": 2874.1732429999993,
"coldFirstMs": 373.17375899999934,
"retainedHeapGrowth": 15762016,
"sampledPeakHeap": 233006272
}
},
"final": {
"runs": [
{
"firstMs": 3.585863999999674,
"totalMs": 28.891853000000083,
"warm_payload_batches": 0,
"warm_sql_statements": 40,
"coldTotalMs": 3006.967681,
"coldFirstMs": 249.4457340000008,
"retainedHeapGrowth": 8663160,
"sampledPeakHeap": 106835168
},
{
"firstMs": 5.768279500000062,
"totalMs": 54.17111300000033,
"warm_payload_batches": 0,
"warm_sql_statements": 40,
"coldTotalMs": 3180.9776810000003,
"coldFirstMs": 985.3852479999987,
"retainedHeapGrowth": 8654448,
"sampledPeakHeap": 111379672
},
{
"firstMs": 2.7595750000000407,
"totalMs": 20.27221649999956,
"warm_payload_batches": 0,
"warm_sql_statements": 40,
"coldTotalMs": 3764.5449720000015,
"coldFirstMs": 472.87386499999957,
"retainedHeapGrowth": 8684016,
"sampledPeakHeap": 106892008
},
{
"firstMs": 1.7255790000017441,
"totalMs": 16.60758700000224,
"warm_payload_batches": 0,
"warm_sql_statements": 40,
"coldTotalMs": 2169.702104,
"coldFirstMs": 454.32347899999877,
"retainedHeapGrowth": 8653664,
"sampledPeakHeap": 102233080
},
{
"firstMs": 3.2914214999982505,
"totalMs": 30.157964499998343,
"warm_payload_batches": 0,
"warm_sql_statements": 40,
"coldTotalMs": 5257.120583999997,
"coldFirstMs": 814.6838119999957,
"retainedHeapGrowth": 8688464,
"sampledPeakHeap": 112999128
}
],
"medians": {
"firstMs": 3.2914214999982505,
"totalMs": 28.891853000000083,
"warm_payload_batches": 0,
"warm_sql_statements": 40,
"coldTotalMs": 3180.9776810000003,
"coldFirstMs": 472.87386499999957,
"retainedHeapGrowth": 8663160,
"sampledPeakHeap": 106892008
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment