Skip to content

feat(tools): request answer tool factory #1150

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

Open
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

Lin-Nikaido
Copy link

Add request_answer_factory as util tool.
This provides a comprehensive handler for tools that require user approvalor interaction.

Example

from google.adk.utils.request_answer_factory import request_answer_factory
requesting_tool, before_agent_callback, after_agent_callback = request_answer_factory("approve", your_tool)

Agent(
    model="your/model-name",
    before_agent_callback=[before_agent_callback]
    after_agent_callback=[after_agent_callback]
    tools=[requesting_tool]
)

@Lin-Nikaido Lin-Nikaido changed the title Feat/request answer tool factory feat(tools): request answer tool factory Jun 4, 2025
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.

1 participant