-
Notifications
You must be signed in to change notification settings - Fork 2k
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
feat: introduce integration with Gradient AI #6179
Conversation
Pull Request Test Coverage Report for Build 6659953333
💛 - Coveralls |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great to see this PR! Looks quite good to me already. I was able to run the end-to-end test locally. 👍
I have some smaller change requests in the comments below. Please also generate a release note with reno as described here: https://github.com/deepset-ai/haystack/blob/main/CONTRIBUTING.md#release-notes You can put your text under preview
in that note.
haystack/preview/components/embedders/gradient_text_embedder.py
Outdated
Show resolved
Hide resolved
haystack/preview/components/embedders/gradient_document_embedder.py
Outdated
Show resolved
Hide resolved
test/preview/components/embedders/test_gradient_document_embedder.py
Outdated
Show resolved
Hide resolved
Added the release notes! let me know |
@mhaligowski Let me try to help you with the CI:
Let me know if you need more help! |
d924819
to
b637865
Compare
@mhaligowski here are the fixes: Preemo-Inc#12 Please merge them into your fork and let's see if they help. One more thing: I noticed that you implemented |
applied the fixes, trying to keep up with your main :) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Left a fix
from haystack.preview import Pipeline, Document | ||
from haystack.components.embedders.gradient_document_embedder import GradientDocumentEmbedder | ||
from haystack.components.embedders.gradient_text_embedder import GradientTextEmbedder | ||
from haystack.preview.document_stores import InMemoryDocumentStore | ||
from haystack.preview.components.writers import DocumentWriter | ||
from haystack.preview.components.retrievers import InMemoryEmbeddingRetriever | ||
from haystack.preview.components.generators.gradient.base import GradientGenerator | ||
from haystack.components.builders.answer_builder import AnswerBuilder | ||
from haystack.components.builders.prompt_builder import PromptBuilder |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The preview
package is gone, here is the fix:
from haystack.preview import Pipeline, Document | |
from haystack.components.embedders.gradient_document_embedder import GradientDocumentEmbedder | |
from haystack.components.embedders.gradient_text_embedder import GradientTextEmbedder | |
from haystack.preview.document_stores import InMemoryDocumentStore | |
from haystack.preview.components.writers import DocumentWriter | |
from haystack.preview.components.retrievers import InMemoryEmbeddingRetriever | |
from haystack.preview.components.generators.gradient.base import GradientGenerator | |
from haystack.components.builders.answer_builder import AnswerBuilder | |
from haystack.components.builders.prompt_builder import PromptBuilder | |
from haystack.core import Pipeline, Document | |
from haystack.components.embedders.gradient_document_embedder import GradientDocumentEmbedder | |
from haystack.components.embedders.gradient_text_embedder import GradientTextEmbedder | |
from haystack.document_stores import InMemoryDocumentStore | |
from haystack.components.writers import DocumentWriter | |
from haystack.components.retrievers import InMemoryEmbeddingRetriever | |
from haystack.components.generators.gradient.base import GradientGenerator | |
from haystack.components.builders.answer_builder import AnswerBuilder | |
from haystack.components.builders.prompt_builder import PromptBuilder |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks like the GradientGenerator wasn't moved out of the preview anyways, so I moved it. All the Gradient tests are passing now in my box!
Superseded by deepset-ai/haystack-core-integrations#72 |
Related Issues
Doesn't have have a related issue.
Proposed Changes:
Gradient AI is a self-managed cloud service for Large Language Models, offering fine-tuning and inference of open-source models and embeddings generation. This PR integrates haystack with Gradient for LLMs and embeddings by adding relevant generators and embedders.
How did you test it?
Notes for the reviewer
pip install -e .[gradient]
,$(gradient env)
command once it's configured.Checklist
[x] I have read the contributors guidelines and the code of conduct
[x]
I have updated the related issue with new insights and changesN/A[x] I added unit tests and updated the docstrings
[x] I've used one of the conventional commit types for my PR title:
fix:
,feat:
,build:
,chore:
,ci:
,docs:
,style:
,refactor:
,perf:
,test:
. NOTE: to be squashed.[x] I documented my code
[x] I ran pre-commit hooks and fixed any issue