Skip to content

Commit

Permalink
Merge branch 'main' into v0.27-release
Browse files Browse the repository at this point in the history
  • Loading branch information
hanouticelina committed Dec 16, 2024
2 parents 9100950 + c4e6079 commit 875b3a8
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -76,10 +76,11 @@ class AutomaticSpeechRecognitionGenerationParameters(BaseInferenceType):
class AutomaticSpeechRecognitionParameters(BaseInferenceType):
"""Additional inference parameters for Automatic Speech Recognition"""

generation_parameters: Optional[AutomaticSpeechRecognitionGenerationParameters] = None
"""Parametrization of the text generation process"""
return_timestamps: Optional[bool] = None
"""Whether to output corresponding timestamps with the generated text"""
# Will be deprecated in the future when the renaming to `generation_parameters` is implemented in transformers
generate_kwargs: Optional[AutomaticSpeechRecognitionGenerationParameters] = None
"""Parametrization of the text generation process"""


@dataclass
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,10 +76,11 @@ class ImageToTextGenerationParameters(BaseInferenceType):
class ImageToTextParameters(BaseInferenceType):
"""Additional inference parameters for Image To Text"""

generation_parameters: Optional[ImageToTextGenerationParameters] = None
"""Parametrization of the text generation process"""
max_new_tokens: Optional[int] = None
"""The amount of maximum tokens to generate."""
# Will be deprecated in the future when the renaming to `generation_parameters` is implemented in transformers
generate_kwargs: Optional[ImageToTextGenerationParameters] = None
"""Parametrization of the text generation process"""


@dataclass
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,8 @@ class TextToAudioGenerationParameters(BaseInferenceType):
class TextToAudioParameters(BaseInferenceType):
"""Additional inference parameters for Text To Audio"""

generation_parameters: Optional[TextToAudioGenerationParameters] = None
# Will be deprecated in the future when the renaming to `generation_parameters` is implemented in transformers
generate_kwargs: Optional[TextToAudioGenerationParameters] = None
"""Parametrization of the text generation process"""


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,8 @@ class TextToSpeechGenerationParameters(BaseInferenceType):
class TextToSpeechParameters(BaseInferenceType):
"""Additional inference parameters for Text To Speech"""

generation_parameters: Optional[TextToSpeechGenerationParameters] = None
# Will be deprecated in the future when the renaming to `generation_parameters` is implemented in transformers
generate_kwargs: Optional[TextToSpeechGenerationParameters] = None
"""Parametrization of the text generation process"""


Expand Down

0 comments on commit 875b3a8

Please sign in to comment.