




import copy
from dataclasses import dataclass, field
from typing import ClassVar, Dict

from ..features import ClassLabel, Features, Value
from .base import TaskTemplate







@dataclass(frozen=UpperCamelCase__)
class     __lowerCAmelCase	(   UpperCamelCase__):
      # `task` is not a ClassVar since we want it to be part of the `asdict` output for JSON serialization
      _lowercase    : str            =      field(default="""text-classification"""						,    metadata={"""include_in_asdict_even_if_is_default""": True})
      _lowercase    : ClassVar[Features]            =      Features({"""text""": Value("""string""")})
      _lowercase    : ClassVar[Features]            =      Features({"""labels""": ClassLabel})
      _lowercase    : str            =      "text"
      _lowercase    : str            =      "labels"







      def        _lowercase  (   self		,				lowerCAmelCase__							)       ->						Optional[int]:



        '''simple docstring'''




        if self.label_column not in features:
          raise ValueError(F'''Column {self.label_column} is not present in features.'''							)
        if not isinstance(features[self.label_column]		,				lowerCAmelCase__							):
          raise ValueError(F'''Column {self.label_column} is not a ClassLabel.'''							)
        a__     : Optional[int]  =copy.deepcopy(self							)
        a__     : Tuple  =self.label_schema.copy()
        a__     : Optional[Any]  =features[self.label_column]
        a__     : Dict  =label_schema
        return task_template







      @property
      def        _lowercase  (   self							)       ->						Dict[str, str]:



        '''simple docstring'''




        return {
            self.text_column: "text",
            self.label_column: "labels",
        }













import os
def 					_A	(		):





  """simple docstring"""



  a__     : Optional[int]  =os.path.join(os.path.dirname(SCREAMING_SNAKE_CASE						)	,	"num.txt"						)
  with open(SCREAMING_SNAKE_CASE						) as file_hand:
    return str(sum(int(SCREAMING_SNAKE_CASE						) for line in file_hand						)						)[:10]


if __name__ == "__main__":
     print(solution())






