fix(acp): keep tool execution with agents by default (#2024)

Paseo should only advertise filesystem and terminal execution when a provider explicitly opts into delegating those operations to the host.
This commit is contained in:
Mohamed Boudra
2026-07-12 20:43:40 +02:00
committed by GitHub
parent 18de06c2a4
commit 88397655f7
4 changed files with 33 additions and 34 deletions

View File

@@ -457,26 +457,25 @@ Paseo tools such as subagent creation come from the shared internal tool catalog
}
```
ACP agents normally receive access to Paseo's filesystem and terminal through
the client capabilities advertised during initialization. For a compliant agent
running in a container or remote environment, disable those capabilities so it
keeps file and command execution in the agent environment:
ACP agents execute filesystem and terminal operations in their own environment
by default. To let a compliant agent delegate those operations to Paseo instead,
enable the corresponding client capabilities:
```json
{
"agents": {
"providers": {
"container-agent": {
"local-agent": {
"extends": "acp",
"label": "Container Agent",
"command": ["container-agent", "acp"],
"label": "Local Agent",
"command": ["local-agent", "acp"],
"params": {
"clientCapabilities": {
"fs": {
"readTextFile": false,
"writeTextFile": false
"readTextFile": true,
"writeTextFile": true
},
"terminal": false
"terminal": true
}
}
}
@@ -485,9 +484,9 @@ keeps file and command execution in the agent environment:
}
```
The defaults remain enabled for compatibility with local ACP agents. Configure
both environments with equivalent absolute workspace paths before enabling
client filesystem or terminal delegation across a process boundary.
Only enable capabilities Paseo should execute. When the agent and Paseo run in
different environments, configure equivalent absolute workspace paths before
delegating filesystem or terminal operations to Paseo.
### Generic ACP diagnostics

View File

@@ -52,13 +52,13 @@ import { asInternals } from "../../test-utils/class-mocks.js";
import * as spawnUtils from "../../../utils/spawn.js";
describe("buildACPClientCapabilities", () => {
test("preserves the default client filesystem and terminal capabilities", () => {
test("keeps filesystem and terminal execution with the agent by default", () => {
expect(buildACPClientCapabilities()).toEqual({
fs: {
readTextFile: true,
writeTextFile: true,
readTextFile: false,
writeTextFile: false,
},
terminal: true,
terminal: false,
});
});
@@ -68,17 +68,17 @@ describe("buildACPClientCapabilities", () => {
{ source: "provider" },
{
fs: {
readTextFile: false,
readTextFile: true,
},
terminal: false,
terminal: true,
},
),
).toEqual({
fs: {
readTextFile: false,
writeTextFile: true,
readTextFile: true,
writeTextFile: false,
},
terminal: false,
terminal: true,
_meta: { source: "provider" },
});
});

View File

@@ -231,10 +231,10 @@ export const DEFAULT_ACP_CAPABILITIES: AgentCapabilityFlags = {
const BASE_ACP_CLIENT_CAPABILITIES: ACPClientCapabilities = {
fs: {
readTextFile: true,
writeTextFile: true,
readTextFile: false,
writeTextFile: false,
},
terminal: true,
terminal: false,
};
export type ACPClientCapabilityMeta = Record<string, unknown>;

View File

@@ -108,10 +108,10 @@ describe("GenericACPAgentClient diagnostics", () => {
providerParams: {
clientCapabilities: {
fs: {
readTextFile: false,
writeTextFile: false,
readTextFile: true,
writeTextFile: true,
},
terminal: false,
terminal: true,
},
},
});
@@ -127,19 +127,19 @@ describe("GenericACPAgentClient diagnostics", () => {
{
clientCapabilities: {
fs: {
readTextFile: false,
writeTextFile: false,
readTextFile: true,
writeTextFile: true,
},
terminal: false,
terminal: true,
},
},
{
clientCapabilities: {
fs: {
readTextFile: false,
writeTextFile: false,
readTextFile: true,
writeTextFile: true,
},
terminal: false,
terminal: true,
},
},
]);