class_docstr: Entity extractor which uses SpaCy.
class_docstr_tok: ["Entity","extractor","which","uses","SpaCy","."]
docstr: Extract entities using SpaCy.
  
  Args:
      messages: List of messages to process.
      model: Container holding a loaded spacy nlp model.
  
  Returns: The processed messages.
docstr_tok: ["Extract","entities","using","SpaCy",".","Args",":","messages",":","List","of","messages","to","process",".","model",":","Container","holding","a","loaded","spacy","nlp","model",".","Returns",":","The","processed","messages","."]
code: def process(
      self, messages: List[Message], model: SpacyModel
  ) -> List[Message]:
      """Extract entities using SpaCy.
  
      Args:
          messages: List of messages to process.
          model: Container holding a loaded spacy nlp model.
  
      Returns: The processed messages.
      """
      for message in messages:
          # can't use the existing doc here (spacy_doc on the message)
          # because tokens are lower cased which is bad for NER
          spacy_nlp = model.model
          doc = spacy_nlp(message.get(TEXT))
          all_extracted = self.add_extractor_name(
              self._extract_entities(doc)
          )
          dimensions = self._config["dimensions"]
          extracted = self.filter_irrelevant_entities(
              all_extracted, dimensions
          )
          message.set(
              ENTITIES,
              message.get(ENTITIES, []) + extracted,
              add_to_output=True,
          )
  
      return messages
  
imports: import typing
  from typing import Any, Dict, List, Text, Type
  from rasa.engine.graph import ExecutionContext, GraphComponent
  from rasa.engine.recipes.default_recipe import DefaultV1Recipe
  from rasa.engine.storage.resource import Resource
  from rasa.engine.storage.storage import ModelStorage
  from rasa.shared.nlu.constants import ENTITIES, TEXT
  from rasa.nlu.utils.spacy_utils import SpacyModel, SpacyNLP
  from rasa.nlu.extractors.extractor import EntityExtractorMixin
  from rasa.shared.nlu.training_data.message import Message
label_desc: Use image node_id 6 for calling the SpacyEntityExtractor obj's underlying member method code with example usage: obj.process(messages, model) and returns: messages