          cdef hash_t alias_hash = self.strings[alias]
          alias_index = <int64_t>self._alias_index.get(alias_hash)
          alias_entry = self._aliases_table[alias_index]
  
          return [Candidate(entity_hash=self._entries[entry_index].entity_hash,
                            alias_hash=alias_hash,
                            prior_prob=prob)
                        for (entry_index, prob) in zip(alias_entry.entry_indices, alias_entry.probs)]
  
 
</s> remove     print("candidates for", alias1)
    candidates1 = mykb.get_candidates(alias1)
    for candidate in candidates1:
        print(" candidate")
        print("  name", candidate.get_entity_name(mykb))
        print("  alias", candidate.get_alias_name(mykb))
        print("  prior_prob", candidate.prior_prob)

    print("candidates for", alias2)
    candidates2 = mykb.get_candidates(alias2)
    for candidate in candidates2:
        print(" candidate")
        print("  name", candidate.get_entity_name(mykb))
        print("  alias", candidate.get_alias_name(mykb))
        print("  prior_prob", candidate.prior_prob)

    print("candidates for", alias3)
    candidates3 = mykb.get_candidates(alias3)
    for candidate in candidates3:
        print(" candidate")
        print("  name", candidate.get_entity_name(mykb))
        print("  alias", candidate.get_alias_name(mykb))
        print("  prior_prob", candidate.prior_prob)
 </s> add     for alias in [alias1, alias2, alias3]:
        print()
        print("candidates for", alias)
        candidates = mykb.get_candidates(alias)
        for candidate in candidates:
            print(" candidate")
            print("  kb_id", candidate.kb_id)
            print("  kb_id_", candidate.kb_id_)
            print("  alias", candidate.alias)
            print("  alias_", candidate.alias_)
            print("  prior_prob", candidate.prior_prob) </s> remove     def __init__(self, entity_hash, alias_hash, prior_prob):
 </s> add     def __init__(self, KnowledgeBase kb, entity_hash, alias_hash, prior_prob):
        self.kb = kb </s> remove     def get_entity_name(self, KnowledgeBase kb):
        return kb.strings[self.entity_hash]
 </s> add     property kb_id_:
        """RETURNS (unicode): ID of this entity in the KB"""
        def __get__(self):
            return self.kb.strings[self.entity_hash]

    property kb_id:
        """RETURNS (uint64): hash of the entity's KB ID"""
        def __get__(self):
            return self.entity_hash

    property alias_:
        """RETURNS (unicode): ID of the original alias"""
        def __get__(self):
            return self.kb.strings[self.alias_hash]
        return [Candidate(kb=self,
                          entity_hash=self._entries[entry_index].entity_hash,
          cdef hash_t alias_hash = self.strings[alias]
          alias_index = <int64_t>self._alias_index.get(alias_hash)
          alias_entry = self._aliases_table[alias_index]
  
        return [Candidate(kb=self,
                          entity_hash=self._entries[entry_index].entity_hash,
                            alias_hash=alias_hash,
                            prior_prob=prob)
                        for (entry_index, prob) in zip(alias_entry.entry_indices, alias_entry.probs)]
  
keep keep keep keep replace keep keep keep keep
 property getters and keep track of KB internally 
spacy/kb.pyx