@@ -26,7 +26,7 @@ class DataConfig:
2626 cleaner : str = "basic"
2727
2828 @classmethod
29- def from_dict (cls , raw : dict [str , Any ]) -> " DataConfig" :
29+ def from_dict (cls , raw : dict [str , Any ]) -> DataConfig :
3030 return cls (
3131 module = raw ["module" ],
3232 source = raw ["source" ],
@@ -50,7 +50,7 @@ class ModelConfig:
5050 lora_alpha : int = 32
5151
5252 @classmethod
53- def from_dict (cls , raw : dict [str , Any ]) -> " ModelConfig" :
53+ def from_dict (cls , raw : dict [str , Any ]) -> ModelConfig :
5454 return cls (
5555 module = raw ["module" ],
5656 teacher_name = raw ["teacher_name" ],
@@ -80,7 +80,7 @@ class TrainConfig:
8080 out_dir : str = "models"
8181
8282 @classmethod
83- def from_dict (cls , raw : dict [str , Any ]) -> " TrainConfig" :
83+ def from_dict (cls , raw : dict [str , Any ]) -> TrainConfig :
8484 return cls (
8585 epochs = raw .get ("epochs" , 3 ),
8686 batch_size = raw .get ("batch_size" , 16 ),
@@ -106,7 +106,7 @@ class EvalConfig:
106106 batch_size : int = 32
107107
108108 @classmethod
109- def from_dict (cls , raw : dict [str , Any ]) -> " EvalConfig" :
109+ def from_dict (cls , raw : dict [str , Any ]) -> EvalConfig :
110110 return cls (
111111 module = raw ["module" ],
112112 metric = raw ["metric" ],
@@ -126,7 +126,7 @@ class ExportConfig:
126126 quantize : bool = False
127127
128128 @classmethod
129- def from_dict (cls , raw : dict [str , Any ]) -> " ExportConfig" :
129+ def from_dict (cls , raw : dict [str , Any ]) -> ExportConfig :
130130 return cls (
131131 opset = raw .get ("opset" , 17 ),
132132 dynamic_axes = raw .get ("dynamic_axes" , {"input_ids" : {0 : "batch" , 1 : "seq" }}),
@@ -152,7 +152,7 @@ class TaskConfig:
152152 export : ExportConfig
153153
154154 @classmethod
155- def from_dict (cls , name : str , raw : dict [str , Any ]) -> " TaskConfig" :
155+ def from_dict (cls , name : str , raw : dict [str , Any ]) -> TaskConfig :
156156 return cls (
157157 name = name ,
158158 description = raw .get ("description" , "" ),
0 commit comments