Giter Club home page Giter Club logo

Comments (4)

dosubot avatar dosubot commented on July 19, 2024 3

Hey there, @Developer-Atomic-Vishnu! 👋 I'm here to assist you with any bugs, questions, or contributions. Let's tackle this issue together!

To resolve the "Error Building Component Astra DB Search: Invalid inputs provided" issue, ensure that you are providing all the required inputs correctly. The required fields for the AstraDBSearchComponent are:

  • token
  • api_endpoint
  • collection_name
  • input_value
  • embedding

Here is a sample code snippet to illustrate how to provide these inputs:

from langflow.components.vectorstores.AstraDB import AstraDBVectorStoreComponent
from langflow.field_typing import Embeddings, Text

# Example values for the required fields
embedding = Embeddings(...)  # Provide the appropriate embedding object
collection_name = "your_collection_name"
input_value = Text("your_input_value")
token = "your_authentication_token"
api_endpoint = "your_api_endpoint_url"

# Optional parameters
search_type = "Similarity"
number_of_results = 4
namespace = None
metric = None
batch_size = None
bulk_insert_batch_concurrency = None
bulk_insert_overwrite_concurrency = None
bulk_delete_concurrency = None
setup_mode = "Sync"
pre_delete_collection = False
metadata_indexing_include = None
metadata_indexing_exclude = None
collection_indexing_policy = None

# Build the AstraDBSearchComponent
astra_db_search_component = AstraDBSearchComponent()
results = astra_db_search_component.build(
    embedding=embedding,
    collection_name=collection_name,
    input_value=input_value,
    token=token,
    api_endpoint=api_endpoint,
    search_type=search_type,
    number_of_results=number_of_results,
    namespace=namespace,
    metric=metric,
    batch_size=batch_size,
    bulk_insert_batch_concurrency=bulk_insert_batch_concurrency,
    bulk_insert_overwrite_concurrency=bulk_insert_overwrite_concurrency,
    bulk_delete_concurrency=bulk_delete_concurrency,
    setup_mode=setup_mode,
    pre_delete_collection=pre_delete_collection,
    metadata_indexing_include=metadata_indexing_include,
    metadata_indexing_exclude=metadata_indexing_exclude,
    collection_indexing_policy=collection_indexing_policy,
)

Ensure that all the required fields are correctly populated with valid values. If any of these fields are missing or incorrect, you will encounter the "Invalid inputs provided" error. Additionally, make sure that your collection contains a field named 'content' if you are querying it through Langflow [1][2].

To continue talking to Dosu, mention @dosu.

from langflow.

qzg avatar qzg commented on July 19, 2024 1

Workaround: in the Chat Input component's advanced settings, turn off "Return Record"

from langflow.

saeidsm avatar saeidsm commented on July 19, 2024

Hi, I had the same issue, I rolled back to the stable version and del and added new chat and Astra search components. in the new chat you can disable Return records.

from langflow.

Developer-Atomic-Vishnu avatar Developer-Atomic-Vishnu commented on July 19, 2024

Thanks guys that worked very well.

from langflow.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.