Find answers from the community

Home
Members
iamrandom
i
iamrandom
Offline, last seen 3 months ago
Joined September 25, 2024
Hey there, new to the community.
A while ago, I was building a similarity search module and then using llama_index RetrieverQueryEngine.
I was initially using v0.6.20 so I was building the response_synthesizer like this:

Plain Text
response_synthesizer = ResponseSynthesizer.from_args(
            node_postprocessors=[
                SimilarityPostprocessor(
                    similarity_cutoff=config_params["retrieval"]["similarity_cutoff"]
                )
            ]
        )

However, when I imported Node:
Plain Text
from llama_index.data_structs import Node
, I started getting the error
Plain Text
ImportError: cannot import name 'BaseCache' from 'langchain'
.
I updated the llama_index version to 0.8.64.post1 but I think ResponseSynthesizer was updated.
I can't seem to find how to use node_postprocessors with the get_response_synthesizer. I may be missing something basic, any suggestions?
Thanks
3 comments
i
L