Find answers from the community

Home
Members
Sriram Vadlamani
S
Sriram Vadlamani
Offline, last seen 3 months ago
Joined September 25, 2024
Hey guys!
I have a VectorIndexAutoRetriever setup as such:
Plain Text
retriever = VectorIndexAutoRetriever(
    loaded_index,
    vector_store_info=vector_store_info,
    similarity_top_k=5,
    empty_query_top_k=5,  # if only metadata filters are specified, this is the limit
    verbose=True,
)


When I test this with nodes = retrievere.retrieve() call, I get the following error:
Plain Text
pydantic.v1.error_wrappers.ValidationError: 6 validation errors for VectorStoreQuerySpec
filters -> 0 -> value
  value is not a valid integer (type=type_error.integer)
filters -> 0 -> value
  value is not a valid float (type=type_error.float)
filters -> 0 -> value
  str type expected (type=type_error.str)
filters -> 1 -> value
  value is not a valid integer (type=type_error.integer)
filters -> 1 -> value
  value is not a valid float (type=type_error.float)
filters -> 1 -> value
  str type expected (type=type_error.str)


I'm using a weaviate vector store. Does anyone know maybe what the issue is?
11 comments
S
L
Hey guys! I have a custom retriever that uses another LLM to generate Nested Elasticsearch queries and returns a List[NodeWithScore] as a return type where NodeWithScore implements the base class BaseNode.
On this returned list of nodes, I want to perform a similarity top k, so now should I build a new index from this list of nodes? I don't really know how what to do from here, so I thought I'd ask for some advice.
31 comments
S
L
I have a quick question.
I have a few records in a json file as such:
Plain Text
[
  "id": "xxxx",
  "title": "some title",
  "text": "Main text for embeddings"
  "some_other_key": "some_other_value"
  "other_key_2": "other_value_2"
]


I want to make a Document() out of this dictionary where the text should be the key text and the metadata is all other keys from the dictionary except text. Is there a smart way to do this, or do I just have to loop all the keys of the record?
6 comments
S
L
Hey guys!
When we index into a vector store with LlamaIndex (in this case a weaviate vector store)
Plain Text
vector_store = WeaviateVectorStore(
    weaviate_client=client, index_name="Wikiindex_docs"
)
storage_context = StorageContext.from_defaults(vector_store=vector_store)

doc_index = VectorStoreIndex.from_documents([], storage_context=storage_context)

for d in tqdm(docs_list):
    doc_index.insert(d)


Is it that this point that the embeddings are also stored in the Weviate base or are the embeddings computed at the runtime of a query?
5 comments
S
R