diff --git a/appbuilder/core/components/asr/component.py b/appbuilder/core/components/asr/component.py index 7da3d5445..b0625bb09 100644 --- a/appbuilder/core/components/asr/component.py +++ b/appbuilder/core/components/asr/component.py @@ -183,6 +183,7 @@ def tool_eval(self, name: str, streaming: bool, **kwargs): raise InvalidRequestArgumentError(f"file {file_url} url does not exist") _, file_type = os.path.splitext(os.path.basename(urlparse(file_url).path)) + file_type = file_type.strip('.') req = ShortSpeechRecognitionRequest() req.speech = requests.get(file_url).content