23
23
FalconOnnxConfig ,
24
24
GemmaOnnxConfig ,
25
25
LlamaOnnxConfig ,
26
+ MPTOnnxConfig ,
26
27
PhiOnnxConfig ,
27
28
UNetOnnxConfig ,
28
29
VaeDecoderOnnxConfig ,
43
44
BaichuanModelPatcher ,
44
45
ChatGLMModelPatcher ,
45
46
GemmaModelPatcher ,
47
+ InternLMPatcher ,
46
48
LlamaModelPatcher ,
47
49
MixtralModelPatcher ,
50
+ MPTModelPatcher ,
48
51
Phi3ModelPatcher ,
49
52
QwenModelPatcher ,
50
53
)
@@ -439,6 +442,11 @@ class InternLM2OpenVINOConfig(TextDecoderWithPositionIdsOnnxConfig):
439
442
DUMMY_PKV_GENERATOR_CLASS = MistralDummyPastKeyValuesGenerator
440
443
NORMALIZED_CONFIG_CLASS = NormalizedTextConfig
441
444
445
+ def patch_model_for_export (
446
+ self , model : Union ["PreTrainedModel" , "TFPreTrainedModel" ], model_kwargs : Optional [Dict [str , Any ]] = None
447
+ ) -> "ModelPatcher" :
448
+ return InternLMPatcher (self , model , model_kwargs = model_kwargs )
449
+
442
450
443
451
@register_in_tasks_manager ("orion" , * ["text-generation" , "text-generation-with-past" ], library_name = "transformers" )
444
452
class OrionOpenVINOConfig (TextDecoderWithPositionIdsOnnxConfig ):
@@ -455,6 +463,16 @@ class OlmoOpenVINOConfig(TextDecoderWithPositionIdsOnnxConfig):
455
463
NORMALIZED_CONFIG_CLASS = NormalizedTextConfig
456
464
457
465
466
+ @register_in_tasks_manager (
467
+ "mpt" , * ["text-generation" , "text-generation-with-past" , "text-classification" ], library_name = "transformers"
468
+ )
469
+ class MPTOpenVINOConfig (MPTOnnxConfig ):
470
+ def patch_model_for_export (
471
+ self , model : Union ["PreTrainedModel" , "TFPreTrainedModel" ], model_kwargs : Optional [Dict [str , Any ]] = None
472
+ ) -> "ModelPatcher" :
473
+ return MPTModelPatcher (self , model , model_kwargs = model_kwargs )
474
+
475
+
458
476
@register_in_tasks_manager (
459
477
"phi3" ,
460
478
* [
0 commit comments