perf: Intern string constants #174
Triggered via pull request
September 22, 2024 19:51
Status
Success
Total duration
46m 34s
Artifacts
–
Annotations
1 warning and 2 notices
benchmark
The following actions use a deprecated Node.js version and will be forced to run on node20: actions/cache@v3. For more info: https://github.blog/changelog/2024-03-07-github-actions-all-actions-will-run-on-node20-instead-of-node16-by-default/
|
Benchmark results:
libs/langgraph/langgraph/constants.py#L1
.........................................
fanout_to_subgraph_10x: Mean +- std dev: 60.3 ms +- 1.6 ms
.........................................
WARNING: the benchmark result may be unstable
* the standard deviation (8.36 ms) is 14% of the mean (59.1 ms)
Try to rerun the benchmark with more runs, values and/or loops.
Run 'python -m pyperf system tune' command to reduce the system jitter.
Use pyperf stats, pyperf dump and pyperf hist to analyze results.
Use --quiet option to hide these warnings.
fanout_to_subgraph_10x_sync: Mean +- std dev: 59.1 ms +- 8.4 ms
.........................................
fanout_to_subgraph_10x_checkpoint: Mean +- std dev: 78.8 ms +- 1.3 ms
.........................................
fanout_to_subgraph_10x_checkpoint_sync: Mean +- std dev: 83.4 ms +- 0.8 ms
.........................................
fanout_to_subgraph_100x: Mean +- std dev: 599 ms +- 12 ms
.........................................
fanout_to_subgraph_100x_sync: Mean +- std dev: 511 ms +- 6 ms
.........................................
fanout_to_subgraph_100x_checkpoint: Mean +- std dev: 847 ms +- 25 ms
.........................................
fanout_to_subgraph_100x_checkpoint_sync: Mean +- std dev: 801 ms +- 11 ms
.........................................
react_agent_10x: Mean +- std dev: 42.1 ms +- 3.8 ms
.........................................
react_agent_10x_sync: Mean +- std dev: 29.9 ms +- 0.4 ms
.........................................
react_agent_10x_checkpoint: Mean +- std dev: 53.4 ms +- 1.5 ms
.........................................
react_agent_10x_checkpoint_sync: Mean +- std dev: 43.2 ms +- 3.4 ms
.........................................
react_agent_100x: Mean +- std dev: 417 ms +- 6 ms
.........................................
react_agent_100x_sync: Mean +- std dev: 333 ms +- 4 ms
.........................................
react_agent_100x_checkpoint: Mean +- std dev: 937 ms +- 15 ms
.........................................
react_agent_100x_checkpoint_sync: Mean +- std dev: 834 ms +- 16 ms
.........................................
wide_state_25x300: Mean +- std dev: 20.4 ms +- 0.3 ms
.........................................
wide_state_25x300_sync: Mean +- std dev: 12.9 ms +- 0.2 ms
.........................................
wide_state_25x300_checkpoint: Mean +- std dev: 240 ms +- 8 ms
.........................................
wide_state_25x300_checkpoint_sync: Mean +- std dev: 238 ms +- 16 ms
.........................................
wide_state_15x600: Mean +- std dev: 23.6 ms +- 0.3 ms
.........................................
wide_state_15x600_sync: Mean +- std dev: 14.8 ms +- 0.2 ms
.........................................
wide_state_15x600_checkpoint: Mean +- std dev: 414 ms +- 11 ms
.........................................
wide_state_15x600_checkpoint_sync: Mean +- std dev: 418 ms +- 20 ms
.........................................
wide_state_9x1200: Mean +- std dev: 23.7 ms +- 0.4 ms
.........................................
wide_state_9x1200_sync: Mean +- std dev: 14.9 ms +- 0.4 ms
.........................................
wide_state_9x1200_checkpoint: Mean +- std dev: 268 ms +- 8 ms
.........................................
wide_state_9x1200_checkpoint_sync: Mean +- std dev: 269 ms +- 16 ms
|
Comparison against main:
libs/langgraph/langgraph/constants.py#L1
+----------------------------------------+---------+-----------------------+
| Benchmark | main | changes |
+========================================+=========+=======================+
| react_agent_100x_sync | 343 ms | 333 ms: 1.03x faster |
+----------------------------------------+---------+-----------------------+
| wide_state_15x600_checkpoint | 426 ms | 414 ms: 1.03x faster |
+----------------------------------------+---------+-----------------------+
| wide_state_9x1200_checkpoint | 274 ms | 268 ms: 1.02x faster |
+----------------------------------------+---------+-----------------------+
| wide_state_15x600 | 24.1 ms | 23.6 ms: 1.02x faster |
+----------------------------------------+---------+-----------------------+
| wide_state_25x300 | 20.8 ms | 20.4 ms: 1.02x faster |
+----------------------------------------+---------+-----------------------+
| wide_state_9x1200 | 24.1 ms | 23.7 ms: 1.02x faster |
+----------------------------------------+---------+-----------------------+
| wide_state_25x300_checkpoint | 243 ms | 240 ms: 1.01x faster |
+----------------------------------------+---------+-----------------------+
| fanout_to_subgraph_10x_checkpoint | 79.5 ms | 78.8 ms: 1.01x faster |
+----------------------------------------+---------+-----------------------+
| fanout_to_subgraph_10x_checkpoint_sync | 84.1 ms | 83.4 ms: 1.01x faster |
+----------------------------------------+---------+-----------------------+
| react_agent_100x | 419 ms | 417 ms: 1.01x faster |
+----------------------------------------+---------+-----------------------+
| fanout_to_subgraph_100x_sync | 508 ms | 511 ms: 1.00x slower |
+----------------------------------------+---------+-----------------------+
| react_agent_100x_checkpoint_sync | 827 ms | 834 ms: 1.01x slower |
+----------------------------------------+---------+-----------------------+
| fanout_to_subgraph_10x | 59.8 ms | 60.3 ms: 1.01x slower |
+----------------------------------------+---------+-----------------------+
| wide_state_9x1200_sync | 14.7 ms | 14.9 ms: 1.01x slower |
+----------------------------------------+---------+-----------------------+
| react_agent_100x_checkpoint | 926 ms | 937 ms: 1.01x slower |
+----------------------------------------+---------+-----------------------+
| wide_state_9x1200_checkpoint_sync | 264 ms | 269 ms: 1.02x slower |
+----------------------------------------+---------+-----------------------+
| wide_state_25x300_checkpoint_sync | 234 ms | 238 ms: 1.02x slower |
+----------------------------------------+---------+-----------------------+
| react_agent_10x | 39.6 ms | 42.1 ms: 1.06x slower |
+----------------------------------------+---------+-----------------------+
| fanout_to_subgraph_100x | 554 ms | 599 ms: 1.08x slower |
+----------------------------------------+---------+-----------------------+
| fanout_to_subgraph_100x_checkpoint | 767 ms | 847 ms: 1.11x slower |
+----------------------------------------+---------+-----------------------+
| Geometric mean | (ref) | 1.00x slower |
+----------------------------------------+---------+-----------------------+
Benchmark hidden because not significant (8): react_agent_10x_checkpoint_sync, fanout_to_subgraph_10x_sync, react_agent_10x_sync, wide_state_15x600_sync, wide_state_15x600_checkpoint_sync, fanout_to_subgraph_100x_checkpoint_sync, react_agent_10x_checkpoint, wide_state_25x300_sync
|