code: def __init__(self, tokenizer):
      super().__init__(tokenizer=tokenizer)
      self.stop_token_ids = list(
          set(
              [
                  self.tokenizer.tokenize(x)[0]
                  for x in ["\n", "\r\n", "\n\n", ".\n\n"]
              ]
          )
      )
  
imports: import abc
  from typing import List, Union
  import torch
label_desc: Use image node_id 1 to create a new NewLineDelimitedStopCriterion object from inherited base classes: BaseGenerationStopCriterion with example: obj = NewLineDelimitedStopCriterion(tokenizer)