Repository navigation
Ask before every tool call in the web chat - #119
Open
arefbehboudi wants to merge 6 commits into
Open
arefbehboudi wants to merge 6 commits into
arefbehboudi wants to merge 6 commits into
Conversation
Every tool call now needs the owner's confirmation. The turn parks with Spring AI's tool call confirmation and the Session Extensions turn advisor; the web chat shows the pending call with Allow and Deny and resumes the turn. A parked turn survives a restart. Where nobody can be asked (messaging channels, scheduled tasks, Vaadin) the calls are denied right away. Part of #100.
agent.approval.allow lists the tools that run without the owner's confirmation (read-only tools by default) and agent.approval.deny the tools that never run. Every other tool still asks in the web chat and is denied where nobody can be asked. Unknown names in either list are logged at startup. Part of #100.
A pending tool call in the web chat can now be allowed or denied for good. The decision is stored as a grant in the sessions database and applies everywhere, including messaging channels and scheduled tasks. Grants are listed on the settings page and can be revoked there. Part of #100.
In a private chat with the owner (Telegram, Discord, WhatsApp, Teams), a tool call that needs confirmation now sends a request with /approve_<id> and /deny_<id> commands, and the turn resumes in the same chat. The id is derived from the tool call, so it works after a restart. Group chats and server channels still deny right away. Part of #100.
ToolGrants returned the clock's time but stored it in a TIMESTAMP column, which keeps microseconds. Where the clock has nanoseconds (Linux), a grant read back differed from the one returned. Every time it stores is now cut to milliseconds, so both are equal. Part of #100.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Every tool call now needs the owner's confirmation. The turn parks with Spring AI's tool call confirmation and the Session Extensions turn advisor; the web chat shows the pending call with Allow and Deny and resumes the turn. A parked turn survives a restart. Where nobody can be asked (messaging channels, scheduled tasks, Vaadin) the calls are denied right away.
Part of #100.