Skip to content

bug: Slow vector parameter pass #664

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

Open
azevaykin opened this issue May 2, 2025 · 2 comments
Open

bug: Slow vector parameter pass #664

azevaykin opened this issue May 2, 2025 · 2 comments
Labels
bug Something isn't working

Comments

@azevaykin
Copy link

Bug Report

YDB Python SDK version: 3.21.1
Python version: 3.8.10
OS: Linux-5.4.210-39.1.pagevecsize-x86_64-with-glibc2.29

Behavior:

  1. When I pass a vector to the query as a list, I have 127 RPS.
  2. When I pass a vector to the query as a string, I have 617 RPS.

First way is the default way in YDB vector search. It's used in langchain-ydb. But it's slower.
Second way is undocumented way but it's much faster.

In C++ SDK we have numbers: 810 and 860 RPS.

Please, fix vector pass as a list in python SDK. 127 RPS is too slow.

See an example in the attached python file: vector-parameter.py.

You can change behaviour by these lines:

MODE = "list"
# MODE = "string"
@azevaykin azevaykin added the bug Something isn't working label May 2, 2025
@azevaykin
Copy link
Author

@vgvoleg , please have a look

@azevaykin
Copy link
Author

@asmyasnikov , please have a look

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant