code: def process(self, document):
      sentences = self._model.extract_sentences(document)
      with torch.no_grad():
          labels = self._model.label_sentences(
              sentences, batch_size=self._batch_size
          )
      # TODO: allow a classifier processor for any attribute, not just sentiment
      document.set(SENTIMENT, labels, to_sentence=True)
      return document
  
file_path: stanza/stanza/pipeline/sentiment_processor.py
imports: import torch
  from types import SimpleNamespace
  from stanza.models.classifiers.trainer import Trainer
  from stanza.pipeline._constants import *
  from stanza.pipeline.processor import UDProcessor, register_processor
label_desc: Use image node_id 2 for calling the SentimentProcessor obj's underlying member method code with example usage: obj.process(document) and returns: document