Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Codeblock ref rendering #2649

Merged
merged 2 commits into from
Dec 5, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions libs/checkpoint-postgres/langgraph/store/postgres/base.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import asyncio

Check notice on line 1 in libs/checkpoint-postgres/langgraph/store/postgres/base.py

View workflow job for this annotation

GitHub Actions / benchmark

Benchmark results

......................................... fanout_to_subgraph_10x: Mean +- std dev: 61.7 ms +- 1.5 ms ......................................... fanout_to_subgraph_10x_sync: Mean +- std dev: 51.6 ms +- 0.8 ms ......................................... fanout_to_subgraph_10x_checkpoint: Mean +- std dev: 91.6 ms +- 7.6 ms ......................................... fanout_to_subgraph_10x_checkpoint_sync: Mean +- std dev: 94.1 ms +- 0.9 ms ......................................... fanout_to_subgraph_100x: Mean +- std dev: 595 ms +- 22 ms ......................................... fanout_to_subgraph_100x_sync: Mean +- std dev: 504 ms +- 5 ms ......................................... fanout_to_subgraph_100x_checkpoint: Mean +- std dev: 926 ms +- 39 ms ......................................... fanout_to_subgraph_100x_checkpoint_sync: Mean +- std dev: 929 ms +- 15 ms ......................................... react_agent_10x: Mean +- std dev: 30.8 ms +- 0.6 ms ......................................... react_agent_10x_sync: Mean +- std dev: 22.5 ms +- 0.3 ms ......................................... react_agent_10x_checkpoint: Mean +- std dev: 47.0 ms +- 0.9 ms ......................................... react_agent_10x_checkpoint_sync: Mean +- std dev: 36.7 ms +- 0.5 ms ......................................... react_agent_100x: Mean +- std dev: 341 ms +- 6 ms ......................................... react_agent_100x_sync: Mean +- std dev: 271 ms +- 3 ms ......................................... react_agent_100x_checkpoint: Mean +- std dev: 938 ms +- 10 ms ......................................... react_agent_100x_checkpoint_sync: Mean +- std dev: 836 ms +- 7 ms ......................................... wide_state_25x300: Mean +- std dev: 24.1 ms +- 0.4 ms ......................................... wide_state_25x300_sync: Mean +- std dev: 15.4 ms +- 0.1 ms ......................................... wide_state_25x300_checkpoint: Mean +- std dev: 279 ms +- 4 ms ......................................... wide_state_25x300_checkpoint_sync: Mean +- std dev: 267 ms +- 4 ms ......................................... wide_state_15x600: Mean +- std dev: 28.1 ms +- 0.5 ms ......................................... wide_state_15x600_sync: Mean +- std dev: 17.8 ms +- 0.1 ms ......................................... wide_state_15x600_checkpoint: Mean +- std dev: 481 ms +- 8 ms ......................................... wide_state_15x600_checkpoint_sync: Mean +- std dev: 466 ms +- 7 ms ......................................... wide_state_9x1200: Mean +- std dev: 28.1 ms +- 0.4 ms ......................................... wide_state_9x1200_sync: Mean +- std dev: 17.8 ms +- 0.1 ms ......................................... wide_state_9x1200_checkpoint: Mean +- std dev: 313 ms +- 3 ms ......................................... wide_state_9x1200_checkpoint_sync: Mean +- std dev: 299 ms +- 5 ms

Check notice on line 1 in libs/checkpoint-postgres/langgraph/store/postgres/base.py

View workflow job for this annotation

GitHub Actions / benchmark

Comparison against main

+-----------------------------------------+---------+-----------------------+ | Benchmark | main | changes | +=========================================+=========+=======================+ | fanout_to_subgraph_100x | 615 ms | 595 ms: 1.03x faster | +-----------------------------------------+---------+-----------------------+ | fanout_to_subgraph_100x_checkpoint | 940 ms | 926 ms: 1.01x faster | +-----------------------------------------+---------+-----------------------+ | wide_state_9x1200_checkpoint | 317 ms | 313 ms: 1.01x faster | +-----------------------------------------+---------+-----------------------+ | react_agent_100x_checkpoint_sync | 845 ms | 836 ms: 1.01x faster | +-----------------------------------------+---------+-----------------------+ | wide_state_15x600_checkpoint_sync | 471 ms | 466 ms: 1.01x faster | +-----------------------------------------+---------+-----------------------+ | wide_state_9x1200 | 28.3 ms | 28.1 ms: 1.01x faster | +-----------------------------------------+---------+-----------------------+ | wide_state_9x1200_sync | 17.9 ms | 17.8 ms: 1.01x faster | +-----------------------------------------+---------+-----------------------+ | react_agent_100x_checkpoint | 946 ms | 938 ms: 1.01x faster | +-----------------------------------------+---------+-----------------------+ | wide_state_25x300_checkpoint | 281 ms | 279 ms: 1.01x faster | +-----------------------------------------+---------+-----------------------+ | wide_state_15x600_checkpoint | 484 ms | 481 ms: 1.01x faster | +-----------------------------------------+---------+-----------------------+ | wide_state_9x1200_checkpoint_sync | 301 ms | 299 ms: 1.01x faster | +-----------------------------------------+---------+-----------------------+ | fanout_to_subgraph_100x_sync | 502 ms | 504 ms: 1.00x slower | +-----------------------------------------+---------+-----------------------+ | react_agent_10x | 30.6 ms | 30.8 ms: 1.01x slower | +-----------------------------------------+---------+-----------------------+ | wide_state_15x600_sync | 17.7 ms | 17.8 ms: 1.01x slower | +-----------------------------------------+---------+-----------------------+ | react_agent_10x_checkpoint | 46.8 ms | 47.0 ms: 1.01x slower | +-----------------------------------------+---------+-----------------------+ | react_agent_100x_sync | 269 ms | 271 ms: 1.01x slower | +-----------------------------------------+---------+-----------------------+ | wide_state_25x300_sync | 15.4 ms | 15.4 ms: 1.01x slower | +-----------------------------------------+---------+-----------------------+ | fanout_to_subgraph_10x_sync | 51.3 ms | 51.6 ms: 1.01x slower | +-----------------------------------------+---------+-----------------------+ | fanout_to_subgraph_100x_checkpoint_sync | 922 ms | 929 ms: 1.01x slower | +-----------------------------------------+---------+-----------------------+ | react_agent_10x_checkpoint_sync | 36.4 ms | 36.7 ms: 1.01x slower | +-----------------------------------------+---------+-----------------------+ | fanout_to_subgraph_10x_checkpoint_sync | 93.4 ms | 94.1 ms: 1.01x slower | +-----------------------------------------+---------+-----------------------+ | fanout_to_subgraph_10x | 61.2 ms | 61.7 ms: 1.01x slower | +-----------------------------------------+---------+-----------------------+ | react_agent_10x_sync | 22.3 ms | 22.5 ms: 1.01x slower | +-----------------------------------------+---------+-----------------------+ | Geometric mean | (ref) | 1.00x faster | +-----------------------------------------+---------+-----------------------+ Benchmark hidden because not significant (5): wide_state_25x300_checkpoint_sync, fanout_to_subgraph_10x_checkpoint, w
import json
import logging
import threading
Expand Down Expand Up @@ -573,6 +573,7 @@

# Search by similarity
results = store.search(("docs",), query="python programming")
```

Note:
Semantic search is disabled by default. You can enable it by providing an `index` configuration
Expand Down
Loading