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

langchain[minor]: Add async methods to EncoderBackedStore #19597

Merged
merged 3 commits into from
Mar 27, 2024

Conversation

cbornet
Copy link
Collaborator

@cbornet cbornet commented Mar 26, 2024

No description provided.

Copy link

vercel bot commented Mar 26, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

1 Ignored Deployment
Name Status Preview Comments Updated (UTC)
langchain ⬜️ Ignored (Inspect) Visit Preview Mar 27, 2024 5:28pm

@dosubot dosubot bot added size:M This PR changes 30-99 lines, ignoring generated files. Ɑ: vector store Related to vector store module 🤖:improvement Medium size change to existing code to handle new use-cases labels Mar 26, 2024
@cbornet cbornet force-pushed the async-EncoderBackedStore branch from 193873b to 92189b0 Compare March 26, 2024 18:21
@dosubot dosubot bot added the lgtm PR looks good. Use to confirm that a PR is ready for merging. label Mar 26, 2024
@eyurtsev eyurtsev self-requested a review March 27, 2024 14:25
def mset(self, key_value_pairs: Sequence[Tuple[K, V]]) -> None:
"""Set the values for the given keys."""
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, but could you restore the comments? (Even if they are only marginally helpful. It's not obvious that folks will know what the abbrevation mset means)

Generally, we need to move in the direction of more in code documentation rather than less

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since Python 3.5, docstrings are inherited : https://docs.python.org/3/library/inspect.html#inspect.getdoc
In IDEs (at least in PyCharm), the docstring is also inherited.
And it's also inherited in the API reference.
Removing docstrings reduces the amount of lines of code. And makes it easier to improve the doc of all subclasses by improving the parent.

Do you confirm that you prefer to duplicate the doc in subclasses nevertheless ?

@eyurtsev
Copy link
Collaborator

updated doc-strings will merge

@eyurtsev eyurtsev enabled auto-merge (squash) March 27, 2024 17:28
@eyurtsev eyurtsev disabled auto-merge March 27, 2024 17:28
@eyurtsev eyurtsev changed the title langchain: Add async methods to EncoderBackedStore langchain[minor]: Add async methods to EncoderBackedStore Mar 27, 2024
@eyurtsev eyurtsev enabled auto-merge (squash) March 27, 2024 17:28
@eyurtsev eyurtsev merged commit 9954c6a into langchain-ai:master Mar 27, 2024
41 checks passed
@cbornet cbornet deleted the async-EncoderBackedStore branch March 27, 2024 18:02
@cbornet
Copy link
Collaborator Author

cbornet commented Mar 27, 2024

updated doc-strings will merge

OK. So I deduce that the policy for docstrings is to duplicate in the subclass ?

gkorland pushed a commit to FalkorDB/langchain that referenced this pull request Mar 30, 2024
hinthornw pushed a commit that referenced this pull request Apr 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🤖:improvement Medium size change to existing code to handle new use-cases lgtm PR looks good. Use to confirm that a PR is ready for merging. size:M This PR changes 30-99 lines, ignoring generated files. Ɑ: vector store Related to vector store module
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants