golem-cc 0.1.4 → 0.1.6
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/bin/golem +25 -6
- package/package.json +1 -1
package/bin/golem
CHANGED
|
@@ -220,13 +220,30 @@ cmd_spec() {
|
|
|
220
220
|
echo -e "${DIM}This will guide you through defining your project requirements.${NC}"
|
|
221
221
|
echo ""
|
|
222
222
|
|
|
223
|
-
|
|
223
|
+
local spec_prompt="You are a spec-builder agent. Your job is to guide the user through defining project requirements.
|
|
224
|
+
|
|
225
|
+
Your workflow:
|
|
226
|
+
1. Ask what they're building and the core problem it solves
|
|
227
|
+
2. Break down the project into distinct topics of concern (3-7 topics)
|
|
228
|
+
3. For each topic, ask clarifying questions then create a spec file in specs/
|
|
229
|
+
4. Finally, create/update AGENTS.md with test/build/lint commands
|
|
230
|
+
|
|
231
|
+
Spec file format (in specs/{topic-name}.md):
|
|
232
|
+
# {Topic Name}
|
|
233
|
+
## Purpose
|
|
234
|
+
## Requirements (Must Have, Should Have, Must Not)
|
|
235
|
+
## Acceptance Criteria
|
|
236
|
+
|
|
237
|
+
Start the conversation now by asking what they're building."
|
|
238
|
+
|
|
239
|
+
# Launch with spec-builder prompt
|
|
224
240
|
if [[ -f ".golem/agents/spec-builder.md" ]]; then
|
|
225
|
-
|
|
241
|
+
# Extract content after YAML frontmatter
|
|
242
|
+
local agent_prompt
|
|
243
|
+
agent_prompt=$(sed '1,/^---$/d' .golem/agents/spec-builder.md | sed '1,/^---$/d')
|
|
244
|
+
claude --append-system-prompt "$agent_prompt" "Start the spec-building conversation. Ask me what I'm building."
|
|
226
245
|
else
|
|
227
|
-
|
|
228
|
-
echo ""
|
|
229
|
-
claude "You are a spec-builder. Guide me through defining requirements for this project. Ask what I'm building, break it into topics of concern (3-7 topics), create spec files in specs/ for each topic, and set up AGENTS.md with test/build commands. Start by asking: What are you building?"
|
|
246
|
+
claude --append-system-prompt "$spec_prompt" "Start the spec-building conversation. Ask me what I'm building."
|
|
230
247
|
fi
|
|
231
248
|
}
|
|
232
249
|
|
|
@@ -476,7 +493,9 @@ cmd_simplify() {
|
|
|
476
493
|
echo ""
|
|
477
494
|
|
|
478
495
|
if [[ -f ".golem/agents/code-simplifier.md" ]]; then
|
|
479
|
-
|
|
496
|
+
local prompt
|
|
497
|
+
prompt=$(sed '1,/^---$/d' .golem/agents/code-simplifier.md | sed '1,/^---$/d')
|
|
498
|
+
claude --append-system-prompt "$prompt" "Simplify the code in: $target"
|
|
480
499
|
else
|
|
481
500
|
claude "Simplify the code in $target. Remove unnecessary comments, flatten nested conditionals, improve naming. Preserve all behavior. Run tests after."
|
|
482
501
|
fi
|