From 0e77751692a47d543e2ce52907fffc2e762f9247 Mon Sep 17 00:00:00 2001 From: Ben Brandt Date: Tue, 17 Feb 2026 12:14:55 +0100 Subject: [PATCH] Claude Code -> Claude Agent (#319) Update based on https://platform.claude.com/docs/en/agent-sdk/overview#branding-guidelines --- CHANGELOG.md | 4 ++++ README.md | 14 ++++++------- package-lock.json | 4 ++-- package.json | 14 ++++++------- src/acp-agent.ts | 12 ++++++------ src/tests/acp-agent.test.ts | 4 ++-- src/tests/list-sessions.test.ts | 8 ++++---- src/tests/typescript-declarations.test.ts | 24 +++++++++++------------ 8 files changed, 44 insertions(+), 40 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 4aa9b608..4112b409 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,9 @@ # Changelog +## 0.17.0 + +Rename from `@zed-industries/claude-code-acp` to `@zed-industries/claude-agent-acp` to align with the current [branding guidelines](https://platform.claude.com/docs/en/agent-sdk/overview#branding-guidelines) + ## 0.16.2 - Update to @anthropic-ai/claude-agent-sdk@0.2.44 diff --git a/README.md b/README.md index a0ca85ce..ec351b7c 100644 --- a/README.md +++ b/README.md @@ -1,8 +1,8 @@ -# ACP adapter for Claude Code +# ACP adapter for the Claude Agent SDK -[![npm](https://img.shields.io/npm/v/%40zed-industries%2Fclaude-code-acp)](https://www.npmjs.com/package/@zed-industries/claude-code-acp) +[![npm](https://img.shields.io/npm/v/%40zed-industries%2Fclaude-agent-acp)](https://www.npmjs.com/package/@zed-industries/claude-agent-acp) -Use [Claude Code](https://www.anthropic.com/claude-code) from [ACP-compatible](https://agentclientprotocol.com) clients such as [Zed](https://zed.dev)! +Use [Claude Agent SDK](https://platform.claude.com/docs/en/agent-sdk/overview#branding-guidelines) from [ACP-compatible](https://agentclientprotocol.com) clients such as [Zed](https://zed.dev)! This tool implements an ACP agent by using the official [Claude Agent SDK](https://platform.claude.com/docs/en/agent-sdk/overview), supporting: @@ -24,7 +24,7 @@ Learn more about the [Agent Client Protocol](https://agentclientprotocol.com/). The latest version of Zed can already use this adapter out of the box. -To use Claude Code, open the Agent Panel and click "New Claude Code Thread" from the `+` button menu in the top-right: +To use Claude Agent, open the Agent Panel and click "New Claude Agent Thread" from the `+` button menu in the top-right: https://github.com/user-attachments/assets/ddce66c7-79ac-47a3-ad59-4a6a3ca74903 @@ -39,13 +39,13 @@ Or try it with any of the other [ACP compatible clients](https://agentclientprot Install the adapter from `npm`: ```bash -npm install -g @zed-industries/claude-code-acp +npm install -g @zed-industries/claude-agent-acp ``` -You can then use `claude-code-acp` as a regular ACP agent: +You can then use `claude-agent-acp` as a regular ACP agent: ``` -ANTHROPIC_API_KEY=sk-... claude-code-acp +ANTHROPIC_API_KEY=sk-... claude-agent-acp ``` ## License diff --git a/package-lock.json b/package-lock.json index 09ae3384..e2404d1c 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { - "name": "@zed-industries/claude-code-acp", - "version": "0.16.2", + "name": "@zed-industries/claude-agent-acp", + "version": "0.17.0", "lockfileVersion": 3, "requires": true, "packages": { diff --git a/package.json b/package.json index a262d198..aa281653 100644 --- a/package.json +++ b/package.json @@ -1,14 +1,14 @@ { - "name": "@zed-industries/claude-code-acp", + "name": "@zed-industries/claude-agent-acp", "publishConfig": { "access": "public" }, - "version": "0.16.2", - "description": "An ACP-compatible coding agent powered by the Claude Code SDK (TypeScript)", + "version": "0.17.0", + "description": "An ACP-compatible coding agent powered by the Claude Agent SDK (TypeScript)", "main": "dist/lib.js", "types": "dist/lib.d.ts", "bin": { - "claude-code-acp": "./dist/index.js" + "claude-agent-acp": "./dist/index.js" }, "type": "module", "exports": { @@ -49,13 +49,13 @@ "sdk", "code" ], - "homepage": "https://github.com/zed-industries/claude-code-acp#readme", + "homepage": "https://github.com/zed-industries/claude-agent-acp#readme", "bugs": { - "url": "https://github.com/zed-industries/claude-code-acp/issues" + "url": "https://github.com/zed-industries/claude-agent-acp/issues" }, "repository": { "type": "git", - "url": "git+https://github.com/zed-industries/claude-code-acp.git" + "url": "git+https://github.com/zed-industries/claude-agent-acp.git" }, "author": "Zed Industries", "license": "Apache-2.0", diff --git a/src/acp-agent.ts b/src/acp-agent.ts index 876d0ed4..3ced86f7 100644 --- a/src/acp-agent.ts +++ b/src/acp-agent.ts @@ -136,7 +136,7 @@ type BackgroundTerminal = }; /** - * Extra metadata that can be given to Claude Code when creating a new session. + * Extra metadata that can be given when creating a new session. */ export type NewSessionMeta = { claudeCode?: { @@ -207,7 +207,7 @@ export class ClaudeAcpAgent implements Agent { // Default authMethod const authMethod: any = { description: "Run `claude /login` in the terminal", - name: "Log in with Claude Code", + name: "Log in with Claude", id: "claude-login", }; @@ -219,7 +219,7 @@ export class ClaudeAcpAgent implements Agent { "terminal-auth": { command: "node", args: [cliPath], - label: "Claude Code Login", + label: "Claude Login", }, }; } @@ -244,7 +244,7 @@ export class ClaudeAcpAgent implements Agent { }, agentInfo: { name: packageJson.name, - title: "Claude Code", + title: "Claude Agent", version: packageJson.version, }, authMethods: [authMethod], @@ -1511,7 +1511,7 @@ export function toAcpNotifications( }); } else { logger.error( - `[claude-code-acp] Got a tool response for tool use that wasn't tracked: ${toolUseId}`, + `[claude-agent-acp] Got a tool response for tool use that wasn't tracked: ${toolUseId}`, ); } }, @@ -1551,7 +1551,7 @@ export function toAcpNotifications( const toolUse = toolUseCache[chunk.tool_use_id]; if (!toolUse) { logger.error( - `[claude-code-acp] Got a tool result for tool use that wasn't tracked: ${chunk.tool_use_id}`, + `[claude-agent-acp] Got a tool result for tool use that wasn't tracked: ${chunk.tool_use_id}`, ); break; } diff --git a/src/tests/acp-agent.test.ts b/src/tests/acp-agent.test.ts index 15dff812..60ae042d 100644 --- a/src/tests/acp-agent.test.ts +++ b/src/tests/acp-agent.test.ts @@ -325,13 +325,13 @@ describe("tool conversions", () => { id: "toolu_01EEqsX7Eb9hpx87KAHVPTey", name: "LS", input: { - path: "/Users/test/github/claude-code-acp", + path: "/Users/test/github/claude-agent-acp", }, }; expect(toolInfoFromToolUse(tool_use)).toStrictEqual({ kind: "search", - title: "List the `/Users/test/github/claude-code-acp` directory's contents", + title: "List the `/Users/test/github/claude-agent-acp` directory's contents", content: [], locations: [], }); diff --git a/src/tests/list-sessions.test.ts b/src/tests/list-sessions.test.ts index b85ef8ae..6b4e4afb 100644 --- a/src/tests/list-sessions.test.ts +++ b/src/tests/list-sessions.test.ts @@ -241,7 +241,7 @@ describe("unstable_listSessions", () => { }); it("returns the true cwd for paths containing hyphens", async () => { - const cwd = "/Users/test/claude-code-acp"; + const cwd = "/Users/test/claude-agent-acp"; writeSessionFile(cwd, "hyphen-session", { userMessage: "Hyphen test" }); const result = await agent.unstable_listSessions({}); @@ -252,14 +252,14 @@ describe("unstable_listSessions", () => { }); it("filters hyphenated paths by cwd correctly", async () => { - writeSessionFile("/Users/test/claude-code-acp", "hyphen-a", { userMessage: "A" }); + writeSessionFile("/Users/test/claude-agent-acp", "hyphen-a", { userMessage: "A" }); writeSessionFile("/Users/test/other-project", "hyphen-b", { userMessage: "B" }); - const result = await agent.unstable_listSessions({ cwd: "/Users/test/claude-code-acp" }); + const result = await agent.unstable_listSessions({ cwd: "/Users/test/claude-agent-acp" }); expect(result.sessions).toHaveLength(1); expect(result.sessions[0]!.sessionId).toBe("hyphen-a"); - expect(result.sessions[0]!.cwd).toBe("/Users/test/claude-code-acp"); + expect(result.sessions[0]!.cwd).toBe("/Users/test/claude-agent-acp"); }); it("returns all sessions when cwd is not specified", async () => { diff --git a/src/tests/typescript-declarations.test.ts b/src/tests/typescript-declarations.test.ts index b032df72..3d65265d 100644 --- a/src/tests/typescript-declarations.test.ts +++ b/src/tests/typescript-declarations.test.ts @@ -180,7 +180,7 @@ import { toolUpdateFromToolResult, createPreToolUseHook, toolNames, -} from "@zed-industries/claude-code-acp"; +} from "@zed-industries/claude-agent-acp"; // Type-only imports import type { @@ -192,7 +192,7 @@ import type { PermissionCheckResult, SettingsManagerOptions, ClaudePlanEntry, -} from "@zed-industries/claude-code-acp"; +} from "@zed-industries/claude-agent-acp"; // Verify exports exist and have expected types const _runAcp: typeof runAcp = runAcp; @@ -222,13 +222,13 @@ import { ACP_TOOL_NAME_PREFIX, toolInfoFromToolUse, planEntries, -} from "@zed-industries/claude-code-acp/dist/tools.js"; +} from "@zed-industries/claude-agent-acp/dist/tools.js"; // Deep import from dist/settings.js import { SettingsManager, getManagedSettingsPath, -} from "@zed-industries/claude-code-acp/dist/settings.js"; +} from "@zed-industries/claude-agent-acp/dist/settings.js"; // Deep import from dist/utils.js import { @@ -236,7 +236,7 @@ import { nodeToWebReadable, nodeToWebWritable, loadManagedSettings, -} from "@zed-industries/claude-code-acp/dist/utils.js"; +} from "@zed-industries/claude-agent-acp/dist/utils.js"; // Verify types work const prefix: string = ACP_TOOL_NAME_PREFIX; @@ -263,7 +263,7 @@ import { ClaudeCodeSettings, PermissionCheckResult, SettingsManagerOptions -} from "@zed-industries/claude-code-acp"; +} from "@zed-industries/claude-agent-acp"; // Test constructor signature const options: SettingsManagerOptions = { @@ -318,7 +318,7 @@ async function testMethods() { await writeTestFile( "test-claude-acp-agent.ts", ` -import { ClaudeAcpAgent } from "@zed-industries/claude-code-acp"; +import { ClaudeAcpAgent } from "@zed-industries/claude-agent-acp"; import type { AgentSideConnection } from "@agentclientprotocol/sdk"; // ClaudeAcpAgent should be a class that can be instantiated @@ -362,7 +362,7 @@ import type { ClaudePlanEntry, ToolUpdateMeta, NewSessionMeta, -} from "@zed-industries/claude-code-acp"; +} from "@zed-industries/claude-agent-acp"; // Test ClaudeCodeSettings shape const settings: ClaudeCodeSettings = { @@ -441,9 +441,9 @@ import { loadManagedSettings, applyEnvironmentSettings, SettingsManager, -} from "@zed-industries/claude-code-acp"; +} from "@zed-industries/claude-agent-acp"; -import type { ClaudeCodeSettings } from "@zed-industries/claude-code-acp"; +import type { ClaudeCodeSettings } from "@zed-industries/claude-agent-acp"; // runAcp should be a function with no parameters that returns void const runAcpType: () => void = runAcp; @@ -488,7 +488,7 @@ const applyResult: void = applyEnvironmentSettings({ permissions: {} }); await writeTestFile( "test-pushable.ts", ` -import { Pushable } from "@zed-industries/claude-code-acp"; +import { Pushable } from "@zed-industries/claude-agent-acp"; // Pushable should be a generic class const pushable = new Pushable(); @@ -530,7 +530,7 @@ customPushable.push({ id: 1, name: "test" }); await writeTestFile( "test-invalid-types.ts", ` -import { SettingsManager, ClaudeCodeSettings } from "@zed-industries/claude-code-acp"; +import { SettingsManager, ClaudeCodeSettings } from "@zed-industries/claude-agent-acp"; // This should fail - SettingsManager constructor requires string cwd // @ts-expect-error - Testing that wrong argument type fails