Repository navigation
Support Auto mode for Pi Agent (or defer T3's tool_call hook to user Pi extensions) #35610
notgrvvvvv
started this conversation in
Ideas
Replies: 2 comments
|
Update: #35609 was closed as a feature request and redirected here. To make the real-world impact concrete: I already wrote a Pi extension that implements an |
0 replies
|
I'd like this too. |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Context
Currently in T3 Code, Pi only advertises
approval-required,auto-accept-edits, andfull-access(PI_PRESENTATIONinpackages/provider-pi). Because of that:pi-t3-mcp-extension.ts(pi.on("tool_call", ...)) only bypassesctx.ui.confirm(...)whenmode === "full-access". Inauto-accept-edits, every non-read-only, non-file-change tool (e.g.bashor custom tools) prompts the user—even when the user has installed a Pi extension specifically to provideautoapproval logic (see [Bug]: Pi's injected T3 tool_call hook forces Full access and blocks Pi extensions from handling approvals in subagents #35609).delegate_taskblocksruntimeMode: "full-access"(runtime_mode_escalation_denied), and inherited mode steps down toauto-accept-edits(see [Bug]: New Pi threads fall back to Supervised when the default permission mode is Auto #30538 / PR fix: threads step down to the broadest permission mode their provider offers #30552).As a result, Pi cannot be used unattended as a subagent from an Auto parent thread unless you put the entire parent thread into Full access—giving up the parent's Auto safety classifier.
(Related closed issues redirected here: #31964, #35500.)
Why this matters for Pi specifically
Pi deliberately delegates permission policies to extensions. Users can already build/install Pi extensions that implement safe
autocommand approval, but T3 Code currently has no way to let those extensions handleautowithout grantingfull-access.Proposed options
automode to Pi extensions (recommended):Allow Pi to advertise
"auto"(either via a Pi provider setting like "Delegate Auto mode to Pi extensions" or when a permission extension is configured), and havepi-t3-mcp-extension.tsskip itsctx.ui.confirm(...)prompt whenmode === "auto"(letting the user's extension decide).Autoreview for Pi in T3 Code:Have T3's Pi adapter/extension evaluate non-file-change tool calls using an automatic classifier in
automode instead of always falling back toauto-accept-edits/ prompting the user.Allow an Auto parent thread to handle or configure child execution policies for providers without native
autowithout requiring Full access on the parent.All reactions