@kraftapps-ai/kai 1.6.2 → 1.6.4

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 (2) hide show
  1. package/kai +2 -35
  2. package/package.json +1 -1
package/kai CHANGED
@@ -18,15 +18,8 @@ fi
18
18
  PRD_FILE=".kai/stories.json"
19
19
  PROGRESS_FILE=".kai/progress.txt"
20
20
  MEMORY_FILE=".kai/memory.md"
21
- SESSION_FILE=".kai/session_id"
22
21
  LOOP_SCRIPT=".kai/loop.sh"
23
22
 
24
- # ── Handle --new flag ─────────────────────────────────
25
-
26
- if [ "${1:-}" = "--new" ]; then
27
- rm -f "$SESSION_FILE"
28
- shift
29
- fi
30
23
 
31
24
  # ── Ensure .kai/ is git-ignored ───────────────────────
32
25
 
@@ -367,17 +360,7 @@ The developer's name is: ${dev_name}"
367
360
 
368
361
  # ── Build Claude args ─────────────────────────────────
369
362
 
370
- CLAUDE_ARGS="--dangerously-skip-permissions"
371
-
372
- # Session persistence: reuse the same session ID per repo
373
- if [ -f "$SESSION_FILE" ]; then
374
- KAI_SESSION=$(cat "$SESSION_FILE")
375
- else
376
- KAI_SESSION=$(uuidgen 2>/dev/null || python3 -c "import uuid; print(uuid.uuid4())" 2>/dev/null || cat /proc/sys/kernel/random/uuid 2>/dev/null)
377
- mkdir -p .kai
378
- echo "$KAI_SESSION" > "$SESSION_FILE"
379
- fi
380
- CLAUDE_ARGS="$CLAUDE_ARGS --name kai"
363
+ CLAUDE_ARGS="--dangerously-skip-permissions --name kai"
381
364
 
382
365
  # ── Launch the PM ─────────────────────────────────────
383
366
 
@@ -533,20 +516,4 @@ When the developer says \"check /designs\", translate that to the full URL using
533
516
  - **On startup without memory (fresh start):** Explore the repo first to understand the project. Read \`package.json\`, \`shopify.app.toml\` (or \`shopify.app.*.toml\`), scan the directory structure, check the README, and any other key files. Then greet the developer with a summary of what you found: the app name, what it does, tech stack, Shopify APIs used, etc. Save this to \`.kai/memory.md\` so you remember next time. Then ask what they want to plan or build. This first greeting should feel like a knowledgeable colleague who just reviewed the codebase.
534
517
  ${status}${progress}${memory}${dev_greeting}"
535
518
 
536
- err_file=$(mktemp)
537
- set +e
538
- claude --session-id "$KAI_SESSION" $CLAUDE_ARGS --system-prompt "$SYSTEM_PROMPT" "${@:-Hey Kai}" 2>"$err_file"
539
- exit_code=$?
540
- set -e
541
-
542
- if [ $exit_code -ne 0 ] && grep -qi "already in use" "$err_file" 2>/dev/null; then
543
- rm -f "$err_file"
544
- echo ""
545
- echo "Kai is already running in another terminal."
546
- echo ""
547
- echo " 1) Start a new session here: kai --new"
548
- echo " 2) Continue in the other terminal where Kai is running"
549
- echo ""
550
- exit 1
551
- fi
552
- rm -f "$err_file"
519
+ exec claude $CLAUDE_ARGS --system-prompt "$SYSTEM_PROMPT" "${@:-Hey Kai}"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kraftapps-ai/kai",
3
- "version": "1.6.2",
3
+ "version": "1.6.4",
4
4
  "description": "Autonomous AI developer loop for Claude Code",
5
5
  "bin": {
6
6
  "kai": "kai"