Skip to content

Commit

Permalink
feat: Expose ES highlight option (#91)
Browse files Browse the repository at this point in the history
Signed-off-by: Michele Dolfi <dol@zurich.ibm.com>
  • Loading branch information
dolfim-ibm authored Jun 1, 2023
1 parent a8cc296 commit 8e65cbf
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions deepsearch/cps/queries/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ def DataQuery(
*,
source: Optional[List[str]] = None,
aggregations: Optional[dict] = None,
highlight: Optional[dict] = None,
sort: Optional[List[Dict[str, Any]]] = None,
limit: int = 20,
search_after: Optional[List[str]] = None,
Expand All @@ -57,6 +58,9 @@ def DataQuery(
if aggregations is not None:
payload["aggregations"] = aggregations

if highlight is not None:
payload["highlight"] = highlight

if search_after is not None:
payload["search_after"] = search_after

Expand Down

0 comments on commit 8e65cbf

Please sign in to comment.