code: def _sent_mask(text_wd, doc_max_timesteps):
      text_len = len(text_wd)
      if text_len < doc_max_timesteps:
          sent_mask = [1] * text_len + [0] * (
              doc_max_timesteps - text_len
          )
      else:
          sent_mask = [1] * doc_max_timesteps
      return sent_mask
  
imports: import os
  import numpy
  from functools import partial
  from .pipe import Pipe
  from .utils import _drop_empty_instance
  from ..loader.summarization import ExtCNNDMLoader
  from ..data_bundle import DataBundle
  from ...core.vocabulary import Vocabulary
label_desc: Use image node_id 8 for calling a global function with example usage: _sent_mask(text_wd, doc_max_timesteps) and returns: sent_mask