code: def _filter_result(self, cand):
      wikidata_id = cand.get("wikidata_id", None)
      res = {
          "wikidata_id": wikidata_id,
          "wikipedia_id": cand["id"],
          "wikipedia_title": cand["title"],
      }
  
      res["aliases"] = cand.get("aliases", None)
      sents = []
  
      for k in range(0, 10):
          key = "sent_desc_{}".format(k + 1)
          sents.append(cand.get(key, ""))
  
      res["sentences"] = sents
  
      res["num_incoming_links"] = cand.get("num_incoming_links", 0)
      res["score"] = cand["score"]
  
      return res
  
file_path: BLINK/blink/candidate_retrieval/candidate_generators.py
imports: import pysolr
  import sys
  import utils
label_desc: Use image node_id 2 for calling the Simple_Candidate_Generator obj's underlying member method code with example usage: obj._filter_result(cand) and returns: res