Find answers from the community

Updated 4 weeks ago

Creating a query engine tool with predefined filters

Hello, is it possible to create a query engine tool that makes use of predefined filters when retrieving?

Instead of creating multiple indexes, Im trying to use the metadata to create multiple query engine tools for a subquery engine workflow.

For example:
query engine tool 1:
use for answer with metadata topic A

query engine tool 2:
use for answer with metadata topic B
L
g
2 comments
for sure

Plain Text
tool = QueryEngineTool.from_defaults(index.as_query_engine(.., filters=filters), name=name, description=description)
Add a reply
Sign up and join the conversation on Discord