code: def _activate_left(self, token):
          
          if not self.right_memory:
              if token.is_valid():
                  self.left_memory[token.to_info()] = 0
              else:
                  del self.left_memory[token.to_info()]
  
              for child in self.children:
                  child.callback(token)
  
          elif token.is_valid():
              count = 0
  
              for _, right_context in self.right_memory:
                  if self.matcher(token.context, dict(right_context)):
                      count += 1
  
              if count == 0:
                  for child in self.children:
                      child.callback(token)
  
              self.left_memory[token.to_info()] = count
          else:
              count = 0
              for _, right_context in self.right_memory:
                  if self.matcher(token.context, dict(right_context)):
                      count += 1
                      break
  
              if count == 0:
                  for child in self.children:
                      child.callback(token)
  
              del self.left_memory[token.to_info()]
docs: Activate from the left.
  
          In case of a valid token this activations test the right memory
          with the given token and looks for the number of matches. The
          token and the number of occurences are stored in the left
          memory.
  
          If the number of matches is zero the token activates all children.