class_docstr: Defines the background information about a person
class_docstr_tok: ["Defines","the","background","information","about","a","person"]
docstr: Return sequence of tokens corresponding to this person. Implemented as
  classmethod since we can null the background in PersonDocument in case of
  unknown background.
docstr_tok: ["Return","sequence","of","tokens","corresponding","to","this","person",".","Implemented","as","classmethod","since","we","can","null","the","background","in","PersonDocument","in","case","of","unknown","background","."]
code: def get_sentence(x: Optional["Background"]) -> List[str]:
      """Return sequence of tokens corresponding to this person. Implemented as
      classmethod since we can null the background in PersonDocument in case of
      unknown background.
      """
  
      if x is None:
          return 4 * ["[UNK]"]
      else:
          return [
              x.origin,
              x.gender,
              f"MONTH_{x.birth_month}",
              f"YEAR_{x.birth_year}",
          ]
  
imports: from dataclasses import dataclass
  from typing import TYPE_CHECKING, Generic, List, NewType, Optional, TypeVar
label_desc: Use image node_id 1 for calling the Background obj's underlying member method code with example usage: obj.get_sentence(x) and returns: unknown, list