Skip to content

Commit

Permalink
ASR 兜底bug fix (#209)
Browse files Browse the repository at this point in the history
* 植物识别fc bad case工程兜底

* 植物识别, 动物识别, 图像内容理解 fc bad case工程兜底

* 音频识别 fc bad case 兜底

* 音频识别 fc bad case 兜底

* 音频识别 fc bad case 兜底

* 音频识别 fc bad case 兜底
  • Loading branch information
hermitgreen authored Mar 20, 2024
1 parent 9728dfa commit 091e03d
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions appbuilder/core/components/asr/component.py
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down

0 comments on commit 091e03d

Please sign in to comment.