code: def python_cardinality(self, subject: str, all_are_optional: bool = False) -> str:
          
          if self.multiple_elements:
              rval = f"typing.List[{subject}]"
          elif self.one_optional_element:
              rval = subject if subject.startswith("typing.Optional[") else f"typing.Optional[{subject}]"
          elif self.max == 0:
              rval = "type(None)"
          else:
              rval = subject
          if all_are_optional and not self.one_optional_element:
              rval = f"typing.Optional[{rval}]"
          return rval
docs: Add the appropriate python typing to subject (e.g. Optional, List, ...)
  
          :param subject: Subject to be decorated
          :param all_are_optional: Force everything to be optional
          :return: Typed subject