@tencent-ai/agent-sdk 0.1.0-next.989 → 0.1.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.
Files changed (91) hide show
  1. package/README.md +73 -2
  2. package/cli/CHANGELOG.md +2418 -0
  3. package/cli/LICENSE.txt +19 -0
  4. package/cli/README.md +26 -0
  5. package/cli/bin/codebuddy +39 -0
  6. package/cli/dist/codebuddy.js +20 -0
  7. package/cli/package.json +44 -0
  8. package/cli/product.cloudhosted.json +242 -0
  9. package/cli/product.internal.json +244 -0
  10. package/cli/product.ioa.json +467 -0
  11. package/cli/product.json +948 -0
  12. package/cli/product.selfhosted.json +196 -0
  13. package/cli/vendor/ripgrep/COPYING +3 -0
  14. package/cli/vendor/ripgrep/arm64-darwin/rg +0 -0
  15. package/cli/vendor/ripgrep/arm64-darwin/ripgrep.node +0 -0
  16. package/cli/vendor/ripgrep/arm64-linux/rg +0 -0
  17. package/cli/vendor/ripgrep/arm64-linux/ripgrep.node +0 -0
  18. package/cli/vendor/ripgrep/x64-darwin/rg +0 -0
  19. package/cli/vendor/ripgrep/x64-darwin/ripgrep.node +0 -0
  20. package/cli/vendor/ripgrep/x64-linux/rg +0 -0
  21. package/cli/vendor/ripgrep/x64-linux/ripgrep.node +0 -0
  22. package/cli/vendor/ripgrep/x64-win32/rg.exe +0 -0
  23. package/cli/vendor/ripgrep/x64-win32/ripgrep.node +0 -0
  24. package/lib/errors.d.ts +10 -0
  25. package/lib/errors.d.ts.map +1 -0
  26. package/lib/errors.js +17 -0
  27. package/lib/errors.js.map +1 -0
  28. package/lib/index.d.ts +36 -0
  29. package/lib/index.d.ts.map +1 -0
  30. package/lib/index.js +40 -0
  31. package/lib/index.js.map +1 -0
  32. package/lib/package.spec.js +3 -2
  33. package/lib/package.spec.js.map +1 -1
  34. package/lib/query.d.ts +46 -0
  35. package/lib/query.d.ts.map +1 -0
  36. package/lib/query.js +270 -0
  37. package/lib/query.js.map +1 -0
  38. package/lib/session.d.ts +53 -0
  39. package/lib/session.d.ts.map +1 -0
  40. package/lib/session.js +163 -0
  41. package/lib/session.js.map +1 -0
  42. package/lib/transport/index.d.ts +104 -0
  43. package/lib/transport/index.d.ts.map +1 -0
  44. package/lib/transport/index.js +20 -0
  45. package/lib/transport/index.js.map +1 -0
  46. package/lib/transport/process-transport.d.ts +65 -0
  47. package/lib/transport/process-transport.d.ts.map +1 -0
  48. package/lib/transport/process-transport.js +380 -0
  49. package/lib/transport/process-transport.js.map +1 -0
  50. package/lib/types.d.ts +603 -0
  51. package/lib/types.d.ts.map +1 -0
  52. package/lib/types.js +58 -0
  53. package/lib/types.js.map +1 -0
  54. package/lib/utils/cli-resolver.d.ts +36 -0
  55. package/lib/utils/cli-resolver.d.ts.map +1 -0
  56. package/lib/utils/cli-resolver.js +123 -0
  57. package/lib/utils/cli-resolver.js.map +1 -0
  58. package/lib/utils/env-utils.d.ts +9 -0
  59. package/lib/utils/env-utils.d.ts.map +1 -0
  60. package/lib/utils/env-utils.js +19 -0
  61. package/lib/utils/env-utils.js.map +1 -0
  62. package/lib/utils/index.d.ts +8 -0
  63. package/lib/utils/index.d.ts.map +1 -0
  64. package/lib/utils/index.js +17 -0
  65. package/lib/utils/index.js.map +1 -0
  66. package/lib/utils/process.d.ts +8 -0
  67. package/lib/utils/process.d.ts.map +1 -0
  68. package/lib/utils/process.js +16 -0
  69. package/lib/utils/process.js.map +1 -0
  70. package/lib/utils/stream.d.ts +24 -0
  71. package/lib/utils/stream.d.ts.map +1 -0
  72. package/lib/utils/stream.js +85 -0
  73. package/lib/utils/stream.js.map +1 -0
  74. package/package.json +21 -14
  75. package/dist/agent-sdk.js +0 -1
  76. package/lib/common/application-utils.d.ts +0 -5
  77. package/lib/common/application-utils.d.ts.map +0 -1
  78. package/lib/common/application-utils.js +0 -18
  79. package/lib/common/application-utils.js.map +0 -1
  80. package/lib/common/component-registry.d.ts +0 -10
  81. package/lib/common/component-registry.d.ts.map +0 -1
  82. package/lib/common/component-registry.js +0 -50
  83. package/lib/common/component-registry.js.map +0 -1
  84. package/lib/common/index.d.ts +0 -4
  85. package/lib/common/index.d.ts.map +0 -1
  86. package/lib/common/index.js +0 -20
  87. package/lib/common/index.js.map +0 -1
  88. package/lib/common/services.d.ts +0 -8
  89. package/lib/common/services.d.ts.map +0 -1
  90. package/lib/common/services.js +0 -21
  91. package/lib/common/services.js.map +0 -1
@@ -0,0 +1,44 @@
1
+ {
2
+ "name": "@tencent-ai/codebuddy-code",
3
+ "version": "2.22.0",
4
+ "description": "Use CodeBuddy, Tencent's AI assistant, right from your terminal. CodeBuddy can understand your codebase, edit files, run terminal commands, and handle entire workflows for you.",
5
+ "main": "lib/node/index.js",
6
+ "typings": "lib/node/index.d.ts",
7
+ "license": "SEE LICENSE IN README.md",
8
+ "bin": {
9
+ "codebuddy": "./bin/codebuddy",
10
+ "cbc": "./bin/codebuddy"
11
+ },
12
+ "dependencies": {},
13
+ "keywords": [
14
+ "codebuddy",
15
+ "ai-assistant",
16
+ "terminal",
17
+ "cli"
18
+ ],
19
+ "files": [
20
+ "dist",
21
+ "bin",
22
+ "vendor",
23
+ "CHANGELOG.md",
24
+ "product.json",
25
+ "product.*.json"
26
+ ],
27
+ "homepage": "https://cnb.cool/codebuddy/codebuddy-code",
28
+ "bugs": {
29
+ "url": "https://cnb.cool/codebuddy/codebuddy-code/-/issues"
30
+ },
31
+ "publishConfig": {
32
+ "access": "public"
33
+ },
34
+ "scripts": {},
35
+ "devDependencies": {},
36
+ "optionalDependencies": {
37
+ "@lydell/node-pty": "1.1.0",
38
+ "@lydell/node-pty-darwin-arm64": "1.1.0",
39
+ "@lydell/node-pty-darwin-x64": "1.1.0",
40
+ "@lydell/node-pty-linux-x64": "1.1.0",
41
+ "@lydell/node-pty-win32-arm64": "1.1.0",
42
+ "@lydell/node-pty-win32-x64": "1.1.0"
43
+ }
44
+ }
@@ -0,0 +1,242 @@
1
+ {
2
+ "agents": [
3
+ {
4
+ "name": "cli",
5
+ "instructions": "cli-agent-prompt",
6
+ "description": "cli agent",
7
+ "models": [
8
+ "glm-4.6",
9
+ "deepseek-v3.1",
10
+ "deepseek-v3-0324"
11
+ ],
12
+ "commands": [
13
+ "init",
14
+ "compact",
15
+ "statusline"
16
+ ],
17
+ "tools": [
18
+ "Task",
19
+ "Read",
20
+ "Write",
21
+ "Edit",
22
+ "MultiEdit",
23
+ "Bash",
24
+ "Glob",
25
+ "Grep",
26
+ "ExitPlanMode",
27
+ "TodoWrite",
28
+ "WebFetch",
29
+ "WebSearch",
30
+ "NotebookEdit",
31
+ "BashOutput",
32
+ "KillShell",
33
+ "SlashCommand",
34
+ "Skill",
35
+ "AskUserQuestion"
36
+ ],
37
+ "tags": [
38
+ "cli",
39
+ "default"
40
+ ]
41
+ },
42
+ {
43
+ "name": "general-purpose",
44
+ "instructions": "cli-agent-prompt",
45
+ "description": "taskgeneral-purpose agent",
46
+ "tools": [
47
+ "Read",
48
+ "Write",
49
+ "Edit",
50
+ "MultiEdit",
51
+ "Bash",
52
+ "Glob",
53
+ "Grep",
54
+ "TodoWrite",
55
+ "WebFetch",
56
+ "WebSearch",
57
+ "NotebookEdit",
58
+ "BashOutput",
59
+ "KillShell",
60
+ "SlashCommand",
61
+ "Skill",
62
+ "AskUserQuestion"
63
+ ],
64
+ "tags": [
65
+ "cli",
66
+ "general-purpose"
67
+ ]
68
+ },
69
+ {
70
+ "name": "compact",
71
+ "instructions": "compact-agent-prompt",
72
+ "description": "compact agent",
73
+ "tools": [
74
+ "Read"
75
+ ],
76
+ "tags": [
77
+ "cli",
78
+ "compact"
79
+ ]
80
+ },
81
+ {
82
+ "name": "contentAnalyzer",
83
+ "instructions": "content-analyzer-agent-instructions",
84
+ "description": "content analyzer agent",
85
+ "tags": [
86
+ "cli",
87
+ "content-analyzer"
88
+ ]
89
+ },
90
+ {
91
+ "name": "terminalTitleGenerator",
92
+ "instructions": "terminal-title-generator-instructions",
93
+ "description": "Generate terminal window titles from conversation topics.",
94
+ "tags": [
95
+ "cli",
96
+ "terminal-title-generator"
97
+ ]
98
+ },
99
+ {
100
+ "name": "agentInstructions",
101
+ "instructions": "agent-instructions",
102
+ "description": "generating agent instructions",
103
+ "tags": [
104
+ "cli",
105
+ "agent-instructions"
106
+ ]
107
+ },
108
+ {
109
+ "name": "statusline-setup",
110
+ "instructions": "agent-statusline-instructions",
111
+ "description": "Use this agent to configure the user's Codebuddy Code status line setting.",
112
+ "tools": [
113
+ "Read",
114
+ "Write",
115
+ "Edit"
116
+ ],
117
+ "asTool": true,
118
+ "tags": [
119
+ "cli",
120
+ "sub-agent"
121
+ ]
122
+ },
123
+ {
124
+ "name": "Explore",
125
+ "instructions": "agent-explore-instructions",
126
+ "description": "Fast agent specialized for exploring codebases. Use this when you need to quickly find files by patterns (eg. \"src/components/**/*.tsx\"), search code for keywords (eg. \"API endpoints\"), or answer questions about the codebase (eg. \"how do API endpoints work?\"). When calling this agent, specify the desired thoroughness level: \"quick\" for basic searches, \"medium\" for moderate exploration, or \"very thorough\" for comprehensive analysis across multiple locations and naming conventions.",
127
+ "tools": [
128
+ "Read",
129
+ "Bash",
130
+ "Glob",
131
+ "Grep",
132
+ "WebFetch",
133
+ "WebSearch",
134
+ "BashOutput",
135
+ "KillShell",
136
+ "SlashCommand",
137
+ "Skill",
138
+ "AskUserQuestion"
139
+ ],
140
+ "asTool": true,
141
+ "tags": [
142
+ "cli",
143
+ "sub-agent"
144
+ ]
145
+ },
146
+ {
147
+ "name": "Plan",
148
+ "instructions": "agent-plan-instructions",
149
+ "description": "Fast agent specialized for exploring codebases. Use this when you need to quickly find files by patterns (eg. \"src/components/**/*.tsx\"), search code for keywords (eg. \"API endpoints\"), or answer questions about the codebase (eg. \"how do API endpoints work?\"). When calling this agent, specify the desired thoroughness level: \"quick\" for basic searches, \"medium\" for moderate exploration, or \"very thorough\" for comprehensive analysis across multiple locations and naming conventions. (Tools: All tools)",
150
+ "tools": [
151
+ "Read",
152
+ "Bash",
153
+ "Glob",
154
+ "Grep",
155
+ "TodoWrite",
156
+ "WebFetch",
157
+ "WebSearch",
158
+ "BashOutput",
159
+ "KillShell",
160
+ "SlashCommand",
161
+ "Skill",
162
+ "AskUserQuestion"
163
+ ],
164
+ "asTool": true,
165
+ "tags": [
166
+ "cli",
167
+ "sub-agent"
168
+ ]
169
+ }
170
+ ],
171
+ "models": [
172
+ {
173
+ "id": "default",
174
+ "credits": "x2.20 credits",
175
+ "name": "Default",
176
+ "vendor": "v",
177
+ "maxOutputTokens": 24000,
178
+ "maxInputTokens": 200000,
179
+ "supportsToolCall": true,
180
+ "supportsImages": false,
181
+ "maxAllowedSize": 56000
182
+ },
183
+ {
184
+ "credits": "x0.20 credits",
185
+ "id": "glm-4.6",
186
+ "name": "GLM-4.6",
187
+ "vendor": "f",
188
+ "maxOutputTokens": 32000,
189
+ "maxInputTokens": 168000,
190
+ "supportsToolCall": true,
191
+ "supportsImages": false,
192
+ "disabledMultimodal": true,
193
+ "maxAllowedSize": 168000,
194
+ "supportsReasoning": true,
195
+ "temperature": 1
196
+ },
197
+ {
198
+ "credits": "x0.43 credits",
199
+ "id": "deepseek-v3.1",
200
+ "name": "DeepSeek-V3.1-Terminus",
201
+ "vendor": "f",
202
+ "maxOutputTokens": 8192,
203
+ "maxInputTokens": 128000,
204
+ "supportsToolCall": true,
205
+ "supportsImages": false,
206
+ "disabledMultimodal": true,
207
+ "maxAllowedSize": 56000
208
+ },
209
+ {
210
+ "id": "hunyuan-chat",
211
+ "name": "Hunyuan-Turbos",
212
+ "vendor": "j",
213
+ "maxOutputTokens": 8192,
214
+ "maxInputTokens": 200000,
215
+ "supportsToolCall": true,
216
+ "supportsImages": false,
217
+ "disabledMultimodal": true
218
+ },
219
+ {
220
+ "credits": "x0.57 credits",
221
+ "id": "deepseek-v3-0324",
222
+ "name": "DeepSeek-V3",
223
+ "vendor": "tencent",
224
+ "maxOutputTokens": 8192,
225
+ "maxInputTokens": 128000,
226
+ "supportsToolCall": true,
227
+ "supportsImages": false,
228
+ "disabledMultimodal": true,
229
+ "maxAllowedSize": 56000
230
+ }
231
+ ],
232
+ "links": {
233
+ "officialWebsite": "https://copilot.tencent.com/cli",
234
+ "upgradeUrl": ""
235
+ },
236
+ "productFeatures": {
237
+ "BillingNotice": false,
238
+ "CustomModelsJSON": true
239
+ },
240
+ "commit": "99513c6e55aec7e6d92db60e8b7b62d96f32dc44",
241
+ "date": "2025-12-19T17:20:32.760Z"
242
+ }
@@ -0,0 +1,244 @@
1
+ {
2
+ "endpoint": "https://copilot.tencent.com",
3
+ "stagingEndpoint": "https://staging-copilot.tencent.com",
4
+ "agents": [
5
+ {
6
+ "name": "cli",
7
+ "instructions": "cli-agent-prompt",
8
+ "description": "cli agent",
9
+ "models": [
10
+ "glm-4.6",
11
+ "deepseek-v3.1",
12
+ "deepseek-v3-0324"
13
+ ],
14
+ "commands": [
15
+ "init",
16
+ "compact",
17
+ "statusline"
18
+ ],
19
+ "tools": [
20
+ "Task",
21
+ "Read",
22
+ "Write",
23
+ "Edit",
24
+ "MultiEdit",
25
+ "Bash",
26
+ "Glob",
27
+ "Grep",
28
+ "ExitPlanMode",
29
+ "TodoWrite",
30
+ "WebFetch",
31
+ "WebSearch",
32
+ "NotebookEdit",
33
+ "BashOutput",
34
+ "KillShell",
35
+ "SlashCommand",
36
+ "Skill",
37
+ "AskUserQuestion"
38
+ ],
39
+ "tags": [
40
+ "cli",
41
+ "default"
42
+ ]
43
+ },
44
+ {
45
+ "name": "general-purpose",
46
+ "instructions": "cli-agent-prompt",
47
+ "description": "taskgeneral-purpose agent",
48
+ "tools": [
49
+ "Read",
50
+ "Write",
51
+ "Edit",
52
+ "MultiEdit",
53
+ "Bash",
54
+ "Glob",
55
+ "Grep",
56
+ "TodoWrite",
57
+ "WebFetch",
58
+ "WebSearch",
59
+ "NotebookEdit",
60
+ "BashOutput",
61
+ "KillShell",
62
+ "SlashCommand",
63
+ "Skill",
64
+ "AskUserQuestion"
65
+ ],
66
+ "tags": [
67
+ "cli",
68
+ "general-purpose"
69
+ ]
70
+ },
71
+ {
72
+ "name": "compact",
73
+ "instructions": "compact-agent-prompt",
74
+ "description": "compact agent",
75
+ "tools": [
76
+ "Read"
77
+ ],
78
+ "tags": [
79
+ "cli",
80
+ "compact"
81
+ ]
82
+ },
83
+ {
84
+ "name": "contentAnalyzer",
85
+ "instructions": "content-analyzer-agent-instructions",
86
+ "description": "content analyzer agent",
87
+ "tags": [
88
+ "cli",
89
+ "content-analyzer"
90
+ ]
91
+ },
92
+ {
93
+ "name": "terminalTitleGenerator",
94
+ "instructions": "terminal-title-generator-instructions",
95
+ "description": "Generate terminal window titles from conversation topics.",
96
+ "tags": [
97
+ "cli",
98
+ "terminal-title-generator"
99
+ ]
100
+ },
101
+ {
102
+ "name": "agentInstructions",
103
+ "instructions": "agent-instructions",
104
+ "description": "generating agent instructions",
105
+ "tags": [
106
+ "cli",
107
+ "agent-instructions"
108
+ ]
109
+ },
110
+ {
111
+ "name": "statusline-setup",
112
+ "instructions": "agent-statusline-instructions",
113
+ "description": "Use this agent to configure the user's Codebuddy Code status line setting.",
114
+ "tools": [
115
+ "Read",
116
+ "Write",
117
+ "Edit"
118
+ ],
119
+ "asTool": true,
120
+ "tags": [
121
+ "cli",
122
+ "sub-agent"
123
+ ]
124
+ },
125
+ {
126
+ "name": "Explore",
127
+ "instructions": "agent-explore-instructions",
128
+ "description": "Fast agent specialized for exploring codebases. Use this when you need to quickly find files by patterns (eg. \"src/components/**/*.tsx\"), search code for keywords (eg. \"API endpoints\"), or answer questions about the codebase (eg. \"how do API endpoints work?\"). When calling this agent, specify the desired thoroughness level: \"quick\" for basic searches, \"medium\" for moderate exploration, or \"very thorough\" for comprehensive analysis across multiple locations and naming conventions.",
129
+ "tools": [
130
+ "Read",
131
+ "Bash",
132
+ "Glob",
133
+ "Grep",
134
+ "WebFetch",
135
+ "WebSearch",
136
+ "BashOutput",
137
+ "KillShell",
138
+ "SlashCommand",
139
+ "Skill",
140
+ "AskUserQuestion"
141
+ ],
142
+ "asTool": true,
143
+ "tags": [
144
+ "cli",
145
+ "sub-agent"
146
+ ]
147
+ },
148
+ {
149
+ "name": "Plan",
150
+ "instructions": "agent-plan-instructions",
151
+ "description": "Fast agent specialized for exploring codebases. Use this when you need to quickly find files by patterns (eg. \"src/components/**/*.tsx\"), search code for keywords (eg. \"API endpoints\"), or answer questions about the codebase (eg. \"how do API endpoints work?\"). When calling this agent, specify the desired thoroughness level: \"quick\" for basic searches, \"medium\" for moderate exploration, or \"very thorough\" for comprehensive analysis across multiple locations and naming conventions. (Tools: All tools)",
152
+ "tools": [
153
+ "Read",
154
+ "Bash",
155
+ "Glob",
156
+ "Grep",
157
+ "TodoWrite",
158
+ "WebFetch",
159
+ "WebSearch",
160
+ "BashOutput",
161
+ "KillShell",
162
+ "SlashCommand",
163
+ "Skill",
164
+ "AskUserQuestion"
165
+ ],
166
+ "asTool": true,
167
+ "tags": [
168
+ "cli",
169
+ "sub-agent"
170
+ ]
171
+ }
172
+ ],
173
+ "models": [
174
+ {
175
+ "id": "default",
176
+ "credits": "x2.20 credits",
177
+ "name": "Default",
178
+ "vendor": "v",
179
+ "maxOutputTokens": 24000,
180
+ "maxInputTokens": 200000,
181
+ "supportsToolCall": true,
182
+ "supportsImages": false,
183
+ "maxAllowedSize": 56000
184
+ },
185
+ {
186
+ "credits": "x0.43 credits",
187
+ "id": "deepseek-v3.1",
188
+ "name": "DeepSeek-V3.1-Terminus",
189
+ "vendor": "f",
190
+ "maxOutputTokens": 16000,
191
+ "maxInputTokens": 104000,
192
+ "supportsToolCall": true,
193
+ "supportsImages": false,
194
+ "disabledMultimodal": true,
195
+ "maxAllowedSize": 56000
196
+ },
197
+ {
198
+ "credits": "x0.20 credits",
199
+ "id": "glm-4.6",
200
+ "name": "GLM-4.6",
201
+ "vendor": "f",
202
+ "maxOutputTokens": 32000,
203
+ "maxInputTokens": 168000,
204
+ "supportsToolCall": true,
205
+ "supportsImages": false,
206
+ "disabledMultimodal": true,
207
+ "maxAllowedSize": 168000,
208
+ "supportsReasoning": true,
209
+ "temperature": 1
210
+ },
211
+ {
212
+ "id": "hunyuan-chat",
213
+ "name": "Hunyuan-Turbos",
214
+ "vendor": "j",
215
+ "maxOutputTokens": 8192,
216
+ "maxInputTokens": 200000,
217
+ "supportsToolCall": true,
218
+ "supportsImages": false,
219
+ "disabledMultimodal": true
220
+ },
221
+ {
222
+ "credits": "x0.57 credits",
223
+ "id": "deepseek-v3-0324",
224
+ "name": "DeepSeek-V3",
225
+ "vendor": "tencent",
226
+ "maxOutputTokens": 8192,
227
+ "maxInputTokens": 128000,
228
+ "supportsToolCall": true,
229
+ "supportsImages": false,
230
+ "disabledMultimodal": true,
231
+ "maxAllowedSize": 56000
232
+ }
233
+ ],
234
+ "links": {
235
+ "officialWebsite": "https://copilot.tencent.com/cli",
236
+ "upgradeUrl": ""
237
+ },
238
+ "productFeatures": {
239
+ "BillingNotice": false,
240
+ "CustomModelsJSON": true
241
+ },
242
+ "commit": "99513c6e55aec7e6d92db60e8b7b62d96f32dc44",
243
+ "date": "2025-12-19T17:20:30.330Z"
244
+ }