mirror of
https://github.com/hwchase17/langchain.git
synced 2025-07-19 11:08:55 +00:00
add allowed_operators property in QdrantTranslator (#12328)
- **Description:** This PR adds `allowd_operators` property to `QdrantTranslator` to fix the `TypeError: can only join an iterable` bug. This property is required in `get_query_constructor_prompt` in `query_constructor\base.py`: ``` allowed_operators=" | ".join(allowed_operators), ``` - **Issue:** #12061 --------- Co-authored-by: XIE Qihui <qihui.xie@bopufund.com>
This commit is contained in:
parent
f5a57fc1ef
commit
6720458c7d
@ -18,6 +18,13 @@ if TYPE_CHECKING:
|
||||
class QdrantTranslator(Visitor):
|
||||
"""Translate `Qdrant` internal query language elements to valid filters."""
|
||||
|
||||
allowed_operators = (
|
||||
Operator.AND,
|
||||
Operator.OR,
|
||||
Operator.NOT,
|
||||
)
|
||||
"""Subset of allowed logical operators."""
|
||||
|
||||
allowed_comparators = (
|
||||
Comparator.EQ,
|
||||
Comparator.LT,
|
||||
|
Loading…
Reference in New Issue
Block a user