-
Notifications
You must be signed in to change notification settings - Fork 2.6k
fix(plugin): Resolves the issue where calling plugins in the workflow fails to pass the ConversationID and AgentID to the plugin service. #2419
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
…fails to pass the ConversationID and AgentID to the plugin service. - 将WithPluginHTTPHeader重命名为WithConversationID以准确反映其用途 - 在工作流节点中增加对ConversationID和AgentID的传递支持
|
这个 PR 用于完善 https://github.com/coze-dev/coze-studio/pull/2191, 请 @fanlv review 一下? |
| }, nil | ||
| } | ||
|
|
||
| func (p *pluginInvokeTool) PluginInvoke(ctx context.Context, argumentsInJSON string, cfg workflowModel.ExecuteConfig) (string, error) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@mrh997 帮忙确认下。
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这个我看下
|
|
||
| req := &model.ExecuteToolRequest{ | ||
| UserID: conv.Int64ToStr(cfg.Operator), | ||
| UserID: uID, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| } | ||
|
|
||
| func WithPluginHTTPHeader(conversationID int64) ExecuteToolOpt { | ||
| func WithConversationID(conversationID int64) ExecuteToolOpt { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这个场景,我看了上个提交,咱们使用了原有的的结构做了传递,正常来说我们的场景是在tool运行的时候透传header信息,是不是单独定义一个关于header的结构做option,所有的字段包含在内,这个option只对tool 透传header生效,不与原因逻辑混在一起比较好;
Codecov Report❌ Patch coverage is
... and 1140 files with indirect coverage changes 🚀 New features to boost your workflow:
|

fix(plugin): 解决 #2418 ,在工作流中没有正确传递UserId 和 没有传递 ConversationID、AgentID 给 插件的问题。