mirror of
https://github.com/binaricat/Netcatty.git
synced 2026-11-20 15:19:16 +00:00
Use Vercel AI SDK's native `needsApproval` on write tools (terminal_execute, terminal_send_input, sftp_write_file, multi_host_execute) when permission mode is "confirm". When the SDK emits a `tool-approval-request` stream event, show the existing PermissionDialog component for user to approve/reject. - tools.ts: replace manual checkToolPermission() calls with `needsApproval` property on write tools; keep blocklist checks in execute() - AIChatSidePanel: handle `tool-approval-request` chunk type, show PermissionDialog via Promise-based pause, resolve on user action - Add i18n key for tool denied message Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>