-
Notifications
You must be signed in to change notification settings - Fork 122
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
chore: Added init_options property #541
Conversation
✅ Deploy Preview for poetic-froyo-8baba7 ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
Hey @Anush008 It does not sound like the right motivation Could you please provide more details and explain the need? |
@joein, yes. For instances like these. https://discord.com/channels/907569970500743200/1206597766999056435/1206601751747371089 Some frameworks require us to pass SDK instances and not the params to construct those. So instead of forcing users to pass 2 instances(sync, async) of essentially the same thing, we can construct one from the other. |
Could you please explain why do they need to create two instances? |
To implement the sync and async interfaces of the frameworks. Like Langchain for example, has equivalent sync and async methods that've been implemented. https://python.langchain.com/docs/modules/data_connection/vectorstores/#asynchronous-operations |
So can they just use one client or another one? Why do they need to use both simultaneously? What is the use case for having two clients at the same time? |
For example, the So for Qdrant#add_documents(...)
...
await Qdrant#asimiliarity_search(...)
...
await Qdrant#aadd_documents(...)
...
Qdrant#similiarity_search(...) to work, we need the sync and async instances within the |
* chore: Added init_options property * refactor: @Property * test: init_opts * chore: regen async client again with Py 3.10 * chore: deepcopy kwargs
Why?
This change will be helpful in our integration implementations as we won't have to necessitate users to pass instances of both
QdrantClient
andAsyncQdrantClient
. Either one will suffice.