Find answers from the community

Updated 5 months ago

hey everyone

At a glance

The community member is using QdrantVectorStore and wants to modify the metadata received or retrieved from the vector store before sending it to an LLM to generate a response. The comments suggest two ways to do this:

1. Create a retriever, update the node metadata, and then directly ask the LLM with the entire node content and the query.

2. Create a custom node postprocessor, update the node metadata after the retrieval process, and then send it to the LLM. The comments indicate that this is the better option.

One community member suggests trying the second option first and provides a link to the relevant documentation.

Useful resources
hey everyone
i am using QdrantVectorStore i want to modify the metadata received / retrived from the vector store, before i send it to llm to generate the response any tips how can i do that
W
i
2 comments
You can create a retriever and once you have the relevant nodes you can update the node metadata and then directly ask the llm with llm.complete(ENTIRE NODES content + your query )


Second way would be to create a custom node postprocessor, you can update the nodes metadata after retrieval process here. and then it will go to llm.


I would suggest you try the second option first.

https://docs.llamaindex.ai/en/stable/module_guides/querying/node_postprocessors/?h=node+po#custom-node-postprocessor
Second way would be to create a custom node postprocessor, you can update the nodes metadata after retrieval process here. and then it will go to llm.

This is 100% the better way
Add a reply
Sign up and join the conversation on Discord