From 10ddefa686a61226bd279c1c49045a929417e99f Mon Sep 17 00:00:00 2001 From: Raphael Mitsch Date: Mon, 24 Apr 2023 20:44:37 +0200 Subject: [PATCH] Update spacy/kb/kb_in_memory.pyx Co-authored-by: Sofie Van Landeghem --- spacy/kb/kb_in_memory.pyx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/spacy/kb/kb_in_memory.pyx b/spacy/kb/kb_in_memory.pyx index 8a444d6e7..bc22bdae0 100644 --- a/spacy/kb/kb_in_memory.pyx +++ b/spacy/kb/kb_in_memory.pyx @@ -228,7 +228,7 @@ cdef class InMemoryLookupKB(KnowledgeBase): def get_candidates(self, mentions: Iterator[SpanGroup]) -> Iterator[Iterable[Iterable[InMemoryCandidate]]]: for mentions_for_doc in mentions: - yield [self._get_alias_candidates(ent_span.text) for ent_span in mentions_for_doc] + yield [self._get_alias_candidates(span.text) for span in mentions_for_doc] def _get_alias_candidates(self, str alias) -> Iterable[InMemoryCandidate]: """