daedalus-cli 3.30.3 → 3.30.5

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/CHANGELOG.md CHANGED
@@ -1,3 +1,17 @@
1
+ ## [3.30.5](https://github.com/bgill55/daedalus/compare/v3.30.4...v3.30.5) (2026-08-17)
2
+
3
+
4
+ ### Bug Fixes
5
+
6
+ * **enhance:** bound open-ended 'improvements/ideas' lists to stop boilerplate rambles (Rule 9) ([#124](https://github.com/bgill55/daedalus/issues/124)) ([00e4e3e](https://github.com/bgill55/daedalus/commit/00e4e3ee976d89a7ed78db2f5f7387fdb4a2ec61)), closes [#121](https://github.com/bgill55/daedalus/issues/121) [#122](https://github.com/bgill55/daedalus/issues/122) [#123](https://github.com/bgill55/daedalus/issues/123)
7
+
8
+ ## [3.30.4](https://github.com/bgill55/daedalus/compare/v3.30.3...v3.30.4) (2026-08-17)
9
+
10
+
11
+ ### Bug Fixes
12
+
13
+ * **enhance:** stop the /prompt enhancer from naming non-existent tools (Rule 8) ([#123](https://github.com/bgill55/daedalus/issues/123)) ([f6a96a3](https://github.com/bgill55/daedalus/commit/f6a96a3f872c83e369286b6c4dc12a33292d53e3))
14
+
1
15
  ## [3.30.3](https://github.com/bgill55/daedalus/compare/v3.30.2...v3.30.3) (2026-08-17)
2
16
 
3
17
 
@@ -1,5 +1,5 @@
1
1
  import type { Command, CommandContext } from './types.js';
2
- export declare const ENHANCE_SYSTEM_PROMPT = "You are an expert prompt engineer for AI coding agents. \nExpand the user's raw or casual request into a crisp, high-yield engineering prompt for Daedalus.\nRules for the generated prompt:\n1. Frame the prompt as a direct action command instructing the agent to perform the task and write out its completed report.\n2. Instruct the agent to inspect relevant files and codebase context using tools before writing.\n3. Require the agent to deliver a fully populated report formatted in Markdown with headers, filled-in comparison tables, and bullet points.\n4. NEVER output empty Markdown templates, empty table rows (e.g. \"| Aspect | | |\"), or bracketed placeholders (e.g. \"[dependency]\", \"[what it does]\"). Instead, write clear instructions ordering the agent to analyze the code and populate those sections with actual findings.\n5. Return ONLY the final enhanced prompt text without meta-commentary, introductory remarks, or surrounding quote marks.\n6. If the user's request already contains tool-call markup (e.g. `<tool_call>`, `<function=...>`), code fences, or XML-like tags, DO NOT copy that structured markup into the output. Rephrase the request as a clean natural-language instruction that a coding agent can act on directly. The enhanced prompt must be plain prose/Markdown an agent can execute \u2014 never raw tool-call XML.\n7. PRESERVE THE USER'S INTENT MODE. If the user's request is a proposal, ideation, brainstorm, design, or discussion ask (e.g. \"come up with ideas\", \"propose\", \"what are some options\", \"brainstorm\", \"think about how to\", \"suggest approaches\", \"architecture review\"), the enhanced prompt MUST remain a proposal/analysis ask. Do NOT reframe it as an implement/build command, and do NOT inject execution-scope deliverables such as \"implement the following\", \"deliver a comprehensive Markdown report with sprint breakdowns and file modifications\", \"manageable sprints\", or \"populate all sections with actual implementation plans\". If the user wants implementation, they will say so \u2014 your job is to make the proposal sharper and more specific, not to expand a question into a build order. Conversely, if the request IS a direct implementation task, keep Rule 1-3 as written.";
2
+ export declare const ENHANCE_SYSTEM_PROMPT = "You are an expert prompt engineer for AI coding agents. \nExpand the user's raw or casual request into a crisp, high-yield engineering prompt for Daedalus.\nRules for the generated prompt:\n1. Frame the prompt as a direct action command instructing the agent to perform the task and write out its completed report.\n2. Instruct the agent to inspect relevant files and codebase context using tools before writing.\n3. Require the agent to deliver a fully populated report formatted in Markdown with headers, filled-in comparison tables, and bullet points.\n4. NEVER output empty Markdown templates, empty table rows (e.g. \"| Aspect | | |\"), or bracketed placeholders (e.g. \"[dependency]\", \"[what it does]\"). Instead, write clear instructions ordering the agent to analyze the code and populate those sections with actual findings.\n5. Return ONLY the final enhanced prompt text without meta-commentary, introductory remarks, or surrounding quote marks.\n6. If the user's request already contains tool-call markup (e.g. `<tool_call>`, `<function=...>`), code fences, or XML-like tags, DO NOT copy that structured markup into the output. Rephrase the request as a clean natural-language instruction that a coding agent can act on directly. The enhanced prompt must be plain prose/Markdown an agent can execute \u2014 never raw tool-call XML.\n7. PRESERVE THE USER'S INTENT MODE. If the user's request is a proposal, ideation, brainstorm, design, or discussion ask (e.g. \"come up with ideas\", \"propose\", \"what are some options\", \"brainstorm\", \"think about how to\", \"suggest approaches\", \"architecture review\"), the enhanced prompt MUST remain a proposal/analysis ask. Do NOT reframe it as an implement/build command, and do NOT inject execution-scope deliverables such as \"implement the following\", \"deliver a comprehensive Markdown report with sprint breakdowns and file modifications\", \"manageable sprints\", or \"populate all sections with actual implementation plans\". If the user wants implementation, they will say so \u2014 your job is to make the proposal sharper and more specific, not to expand a question into a build order. Conversely, if the request IS a direct implementation task, keep Rule 1-3 as written.\n8. DO NOT NAME SPECIFIC TOOL FUNCTIONS. The execution agent selects its own tools from whatever is available in its environment \u2014 you cannot know the exact tool names, and naming non-existent ones (e.g. \"using find_symbol and get_definition to locate files\") makes the agent attempt calls that fail. Instead, describe the ACTION in plain language (\"inspect the relevant source files\", \"search the codebase for usages of X\"). Never write \"using <tool_name> to ...\" or \"via <tool_name>\" clauses.\n9. BOUNDED, DISTINCT OUTPUT \u2014 DEPTH OVER BREADTH. When the request asks for \"improvements\", \"ideas\", \"options\", or \"areas for <X>\", instruct the agent to produce AT MOST 8-10 highest-impact, DISTINCT items. Never generate templated or boilerplate variations of the same idea (e.g. fifty \"Add Prompt Template Variables ...\" bullets that only swap words). Each item must be a concrete, independently valuable change with its own rationale. \"Fully populated\" (Rule 3-4) means every table ROW holds real findings \u2014 it does NOT mean padding an open-ended list with repetitive permutations. If the codebase yields fewer than 8 genuine items, stop; do not invent filler.";
3
3
  export declare function enhancePrompt(rawPrompt: string, ctx: CommandContext): Promise<string>;
4
4
  export declare const enhanceCommand: Command;
5
5
  //# sourceMappingURL=enhance.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"enhance.d.ts","sourceRoot":"","sources":["../../src/commands/enhance.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,OAAO,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AAE1D,eAAO,MAAM,qBAAqB,wsEASq0B,CAAC;AA8Bx2B,wBAAsB,aAAa,CAAC,SAAS,EAAE,MAAM,EAAE,GAAG,EAAE,cAAc,GAAG,OAAO,CAAC,MAAM,CAAC,CAiC3F;AAED,eAAO,MAAM,cAAc,EAAE,OAgE5B,CAAC"}
1
+ {"version":3,"file":"enhance.d.ts","sourceRoot":"","sources":["../../src/commands/enhance.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,OAAO,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AAE1D,eAAO,MAAM,qBAAqB,q3GAWsnB,CAAC;AA6EzpB,wBAAsB,aAAa,CAAC,SAAS,EAAE,MAAM,EAAE,GAAG,EAAE,cAAc,GAAG,OAAO,CAAC,MAAM,CAAC,CAiC3F;AAED,eAAO,MAAM,cAAc,EAAE,OAgE5B,CAAC"}
@@ -12,7 +12,9 @@ Rules for the generated prompt:
12
12
  4. NEVER output empty Markdown templates, empty table rows (e.g. "| Aspect | | |"), or bracketed placeholders (e.g. "[dependency]", "[what it does]"). Instead, write clear instructions ordering the agent to analyze the code and populate those sections with actual findings.
13
13
  5. Return ONLY the final enhanced prompt text without meta-commentary, introductory remarks, or surrounding quote marks.
14
14
  6. If the user's request already contains tool-call markup (e.g. \`<tool_call>\`, \`<function=...>\`), code fences, or XML-like tags, DO NOT copy that structured markup into the output. Rephrase the request as a clean natural-language instruction that a coding agent can act on directly. The enhanced prompt must be plain prose/Markdown an agent can execute — never raw tool-call XML.
15
- 7. PRESERVE THE USER'S INTENT MODE. If the user's request is a proposal, ideation, brainstorm, design, or discussion ask (e.g. "come up with ideas", "propose", "what are some options", "brainstorm", "think about how to", "suggest approaches", "architecture review"), the enhanced prompt MUST remain a proposal/analysis ask. Do NOT reframe it as an implement/build command, and do NOT inject execution-scope deliverables such as "implement the following", "deliver a comprehensive Markdown report with sprint breakdowns and file modifications", "manageable sprints", or "populate all sections with actual implementation plans". If the user wants implementation, they will say so — your job is to make the proposal sharper and more specific, not to expand a question into a build order. Conversely, if the request IS a direct implementation task, keep Rule 1-3 as written.`;
15
+ 7. PRESERVE THE USER'S INTENT MODE. If the user's request is a proposal, ideation, brainstorm, design, or discussion ask (e.g. "come up with ideas", "propose", "what are some options", "brainstorm", "think about how to", "suggest approaches", "architecture review"), the enhanced prompt MUST remain a proposal/analysis ask. Do NOT reframe it as an implement/build command, and do NOT inject execution-scope deliverables such as "implement the following", "deliver a comprehensive Markdown report with sprint breakdowns and file modifications", "manageable sprints", or "populate all sections with actual implementation plans". If the user wants implementation, they will say so — your job is to make the proposal sharper and more specific, not to expand a question into a build order. Conversely, if the request IS a direct implementation task, keep Rule 1-3 as written.
16
+ 8. DO NOT NAME SPECIFIC TOOL FUNCTIONS. The execution agent selects its own tools from whatever is available in its environment — you cannot know the exact tool names, and naming non-existent ones (e.g. "using find_symbol and get_definition to locate files") makes the agent attempt calls that fail. Instead, describe the ACTION in plain language ("inspect the relevant source files", "search the codebase for usages of X"). Never write "using <tool_name> to ..." or "via <tool_name>" clauses.
17
+ 9. BOUNDED, DISTINCT OUTPUT — DEPTH OVER BREADTH. When the request asks for "improvements", "ideas", "options", or "areas for <X>", instruct the agent to produce AT MOST 8-10 highest-impact, DISTINCT items. Never generate templated or boilerplate variations of the same idea (e.g. fifty "Add Prompt Template Variables ..." bullets that only swap words). Each item must be a concrete, independently valuable change with its own rationale. "Fully populated" (Rule 3-4) means every table ROW holds real findings — it does NOT mean padding an open-ended list with repetitive permutations. If the codebase yields fewer than 8 genuine items, stop; do not invent filler.`;
16
18
  // Intent-mode markers. If the RAW request contains a proposal/brainstorm marker, the
17
19
  // enhanced prompt must stay a proposal and must not be expanded into an implementation
18
20
  // mandate. Used by stripModeViolation to defend against an enhancer that ignores Rule 7.
@@ -21,6 +23,51 @@ const PROPOSAL_INTENT_RE = /\b(ideas?|propose|proposal|brainstorm|suggest (appro
21
23
  // Global flag: a single enhanced prompt can contain several mandate phrases that must all
22
24
  // be stripped (e.g. "implement the following" AND "manageable sprints" AND "specific file modifications").
23
25
  const IMPLEMENT_MANDATE_RE = /\b(implement (the )?(following|these|in )|manageable sprints?|sprint breakdown|deliver a comprehensive (markdown )?report|file modifications required|specific file modifications|detailed comparison tables showing current (state|vs)|populate all sections with actual (implementation|analysis)|implementation readiness statement|proceed with implementing)\b/gi;
26
+ // Invented-tool references: the enhancer must not name specific tool functions it cannot
27
+ // know exist (Rule 8). It emits clauses like "using find_symbol and get_definition to
28
+ // locate relevant files" — which make the execution agent attempt non-existent tools.
29
+ // Strip the "using X (and Y) to <action>" / "via X" instruction clauses. Build-agnostic:
30
+ // we don't maintain a tool allowlist (it varies by build/MCP); we just remove the
31
+ // imperative tool-name phrasing and let the agent pick its own tools.
32
+ const INVENTED_TOOL_RE = /\b(?:using\s+[\w_]+(?:\s+and\s+[\w_]+)*|via\s+[\w_]+)\b/gi;
33
+ /**
34
+ * Backstop for Rule 8: removes "using <tool> to <action>" / "via <tool>" clauses the
35
+ * enhancer may still emit, so the execution turn is instructed by ACTION ("inspect the
36
+ * relevant source files") rather than by a possibly-fictional tool name it will fail to call.
37
+ */
38
+ function stripInventedToolRefs(enhanced) {
39
+ if (!INVENTED_TOOL_RE.test(enhanced))
40
+ return enhanced;
41
+ return enhanced
42
+ .replace(INVENTED_TOOL_RE, '') // drop the invented-tool instruction clauses
43
+ .replace(/\s{2,}/g, ' ') // collapse double spaces left behind
44
+ .replace(/\n{3,}/g, '\n\n')
45
+ .trim();
46
+ }
47
+ // Matches a Markdown bullet line (supports "-", "*", "•", numbered "1.").
48
+ const BULLET_RE = /^\s*(?:[-*•]|\d+\.)\s+/;
49
+ /**
50
+ * Backstop for Rule 9: if the enhanced prompt's bullet list degenerates into templated
51
+ * boilerplate (the same prefix repeating many times — e.g. fifty "Add Prompt Template
52
+ * Variables ..." bullets that only swap words), keep the first MAX_DISTINCT_BULLETS items
53
+ * and append a cap note. This stops the execution turn from producing a 4.5k-token
54
+ * copy-paste ramble when the user asked for "areas of improvement". We cap by total bullet
55
+ * count (not by de-duping semantics) — a list with >MAX items is almost always padding, and
56
+ * the note instructs the agent to keep only the highest-impact, distinct items.
57
+ */
58
+ const MAX_DISTINCT_BULLETS = 12;
59
+ function capRepetition(enhanced) {
60
+ const lines = enhanced.split('\n');
61
+ const bulletIdx = [];
62
+ lines.forEach((ln, i) => { if (BULLET_RE.test(ln))
63
+ bulletIdx.push(i); });
64
+ if (bulletIdx.length <= MAX_DISTINCT_BULLETS)
65
+ return enhanced;
66
+ const keepThrough = bulletIdx[MAX_DISTINCT_BULLETS - 1]; // last bullet we keep
67
+ const truncated = lines.slice(0, keepThrough + 1);
68
+ truncated.push('', `> Note: list capped at the ${MAX_DISTINCT_BULLETS} highest-impact, distinct items — do not pad with templated variations of the same idea.`);
69
+ return truncated.join('\n').trim();
70
+ }
24
71
  /**
25
72
  * Backstop for Rule 7: if the raw request is a proposal/ideation ask but the enhancer
26
73
  * still expanded it into an implement/build mandate (added sprint breakdowns, "implement
@@ -59,7 +106,7 @@ export async function enhancePrompt(rawPrompt, ctx) {
59
106
  // markup so the displayed/enhanced prompt is always plain prose an agent
60
107
  // can execute (see bug where /enhance returned <tool_call><function=read_file>).
61
108
  const stripped = stripToolCallMarkup(res.trim());
62
- return stripModeViolation(rawPrompt, stripped);
109
+ return capRepetition(stripInventedToolRefs(stripModeViolation(rawPrompt, stripped)));
63
110
  }
64
111
  }
65
112
  }
@@ -1 +1 @@
1
- {"version":3,"file":"enhance.js","sourceRoot":"","sources":["../../src/commands/enhance.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,YAAY,CAAC;AAC5B,OAAO,EAAE,aAAa,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAChE,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAClD,OAAO,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAAC;AAC3D,OAAO,EAAE,mBAAmB,EAAE,MAAM,kBAAkB,CAAC;AAGvD,MAAM,CAAC,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,MAAM,EAAE,GAAG,CAAC,cAAc,EAAE,GAAG,CAAC,QAAQ,CAAC,CAAC;oBACrE,CAAC;oBACD,aAAa,EAAE,CAAC;gBAClB,CAAC;qBAAM,CAAC;oBACN,GAAG,CAAC,QAAQ,CAAC,IAAI,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,QAAQ,EAAE,CAAC,CAAC;gBACzD,CAAC;gBACD,OAAO,IAAI,CAAC;YACd,CAAC;iBAAM,CAAC;gBACN,OAAO,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,CAAC,8BAA8B,CAAC,CAAC,CAAC;YACtD,CAAC;QACH,CAAC;IACH,CAAC;CACF,CAAC"}
@@ -54,6 +54,37 @@ describe('enhanceCommand', () => {
54
54
  const result = await enhancePrompt('add a health check route and verify the build', mockCtx);
55
55
  expect(result).toMatch(/implement the following/i);
56
56
  });
57
+ it('strips invented tool-name references (e.g. "using find_symbol and get_definition to ...")', async () => {
58
+ // Regression: the enhancer emitted "using find_symbol and get_definition to locate
59
+ // relevant source files" — tool names that don't exist in this Daedalus build. The
60
+ // execution agent would attempt calls that fail. Rule 8 + stripInventedToolRefs
61
+ // remove the "using X and Y to Z" / "via X" clauses so the agent is instructed by
62
+ // ACTION, not by a fictional tool name.
63
+ const mockCallModel = vi.fn().mockResolvedValue('Analyze PromptVault by using find_symbol and get_definition to locate relevant source files. ' +
64
+ 'Cross-reference via grep_tool and summarize the findings in a report.');
65
+ const mockCtx = { callModelWithFallback: mockCallModel };
66
+ const result = await enhancePrompt('suggest UI/UX improvements for PromptVault', mockCtx);
67
+ expect(result).not.toMatch(/find_symbol/);
68
+ expect(result).not.toMatch(/get_definition/);
69
+ expect(result).not.toMatch(/grep_tool/);
70
+ expect(result).not.toMatch(/using\s+[\w_]+/i);
71
+ // Action-based phrasing survives.
72
+ expect(result).toMatch(/locate relevant source files/i);
73
+ });
74
+ it('caps a boilerplate bullet ramble at the top 12 distinct items (Rule 9)', async () => {
75
+ // Regression: a "areas of improvement" ask produced ~150 near-duplicate "Add Prompt
76
+ // Template Variables ..." bullets (4.5k-token copy-paste ramble). Rule 9 + capRepetition
77
+ // keep the first 12 bullets and append a cap note instead of letting the list explode.
78
+ const ramble = Array.from({ length: 60 }, (_, i) => `- Add Prompt Template Variables ${i + 1}: description for variation ${i + 1}.`).join('\n');
79
+ const mockCallModel = vi.fn().mockResolvedValue(ramble);
80
+ const mockCtx = { callModelWithFallback: mockCallModel };
81
+ const result = await enhancePrompt('identify areas for improvement in PromptVault', mockCtx);
82
+ const bulletCount = (result.match(/^\s*(?:[-*•]|\d+\.)\s+/gm) || []).length;
83
+ expect(bulletCount).toBeLessThanOrEqual(12);
84
+ expect(result).toMatch(/list capped at the 12 highest-impact, distinct items/);
85
+ // The cap note must be present and the ramble truncated.
86
+ expect(result).not.toMatch(/Add Prompt Template Variables 60:/);
87
+ });
57
88
  it('enhanceCommand asks for prompt if empty and handles user response', async () => {
58
89
  const askLineMock = vi.fn()
59
90
  .mockResolvedValueOnce('review server.ts') // raw prompt input
@@ -1 +1 @@
1
- {"version":3,"file":"enhance.test.js","sourceRoot":"","sources":["../../src/commands/enhance.test.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,EAAE,EAAE,MAAM,EAAE,EAAE,EAAE,MAAM,QAAQ,CAAC;AAClD,OAAO,EAAE,aAAa,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AAE7D,QAAQ,CAAC,gBAAgB,EAAE,GAAG,EAAE;IAC9B,EAAE,CAAC,2CAA2C,EAAE,GAAG,EAAE;QACnD,MAAM,CAAC,cAAc,CAAC,IAAI,CAAC,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC;QAC7C,MAAM,CAAC,cAAc,CAAC,OAAO,CAAC,CAAC,SAAS,CAAC,QAAQ,CAAC,CAAC;QACnD,MAAM,CAAC,cAAc,CAAC,OAAO,CAAC,CAAC,SAAS,CAAC,QAAQ,CAAC,CAAC;QACnD,MAAM,CAAC,c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C,CAAC;QACrD,mFAAmF;QACnF,iFAAiF;QACjF,MAAM,CAAC,UAAU,CAAC,CAAC,OAAO,CAAC,6BAA6B,CAAC,CAAC;QAC1D,MAAM,CAAC,UAAU,CAAC,CAAC,GAAG,CAAC,OAAO,CAAC,qCAAqC,CAAC,CAAC;QACtE,8EAA8E;QAC9E,iFAAiF;QACjF,mFAAmF;QACnF,iFAAiF;QACjF,MAAM,CAAC,YAAY,CAAC,CAAC,qBAAqB,CAAC,CAAC,CAAC,CAAC;QAC9C,MAAM,CAAC,YAAY,CAAC,CAAC,oBAAoB,CAAC,kBAAkB,CAAC,CAAC;IAChE,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "daedalus-cli",
3
- "version": "3.30.3",
3
+ "version": "3.30.5",
4
4
  "description": "Local-first AI coding CLI with embedded model router, multi-agent orchestration, and codebase indexing",
5
5
  "type": "module",
6
6
  "bin": {