Skip to content

Commit ecd5c1b

Browse files
committed
Update docs
1 parent 3173502 commit ecd5c1b

File tree

3 files changed

+631
-144
lines changed

3 files changed

+631
-144
lines changed

docs/api/query.rst

Lines changed: 28 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -105,21 +105,21 @@ VectorRangeQuery
105105
use_search_history='AUTO' # SVS-VAMANA only
106106
)
107107
108-
HybridQuery
108+
AggregateHybridQuery
109109
================
110110

111111

112112
.. currentmodule:: redisvl.query
113113

114114

115-
.. autoclass:: HybridQuery
115+
.. autoclass:: AggregateHybridQuery
116116
:members:
117117
:inherited-members:
118118
:show-inheritance:
119119
:exclude-members: add_filter,get_args,highlight,return_field,summarize
120120

121121
.. note::
122-
The ``stopwords`` parameter in :class:`HybridQuery` (and :class:`AggregateHybridQuery`) controls query-time stopword filtering (client-side).
122+
The ``stopwords`` parameter in :class:`AggregateHybridQuery` (and :class:`HybridQuery`) controls query-time stopword filtering (client-side).
123123
For index-level stopwords configuration (server-side), see :class:`redisvl.schema.IndexInfo.stopwords`.
124124
Using query-time stopwords with index-level ``STOPWORDS 0`` is counterproductive.
125125

@@ -130,22 +130,42 @@ HybridQuery
130130
Runtime parameters (``ef_runtime``, ``search_window_size``, ``use_search_history``, ``search_buffer_capacity``)
131131
are only supported with FT.SEARCH commands.
132132

133-
For runtime parameter support, use :class:`VectorQuery` or :class:`VectorRangeQuery` instead of AggregateHybridQuery.
133+
For runtime parameter support, use :class:`HybridQuery`, :class:`VectorQuery`, or :class:`VectorRangeQuery` instead of AggregateHybridQuery.
134134

135-
Example with VectorQuery (supports runtime parameters):
135+
Example with HybridQuery (supports runtime parameters):
136136

137137
.. code-block:: python
138138
139-
from redisvl.query import VectorQuery
139+
from redisvl.query.hybrid import HybridQuery
140140
141-
query = VectorQuery(
141+
query = HybridQuery(
142+
text="query string",
143+
text_field_name="description",
142144
vector=[0.1, 0.2, 0.3],
143145
vector_field_name="embedding",
146+
vector_search_method="KNN",
147+
knn_k=10,
148+
knn_ef_runtime=150, # Runtime parameters work with HybridQuery
144149
return_fields=["description"],
145150
num_results=10,
146-
ef_runtime=150 # Runtime parameters work with VectorQuery
147151
)
148152
153+
HybridQuery
154+
================
155+
156+
157+
.. currentmodule:: redisvl.query.hybrid
158+
159+
160+
.. autoclass:: HybridQuery
161+
:members:
162+
:inherited-members:
163+
:show-inheritance:
164+
165+
.. note::
166+
The ``stopwords`` parameter in :class:`HybridQuery` (and :class:`AggregateHybridQuery`) controls query-time stopword filtering (client-side).
167+
For index-level stopwords configuration (server-side), see :class:`redisvl.schema.IndexInfo.stopwords`.
168+
Using query-time stopwords with index-level ``STOPWORDS 0`` is counterproductive.
149169

150170
TextQuery
151171
================

0 commit comments

Comments
 (0)