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

fix: Fix Langchain performance issue #221

Merged
merged 10 commits into from
Oct 16, 2024
Merged

Conversation

marikaner
Copy link
Contributor

@marikaner marikaner commented Oct 14, 2024

Context

AI/gen-ai-hub-sdk-js-backlog#158.
Closes #213

We were sending embedding requests individually. This PR changes this to send them as a batch.

Copy link
Member

@MatKuhr MatKuhr left a comment

Choose a reason for hiding this comment

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

LGTM, aside from the build failure (I am guessing that is related to the changes to mock-http.ts, so unrelated to the embedding fix).

packages/langchain/src/openai/embedding.ts Show resolved Hide resolved
@MatKuhr MatKuhr enabled auto-merge (squash) October 16, 2024 09:28
@MatKuhr MatKuhr merged commit 99498cd into main Oct 16, 2024
9 checks passed
@MatKuhr MatKuhr deleted the langchain-performance-issue branch October 16, 2024 09:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Performance issues while creating embeddings with ai-sdk-js
2 participants