chenghuichen commented on code in PR #7670:
URL: https://github.com/apache/paimon/pull/7670#discussion_r3115313164


##########
paimon-python/pypaimon/globalindex/tantivy/tantivy_full_text_global_index_reader.py:
##########
@@ -152,13 +152,27 @@ def visit_full_text_search(self, full_text_search) -> 
Optional[ScoredGlobalIndex
 
         searcher = self._searcher
         query = self._index.parse_query(query_text, ["text"])
-        results = searcher.search(query, limit)
 
+        scored_results = searcher.search(query, limit)
+        if not scored_results.hits:
+            return DictBasedScoredIndexResult({})
+
+        addr_to_score: Dict[tuple, float] = {
+            (addr.segment_ord, addr.doc): score
+            for score, addr in scored_results.hits
+        }
+

Review Comment:
   Thanks for the review! Based on feedback from the tantivy-py community, 
v0.26 with fast-field access should be released in a few weeks. I think it 
makes sense to hold this PR for now — I'll track the community progress and 
ping you once the code is updated.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to