QueryTransformer#
- class langchain.chains.query_constructor.parser.QueryTransformer(
- *args: Any,
- allowed_comparators: Sequence[Comparator] | None = None,
- allowed_operators: Sequence[Operator] | None = None,
- allowed_attributes: Sequence[str] | None = None,
- **kwargs: Any,
Transform a query string into an intermediate representation.
Methods
__init__
(*args[, allowed_comparators, ...])args
(*items)date
(item)datetime
(item)false
()float
(item)func_call
(func_name, args)int
(item)list
(item)program
(*items)string
(item)transform
(tree)Transform the given tree, and return the final result
true
()- Parameters:
args (Any)
allowed_comparators (Sequence[Comparator] | None)
allowed_operators (Sequence[Operator] | None)
allowed_attributes (Sequence[str] | None)
kwargs (Any)
- __init__(
- *args: Any,
- allowed_comparators: Sequence[Comparator] | None = None,
- allowed_operators: Sequence[Operator] | None = None,
- allowed_attributes: Sequence[str] | None = None,
- **kwargs: Any,
- Parameters:
args (Any)
allowed_comparators (Sequence[Comparator] | None)
allowed_operators (Sequence[Operator] | None)
allowed_attributes (Sequence[str] | None)
kwargs (Any)
- date(
- item: Any,
- Parameters:
item (Any)
- Return type:
- datetime(
- item: Any,
- Parameters:
item (Any)
- Return type:
- func_call(
- func_name: Any,
- args: list,
- Parameters:
func_name (Any)
args (list)
- Return type:
- transform(
- tree: Tree[_Leaf_T],
Transform the given tree, and return the final result
- Parameters:
tree (Tree[_Leaf_T])
- Return type:
_Return_T