@agentclientprotocol/claude-agent-acp 0.26.0 → 0.28.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/acp-agent.d.ts +19 -1
- package/dist/acp-agent.d.ts.map +1 -1
- package/dist/acp-agent.js +49 -16
- package/dist/index.js +14 -2
- package/dist/lib.d.ts +1 -1
- package/dist/lib.d.ts.map +1 -1
- package/dist/tools.d.ts +1 -1
- package/dist/tools.d.ts.map +1 -1
- package/dist/tools.js +25 -25
- package/package.json +10 -10
package/dist/acp-agent.d.ts
CHANGED
|
@@ -38,6 +38,7 @@ type Session = {
|
|
|
38
38
|
}>;
|
|
39
39
|
nextPendingOrder: number;
|
|
40
40
|
abortController: AbortController;
|
|
41
|
+
emitRawSDKMessages: boolean | SDKMessageFilter[];
|
|
41
42
|
};
|
|
42
43
|
type BackgroundTerminal = {
|
|
43
44
|
handle: TerminalHandle;
|
|
@@ -47,6 +48,10 @@ type BackgroundTerminal = {
|
|
|
47
48
|
status: "aborted" | "exited" | "killed" | "timedOut";
|
|
48
49
|
pendingOutput: TerminalOutputResponse;
|
|
49
50
|
};
|
|
51
|
+
export type SDKMessageFilter = {
|
|
52
|
+
type: string;
|
|
53
|
+
subtype?: string;
|
|
54
|
+
};
|
|
50
55
|
/**
|
|
51
56
|
* Extra metadata that can be given when creating a new session.
|
|
52
57
|
*/
|
|
@@ -68,6 +73,14 @@ export type NewSessionMeta = {
|
|
|
68
73
|
* - tools (passed through; defaults to claude_code preset if not provided)
|
|
69
74
|
*/
|
|
70
75
|
options?: Options;
|
|
76
|
+
/**
|
|
77
|
+
* When set, raw SDK messages are emitted as extNotification("_claude/sdkMessage", message)
|
|
78
|
+
* in addition to normal processing.
|
|
79
|
+
* - true: emit all messages
|
|
80
|
+
* - false/undefined: emit nothing (default)
|
|
81
|
+
* - SDKMessageFilter[]: emit only messages matching at least one filter
|
|
82
|
+
*/
|
|
83
|
+
emitRawSDKMessages?: boolean | SDKMessageFilter[];
|
|
71
84
|
};
|
|
72
85
|
additionalRoots?: string[];
|
|
73
86
|
};
|
|
@@ -142,6 +155,8 @@ export declare class ClaudeAcpAgent implements Agent {
|
|
|
142
155
|
/** Cleanly tear down a session: cancel in-flight work, dispose resources,
|
|
143
156
|
* and remove it from the session map. */
|
|
144
157
|
private teardownSession;
|
|
158
|
+
/** Tear down all active sessions. Called when the ACP connection closes. */
|
|
159
|
+
dispose(): Promise<void>;
|
|
145
160
|
unstable_closeSession(params: CloseSessionRequest): Promise<CloseSessionResponse>;
|
|
146
161
|
unstable_setSessionModel(params: SetSessionModelRequest): Promise<SetSessionModelResponse | void>;
|
|
147
162
|
setSessionMode(params: SetSessionModeRequest): Promise<SetSessionModeResponse>;
|
|
@@ -172,6 +187,9 @@ export declare function streamEventToAcpNotifications(message: SDKPartialAssista
|
|
|
172
187
|
clientCapabilities?: ClientCapabilities;
|
|
173
188
|
cwd?: string;
|
|
174
189
|
}): SessionNotification[];
|
|
175
|
-
export declare function runAcp():
|
|
190
|
+
export declare function runAcp(): {
|
|
191
|
+
connection: AgentSideConnection;
|
|
192
|
+
agent: ClaudeAcpAgent;
|
|
193
|
+
};
|
|
176
194
|
export {};
|
|
177
195
|
//# sourceMappingURL=acp-agent.d.ts.map
|
package/dist/acp-agent.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"acp-agent.d.ts","sourceRoot":"","sources":["../src/acp-agent.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,EACL,mBAAmB,EACnB,mBAAmB,EAGnB,kBAAkB,EAClB,kBAAkB,EAClB,kBAAkB,EAClB,mBAAmB,EACnB,iBAAiB,EACjB,kBAAkB,EAClB,mBAAmB,EACnB,oBAAoB,EACpB,kBAAkB,EAClB,mBAAmB,EAEnB,iBAAiB,EACjB,kBAAkB,EAClB,aAAa,EACb,cAAc,EACd,mBAAmB,EACnB,oBAAoB,EAEpB,oBAAoB,EACpB,qBAAqB,EACrB,mBAAmB,EACnB,iBAAiB,EACjB,gBAAgB,EAChB,mBAAmB,EACnB,6BAA6B,EAC7B,8BAA8B,EAC9B,sBAAsB,EACtB,uBAAuB,EACvB,qBAAqB,EACrB,sBAAsB,EACtB,mBAAmB,EACnB,oBAAoB,EACpB,cAAc,EACd,sBAAsB,EACtB,oBAAoB,EACpB,qBAAqB,EAEtB,MAAM,0BAA0B,CAAC;AAClC,OAAO,EACL,UAAU,EAMV,OAAO,EACP,cAAc,EACd,KAAK,EAEL,0BAA0B,EAE1B,cAAc,EAEf,MAAM,gCAAgC,CAAC;AACxC,OAAO,EAAE,iBAAiB,EAAE,MAAM,6BAA6B,CAAC;AAChE,OAAO,EAAE,gBAAgB,EAAE,wBAAwB,EAAE,MAAM,sCAAsC,CAAC;
|
|
1
|
+
{"version":3,"file":"acp-agent.d.ts","sourceRoot":"","sources":["../src/acp-agent.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,EACL,mBAAmB,EACnB,mBAAmB,EAGnB,kBAAkB,EAClB,kBAAkB,EAClB,kBAAkB,EAClB,mBAAmB,EACnB,iBAAiB,EACjB,kBAAkB,EAClB,mBAAmB,EACnB,oBAAoB,EACpB,kBAAkB,EAClB,mBAAmB,EAEnB,iBAAiB,EACjB,kBAAkB,EAClB,aAAa,EACb,cAAc,EACd,mBAAmB,EACnB,oBAAoB,EAEpB,oBAAoB,EACpB,qBAAqB,EACrB,mBAAmB,EACnB,iBAAiB,EACjB,gBAAgB,EAChB,mBAAmB,EACnB,6BAA6B,EAC7B,8BAA8B,EAC9B,sBAAsB,EACtB,uBAAuB,EACvB,qBAAqB,EACrB,sBAAsB,EACtB,mBAAmB,EACnB,oBAAoB,EACpB,cAAc,EACd,sBAAsB,EACtB,oBAAoB,EACpB,qBAAqB,EAEtB,MAAM,0BAA0B,CAAC;AAClC,OAAO,EACL,UAAU,EAMV,OAAO,EACP,cAAc,EACd,KAAK,EAEL,0BAA0B,EAE1B,cAAc,EAEf,MAAM,g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EAAE,EACvF,IAAI,EAAE,WAAW,GAAG,MAAM,EAC1B,SAAS,EAAE,MAAM,EACjB,YAAY,EAAE,YAAY,EAC1B,MAAM,EAAE,mBAAmB,EAC3B,MAAM,EAAE,MAAM,EACd,OAAO,CAAC,EAAE;IACR,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,kBAAkB,CAAC,EAAE,kBAAkB,CAAC;IACxC,eAAe,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAChC,GAAG,CAAC,EAAE,MAAM,CAAC;CACd,GACA,mBAAmB,EAAE,CAoPvB;AAED,wBAAgB,6BAA6B,CAC3C,OAAO,EAAE,0BAA0B,EACnC,SAAS,EAAE,MAAM,EACjB,YAAY,EAAE,YAAY,EAC1B,MAAM,EAAE,mBAAmB,EAC3B,MAAM,EAAE,MAAM,EACd,OAAO,CAAC,EAAE;IACR,kBAAkB,CAAC,EAAE,kBAAkB,CAAC;IACxC,GAAG,CAAC,EAAE,MAAM,CAAC;CACd,GACA,mBAAmB,EAAE,CA0CvB;AAED,wBAAgB,MAAM;;;EAWrB"}
|
package/dist/acp-agent.js
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { AgentSideConnection, ndJsonStream, RequestError, } from "@agentclientprotocol/sdk";
|
|
2
2
|
import { getSessionMessages, listSessions, query, } from "@anthropic-ai/claude-agent-sdk";
|
|
3
3
|
import { randomUUID } from "node:crypto";
|
|
4
|
-
import * as fs from "node:fs";
|
|
5
4
|
import * as os from "node:os";
|
|
6
5
|
import * as path from "node:path";
|
|
7
6
|
import packageJson from "../package.json" with { type: "json" };
|
|
@@ -101,11 +100,17 @@ export class ClaudeAcpAgent {
|
|
|
101
100
|
};
|
|
102
101
|
const supportsTerminalAuth = request.clientCapabilities?.auth?.terminal === true;
|
|
103
102
|
const supportsMetaTerminalAuth = request.clientCapabilities?._meta?.["terminal-auth"] === true;
|
|
104
|
-
|
|
105
|
-
//
|
|
106
|
-
//
|
|
103
|
+
// Detect remote environments where the OAuth browser redirect to localhost
|
|
104
|
+
// won't work. This matches the SDK's internal isRemote check. In these cases,
|
|
105
|
+
// the `auth login` subcommand would fall back to a device-code-like manual
|
|
106
|
+
// flow, which doesn't work well over ACP, so we offer the TUI login instead.
|
|
107
|
+
const isRemote = !!(process.env.NO_BROWSER ||
|
|
108
|
+
process.env.SSH_CONNECTION ||
|
|
109
|
+
process.env.SSH_CLIENT ||
|
|
110
|
+
process.env.SSH_TTY ||
|
|
111
|
+
process.env.CLAUDE_CODE_REMOTE);
|
|
107
112
|
const terminalAuthMethods = [];
|
|
108
|
-
if (
|
|
113
|
+
if (isRemote) {
|
|
109
114
|
const remoteLoginMethod = {
|
|
110
115
|
description: "Run `claude /login` in the terminal",
|
|
111
116
|
name: "Log in with Claude",
|
|
@@ -198,11 +203,6 @@ export class ClaudeAcpAgent {
|
|
|
198
203
|
};
|
|
199
204
|
}
|
|
200
205
|
async newSession(params) {
|
|
201
|
-
if (!this.gatewayAuthMeta &&
|
|
202
|
-
fs.existsSync(path.resolve(os.homedir(), ".claude.json.backup")) &&
|
|
203
|
-
!fs.existsSync(path.resolve(os.homedir(), ".claude.json"))) {
|
|
204
|
-
throw RequestError.authRequired();
|
|
205
|
-
}
|
|
206
206
|
const response = await this.createSession(params, {
|
|
207
207
|
// Revisit these meta values once we support resume
|
|
208
208
|
resume: params._meta?.claudeCode?.options?.resume,
|
|
@@ -317,6 +317,13 @@ export class ClaudeAcpAgent {
|
|
|
317
317
|
}
|
|
318
318
|
break;
|
|
319
319
|
}
|
|
320
|
+
if (session.emitRawSDKMessages &&
|
|
321
|
+
shouldEmitRawMessage(session.emitRawSDKMessages, message)) {
|
|
322
|
+
await this.client.extNotification("_claude/sdkMessage", {
|
|
323
|
+
sessionId: params.sessionId,
|
|
324
|
+
message: message,
|
|
325
|
+
});
|
|
326
|
+
}
|
|
320
327
|
switch (message.type) {
|
|
321
328
|
case "system":
|
|
322
329
|
switch (message.subtype) {
|
|
@@ -387,7 +394,11 @@ export class ClaudeAcpAgent {
|
|
|
387
394
|
case "task_started":
|
|
388
395
|
case "task_notification":
|
|
389
396
|
case "task_progress":
|
|
397
|
+
case "task_updated":
|
|
390
398
|
case "elicitation_complete":
|
|
399
|
+
case "plugin_install":
|
|
400
|
+
case "memory_recall":
|
|
401
|
+
case "notification":
|
|
391
402
|
case "api_retry":
|
|
392
403
|
// Todo: process via status api: https://docs.claude.com/en/docs/claude-code/hooks#hook-output
|
|
393
404
|
break;
|
|
@@ -618,7 +629,7 @@ export class ClaudeAcpAgent {
|
|
|
618
629
|
async cancel(params) {
|
|
619
630
|
const session = this.sessions[params.sessionId];
|
|
620
631
|
if (!session) {
|
|
621
|
-
|
|
632
|
+
return;
|
|
622
633
|
}
|
|
623
634
|
session.cancelled = true;
|
|
624
635
|
for (const [, pending] of session.pendingMessages) {
|
|
@@ -637,8 +648,13 @@ export class ClaudeAcpAgent {
|
|
|
637
648
|
await this.cancel({ sessionId });
|
|
638
649
|
session.settingsManager.dispose();
|
|
639
650
|
session.abortController.abort();
|
|
651
|
+
session.query.close();
|
|
640
652
|
delete this.sessions[sessionId];
|
|
641
653
|
}
|
|
654
|
+
/** Tear down all active sessions. Called when the ACP connection closes. */
|
|
655
|
+
async dispose() {
|
|
656
|
+
await Promise.all(Object.keys(this.sessions).map((id) => this.teardownSession(id)));
|
|
657
|
+
}
|
|
642
658
|
async unstable_closeSession(params) {
|
|
643
659
|
if (!this.sessions[params.sessionId]) {
|
|
644
660
|
throw new Error("Session not found");
|
|
@@ -781,6 +797,7 @@ export class ClaudeAcpAgent {
|
|
|
781
797
|
}
|
|
782
798
|
if (toolName === "ExitPlanMode") {
|
|
783
799
|
const options = [
|
|
800
|
+
{ kind: "allow_always", name: 'Yes, and use "auto" mode', optionId: "auto" },
|
|
784
801
|
{
|
|
785
802
|
kind: "allow_always",
|
|
786
803
|
name: "Yes, and auto-accept edits",
|
|
@@ -811,6 +828,7 @@ export class ClaudeAcpAgent {
|
|
|
811
828
|
if (response.outcome?.outcome === "selected" &&
|
|
812
829
|
(response.outcome.optionId === "default" ||
|
|
813
830
|
response.outcome.optionId === "acceptEdits" ||
|
|
831
|
+
response.outcome.optionId === "auto" ||
|
|
814
832
|
response.outcome.optionId === "bypassPermissions")) {
|
|
815
833
|
await this.client.sessionUpdate({
|
|
816
834
|
sessionId,
|
|
@@ -1116,7 +1134,8 @@ export class ClaudeAcpAgent {
|
|
|
1116
1134
|
catch (error) {
|
|
1117
1135
|
if (creationOpts.resume &&
|
|
1118
1136
|
error instanceof Error &&
|
|
1119
|
-
error.message === "Query closed before response received"
|
|
1137
|
+
(error.message === "Query closed before response received" ||
|
|
1138
|
+
error.message.includes("No conversation found with session ID"))) {
|
|
1120
1139
|
throw RequestError.resourceNotFound(sessionId);
|
|
1121
1140
|
}
|
|
1122
1141
|
throw error;
|
|
@@ -1131,7 +1150,7 @@ export class ClaudeAcpAgent {
|
|
|
1131
1150
|
{
|
|
1132
1151
|
id: "auto",
|
|
1133
1152
|
name: "Auto",
|
|
1134
|
-
|
|
1153
|
+
description: "Use a model classifier to approve/deny permission prompts.",
|
|
1135
1154
|
},
|
|
1136
1155
|
{
|
|
1137
1156
|
id: "default",
|
|
@@ -1187,6 +1206,7 @@ export class ClaudeAcpAgent {
|
|
|
1187
1206
|
pendingMessages: new Map(),
|
|
1188
1207
|
nextPendingOrder: 0,
|
|
1189
1208
|
abortController,
|
|
1209
|
+
emitRawSDKMessages: sessionMeta?.claudeCode?.emitRawSDKMessages ?? false,
|
|
1190
1210
|
};
|
|
1191
1211
|
return {
|
|
1192
1212
|
sessionId,
|
|
@@ -1196,6 +1216,13 @@ export class ClaudeAcpAgent {
|
|
|
1196
1216
|
};
|
|
1197
1217
|
}
|
|
1198
1218
|
}
|
|
1219
|
+
function shouldEmitRawMessage(config, message) {
|
|
1220
|
+
if (config === true)
|
|
1221
|
+
return true;
|
|
1222
|
+
if (config === false)
|
|
1223
|
+
return false;
|
|
1224
|
+
return config.some((f) => f.type === message.type && (f.subtype === undefined || f.subtype === message.subtype));
|
|
1225
|
+
}
|
|
1199
1226
|
function sessionUsage(session) {
|
|
1200
1227
|
return {
|
|
1201
1228
|
inputTokens: session.accumulatedUsage.inputTokens,
|
|
@@ -1536,8 +1563,8 @@ export function toAcpNotifications(content, role, sessionId, toolUseCache, clien
|
|
|
1536
1563
|
const alreadyCached = chunk.id in toolUseCache;
|
|
1537
1564
|
toolUseCache[chunk.id] = chunk;
|
|
1538
1565
|
if (chunk.name === "TodoWrite") {
|
|
1539
|
-
// @ts-expect-error - sometimes input is empty object
|
|
1540
|
-
if (Array.isArray(chunk.input
|
|
1566
|
+
// @ts-expect-error - sometimes input is empty object or undefined
|
|
1567
|
+
if (Array.isArray(chunk.input?.todos)) {
|
|
1541
1568
|
update = {
|
|
1542
1569
|
sessionUpdate: "plan",
|
|
1543
1570
|
entries: planEntries(chunk.input),
|
|
@@ -1679,6 +1706,7 @@ export function toAcpNotifications(content, role, sessionId, toolUseCache, clien
|
|
|
1679
1706
|
case "container_upload":
|
|
1680
1707
|
case "compaction":
|
|
1681
1708
|
case "compaction_delta":
|
|
1709
|
+
case "advisor_tool_result":
|
|
1682
1710
|
break;
|
|
1683
1711
|
default:
|
|
1684
1712
|
unreachable(chunk, logger);
|
|
@@ -1729,7 +1757,12 @@ export function runAcp() {
|
|
|
1729
1757
|
const input = nodeToWebWritable(process.stdout);
|
|
1730
1758
|
const output = nodeToWebReadable(process.stdin);
|
|
1731
1759
|
const stream = ndJsonStream(input, output);
|
|
1732
|
-
|
|
1760
|
+
let agent;
|
|
1761
|
+
const connection = new AgentSideConnection((client) => {
|
|
1762
|
+
agent = new ClaudeAcpAgent(client);
|
|
1763
|
+
return agent;
|
|
1764
|
+
}, stream);
|
|
1765
|
+
return { connection, agent };
|
|
1733
1766
|
}
|
|
1734
1767
|
function commonPrefixLength(a, b) {
|
|
1735
1768
|
let i = 0;
|
package/dist/index.js
CHANGED
|
@@ -20,7 +20,19 @@ else {
|
|
|
20
20
|
process.on("unhandledRejection", (reason, promise) => {
|
|
21
21
|
console.error("Unhandled Rejection at:", promise, "reason:", reason);
|
|
22
22
|
});
|
|
23
|
-
runAcp();
|
|
24
|
-
|
|
23
|
+
const { connection, agent } = runAcp();
|
|
24
|
+
async function shutdown() {
|
|
25
|
+
await agent.dispose().catch((err) => {
|
|
26
|
+
console.error("Error during cleanup:", err);
|
|
27
|
+
});
|
|
28
|
+
process.exit(0);
|
|
29
|
+
}
|
|
30
|
+
// Exit cleanly when the ACP connection closes (e.g. stdin EOF, transport
|
|
31
|
+
// error). Without this, `process.stdin.resume()` keeps the event loop
|
|
32
|
+
// alive indefinitely, causing orphan process accumulation in oneshot mode.
|
|
33
|
+
connection.closed.then(shutdown);
|
|
34
|
+
process.on("SIGTERM", shutdown);
|
|
35
|
+
process.on("SIGINT", shutdown);
|
|
36
|
+
// Keep process alive while connection is open
|
|
25
37
|
process.stdin.resume();
|
|
26
38
|
}
|
package/dist/lib.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { ClaudeAcpAgent, runAcp, toAcpNotifications, streamEventToAcpNotifications, type ToolUpdateMeta, type NewSessionMeta, } from "./acp-agent.js";
|
|
1
|
+
export { ClaudeAcpAgent, runAcp, toAcpNotifications, streamEventToAcpNotifications, type ToolUpdateMeta, type NewSessionMeta, type SDKMessageFilter, } from "./acp-agent.js";
|
|
2
2
|
export { loadManagedSettings, applyEnvironmentSettings, nodeToWebReadable, nodeToWebWritable, Pushable, unreachable, } from "./utils.js";
|
|
3
3
|
export { toolInfoFromToolUse, toDisplayPath, planEntries, toolUpdateFromToolResult, } from "./tools.js";
|
|
4
4
|
export { SettingsManager, type ClaudeCodeSettings, type SettingsManagerOptions, } from "./settings.js";
|
package/dist/lib.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"lib.d.ts","sourceRoot":"","sources":["../src/lib.ts"],"names":[],"mappings":"AACA,OAAO,EACL,cAAc,EACd,MAAM,EACN,kBAAkB,EAClB,6BAA6B,EAC7B,KAAK,cAAc,EACnB,KAAK,cAAc,
|
|
1
|
+
{"version":3,"file":"lib.d.ts","sourceRoot":"","sources":["../src/lib.ts"],"names":[],"mappings":"AACA,OAAO,EACL,cAAc,EACd,MAAM,EACN,kBAAkB,EAClB,6BAA6B,EAC7B,KAAK,cAAc,EACnB,KAAK,cAAc,EACnB,KAAK,gBAAgB,GACtB,MAAM,gBAAgB,CAAC;AACxB,OAAO,EACL,mBAAmB,EACnB,wBAAwB,EACxB,iBAAiB,EACjB,iBAAiB,EACjB,QAAQ,EACR,WAAW,GACZ,MAAM,YAAY,CAAC;AACpB,OAAO,EACL,mBAAmB,EACnB,aAAa,EACb,WAAW,EACX,wBAAwB,GACzB,MAAM,YAAY,CAAC;AACpB,OAAO,EACL,eAAe,EACf,KAAK,kBAAkB,EACvB,KAAK,sBAAsB,GAC5B,MAAM,eAAe,CAAC;AAGvB,YAAY,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC"}
|
package/dist/tools.d.ts
CHANGED
|
@@ -42,7 +42,7 @@ export type ClaudePlanEntry = {
|
|
|
42
42
|
};
|
|
43
43
|
export declare function planEntries(input: {
|
|
44
44
|
todos: ClaudePlanEntry[];
|
|
45
|
-
}): PlanEntry[];
|
|
45
|
+
} | undefined): PlanEntry[];
|
|
46
46
|
export declare function markdownEscape(text: string): string;
|
|
47
47
|
/**
|
|
48
48
|
* Builds diff ToolUpdate content from the structured Edit toolResponse provided
|
package/dist/tools.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tools.d.ts","sourceRoot":"","sources":["../src/tools.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,SAAS,EACT,eAAe,EACf,gBAAgB,EAChB,QAAQ,EACT,MAAM,0BAA0B,CAAC;AAClC,OAAO,EAAE,YAAY,EAAE,MAAM,gCAAgC,CAAC;AAa9D,OAAO,EAGL,oBAAoB,EAEpB,6BAA6B,EAE9B,MAAM,6BAA6B,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,SAAS,CAAC,EAAE,gBAAgB,EAAE,CAAC;CAChC,CAoCA;AAcD,eAAO,MAAM,oBAAoB,GAC/B,WAAW,MAAM,EACjB,wBAEG;IACD,iBAAiB,CAAC,EAAE,CAClB,SAAS,EAAE,MAAM,EACjB,SAAS,EAAE,OAAO,EAClB,YAAY,EAAE,OAAO,KAClB,OAAO,CAAC,IAAI,CAAC,CAAC;CACpB,SAKF,CAAC;AAGF,eAAO,MAAM,qBAAqB,GAE9B,SAAQ,MAAgB,EACxB,UAAU;IACR,eAAe,CAAC,EAAE,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC;CACvC,KACA,YAoBF,CAAC"}
|
package/dist/tools.js
CHANGED
|
@@ -52,17 +52,17 @@ export function toolInfoFromToolUse(toolUse, supportsTerminalOutput = false, cwd
|
|
|
52
52
|
case "Read": {
|
|
53
53
|
const input = toolUse.input;
|
|
54
54
|
let limit = "";
|
|
55
|
-
if (input
|
|
55
|
+
if (input?.limit && input.limit > 0) {
|
|
56
56
|
limit = " (" + (input.offset ?? 1) + " - " + ((input.offset ?? 1) + input.limit - 1) + ")";
|
|
57
57
|
}
|
|
58
|
-
else if (input
|
|
58
|
+
else if (input?.offset) {
|
|
59
59
|
limit = " (from line " + input.offset + ")";
|
|
60
60
|
}
|
|
61
|
-
const displayPath = input
|
|
61
|
+
const displayPath = input?.file_path ? toDisplayPath(input.file_path, cwd) : "File";
|
|
62
62
|
return {
|
|
63
63
|
title: "Read " + displayPath + limit,
|
|
64
64
|
kind: "read",
|
|
65
|
-
locations: input
|
|
65
|
+
locations: input?.file_path
|
|
66
66
|
? [
|
|
67
67
|
{
|
|
68
68
|
path: input.file_path,
|
|
@@ -126,38 +126,38 @@ export function toolInfoFromToolUse(toolUse, supportsTerminalOutput = false, cwd
|
|
|
126
126
|
case "Glob": {
|
|
127
127
|
const input = toolUse.input;
|
|
128
128
|
let label = "Find";
|
|
129
|
-
if (input
|
|
129
|
+
if (input?.path) {
|
|
130
130
|
label += ` \`${input.path}\``;
|
|
131
131
|
}
|
|
132
|
-
if (input
|
|
132
|
+
if (input?.pattern) {
|
|
133
133
|
label += ` \`${input.pattern}\``;
|
|
134
134
|
}
|
|
135
135
|
return {
|
|
136
136
|
title: label,
|
|
137
137
|
kind: "search",
|
|
138
138
|
content: [],
|
|
139
|
-
locations: input
|
|
139
|
+
locations: input?.path ? [{ path: input.path }] : [],
|
|
140
140
|
};
|
|
141
141
|
}
|
|
142
142
|
case "Grep": {
|
|
143
143
|
const input = toolUse.input;
|
|
144
144
|
let label = "grep";
|
|
145
|
-
if (input["-i"]) {
|
|
145
|
+
if (input?.["-i"]) {
|
|
146
146
|
label += " -i";
|
|
147
147
|
}
|
|
148
|
-
if (input["-n"]) {
|
|
148
|
+
if (input?.["-n"]) {
|
|
149
149
|
label += " -n";
|
|
150
150
|
}
|
|
151
|
-
if (input["-A"] !== undefined) {
|
|
151
|
+
if (input?.["-A"] !== undefined) {
|
|
152
152
|
label += ` -A ${input["-A"]}`;
|
|
153
153
|
}
|
|
154
|
-
if (input["-B"] !== undefined) {
|
|
154
|
+
if (input?.["-B"] !== undefined) {
|
|
155
155
|
label += ` -B ${input["-B"]}`;
|
|
156
156
|
}
|
|
157
|
-
if (input["-C"] !== undefined) {
|
|
157
|
+
if (input?.["-C"] !== undefined) {
|
|
158
158
|
label += ` -C ${input["-C"]}`;
|
|
159
159
|
}
|
|
160
|
-
if (input
|
|
160
|
+
if (input?.output_mode) {
|
|
161
161
|
switch (input.output_mode) {
|
|
162
162
|
case "files_with_matches":
|
|
163
163
|
label += " -l";
|
|
@@ -170,22 +170,22 @@ export function toolInfoFromToolUse(toolUse, supportsTerminalOutput = false, cwd
|
|
|
170
170
|
break;
|
|
171
171
|
}
|
|
172
172
|
}
|
|
173
|
-
if (input
|
|
173
|
+
if (input?.head_limit !== undefined) {
|
|
174
174
|
label += ` | head -${input.head_limit}`;
|
|
175
175
|
}
|
|
176
|
-
if (input
|
|
176
|
+
if (input?.glob) {
|
|
177
177
|
label += ` --include="${input.glob}"`;
|
|
178
178
|
}
|
|
179
|
-
if (input
|
|
179
|
+
if (input?.type) {
|
|
180
180
|
label += ` --type=${input.type}`;
|
|
181
181
|
}
|
|
182
|
-
if (input
|
|
182
|
+
if (input?.multiline) {
|
|
183
183
|
label += " -P";
|
|
184
184
|
}
|
|
185
|
-
if (input
|
|
185
|
+
if (input?.pattern) {
|
|
186
186
|
label += ` "${input.pattern}"`;
|
|
187
187
|
}
|
|
188
|
-
if (input
|
|
188
|
+
if (input?.path) {
|
|
189
189
|
label += ` ${input.path}`;
|
|
190
190
|
}
|
|
191
191
|
return {
|
|
@@ -211,11 +211,11 @@ export function toolInfoFromToolUse(toolUse, supportsTerminalOutput = false, cwd
|
|
|
211
211
|
}
|
|
212
212
|
case "WebSearch": {
|
|
213
213
|
const input = toolUse.input;
|
|
214
|
-
let label = `"${input.query}"
|
|
215
|
-
if (input
|
|
214
|
+
let label = input?.query ? `"${input.query}"` : "Web search";
|
|
215
|
+
if (input?.allowed_domains && input.allowed_domains.length > 0) {
|
|
216
216
|
label += ` (allowed: ${input.allowed_domains.join(", ")})`;
|
|
217
217
|
}
|
|
218
|
-
if (input
|
|
218
|
+
if (input?.blocked_domains && input.blocked_domains.length > 0) {
|
|
219
219
|
label += ` (blocked: ${input.blocked_domains.join(", ")})`;
|
|
220
220
|
}
|
|
221
221
|
return {
|
|
@@ -477,9 +477,9 @@ function toAcpContentBlock(content, isError) {
|
|
|
477
477
|
}
|
|
478
478
|
}
|
|
479
479
|
export function planEntries(input) {
|
|
480
|
-
return input
|
|
481
|
-
content:
|
|
482
|
-
status:
|
|
480
|
+
return (input?.todos ?? []).map((todo) => ({
|
|
481
|
+
content: todo.content,
|
|
482
|
+
status: todo.status,
|
|
483
483
|
priority: "medium",
|
|
484
484
|
}));
|
|
485
485
|
}
|
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"publishConfig": {
|
|
4
4
|
"access": "public"
|
|
5
5
|
},
|
|
6
|
-
"version": "0.
|
|
6
|
+
"version": "0.28.0",
|
|
7
7
|
"description": "An ACP-compatible coding agent powered by the Claude Agent SDK (TypeScript)",
|
|
8
8
|
"main": "dist/lib.js",
|
|
9
9
|
"types": "dist/lib.d.ts",
|
|
@@ -60,22 +60,22 @@
|
|
|
60
60
|
"author": "Zed Industries",
|
|
61
61
|
"license": "Apache-2.0",
|
|
62
62
|
"dependencies": {
|
|
63
|
-
"@agentclientprotocol/sdk": "0.
|
|
64
|
-
"@anthropic-ai/claude-agent-sdk": "0.2.
|
|
63
|
+
"@agentclientprotocol/sdk": "0.19.0",
|
|
64
|
+
"@anthropic-ai/claude-agent-sdk": "0.2.109",
|
|
65
65
|
"zod": "^3.25.0 || ^4.0.0"
|
|
66
66
|
},
|
|
67
67
|
"devDependencies": {
|
|
68
|
-
"@anthropic-ai/sdk": "0.
|
|
68
|
+
"@anthropic-ai/sdk": "0.89.0",
|
|
69
69
|
"@eslint/js": "10.0.1",
|
|
70
|
-
"@types/node": "25.
|
|
71
|
-
"@typescript-eslint/eslint-plugin": "8.58.
|
|
72
|
-
"@typescript-eslint/parser": "8.58.
|
|
70
|
+
"@types/node": "25.6.0",
|
|
71
|
+
"@typescript-eslint/eslint-plugin": "8.58.2",
|
|
72
|
+
"@typescript-eslint/parser": "8.58.2",
|
|
73
73
|
"eslint": "10.2.0",
|
|
74
74
|
"eslint-config-prettier": "10.1.8",
|
|
75
|
-
"globals": "17.
|
|
76
|
-
"prettier": "3.8.
|
|
75
|
+
"globals": "17.5.0",
|
|
76
|
+
"prettier": "3.8.3",
|
|
77
77
|
"ts-node": "10.9.2",
|
|
78
78
|
"typescript": "6.0.2",
|
|
79
|
-
"vitest": "4.1.
|
|
79
|
+
"vitest": "4.1.4"
|
|
80
80
|
}
|
|
81
81
|
}
|