-
Notifications
You must be signed in to change notification settings - Fork 2.2k
docs: crud vector kv indexer #1814
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
Conversation
Codecov Report
@@ Coverage Diff @@
## master #1814 +/- ##
=======================================
Coverage 85.85% 85.85%
=======================================
Files 145 145
Lines 6944 6944
=======================================
Hits 5962 5962
Misses 982 982
Continue to review full report at Codecov.
|
Latency summaryCurrent PR yields:
Breakdown
Backed by latency-tracking. Further commits will update this comment. |
jina/executors/indexers/cache.py
Outdated
Show resolved
jina/drivers/search.py
Outdated
- ``level=all``: D x C x K | ||
- ``granularity=0``: D x K | ||
- ``granularity=1``: D x C x K | ||
- ``granularity=1``: D x C x C x K |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is granularity 0 and 1
.
jina/drivers/search.py
Outdated
- ``level=doc``: D x K | ||
- ``level=all``: D x C x K | ||
- ``granularity=0``: D x K | ||
- ``granularity=1``: D x C x K |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would reflect it with traversal_paths
arguments and not granularity.
If
traversal_paths = ['m'] => D x K
traversal_paths = ['r'] => D
traversal_paths = ['cm'] => D x C x K
traversal_paths = ['m', 'cm'] => D x K + D x C x K
Is this what we want to express?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
really awesome illustration. Thanks I will take this. This is much more understandable for the user
jina/executors/indexers/__init__.py
Outdated
@@ -12,7 +12,7 @@ | |||
|
|||
|
|||
class BaseIndexer(BaseExecutor): | |||
""" base class for storing and searching any kind of data structure | |||
"""base class for storing and searching any kind of data structure |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Capital letter at the beginning?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
check
jina/drivers/cache.py
Outdated
@@ -42,7 +41,7 @@ def _apply_all(self, docs: 'DocumentSet', *args, **kwargs) -> None: | |||
self.on_hit(d, result) | |||
|
|||
def on_miss(self, doc: 'Document', data) -> None: | |||
"""Function to call when doc is missing, the default behavior is add to cache when miss | |||
"""Function to call when document is missing, the default behavior is add to cache when miss. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
'the default behavior is add to cache when miss. '
does it mean 'the default behavior is to add the document to cache when miss. '?
@@ -31,24 +31,26 @@ def __init__( | |||
|
|||
|
|||
class KVSearchDriver(BaseSearchDriver): | |||
"""Fill in the doc/chunk-level top-k results using the :class:`jina.executors.indexers.meta.BinaryPbIndexer` | |||
"""Fill in the results using the :class:`jina.executors.indexers.meta.BinaryPbIndexer` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Probably we could all use first-person expressions(like 'fill') or third person(like 'fills')? Now some docstrings use first-person but some use third-person
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's stick to the first-person expression
No description provided.