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

[Bug] Astra DB Vectorize doesn't allow for Bring-Your-Own-Embedding (BYOE) #4387

Closed
msmygit opened this issue Nov 4, 2024 · 2 comments · Fixed by #4410
Closed

[Bug] Astra DB Vectorize doesn't allow for Bring-Your-Own-Embedding (BYOE) #4387

msmygit opened this issue Nov 4, 2024 · 2 comments · Fixed by #4410
Assignees
Labels
bug Something isn't working

Comments

@msmygit
Copy link
Contributor

msmygit commented Nov 4, 2024

Bug Description

Error building Component Astra DB: Error adding documents to AstraDBVectorStore: AstraDBVectorStore.add_texts could not insert all requested documents (53 failed replace_one calls)
Duration: 1.46 seconds

Reproduction

Steps to reproduce the behavior.

  • Create a workflow similar to this,
image
  • The key here is that, instead of API Key Name, we will provide the key value at Provider API Key and as documented, this Astra DB vector store document should accept a bring-your-own-embedding style setup and properly embedding the input data.

  • My flow is attached here for reference
    Docs_Search_to_AstraDB.json


FWIW, when we add the BYOE key via the Astra portal's integration menu -> add a new key -> marry it with a database -> Come to langflow component -> choose Astra Vectorize -> Choose the API Key name (as we gave it at the Astra portal integration menu) -> this works.

Expected behavior

This setup should just work leveraging the Azure OpenAI embedding provider's key to embed the input text

Who can help?

No response

Operating System

n/a

Langflow Version

DSLF as on 02-Nov-2024

Python Version

None

Screenshot

No response

Flow File

No response

@msmygit msmygit added the bug Something isn't working label Nov 4, 2024
Copy link

dosubot bot commented Nov 4, 2024

The issue you're encountering with the AstraDBVectorStore component when using Bring-Your-Own-Embedding (BYOE) and the Provider API Key might be related to how the component handles API keys and embeddings. Here are a few points to consider:

  1. API Key Handling: The AstraDBVectorStore component uses two parameters for API keys: 'API Key Name' and 'Provider API Key'. The 'API Key Name' is used when the key is stored within Astra's system, while the 'Provider API Key' is used when the key is not stored within Astra and needs to be provided directly with each request [1].

  2. Embedding Process: When using BYOE, ensure that the embedding configuration is correctly set up. The embedding input should be configured properly, either as an "Embeddings" object or a dictionary with the necessary options [1][2].

  3. Error Handling: The error message indicates that there were failed replace_one calls. This could be due to issues with the document format, the embedding process, or the API key configuration. Check the logs for more detailed error messages, as the component uses loguru for logging [3].

  4. Configuration: Double-check the configuration of your embedding model and ensure that all necessary parameters are correctly set. This includes the Azure OpenAI embedding provider's key and any other required settings [4].

If the issue persists, reviewing the specific configurations and logs might provide more insights into the problem.

To continue talking to Dosu, mention @dosu.

@msmygit
Copy link
Contributor Author

msmygit commented Nov 22, 2024

This is not yet fixed

diogocabral pushed a commit to headlinevc/langflow that referenced this issue Nov 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants