Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs(drivers): remove the legacy docstring #1941

Merged
merged 1 commit into from
Feb 15, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
12 changes: 6 additions & 6 deletions jina/drivers/rank/aggregate/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,24 +14,24 @@


class BaseAggregateMatchesRanker(BaseRankDriver):
"""Drivers inherited from this Driver will focus on aggregating scores from `chunks` to its `parents`."""
"""Drivers inherited from this Driver focus on aggregating scores from `chunks` to its `parents`."""

def __init__(self,
keep_source_matches_as_chunks: bool = False,
*args,
**kwargs):
"""

`keep_old_matches_as_chunks` is useful to keep track of the chunks that lead to a retrieved result.

.. note::
- The chunks of the matches will only contain the chunks that lead to the document matching, not all the chunks of the match.

:param keep_source_matches_as_chunks: A flag to indicate if the driver must return the old matches of the query or its chunks
(at a greater granularity level (k + 1)) as the chunks of the new computed `matches` (at granularity level k)
Set it to `True` when keeping track of the chunks that lead to a retrieved result.
:param *args: *args for super
:param **kwargs: **kwargs for super

.. note::
When set `keep_source_matches_as_chunks=True`, the chunks of the match contains **ONLY** the chunks leading
to the match rather than **ALL** the chunks of the match.

"""
super().__init__(*args, **kwargs)
self.keep_source_matches_as_chunks = keep_source_matches_as_chunks
Expand Down