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

community[patch]: update libs/langchain-community/src/vectorstores/analyticdb.ts #5025

Merged
merged 4 commits into from
Apr 12, 2024

Conversation

lz82
Copy link
Contributor

@lz82 lz82 commented Apr 9, 2024

Fixes # (issue)
When the pageContent is empty in certain scenarios (such as when using unstructuredIo), an error occurs during embedding.

lz82 added 2 commits April 9, 2024 14:09
When the pageContent is empty in certain scenarios (such as when using unstructuredIo), an error occurs during embedding.
Update analyticdb.ts When the pageContent is empty in certain scenarios (such as when using unstructuredIo), an error occurs during embedding.
@dosubot dosubot bot added the size:XS This PR changes 0-9 lines, ignoring generated files. label Apr 9, 2024
Copy link

vercel bot commented Apr 9, 2024

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

Name Status Preview Comments Updated (UTC)
langchainjs-api-refs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Apr 12, 2024 9:50pm
langchainjs-docs ✅ Ready (Inspect) Visit Preview Apr 12, 2024 9:50pm

@jacoblee93
Copy link
Collaborator

Thanks for this!

Is the issue empty string or undefined/null? Fine with defensive programming here but would it make sense to apply a fix to Unstructured too?

@jacoblee93 jacoblee93 added the question Further information is requested label Apr 11, 2024
@lz82
Copy link
Contributor Author

lz82 commented Apr 12, 2024

Thanks for this!

Is the issue empty string or undefined/null? Fine with defensive programming here but would it make sense to apply a fix to Unstructured too?

I've encountered a scenario where loading PDF files using https://unstructured.io/ results in some content being parsed as undefined. While it's possible to implement a fix before writing to the ADB, I believe that the purpose of langchain is to facilitate easier integration between upstream and downstream processes.

Wouldn't it be more efficient for the langchain to handle these cases of undefined values, ensuring a smoother data flow and reducing the need for additional checks and fixes on the client side?

@jacoblee93
Copy link
Collaborator

Yeah we can, I'm thinking we should add this to the unstructured loader too since this won't be the only integration that will deal with it.

Fine for now!

@dosubot dosubot bot added size:S This PR changes 10-29 lines, ignoring generated files. and removed size:XS This PR changes 0-9 lines, ignoring generated files. labels Apr 12, 2024
@jacoblee93 jacoblee93 changed the title update libs/langchain-community/src/vectorstores/analyticdb.ts langchain[patch]: update libs/langchain-community/src/vectorstores/analyticdb.ts Apr 12, 2024
@jacoblee93 jacoblee93 changed the title langchain[patch]: update libs/langchain-community/src/vectorstores/analyticdb.ts community[patch]: update libs/langchain-community/src/vectorstores/analyticdb.ts Apr 12, 2024
@jacoblee93 jacoblee93 merged commit ee3df7a into langchain-ai:main Apr 12, 2024
16 checks passed
@jacoblee93
Copy link
Collaborator

Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
auto:bug Related to a bug, vulnerability, unexpected error with an existing feature question Further information is requested size:S This PR changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants