@toyon-dev/claude-agent-acp 0.0.0-stage → 0.99.1-toyon.1
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/LICENSE +191 -0
- package/README.md +125 -2
- package/dist/acp-agent.d.ts +2058 -0
- package/dist/acp-agent.d.ts.map +1 -0
- package/dist/acp-agent.js +11332 -0
- package/dist/acp-subagents.d.ts +99 -0
- package/dist/acp-subagents.d.ts.map +1 -0
- package/dist/acp-subagents.js +19 -0
- package/dist/air-extension.d.ts +114 -0
- package/dist/air-extension.d.ts.map +1 -0
- package/dist/air-extension.js +162 -0
- package/dist/async-tasks.d.ts +232 -0
- package/dist/async-tasks.d.ts.map +1 -0
- package/dist/async-tasks.js +935 -0
- package/dist/auth-status.d.ts +140 -0
- package/dist/auth-status.d.ts.map +1 -0
- package/dist/auth-status.js +285 -0
- package/dist/blob-resources.d.ts +48 -0
- package/dist/blob-resources.d.ts.map +1 -0
- package/dist/blob-resources.js +93 -0
- package/dist/clear-context-coordinator.d.ts +64 -0
- package/dist/clear-context-coordinator.d.ts.map +1 -0
- package/dist/clear-context-coordinator.js +91 -0
- package/dist/client-system-prompt.d.ts +41 -0
- package/dist/client-system-prompt.d.ts.map +1 -0
- package/dist/client-system-prompt.js +40 -0
- package/dist/context-compaction-meta.d.ts +19 -0
- package/dist/context-compaction-meta.d.ts.map +1 -0
- package/dist/context-compaction-meta.js +15 -0
- package/dist/context-compaction.d.ts +135 -0
- package/dist/context-compaction.d.ts.map +1 -0
- package/dist/context-compaction.js +341 -0
- package/dist/diff.d.ts +120 -0
- package/dist/diff.d.ts.map +1 -0
- package/dist/diff.js +619 -0
- package/dist/elicitation.d.ts +148 -0
- package/dist/elicitation.d.ts.map +1 -0
- package/dist/elicitation.js +370 -0
- package/dist/exit-plan.d.ts +63 -0
- package/dist/exit-plan.d.ts.map +1 -0
- package/dist/exit-plan.js +205 -0
- package/dist/file-change-audit.d.ts +64 -0
- package/dist/file-change-audit.d.ts.map +1 -0
- package/dist/file-change-audit.js +290 -0
- package/dist/fork-session.d.ts +15 -0
- package/dist/fork-session.d.ts.map +1 -0
- package/dist/fork-session.js +142 -0
- package/dist/gateway-models.d.ts +62 -0
- package/dist/gateway-models.d.ts.map +1 -0
- package/dist/gateway-models.js +180 -0
- package/dist/goal-extension.d.ts +36 -0
- package/dist/goal-extension.d.ts.map +1 -0
- package/dist/goal-extension.js +50 -0
- package/dist/hide-claude-auth.d.ts +149 -0
- package/dist/hide-claude-auth.d.ts.map +1 -0
- package/dist/hide-claude-auth.js +223 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +98 -0
- package/dist/lib.d.ts +7 -0
- package/dist/lib.d.ts.map +1 -0
- package/dist/lib.js +8 -0
- package/dist/managed-policy.d.ts +19 -0
- package/dist/managed-policy.d.ts.map +1 -0
- package/dist/managed-policy.js +31 -0
- package/dist/mcp-command.d.ts +51 -0
- package/dist/mcp-command.d.ts.map +1 -0
- package/dist/mcp-command.js +326 -0
- package/dist/native-subagents.d.ts +588 -0
- package/dist/native-subagents.d.ts.map +1 -0
- package/dist/native-subagents.js +1725 -0
- package/dist/paths.d.ts +3 -0
- package/dist/paths.d.ts.map +1 -0
- package/dist/paths.js +6 -0
- package/dist/permissions/effects.d.ts +19 -0
- package/dist/permissions/effects.d.ts.map +1 -0
- package/dist/permissions/effects.js +166 -0
- package/dist/permissions/modes.d.ts +10 -0
- package/dist/permissions/modes.d.ts.map +1 -0
- package/dist/permissions/modes.js +43 -0
- package/dist/permissions/normalization.d.ts +6 -0
- package/dist/permissions/normalization.d.ts.map +1 -0
- package/dist/permissions/normalization.js +100 -0
- package/dist/permissions/options/filesystem.d.ts +9 -0
- package/dist/permissions/options/filesystem.d.ts.map +1 -0
- package/dist/permissions/options/filesystem.js +124 -0
- package/dist/permissions/options/shared.d.ts +47 -0
- package/dist/permissions/options/shared.d.ts.map +1 -0
- package/dist/permissions/options/shared.js +64 -0
- package/dist/permissions/options/shell.d.ts +5 -0
- package/dist/permissions/options/shell.d.ts.map +1 -0
- package/dist/permissions/options/shell.js +100 -0
- package/dist/permissions/options/tools.d.ts +11 -0
- package/dist/permissions/options/tools.d.ts.map +1 -0
- package/dist/permissions/options/tools.js +133 -0
- package/dist/permissions/options.d.ts +5 -0
- package/dist/permissions/options.d.ts.map +1 -0
- package/dist/permissions/options.js +73 -0
- package/dist/permissions/presentation.d.ts +42 -0
- package/dist/permissions/presentation.d.ts.map +1 -0
- package/dist/permissions/presentation.js +97 -0
- package/dist/permissions/response.d.ts +11 -0
- package/dist/permissions/response.d.ts.map +1 -0
- package/dist/permissions/response.js +19 -0
- package/dist/prompt-suggestions.d.ts +37 -0
- package/dist/prompt-suggestions.d.ts.map +1 -0
- package/dist/prompt-suggestions.js +36 -0
- package/dist/resumed-session.d.ts +40 -0
- package/dist/resumed-session.d.ts.map +1 -0
- package/dist/resumed-session.js +210 -0
- package/dist/serve.d.ts +31 -0
- package/dist/serve.d.ts.map +1 -0
- package/dist/serve.js +51 -0
- package/dist/session-config-ids.d.ts +6 -0
- package/dist/session-config-ids.d.ts.map +1 -0
- package/dist/session-config-ids.js +5 -0
- package/dist/session-effort.d.ts +19 -0
- package/dist/session-effort.d.ts.map +1 -0
- package/dist/session-effort.js +105 -0
- package/dist/session-failure-extension.d.ts +97 -0
- package/dist/session-failure-extension.d.ts.map +1 -0
- package/dist/session-failure-extension.js +364 -0
- package/dist/session-index/activity.d.ts +60 -0
- package/dist/session-index/activity.d.ts.map +1 -0
- package/dist/session-index/activity.js +112 -0
- package/dist/session-index/archive-title.d.ts +52 -0
- package/dist/session-index/archive-title.d.ts.map +1 -0
- package/dist/session-index/archive-title.js +77 -0
- package/dist/session-index/background-tasks.d.ts +69 -0
- package/dist/session-index/background-tasks.d.ts.map +1 -0
- package/dist/session-index/background-tasks.js +173 -0
- package/dist/session-index/connection.d.ts +164 -0
- package/dist/session-index/connection.d.ts.map +1 -0
- package/dist/session-index/connection.js +340 -0
- package/dist/session-index/dir-listing.d.ts +30 -0
- package/dist/session-index/dir-listing.d.ts.map +1 -0
- package/dist/session-index/dir-listing.js +110 -0
- package/dist/session-index/explicit-title.d.ts +34 -0
- package/dist/session-index/explicit-title.d.ts.map +1 -0
- package/dist/session-index/explicit-title.js +65 -0
- package/dist/session-index/first-prompt.d.ts +38 -0
- package/dist/session-index/first-prompt.d.ts.map +1 -0
- package/dist/session-index/first-prompt.js +196 -0
- package/dist/session-index/list-subscriptions.d.ts +229 -0
- package/dist/session-index/list-subscriptions.d.ts.map +1 -0
- package/dist/session-index/list-subscriptions.js +1251 -0
- package/dist/session-index/live-registry.d.ts +72 -0
- package/dist/session-index/live-registry.d.ts.map +1 -0
- package/dist/session-index/live-registry.js +240 -0
- package/dist/session-index/project-dirs.d.ts +47 -0
- package/dist/session-index/project-dirs.d.ts.map +1 -0
- package/dist/session-index/project-dirs.js +134 -0
- package/dist/session-index/service.d.ts +191 -0
- package/dist/session-index/service.d.ts.map +1 -0
- package/dist/session-index/service.js +610 -0
- package/dist/session-index/session-index.d.ts +256 -0
- package/dist/session-index/session-index.d.ts.map +1 -0
- package/dist/session-index/session-index.js +955 -0
- package/dist/session-index/session-info.d.ts +16 -0
- package/dist/session-index/session-info.d.ts.map +1 -0
- package/dist/session-index/session-info.js +52 -0
- package/dist/session-index/transcript-scan.d.ts +173 -0
- package/dist/session-index/transcript-scan.d.ts.map +1 -0
- package/dist/session-index/transcript-scan.js +624 -0
- package/dist/session-index/worktrees.d.ts +31 -0
- package/dist/session-index/worktrees.d.ts.map +1 -0
- package/dist/session-index/worktrees.js +140 -0
- package/dist/session-mode.d.ts +90 -0
- package/dist/session-mode.d.ts.map +1 -0
- package/dist/session-mode.js +277 -0
- package/dist/session-model.d.ts +96 -0
- package/dist/session-model.d.ts.map +1 -0
- package/dist/session-model.js +614 -0
- package/dist/session-notices.d.ts +41 -0
- package/dist/session-notices.d.ts.map +1 -0
- package/dist/session-notices.js +69 -0
- package/dist/session-timing.d.ts +15 -0
- package/dist/session-timing.d.ts.map +1 -0
- package/dist/session-timing.js +20 -0
- package/dist/session-titles.d.ts +132 -0
- package/dist/session-titles.d.ts.map +1 -0
- package/dist/session-titles.js +382 -0
- package/dist/session-ultracode.d.ts +51 -0
- package/dist/session-ultracode.d.ts.map +1 -0
- package/dist/session-ultracode.js +86 -0
- package/dist/settings.d.ts +80 -0
- package/dist/settings.d.ts.map +1 -0
- package/dist/settings.js +211 -0
- package/dist/subagent-history.d.ts +86 -0
- package/dist/subagent-history.d.ts.map +1 -0
- package/dist/subagent-history.js +272 -0
- package/dist/subagent-replay.d.ts +186 -0
- package/dist/subagent-replay.d.ts.map +1 -0
- package/dist/subagent-replay.js +433 -0
- package/dist/task-notifications.d.ts +30 -0
- package/dist/task-notifications.d.ts.map +1 -0
- package/dist/task-notifications.js +62 -0
- package/dist/tool-calls/background.d.ts +32 -0
- package/dist/tool-calls/background.d.ts.map +1 -0
- package/dist/tool-calls/background.js +61 -0
- package/dist/tool-calls/changed-meta-filter.d.ts +27 -0
- package/dist/tool-calls/changed-meta-filter.d.ts.map +1 -0
- package/dist/tool-calls/changed-meta-filter.js +102 -0
- package/dist/tool-calls/client-capabilities.d.ts +69 -0
- package/dist/tool-calls/client-capabilities.d.ts.map +1 -0
- package/dist/tool-calls/client-capabilities.js +53 -0
- package/dist/tool-calls/content.d.ts +59 -0
- package/dist/tool-calls/content.d.ts.map +1 -0
- package/dist/tool-calls/content.js +194 -0
- package/dist/tool-calls/facts.d.ts +123 -0
- package/dist/tool-calls/facts.d.ts.map +1 -0
- package/dist/tool-calls/facts.js +1 -0
- package/dist/tool-calls/field-tracker.d.ts +58 -0
- package/dist/tool-calls/field-tracker.d.ts.map +1 -0
- package/dist/tool-calls/field-tracker.js +167 -0
- package/dist/tool-calls/renderer.d.ts +294 -0
- package/dist/tool-calls/renderer.d.ts.map +1 -0
- package/dist/tool-calls/renderer.js +625 -0
- package/dist/tool-calls/reporters/agent.d.ts +7 -0
- package/dist/tool-calls/reporters/agent.d.ts.map +1 -0
- package/dist/tool-calls/reporters/agent.js +193 -0
- package/dist/tool-calls/reporters/bash.d.ts +16 -0
- package/dist/tool-calls/reporters/bash.d.ts.map +1 -0
- package/dist/tool-calls/reporters/bash.js +125 -0
- package/dist/tool-calls/reporters/compaction.d.ts +24 -0
- package/dist/tool-calls/reporters/compaction.d.ts.map +1 -0
- package/dist/tool-calls/reporters/compaction.js +66 -0
- package/dist/tool-calls/reporters/file-edit.d.ts +46 -0
- package/dist/tool-calls/reporters/file-edit.d.ts.map +1 -0
- package/dist/tool-calls/reporters/file-edit.js +186 -0
- package/dist/tool-calls/reporters/index.d.ts +4 -0
- package/dist/tool-calls/reporters/index.d.ts.map +1 -0
- package/dist/tool-calls/reporters/index.js +41 -0
- package/dist/tool-calls/reporters/interaction.d.ts +90 -0
- package/dist/tool-calls/reporters/interaction.d.ts.map +1 -0
- package/dist/tool-calls/reporters/interaction.js +438 -0
- package/dist/tool-calls/reporters/read.d.ts +7 -0
- package/dist/tool-calls/reporters/read.d.ts.map +1 -0
- package/dist/tool-calls/reporters/read.js +68 -0
- package/dist/tool-calls/reporters/search.d.ts +16 -0
- package/dist/tool-calls/reporters/search.d.ts.map +1 -0
- package/dist/tool-calls/reporters/search.js +82 -0
- package/dist/tool-calls/reporters/web.d.ts +11 -0
- package/dist/tool-calls/reporters/web.d.ts.map +1 -0
- package/dist/tool-calls/reporters/web.js +44 -0
- package/dist/tool-result-meta.d.ts +15 -0
- package/dist/tool-result-meta.d.ts.map +1 -0
- package/dist/tool-result-meta.js +28 -0
- package/dist/tools.d.ts +93 -0
- package/dist/tools.d.ts.map +1 -0
- package/dist/tools.js +350 -0
- package/dist/turn-events.d.ts +97 -0
- package/dist/turn-events.d.ts.map +1 -0
- package/dist/turn-events.js +1 -0
- package/dist/usage-markdown.d.ts +9 -0
- package/dist/usage-markdown.d.ts.map +1 -0
- package/dist/usage-markdown.js +173 -0
- package/dist/utils.d.ts +59 -0
- package/dist/utils.d.ts.map +1 -0
- package/dist/utils.js +167 -0
- package/dist/v2/agent.d.ts +13 -0
- package/dist/v2/agent.d.ts.map +1 -0
- package/dist/v2/agent.js +336 -0
- package/dist/v2/initialize.d.ts +21 -0
- package/dist/v2/initialize.d.ts.map +1 -0
- package/dist/v2/initialize.js +117 -0
- package/dist/v2/permission.d.ts +25 -0
- package/dist/v2/permission.d.ts.map +1 -0
- package/dist/v2/permission.js +38 -0
- package/dist/v2/prompt.d.ts +58 -0
- package/dist/v2/prompt.d.ts.map +1 -0
- package/dist/v2/prompt.js +172 -0
- package/dist/v2/session-update.d.ts +32 -0
- package/dist/v2/session-update.d.ts.map +1 -0
- package/dist/v2/session-update.js +123 -0
- package/dist/v2/session.d.ts +42 -0
- package/dist/v2/session.d.ts.map +1 -0
- package/dist/v2/session.js +140 -0
- package/dist/v2/terminal.d.ts +42 -0
- package/dist/v2/terminal.d.ts.map +1 -0
- package/dist/v2/terminal.js +94 -0
- package/dist/v2/tool-call-meta.d.ts +55 -0
- package/dist/v2/tool-call-meta.d.ts.map +1 -0
- package/dist/v2/tool-call-meta.js +104 -0
- package/dist/v2/tool-call.d.ts +49 -0
- package/dist/v2/tool-call.d.ts.map +1 -0
- package/dist/v2/tool-call.js +75 -0
- package/package.json +87 -4
package/LICENSE
ADDED
|
@@ -0,0 +1,191 @@
|
|
|
1
|
+
|
|
2
|
+
Apache License
|
|
3
|
+
Version 2.0, January 2004
|
|
4
|
+
http://www.apache.org/licenses/
|
|
5
|
+
|
|
6
|
+
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
|
7
|
+
|
|
8
|
+
1. Definitions.
|
|
9
|
+
|
|
10
|
+
"License" shall mean the terms and conditions for use, reproduction,
|
|
11
|
+
and distribution as defined by Sections 1 through 9 of this document.
|
|
12
|
+
|
|
13
|
+
"Licensor" shall mean the copyright owner or entity authorized by
|
|
14
|
+
the copyright owner that is granting the License.
|
|
15
|
+
|
|
16
|
+
"Legal Entity" shall mean the union of the acting entity and all
|
|
17
|
+
other entities that control, are controlled by, or are under common
|
|
18
|
+
control with that entity. For the purposes of this definition,
|
|
19
|
+
"control" means (i) the power, direct or indirect, to cause the
|
|
20
|
+
direction or management of such entity, whether by contract or
|
|
21
|
+
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
|
22
|
+
outstanding shares, or (iii) beneficial ownership of such entity.
|
|
23
|
+
|
|
24
|
+
"You" (or "Your") shall mean an individual or Legal Entity
|
|
25
|
+
exercising permissions granted by this License.
|
|
26
|
+
|
|
27
|
+
"Source" form shall mean the preferred form for making modifications,
|
|
28
|
+
including but not limited to software source code, documentation
|
|
29
|
+
source, and configuration files.
|
|
30
|
+
|
|
31
|
+
"Object" form shall mean any form resulting from mechanical
|
|
32
|
+
transformation or translation of a Source form, including but
|
|
33
|
+
not limited to compiled object code, generated documentation,
|
|
34
|
+
and conversions to other media types.
|
|
35
|
+
|
|
36
|
+
"Work" shall mean the work of authorship, whether in Source or
|
|
37
|
+
Object form, made available under the License, as indicated by a
|
|
38
|
+
copyright notice that is included in or attached to the work
|
|
39
|
+
(an example is provided in the Appendix below).
|
|
40
|
+
|
|
41
|
+
"Derivative Works" shall mean any work, whether in Source or Object
|
|
42
|
+
form, that is based on (or derived from) the Work and for which the
|
|
43
|
+
editorial revisions, annotations, elaborations, or other modifications
|
|
44
|
+
represent, as a whole, an original work of authorship. For the purposes
|
|
45
|
+
of this License, Derivative Works shall not include works that remain
|
|
46
|
+
separable from, or merely link (or bind by name) to the interfaces of,
|
|
47
|
+
the Work and Derivative Works thereof.
|
|
48
|
+
|
|
49
|
+
"Contribution" shall mean any work of authorship, including
|
|
50
|
+
the original version of the Work and any modifications or additions
|
|
51
|
+
to that Work or Derivative Works thereof, that is intentionally
|
|
52
|
+
submitted to Licensor for inclusion in the Work by the copyright owner
|
|
53
|
+
or by an individual or Legal Entity authorized to submit on behalf of
|
|
54
|
+
the copyright owner. For the purposes of this definition, "submitted"
|
|
55
|
+
means any form of electronic, verbal, or written communication sent
|
|
56
|
+
to the Licensor or its representatives, including but not limited to
|
|
57
|
+
communication on electronic mailing lists, source code control systems,
|
|
58
|
+
and issue tracking systems that are managed by, or on behalf of, the
|
|
59
|
+
Licensor for the purpose of discussing and improving the Work, but
|
|
60
|
+
excluding communication that is conspicuously marked or otherwise
|
|
61
|
+
designated in writing by the copyright owner as "Not a Contribution."
|
|
62
|
+
|
|
63
|
+
"Contributor" shall mean Licensor and any individual or Legal Entity
|
|
64
|
+
on behalf of whom a Contribution has been received by Licensor and
|
|
65
|
+
subsequently incorporated within the Work.
|
|
66
|
+
|
|
67
|
+
2. Grant of Copyright License. Subject to the terms and conditions of
|
|
68
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
69
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
70
|
+
copyright license to reproduce, prepare Derivative Works of,
|
|
71
|
+
publicly display, publicly perform, sublicense, and distribute the
|
|
72
|
+
Work and such Derivative Works in Source or Object form.
|
|
73
|
+
|
|
74
|
+
3. Grant of Patent License. Subject to the terms and conditions of
|
|
75
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
76
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
77
|
+
(except as stated in this section) patent license to make, have made,
|
|
78
|
+
use, offer to sell, sell, import, and otherwise transfer the Work,
|
|
79
|
+
where such license applies only to those patent claims licensable
|
|
80
|
+
by such Contributor that are necessarily infringed by their
|
|
81
|
+
Contribution(s) alone or by combination of their Contribution(s)
|
|
82
|
+
with the Work to which such Contribution(s) was submitted. If You
|
|
83
|
+
institute patent litigation against any entity (including a
|
|
84
|
+
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
|
85
|
+
or a Contribution incorporated within the Work constitutes direct
|
|
86
|
+
or contributory patent infringement, then any patent licenses
|
|
87
|
+
granted to You under this License for that Work shall terminate
|
|
88
|
+
as of the date such litigation is filed.
|
|
89
|
+
|
|
90
|
+
4. Redistribution. You may reproduce and distribute copies of the
|
|
91
|
+
Work or Derivative Works thereof in any medium, with or without
|
|
92
|
+
modifications, and in Source or Object form, provided that You
|
|
93
|
+
meet the following conditions:
|
|
94
|
+
|
|
95
|
+
(a) You must give any other recipients of the Work or
|
|
96
|
+
Derivative Works a copy of this License; and
|
|
97
|
+
|
|
98
|
+
(b) You must cause any modified files to carry prominent notices
|
|
99
|
+
stating that You changed the files; and
|
|
100
|
+
|
|
101
|
+
(c) You must retain, in the Source form of any Derivative Works
|
|
102
|
+
that You distribute, all copyright, patent, trademark, and
|
|
103
|
+
attribution notices from the Source form of the Work,
|
|
104
|
+
excluding those notices that do not pertain to any part of
|
|
105
|
+
the Derivative Works; and
|
|
106
|
+
|
|
107
|
+
(d) If the Work includes a "NOTICE" text file as part of its
|
|
108
|
+
distribution, then any Derivative Works that You distribute must
|
|
109
|
+
include a readable copy of the attribution notices contained
|
|
110
|
+
within such NOTICE file, excluding those notices that do not
|
|
111
|
+
pertain to any part of the Derivative Works, in at least one
|
|
112
|
+
of the following places: within a NOTICE text file distributed
|
|
113
|
+
as part of the Derivative Works; within the Source form or
|
|
114
|
+
documentation, if provided along with the Derivative Works; or,
|
|
115
|
+
within a display generated by the Derivative Works, if and
|
|
116
|
+
wherever such third-party notices normally appear. The contents
|
|
117
|
+
of the NOTICE file are for informational purposes only and
|
|
118
|
+
do not modify the License. You may add Your own attribution
|
|
119
|
+
notices within Derivative Works that You distribute, alongside
|
|
120
|
+
or as an addendum to the NOTICE text from the Work, provided
|
|
121
|
+
that such additional attribution notices cannot be construed
|
|
122
|
+
as modifying the License.
|
|
123
|
+
|
|
124
|
+
You may add Your own copyright statement to Your modifications and
|
|
125
|
+
may provide additional or different license terms and conditions
|
|
126
|
+
for use, reproduction, or distribution of Your modifications, or
|
|
127
|
+
for any such Derivative Works as a whole, provided Your use,
|
|
128
|
+
reproduction, and distribution of the Work otherwise complies with
|
|
129
|
+
the conditions stated in this License.
|
|
130
|
+
|
|
131
|
+
5. Submission of Contributions. Unless You explicitly state otherwise,
|
|
132
|
+
any Contribution intentionally submitted for inclusion in the Work
|
|
133
|
+
by You to the Licensor shall be under the terms and conditions of
|
|
134
|
+
this License, without any additional terms or conditions.
|
|
135
|
+
Notwithstanding the above, nothing herein shall supersede or modify
|
|
136
|
+
the terms of any separate license agreement you may have executed
|
|
137
|
+
with Licensor regarding such Contributions.
|
|
138
|
+
|
|
139
|
+
6. Trademarks. This License does not grant permission to use the trade
|
|
140
|
+
names, trademarks, service marks, or product names of the Licensor,
|
|
141
|
+
except as required for reasonable and customary use in describing the
|
|
142
|
+
origin of the Work and reproducing the content of the NOTICE file.
|
|
143
|
+
|
|
144
|
+
7. Disclaimer of Warranty. Unless required by applicable law or
|
|
145
|
+
agreed to in writing, Licensor provides the Work (and each
|
|
146
|
+
Contributor provides its Contributions) on an "AS IS" BASIS,
|
|
147
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
|
148
|
+
implied, including, without limitation, any warranties or conditions
|
|
149
|
+
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
|
150
|
+
PARTICULAR PURPOSE. You are solely responsible for determining the
|
|
151
|
+
appropriateness of using or redistributing the Work and assume any
|
|
152
|
+
risks associated with Your exercise of permissions under this License.
|
|
153
|
+
|
|
154
|
+
8. Limitation of Liability. In no event and under no legal theory,
|
|
155
|
+
whether in tort (including negligence), contract, or otherwise,
|
|
156
|
+
unless required by applicable law (such as deliberate and grossly
|
|
157
|
+
negligent acts) or agreed to in writing, shall any Contributor be
|
|
158
|
+
liable to You for damages, including any direct, indirect, special,
|
|
159
|
+
incidental, or consequential damages of any character arising as a
|
|
160
|
+
result of this License or out of the use or inability to use the
|
|
161
|
+
Work (including but not limited to damages for loss of goodwill,
|
|
162
|
+
work stoppage, computer failure or malfunction, or any and all
|
|
163
|
+
other commercial damages or losses), even if such Contributor
|
|
164
|
+
has been advised of the possibility of such damages.
|
|
165
|
+
|
|
166
|
+
9. Accepting Warranty or Additional Liability. While redistributing
|
|
167
|
+
the Work or Derivative Works thereof, You may choose to offer,
|
|
168
|
+
and charge a fee for, acceptance of support, warranty, indemnity,
|
|
169
|
+
or other liability obligations and/or rights consistent with this
|
|
170
|
+
License. However, in accepting such obligations, You may act only
|
|
171
|
+
on Your own behalf and on Your sole responsibility, not on behalf
|
|
172
|
+
of any other Contributor, and only if You agree to indemnify,
|
|
173
|
+
defend, and hold each Contributor harmless for any liability
|
|
174
|
+
incurred by, or claims asserted against, such Contributor by reason
|
|
175
|
+
of your accepting any such warranty or additional liability.
|
|
176
|
+
|
|
177
|
+
END OF TERMS AND CONDITIONS
|
|
178
|
+
|
|
179
|
+
Copyright 2025 Zed Industries, Inc. and contributors
|
|
180
|
+
|
|
181
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
|
182
|
+
you may not use this file except in compliance with the License.
|
|
183
|
+
You may obtain a copy of the License at
|
|
184
|
+
|
|
185
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
|
186
|
+
|
|
187
|
+
Unless required by applicable law or agreed to in writing, software
|
|
188
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
|
189
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
190
|
+
See the License for the specific language governing permissions and
|
|
191
|
+
limitations under the License.
|
package/README.md
CHANGED
|
@@ -1,3 +1,126 @@
|
|
|
1
|
-
#
|
|
1
|
+
# ACP adapter for the Claude Agent SDK
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
[](https://www.npmjs.com/package/@agentclientprotocol/claude-agent-acp)
|
|
4
|
+
|
|
5
|
+
Use [Claude Agent SDK](https://platform.claude.com/docs/en/agent-sdk/overview#branding-guidelines) from [ACP-compatible](https://agentclientprotocol.com) clients!
|
|
6
|
+
|
|
7
|
+
This tool implements an ACP agent by using the official [Claude Agent SDK](https://platform.claude.com/docs/en/agent-sdk/overview), supporting:
|
|
8
|
+
|
|
9
|
+
- Context @-mentions
|
|
10
|
+
- Images
|
|
11
|
+
- Tool calls (with permission requests)
|
|
12
|
+
- Compact file changes through the negotiated [AIR diff patch extension](docs/air-extensions.md#diff-patch)
|
|
13
|
+
- Following
|
|
14
|
+
- Edit review
|
|
15
|
+
- TODO lists
|
|
16
|
+
- Nested subagent transcripts
|
|
17
|
+
- Interactive (and background) terminals
|
|
18
|
+
- Custom [Slash commands](https://docs.anthropic.com/en/docs/claude-code/slash-commands)
|
|
19
|
+
- Client MCP servers
|
|
20
|
+
- An Ultracode session config option, which turns on Claude Code's dynamic workflows for every task. It appears when dynamic workflows are enabled and the model supports ultracode (any model with `xhigh` effort)
|
|
21
|
+
- `/mcp` in the chat: the MCP server status as a list. The adapter runs `/mcp reconnect`, `/mcp enable`, and `/mcp disable` through the SDK control API, because Claude Code refuses them in SDK mode. A reconnect of an ACP server that needs authentication starts MCP OAuth through URL elicitation
|
|
22
|
+
- Session-scoped long-running goals for AIR through the [goal extension](docs/air-extensions.md#goal) under `_meta.jetbrains.air.goal`
|
|
23
|
+
- Structured errors, recovery, and warnings through the opt-in [session failure extension](docs/air-extensions.md#session-failure)
|
|
24
|
+
- Concrete model and effort defaults through the opt-in [recommended config value extension](docs/air-extensions.md#recommended-config-values)
|
|
25
|
+
- Tool permission presentation, editable choices, and durable effects through the [permission extension](docs/air-extensions.md#permission-presentation)
|
|
26
|
+
- One fact per field in every tool call report, as the [ACP tool call contract](docs/air-extensions.md#tool-call-contract) defines
|
|
27
|
+
- All AIR extensions, capabilities, and `_meta` keys: [AIR extensions](docs/air-extensions.md)
|
|
28
|
+
|
|
29
|
+
Learn more about the [Agent Client Protocol](https://agentclientprotocol.com/).
|
|
30
|
+
|
|
31
|
+
To try changes that have landed on `main` but are not released yet, install from the
|
|
32
|
+
`preview` channel — every push to `main` publishes one. See
|
|
33
|
+
[`docs/RELEASES.md`](docs/RELEASES.md#preview-releases).
|
|
34
|
+
|
|
35
|
+
```sh
|
|
36
|
+
npm install @agentclientprotocol/claude-agent-acp@preview
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
### Subagent sessions
|
|
40
|
+
|
|
41
|
+
A client that declares `clientCapabilities.subagents`, other than JetBrains AIR, gets each Agent or
|
|
42
|
+
Task subagent as its own child session, following the [subagents RFD](https://github.com/agentclientprotocol/agent-client-protocol/blob/main/docs/rfds/subagents.mdx):
|
|
43
|
+
|
|
44
|
+
- `subagent_update` on the parent announces the child before any of its traffic, with the
|
|
45
|
+
parent's `title` and `description` for it, and reports its work state: `running`,
|
|
46
|
+
`requires_action` while one of its requests is open (and `running` again when the last one ends,
|
|
47
|
+
unless a cancel withdrew it: the child is stopping then), and `idle` when its work ends, with
|
|
48
|
+
`end_turn` or `cancelled` when the SDK gives the reason. A failure is `idle` with the `error`
|
|
49
|
+
stop reason and the SDK's error text as its `error`. The child keeps its session for every
|
|
50
|
+
delegation to it.
|
|
51
|
+
- Session messages replace the Agent or Task call that launches the child, which its parent is
|
|
52
|
+
not shown:
|
|
53
|
+
- The launch's prompt is a `session_message` in both transcripts: the parent's outgoing view and
|
|
54
|
+
the child's incoming one. Both use the launch's tool use id, and each names the other with the
|
|
55
|
+
draft RFD's `recipientMessageId` and `senderMessageId`.
|
|
56
|
+
- A foreground child's answer, from the launch's result, is the child's `session_message` to
|
|
57
|
+
the parent. In Claude Code's hand-back mode, the child's `SubagentHandback` call is its
|
|
58
|
+
message to the parent instead, in both transcripts and linked the same way.
|
|
59
|
+
- A launch whose child is never exposed is shown as a tool call after all, with its final
|
|
60
|
+
status.
|
|
61
|
+
- The message of a SendMessage call that resumes the child is a `session_message` in the child's
|
|
62
|
+
transcript. The SendMessage call stays a tool call of the session that made it.
|
|
63
|
+
- `session/cancel` on the parent interrupts Claude Code, which stops the foreground children that
|
|
64
|
+
the turn waits on. Background children keep running, as the RFD prefers; a client stops one with
|
|
65
|
+
its own `cancel`. Each stopped child reports `idle` with `cancelled` from Claude Code's own
|
|
66
|
+
events, and its open requests are withdrawn. The adapter ends no child at a cancel itself, so a
|
|
67
|
+
child that keeps running keeps its open requests and its open tool calls. To spare background
|
|
68
|
+
children, the adapter declares the SDK option `perTaskStopAffordance`, which a client can turn
|
|
69
|
+
off in `_meta.claudeCode.options`. That option spares background workflows too, which a client
|
|
70
|
+
cannot stop, so the adapter stops them after the interrupt, as Claude Code did without it.
|
|
71
|
+
Background commands keep running after a cancel either way. A tool call of a stopped child that Claude Code reports no
|
|
72
|
+
result for, such as the command it was running, ends in the child's session before the cancelled
|
|
73
|
+
prompt resolves. When Claude Code stops a background child after that, or while no prompt runs,
|
|
74
|
+
the tool call ends right after the child reports `idle`. A child that still runs when Claude Code
|
|
75
|
+
exits is `idle` with no stop reason.
|
|
76
|
+
- A child whose parent is not yet known when it ends is not exposed, since the RFD forbids
|
|
77
|
+
guessing its parent.
|
|
78
|
+
- A replay restores each child under its live session id, from its own transcript, with the same
|
|
79
|
+
session messages as live, and its end is an `idle` before the response.
|
|
80
|
+
A launch without Claude Code's metadata file for the child stays an ordinary tool call of the
|
|
81
|
+
parent, and a notice, for a client that takes notices, says that subagent history is missing.
|
|
82
|
+
- After a load or resume, with or without replay, a SendMessage that resumes an agent from before
|
|
83
|
+
it runs that agent in its session from before. Before the agent's traffic, each of its ancestors
|
|
84
|
+
that the client was not told about in this connection is announced, parent before child and
|
|
85
|
+
with no work state, as the RFD requires. An agent whose launch the session's history does not
|
|
86
|
+
record stays unexposed.
|
|
87
|
+
- Each running child is announced with the `cancel` capability. `session/cancel` with the child's
|
|
88
|
+
session id stops that child's current work, through the SDK's `Query.stopTask`, and not its
|
|
89
|
+
parent's: Claude Code also stops the foreground children it waits on, and the parent's turn goes
|
|
90
|
+
on. Each stopped child reports `idle` with `cancelled` from Claude Code's own events, and its
|
|
91
|
+
requests that the stop withdraws report no `running` first. A replayed child, which no longer
|
|
92
|
+
runs, gets no capabilities. A client cannot prompt or otherwise change a child.
|
|
93
|
+
|
|
94
|
+
An [ACP v2](#experimental-acp-v2) client gets the same without declaring anything, since subagents
|
|
95
|
+
are part of v2's baseline. Each child also reports its work state as its own `state_update`, right
|
|
96
|
+
after the parent's copy.
|
|
97
|
+
|
|
98
|
+
JetBrains AIR keeps the earlier draft of the RFD (`subagent_spawned`, `subagent_state_update`),
|
|
99
|
+
which it enables with `nativeSubagentSessions` in `_meta.jetbrains.air.capabilities`. See
|
|
100
|
+
[AIR extensions](docs/air-extensions.md#native-subagent-sessions).
|
|
101
|
+
|
|
102
|
+
Without either signal, Agent and Task stay ordinary tool calls and child interactions stay on the
|
|
103
|
+
root session. Clients that use the historical `_meta["subagent-transcript"]` capability or the
|
|
104
|
+
`forwardSubagentText` session option retain the flattened child transcript.
|
|
105
|
+
|
|
106
|
+
### Experimental ACP v2
|
|
107
|
+
|
|
108
|
+
The adapter also serves the [draft ACP v2](https://agentclientprotocol.com/protocol/v2/overview):
|
|
109
|
+
a client that asks for protocol version 2 or later in `initialize` gets v2, and every other client
|
|
110
|
+
gets v1. The draft can still change, and this surface changes with it.
|
|
111
|
+
|
|
112
|
+
`CLAUDE_AGENT_ACP_PROTOCOL` limits the adapter to one version. With `v1`, a client that asks
|
|
113
|
+
for v2 is negotiated down to v1. With `v2`, the adapter rejects the `initialize` of a v1 client.
|
|
114
|
+
`auto`, the default, serves both.
|
|
115
|
+
|
|
116
|
+
On v2 the adapter serves the session baseline (`session/new`, `session/list`, `session/resume`
|
|
117
|
+
with replay, `session/close`, `session/prompt`, `session/cancel`), `session/delete`,
|
|
118
|
+
`session/fork`, additional directories, config options (the mode is one), plans, notices,
|
|
119
|
+
compaction, display terminals for commands, permission requests, elicitation, providers, auth, and
|
|
120
|
+
[subagents](#subagent-sessions). Steering and the AIR extensions are v1 only for now.
|
|
121
|
+
|
|
122
|
+
## Contribution Policy
|
|
123
|
+
|
|
124
|
+
This project does not require a Contributor License Agreement (CLA). Instead, contributions are accepted under the following terms:
|
|
125
|
+
|
|
126
|
+
> By contributing to this project, you agree that your contributions will be licensed under the [Apache License, Version 2.0](https://www.apache.org/licenses/LICENSE-2.0). You affirm that you have the legal right to submit your work, that you are not including code you do not have rights to, and that you understand contributions are made without requiring a Contributor License Agreement (CLA).
|