Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions src/strands_tools/retrieve.py
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,20 @@
),
"default": False,
},
"retrieveFilter": {
"type": "object",
"description": (
"Optional filter to apply to retrieval results based on metadata attributes in the "
"knowledge base. This is a UNION type - only one operator can be specified at the top level. "
"Available operators: "
"equals (exact match), notEquals, greaterThan, greaterThanOrEquals, lessThan, "
"lessThanOrEquals, in (value in list), notIn, listContains (list contains value), "
"stringContains (substring match), startsWith (OpenSearch Serverless only), "
"andAll (all conditions must match, min 2 items), orAll (at least one condition must match, "
"min 2 items). Example: {\"andAll\": [{\"equals\": {\"key\": \"category\", "
"\"value\": \"security\"}}, {\"greaterThan\": {\"key\": \"year\", \"value\": \"2022\"}}]}"
),
},
},
"required": ["text"],
}
Expand Down