Skip to content

Conversation

@Yimi81
Copy link

@Yimi81 Yimi81 commented Dec 17, 2023

  1. 保留原始openai_api.py与function_call代码不动;迁移openai_api.py至openai 1.0以上的版本 openai 接口 v1.x 返回错误 'NoneType' object has no attribute 'items'  #768
  2. 支持流式function_call

此 PR 已准备好接受审核, 所有代码已完成检查。

@JianxinMa JianxinMa self-requested a review December 21, 2023 02:46
if func_call:
f_name, f_args = func_call.get("name"), func_call.get("arguments")
else:
f_name, f_args = tools_call[0]["function"]["name"], tools_call[0]["function"]["arguments"]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这里的实现可能有疏漏,f_args没有被用到。而原版openai-api.py的f_args会被用到。

不过,十分感谢您的PR,我会抽空处理下。

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

感谢您的审查,已更正

@Tejaswgupta
Copy link

@Yimi81 @JianxinMa any updates here?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants