deepseek-coder-agent-cli 1.0.44 → 1.0.47

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.
@@ -1,73 +1,368 @@
1
1
  /**
2
- * Planning Tools - Minimal stub for backward compatibility
2
+ * Planning Tools - Claude Code-style planning with suggestions and user input
3
+ *
4
+ * Workflow: Explore → Plan → Execute
5
+ * Each plan step supports:
6
+ * - Pre-generated suggestions
7
+ * - User custom instructions
8
+ * - Editable step details
3
9
  */
4
10
  let _planApprovalCallback = null;
11
+ let _currentPlan = null;
12
+ let _explorationComplete = false;
5
13
  export function setPlanApprovalCallback(callback) {
6
14
  _planApprovalCallback = callback;
7
15
  }
8
16
  export function getPlanApprovalCallback() {
9
17
  return _planApprovalCallback;
10
18
  }
19
+ export function setExplorationComplete(complete) {
20
+ _explorationComplete = complete;
21
+ }
22
+ export function isExplorationComplete() {
23
+ return _explorationComplete;
24
+ }
25
+ export function getCurrentPlan() {
26
+ return _currentPlan;
27
+ }
28
+ /**
29
+ * Generate suggestions for a plan step based on context
30
+ */
31
+ function generateStepSuggestions(stepDescription, context) {
32
+ const suggestions = [];
33
+ const lower = stepDescription.toLowerCase();
34
+ // File/component creation suggestions
35
+ if (/create|add|new|implement/i.test(lower)) {
36
+ suggestions.push('Create with minimal implementation first, then iterate');
37
+ suggestions.push('Create with full implementation including tests');
38
+ suggestions.push('Create stub/placeholder, fill in details later');
39
+ }
40
+ // Modification suggestions
41
+ if (/update|modify|change|edit|refactor/i.test(lower)) {
42
+ suggestions.push('Make minimal changes to achieve the goal');
43
+ suggestions.push('Refactor comprehensively while making changes');
44
+ suggestions.push('Update with backward compatibility');
45
+ }
46
+ // Integration suggestions
47
+ if (/integrate|connect|link|api/i.test(lower)) {
48
+ suggestions.push('Implement with error handling and retry logic');
49
+ suggestions.push('Implement basic integration first, enhance later');
50
+ suggestions.push('Implement with full authentication flow');
51
+ }
52
+ // Testing suggestions
53
+ if (/test|verify|validate/i.test(lower)) {
54
+ suggestions.push('Add unit tests for core functionality');
55
+ suggestions.push('Add integration tests with mocks');
56
+ suggestions.push('Add end-to-end tests');
57
+ }
58
+ // UI suggestions
59
+ if (/ui|component|page|screen|view/i.test(lower)) {
60
+ suggestions.push('Create responsive layout with mobile-first approach');
61
+ suggestions.push('Create desktop layout, add mobile later');
62
+ suggestions.push('Create with accessibility (a11y) best practices');
63
+ }
64
+ // Documentation suggestions
65
+ if (/document|readme|explain/i.test(lower)) {
66
+ suggestions.push('Add inline code comments');
67
+ suggestions.push('Create comprehensive README');
68
+ suggestions.push('Add JSDoc/TSDoc annotations');
69
+ }
70
+ // Default suggestions if none matched
71
+ if (suggestions.length === 0) {
72
+ suggestions.push('Implement as described');
73
+ suggestions.push('Implement with additional error handling');
74
+ suggestions.push('Let me provide specific instructions');
75
+ }
76
+ return suggestions.slice(0, 4); // Max 4 suggestions
77
+ }
11
78
  export function createPlanningTools(_workingDir) {
12
79
  return [
13
80
  {
14
- name: 'UpdatePlan',
15
- description: 'Present a multi-step plan to the user',
81
+ name: 'MarkExplorationComplete',
82
+ description: 'Mark that codebase exploration is complete. MUST be called after exploring the codebase and BEFORE creating a plan. This ensures the plan is based on actual understanding of the code.',
16
83
  parameters: {
17
84
  type: 'object',
18
85
  properties: {
19
- steps: {
86
+ summary: {
87
+ type: 'string',
88
+ description: 'Summary of what was learned during exploration (key files, architecture, patterns)',
89
+ },
90
+ keyFindings: {
20
91
  type: 'array',
21
92
  items: { type: 'string' },
22
- description: 'Plan steps',
93
+ description: 'Key findings from exploration',
23
94
  },
24
- explanation: { type: 'string', description: 'Plan explanation' },
25
95
  },
26
- required: ['steps'],
96
+ required: ['summary'],
27
97
  },
28
98
  handler: async (args) => {
29
- const steps = args['steps'];
30
- return `Plan with ${steps.length} steps presented.`;
99
+ const summary = args['summary'];
100
+ const keyFindings = args['keyFindings'];
101
+ _explorationComplete = true;
102
+ return JSON.stringify({
103
+ status: 'exploration_complete',
104
+ summary,
105
+ keyFindings: keyFindings || [],
106
+ message: 'Exploration marked complete. You may now create a plan using ProposePlan.',
107
+ });
31
108
  },
32
109
  },
33
110
  {
34
111
  name: 'ProposePlan',
35
- description: 'Propose a plan for user approval',
112
+ description: `Propose a structured plan for user approval. Each step includes pre-generated suggestions that users can select from or override with their own instructions.
113
+
114
+ IMPORTANT: You MUST call MarkExplorationComplete BEFORE using this tool. Plans created without exploration will be rejected.
115
+
116
+ The plan should include:
117
+ - Clear step descriptions
118
+ - Suggestions for each step (auto-generated if not provided)
119
+ - Scope/files affected
120
+ - Complexity estimates
121
+ - Dependencies between steps`,
36
122
  parameters: {
37
123
  type: 'object',
38
124
  properties: {
125
+ title: {
126
+ type: 'string',
127
+ description: 'Plan title/summary',
128
+ },
129
+ explanation: {
130
+ type: 'string',
131
+ description: 'Overall explanation of what this plan accomplishes',
132
+ },
39
133
  steps: {
134
+ type: 'array',
135
+ items: {
136
+ type: 'object',
137
+ properties: {
138
+ description: { type: 'string', description: 'Step description' },
139
+ suggestions: {
140
+ type: 'array',
141
+ items: { type: 'string' },
142
+ description: 'Pre-generated suggestions for this step (2-4 options)',
143
+ },
144
+ affectedScope: {
145
+ type: 'array',
146
+ items: { type: 'string' },
147
+ description: 'Files or components affected by this step',
148
+ },
149
+ complexity: {
150
+ type: 'string',
151
+ enum: ['low', 'medium', 'high'],
152
+ description: 'Estimated complexity',
153
+ },
154
+ requiresConfirmation: {
155
+ type: 'boolean',
156
+ description: 'Whether this step needs explicit user confirmation',
157
+ },
158
+ dependsOn: {
159
+ type: 'array',
160
+ items: { type: 'number' },
161
+ description: 'Indices of steps this depends on (0-indexed)',
162
+ },
163
+ },
164
+ required: ['description'],
165
+ },
166
+ description: 'Plan steps with suggestions',
167
+ },
168
+ risks: {
40
169
  type: 'array',
41
170
  items: { type: 'string' },
42
- description: 'Plan steps',
171
+ description: 'Potential risks or concerns',
172
+ },
173
+ alternatives: {
174
+ type: 'array',
175
+ items: { type: 'string' },
176
+ description: 'Alternative approaches considered',
43
177
  },
44
- explanation: { type: 'string', description: 'Plan explanation' },
45
178
  },
46
- required: ['steps'],
179
+ required: ['title', 'steps'],
47
180
  },
48
181
  handler: async (args) => {
49
- const steps = args['steps'];
182
+ // Enforce exploration before planning
183
+ if (!_explorationComplete) {
184
+ return JSON.stringify({
185
+ status: 'error',
186
+ error: 'EXPLORATION_REQUIRED',
187
+ message: 'You must call MarkExplorationComplete before creating a plan. Please explore the codebase first to understand the existing code structure, then mark exploration complete.',
188
+ });
189
+ }
190
+ const title = args['title'];
50
191
  const explanation = args['explanation'] || '';
192
+ const rawSteps = args['steps'];
193
+ const risks = args['risks'];
194
+ const alternatives = args['alternatives'];
195
+ // Build plan with auto-generated suggestions where missing
196
+ const steps = rawSteps.map((step) => ({
197
+ description: step.description,
198
+ suggestions: step.suggestions?.length ? step.suggestions : generateStepSuggestions(step.description),
199
+ affectedScope: step.affectedScope,
200
+ complexity: step.complexity || 'medium',
201
+ requiresConfirmation: step.requiresConfirmation ?? false,
202
+ dependsOn: step.dependsOn,
203
+ }));
204
+ const plan = {
205
+ title,
206
+ explanation,
207
+ steps,
208
+ explorationComplete: true,
209
+ risks,
210
+ alternatives,
211
+ };
212
+ _currentPlan = plan;
51
213
  if (_planApprovalCallback) {
52
214
  return new Promise((resolve) => {
53
- const planSteps = steps.map(s => ({ description: s }));
54
- _planApprovalCallback(planSteps, explanation, (approved) => {
55
- resolve(approved ? 'Plan approved' : 'Plan rejected');
215
+ _planApprovalCallback(plan, (result) => {
216
+ if (result.approved) {
217
+ // Apply user inputs to steps
218
+ if (result.stepInputs) {
219
+ result.stepInputs.forEach((input, index) => {
220
+ if (index < plan.steps.length && input) {
221
+ if (input.skip) {
222
+ plan.steps[index].userInstruction = '[SKIPPED]';
223
+ }
224
+ else if (input.selectedSuggestion >= 0 && plan.steps[index].suggestions) {
225
+ plan.steps[index].userInstruction = plan.steps[index].suggestions[input.selectedSuggestion];
226
+ }
227
+ else if (input.customInstruction) {
228
+ plan.steps[index].userInstruction = input.customInstruction;
229
+ }
230
+ }
231
+ });
232
+ }
233
+ resolve(JSON.stringify({
234
+ status: 'approved',
235
+ plan: plan,
236
+ feedback: result.feedback,
237
+ }));
238
+ }
239
+ else if (result.requestRePlan) {
240
+ resolve(JSON.stringify({
241
+ status: 're_plan_requested',
242
+ feedback: result.feedback,
243
+ message: 'User requested modifications to the plan. Please revise based on feedback.',
244
+ }));
245
+ }
246
+ else {
247
+ resolve(JSON.stringify({
248
+ status: 'rejected',
249
+ feedback: result.feedback,
250
+ }));
251
+ }
56
252
  });
57
253
  });
58
254
  }
59
- return `Plan with ${steps.length} steps proposed (auto-approved).`;
255
+ // Auto-approve if no callback (headless mode)
256
+ return JSON.stringify({
257
+ status: 'approved',
258
+ plan: plan,
259
+ message: `Plan "${title}" with ${steps.length} steps approved (auto-approved in headless mode).`,
260
+ });
60
261
  },
61
262
  },
62
263
  {
63
- name: 'ExitPlanMode',
64
- description: 'Signal that planning is complete',
264
+ name: 'UpdatePlan',
265
+ description: 'Update the current plan with new information or modified steps',
266
+ parameters: {
267
+ type: 'object',
268
+ properties: {
269
+ stepIndex: {
270
+ type: 'number',
271
+ description: 'Index of step to update (0-indexed)',
272
+ },
273
+ newDescription: {
274
+ type: 'string',
275
+ description: 'New description for the step',
276
+ },
277
+ newSuggestions: {
278
+ type: 'array',
279
+ items: { type: 'string' },
280
+ description: 'New suggestions for the step',
281
+ },
282
+ markComplete: {
283
+ type: 'boolean',
284
+ description: 'Mark this step as complete',
285
+ },
286
+ },
287
+ required: ['stepIndex'],
288
+ },
289
+ handler: async (args) => {
290
+ if (!_currentPlan) {
291
+ return JSON.stringify({
292
+ status: 'error',
293
+ error: 'NO_ACTIVE_PLAN',
294
+ message: 'No active plan. Use ProposePlan first.',
295
+ });
296
+ }
297
+ const stepIndex = args['stepIndex'];
298
+ if (stepIndex < 0 || stepIndex >= _currentPlan.steps.length) {
299
+ return JSON.stringify({
300
+ status: 'error',
301
+ error: 'INVALID_STEP_INDEX',
302
+ message: `Step index ${stepIndex} is out of range (0-${_currentPlan.steps.length - 1})`,
303
+ });
304
+ }
305
+ const step = _currentPlan.steps[stepIndex];
306
+ if (args['newDescription']) {
307
+ step.description = args['newDescription'];
308
+ }
309
+ if (args['newSuggestions']) {
310
+ step.suggestions = args['newSuggestions'];
311
+ }
312
+ return JSON.stringify({
313
+ status: 'updated',
314
+ stepIndex,
315
+ step,
316
+ });
317
+ },
318
+ },
319
+ {
320
+ name: 'GetPlanStatus',
321
+ description: 'Get the current status of the plan and which steps are complete',
65
322
  parameters: {
66
323
  type: 'object',
67
324
  properties: {},
68
325
  },
69
326
  handler: async () => {
70
- return 'Plan mode exited.';
327
+ if (!_currentPlan) {
328
+ return JSON.stringify({
329
+ status: 'no_plan',
330
+ explorationComplete: _explorationComplete,
331
+ message: _explorationComplete
332
+ ? 'Exploration complete. Ready to create a plan.'
333
+ : 'No exploration or plan yet. Start by exploring the codebase.',
334
+ });
335
+ }
336
+ return JSON.stringify({
337
+ status: 'has_plan',
338
+ plan: _currentPlan,
339
+ explorationComplete: _explorationComplete,
340
+ });
341
+ },
342
+ },
343
+ {
344
+ name: 'ExitPlanMode',
345
+ description: 'Signal that planning is complete and ready to execute. Call this after the plan is approved.',
346
+ parameters: {
347
+ type: 'object',
348
+ properties: {
349
+ summary: {
350
+ type: 'string',
351
+ description: 'Summary of the approved plan',
352
+ },
353
+ },
354
+ },
355
+ handler: async (args) => {
356
+ const summary = args['summary'];
357
+ const plan = _currentPlan;
358
+ // Reset state
359
+ _explorationComplete = false;
360
+ _currentPlan = null;
361
+ return JSON.stringify({
362
+ status: 'plan_mode_exited',
363
+ summary: summary || (plan ? plan.title : 'No plan'),
364
+ message: 'Plan mode exited. Ready to execute the approved plan.',
365
+ });
71
366
  },
72
367
  },
73
368
  ];
@@ -1 +1 @@
1
- {"version":3,"file":"planningTools.js","sourceRoot":"","sources":["../../src/tools/planningTools.ts"],"names":[],"mappings":"AAAA;;GAEG;AAcH,IAAI,qBAAqB,GAAgC,I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K,CAAC;gBAC7B,YAAY,GAAG,IAAI,CAAC;gBAEpB,OAAO,IAAI,CAAC,SAAS,CAAC;oBACpB,MAAM,EAAE,kBAAkB;oBAC1B,OAAO,EAAE,OAAO,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,SAAS,CAAC;oBACnD,OAAO,EAAE,uDAAuD;iBACjE,CAAC,CAAC;YACL,CAAC;SACF;KACF,CAAC;AACJ,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "deepseek-coder-agent-cli",
3
- "version": "1.0.44",
3
+ "version": "1.0.47",
4
4
  "description": "DeepSeek AI-powered CLI agent for code assistance and automation",
5
5
  "deepseek": {
6
6
  "rulebookSchema": "src/contracts/schemas/agent-rules.schema.json"