Update commits_ft.py
Browse files306 unmodified lines307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357306 unmodified linesVERSION = datasets.Version("1.1.0")class CommitConfig(datasets.BuilderConfig):"""BuilderConfig for SuperGLUE."""def __init__(self, features, data_url, **kwargs):"""BuilderConfig for SuperGLUE.Args:features: *list[string]*, list of the features that will appear in thefeature dict. Should not include "label".data_url: *string*, url to download the zip file from.citation: *string*, citation for the data set.url: *string*, url for information about the data set.label_classes: *list[string]*, the list of classes for the label if thelabel is present as a string. Non-string labels will be cast to either'False' or 'True'.**kwargs: keyword arguments forwarded to super."""super().__init__(version=VERSION, **kwargs)self.features = featuresself.data_url = data_urlclass CommitIT(datasets.GeneratorBasedBuilder):BUILDER_CONFIGS = [CommitConfig(name=lang,description="This part of dataset covers {lang} language".format(lang=lang),features=['commit','old_file','new_file','old_contents','new_contents','subject','message','lang','license','repos'],data_url=_URLS[lang])for lang in languages]# BUILDER_CONFIGS = [# datasets.BuilderConfig(name=lang, version=VERSION,# description="This part of dataset covers {lang} language".format(lang=lang))# for lang in languages# ]DEFAULT_CONFIG_NAME = "python"306 unmodified lines307308309310311312313314315316317318306 unmodified linesVERSION = datasets.Version("1.1.0")class CommitIT(datasets.GeneratorBasedBuilder):BUILDER_CONFIGS = [datasets.BuilderConfig(name=lang, version=VERSION,description="This part of dataset covers {lang} language".format(lang=lang))for lang in languages]DEFAULT_CONFIG_NAME = "python"
commits_ft.py+2-41