Skip to content

Commit

Permalink
植物识别, 动物识别, 图像内容理解 fc bad case工程兜底
Browse files Browse the repository at this point in the history
  • Loading branch information
hermitgreen committed Mar 19, 2024
1 parent d82714d commit 244d6e2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions appbuilder/core/components/animal_recognize/component.py
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,8 @@ def _recognize_w_post_process(self, img_path, img_url, file_urls) -> str:
if img_path in file_urls:
req.url = file_urls[img_path]
if img_url:
if img_url in file_urls:
img_url = file_urls['img_url']
req.url = img_url
req.top_num = 6
req.baike_num = 0
Expand Down
2 changes: 2 additions & 0 deletions appbuilder/core/components/image_understand/component.py
Original file line number Diff line number Diff line change
Expand Up @@ -188,6 +188,8 @@ def _recognize_w_post_process(self, img_path, img_url, file_urls, question="图
if img_path in file_urls:
req.url = file_urls[img_path]
if img_url:
if img_url in file_urls:
img_url = file_urls['img_url']
req.url = img_url
response = self.__recognize(req)
description_to_llm = response.result.description_to_llm
Expand Down

0 comments on commit 244d6e2

Please sign in to comment.