google / google/adk-java

Invocation context attribute propagation

未关闭
#564 2 条评论 0 个 reaction 已指派 1 人 已被 @hemasekhar-p 认领 在 GitHub 查看
needs review
主要语言
Java
星标
1.7k
派生
420
平均合并
4 天 12 小时
30 天内合并 PR
31

描述

As per python-variant of the ADK library issue (https://github.com/google/adk-python/issues/1746) I would like to propagate request-scoped variable into agent and his tools (ToolContext) in order that tool used by agent would have this variable at its disposal for the given runAsync() run.
I suppose that instances of Runner, Agent and Tool(set) are meant to be long-lived singletons, so that leaves me only Session option, which also seem to live across many requests, so only hack-like solution with pushing and then removing the request variable through Session with before/afterToolCallback are available now.

贡献指南

打开贡献指南

评估

这个 Issue 还没有评估数据。

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。