diff --git a/src/transformers/configuration_utils.py b/src/transformers/configuration_utils.py index 8d8784be39117b..a25ac51cf20bfa 100755 --- a/src/transformers/configuration_utils.py +++ b/src/transformers/configuration_utils.py @@ -1036,6 +1036,7 @@ def _get_non_default_generation_parameters(self) -> Dict[str, Any]: if decoder_config is not self: default_config = decoder_config.__class__() else: + default_config = None decoder_config = None # If it is a composite model, we want to check the subconfig that will be used for generation