Skip to content

Commit

Permalink
⭐feat gpt-4-o 支持上传文件
Browse files Browse the repository at this point in the history
  • Loading branch information
Yanyutin753 committed May 14, 2024
1 parent 10782fb commit 12f7d61
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
3 changes: 3 additions & 0 deletions .idea/misc.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions main.py
Original file line number Diff line number Diff line change
Expand Up @@ -338,7 +338,7 @@ def generate_gpts_payload(model, messages):

VERSION = '0.7.9.2'
# VERSION = 'test'
UPDATE_INFO = '支持最新的gpt-4-o模型'
UPDATE_INFO = '支持最新的gpt-4-o模型,且支持上传文件'
# UPDATE_INFO = '【仅供临时测试使用】 '

with app.app_context():
Expand Down Expand Up @@ -724,7 +724,7 @@ def send_text_prompt_and_get_response(messages, api_key, account_id, stream, mod
message_id = str(uuid.uuid4())
content = message.get("content")

if isinstance(content, list) and ori_model_name not in ['gpt-3.5-turbo', 'gpt-4-o']:
if isinstance(content, list) and ori_model_name not in ['gpt-3.5-turbo']:
logger.debug(f"gpt-vision 调用")
new_parts = []
attachments = []
Expand Down

0 comments on commit 12f7d61

Please sign in to comment.