create-walle 0.9.13 → 0.9.15

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 (98) hide show
  1. package/README.md +8 -3
  2. package/bin/create-walle.js +232 -32
  3. package/bin/mcp-inject.js +18 -53
  4. package/package.json +3 -1
  5. package/template/claude-task-manager/api-prompts.js +11 -2
  6. package/template/claude-task-manager/approval-agent.js +7 -0
  7. package/template/claude-task-manager/db.js +94 -75
  8. package/template/claude-task-manager/docs/session-standup-command-center-design.md +242 -0
  9. package/template/claude-task-manager/docs/session-tooltip-freshness-design.md +224 -0
  10. package/template/claude-task-manager/docs/session-ux-issue-review-2026-05-01.md +369 -0
  11. package/template/claude-task-manager/fuzzy-utils.js +10 -2
  12. package/template/claude-task-manager/git-utils.js +140 -10
  13. package/template/claude-task-manager/lib/agent-capabilities.js +1 -1
  14. package/template/claude-task-manager/lib/agent-presets.js +38 -5
  15. package/template/claude-task-manager/lib/codex-terminal-final.js +53 -0
  16. package/template/claude-task-manager/lib/ctm-session-context-api.js +222 -0
  17. package/template/claude-task-manager/lib/session-diagnostics.js +56 -0
  18. package/template/claude-task-manager/lib/session-history.js +309 -16
  19. package/template/claude-task-manager/lib/session-standup.js +409 -0
  20. package/template/claude-task-manager/lib/session-stream.js +253 -20
  21. package/template/claude-task-manager/lib/standup-attention.js +200 -0
  22. package/template/claude-task-manager/lib/status-hooks.js +8 -2
  23. package/template/claude-task-manager/lib/update-telemetry.js +114 -0
  24. package/template/claude-task-manager/lib/walle-ctm-history.js +49 -6
  25. package/template/claude-task-manager/lib/walle-default-model.js +55 -0
  26. package/template/claude-task-manager/lib/walle-mcp-auto-config.js +66 -0
  27. package/template/claude-task-manager/lib/walle-supervisor.js +86 -19
  28. package/template/claude-task-manager/lib/walle-transcript.js +1 -3
  29. package/template/claude-task-manager/lib/worktree-cwd.js +82 -0
  30. package/template/claude-task-manager/package.json +1 -0
  31. package/template/claude-task-manager/providers/codex-mcp.js +104 -0
  32. package/template/claude-task-manager/providers/index.js +2 -0
  33. package/template/claude-task-manager/public/css/setup.css +2 -1
  34. package/template/claude-task-manager/public/css/walle.css +71 -0
  35. package/template/claude-task-manager/public/index.html +2388 -429
  36. package/template/claude-task-manager/public/js/message-renderer.js +314 -35
  37. package/template/claude-task-manager/public/js/session-search-utils.js +185 -3
  38. package/template/claude-task-manager/public/js/session-status-precedence.js +125 -0
  39. package/template/claude-task-manager/public/js/setup.js +62 -19
  40. package/template/claude-task-manager/public/js/stream-view.js +396 -55
  41. package/template/claude-task-manager/public/js/terminal-restore-state.js +57 -0
  42. package/template/claude-task-manager/public/js/walle-session.js +234 -26
  43. package/template/claude-task-manager/public/js/walle.js +143 -2
  44. package/template/claude-task-manager/server.js +1402 -433
  45. package/template/claude-task-manager/session-integrity.js +77 -28
  46. package/template/claude-task-manager/workers/approval-widget-validator.js +15 -5
  47. package/template/claude-task-manager/workers/scrollback-worker.js +5 -6
  48. package/template/claude-task-manager/workers/state-detectors/codex.js +6 -0
  49. package/template/package.json +1 -1
  50. package/template/wall-e/agent-runners/claude-code.js +2 -0
  51. package/template/wall-e/agent.js +63 -8
  52. package/template/wall-e/api-walle.js +330 -52
  53. package/template/wall-e/brain.js +291 -42
  54. package/template/wall-e/chat.js +172 -15
  55. package/template/wall-e/coding/compaction-service.js +19 -5
  56. package/template/wall-e/coding/stream-processor.js +22 -2
  57. package/template/wall-e/coding/workspace-replay.js +1 -4
  58. package/template/wall-e/coding-orchestrator.js +250 -80
  59. package/template/wall-e/compat.js +0 -28
  60. package/template/wall-e/context/context-builder.js +3 -1
  61. package/template/wall-e/embeddings.js +2 -7
  62. package/template/wall-e/eval/agent-runner.js +30 -9
  63. package/template/wall-e/eval/benchmark-generator.js +21 -1
  64. package/template/wall-e/eval/benchmarks/chat-eval.json +66 -6
  65. package/template/wall-e/eval/benchmarks/coding-agent.json +0 -596
  66. package/template/wall-e/eval/cc-replay.js +1 -0
  67. package/template/wall-e/eval/codex-cli-baseline.js +633 -0
  68. package/template/wall-e/eval/debug-agent003.js +1 -0
  69. package/template/wall-e/eval/eval-orchestrator.js +3 -3
  70. package/template/wall-e/eval/run-agent-benchmarks.js +11 -3
  71. package/template/wall-e/eval/run-codex-cli-baseline.js +177 -0
  72. package/template/wall-e/eval/run-model-comparison.js +1 -0
  73. package/template/wall-e/eval/swebench-adapter.js +1 -0
  74. package/template/wall-e/evaluation/quorum-evaluator.js +0 -1
  75. package/template/wall-e/extraction/knowledge-extractor.js +1 -2
  76. package/template/wall-e/lib/mcp-integration.js +336 -0
  77. package/template/wall-e/llm/ollama.js +47 -8
  78. package/template/wall-e/llm/ollama.plugin.json +1 -1
  79. package/template/wall-e/llm/tool-adapter.js +1 -0
  80. package/template/wall-e/loops/ingest.js +42 -8
  81. package/template/wall-e/loops/initiative.js +87 -2
  82. package/template/wall-e/mcp-server.js +872 -19
  83. package/template/wall-e/memory/ctm-context-client.js +230 -0
  84. package/template/wall-e/memory/ctm-session-context.js +1376 -0
  85. package/template/wall-e/prompts/coding/memory-protocol.md +6 -0
  86. package/template/wall-e/server.js +30 -1
  87. package/template/wall-e/skills/_bundled/memory-search/SKILL.md +8 -0
  88. package/template/wall-e/skills/_bundled/scan-ctm-sessions/SKILL.md +20 -0
  89. package/template/wall-e/skills/_bundled/scan-ctm-sessions/run.js +43 -0
  90. package/template/wall-e/skills/_bundled/slack-mentions/run.js +471 -188
  91. package/template/wall-e/skills/skill-planner.js +86 -4
  92. package/template/wall-e/slack/socket-mode-listener.js +276 -0
  93. package/template/wall-e/telemetry.js +70 -2
  94. package/template/wall-e/tools/builtin-middleware.js +55 -2
  95. package/template/wall-e/tools/shell-policy.js +1 -1
  96. package/template/wall-e/tools/slack-owner.js +104 -0
  97. package/template/website/index.html +4 -4
  98. package/template/builder-journal.md +0 -17
@@ -0,0 +1,104 @@
1
+ 'use strict';
2
+
3
+ const fs = require('fs');
4
+ const path = require('path');
5
+ const slackMcp = require('./slack-mcp');
6
+
7
+ const OWNER_ENV_KEY = 'SLACK_OWNER_USER_ID';
8
+
9
+ function getEnvPath() {
10
+ return process.env.WALLE_ENV_PATH || path.resolve(__dirname, '..', '..', '.env');
11
+ }
12
+
13
+ function normalizeSlackUserId(value) {
14
+ const id = String(value || '').trim();
15
+ if (!id || /[\r\n=]/.test(id)) return '';
16
+ return /^[A-Z][A-Z0-9]{2,}$/.test(id) ? id : '';
17
+ }
18
+
19
+ function readOwnerUserIdFromToken() {
20
+ const token = slackMcp.loadToken();
21
+ return normalizeSlackUserId(token?.user_id || token?.authed_user?.id || token?.user?.id || '');
22
+ }
23
+
24
+ function persistEnvVar(key, value, envPath = getEnvPath()) {
25
+ const safeKey = String(key || '').replace(/[^A-Z0-9_]/g, '');
26
+ const safeValue = String(value || '').trim();
27
+ if (!safeKey || !safeValue || /[\r\n]/.test(safeValue)) {
28
+ throw new Error('Invalid environment value');
29
+ }
30
+
31
+ const lines = [];
32
+ try {
33
+ for (const line of fs.readFileSync(envPath, 'utf8').split('\n')) {
34
+ const m = line.match(/^\s*#?\s*([A-Z0-9_]+)\s*=/);
35
+ if (m && m[1] === safeKey) continue;
36
+ lines.push(line);
37
+ }
38
+ } catch {
39
+ lines.push('# Wall-E configuration');
40
+ lines.push('');
41
+ }
42
+ while (lines.length > 0 && lines[lines.length - 1].trim() === '') lines.pop();
43
+ lines.push('');
44
+ lines.push(`${safeKey}=${safeValue}`);
45
+
46
+ const dir = path.dirname(envPath);
47
+ fs.mkdirSync(dir, { recursive: true });
48
+ const tmpPath = `${envPath}.${process.pid}.${Date.now()}.tmp`;
49
+ fs.writeFileSync(tmpPath, lines.join('\n') + '\n', { mode: 0o600 });
50
+ fs.renameSync(tmpPath, envPath);
51
+ }
52
+
53
+ function repairSlackOwnerIdentity(opts = {}) {
54
+ const existing = normalizeSlackUserId(process.env[OWNER_ENV_KEY]);
55
+ if (existing) {
56
+ return { ok: true, alreadyConfigured: true, userId: existing, source: 'env', persisted: false };
57
+ }
58
+
59
+ const tokenUserId = readOwnerUserIdFromToken();
60
+ if (!tokenUserId) {
61
+ return {
62
+ ok: false,
63
+ error: 'Connect Slack first so Wall-E can identify your Slack account automatically.',
64
+ needsSlackAuth: true,
65
+ };
66
+ }
67
+
68
+ let persisted = false;
69
+ if (opts.persist !== false) {
70
+ persistEnvVar(OWNER_ENV_KEY, tokenUserId, opts.envPath);
71
+ persisted = true;
72
+ }
73
+ process.env[OWNER_ENV_KEY] = tokenUserId;
74
+
75
+ return {
76
+ ok: true,
77
+ alreadyConfigured: false,
78
+ userId: tokenUserId,
79
+ source: 'slack_oauth_token',
80
+ persisted,
81
+ };
82
+ }
83
+
84
+ function getSlackOwnerRepairState() {
85
+ const envUserId = normalizeSlackUserId(process.env[OWNER_ENV_KEY]);
86
+ if (envUserId) return { configured: true, canRepair: false, userId: envUserId, source: 'env' };
87
+ const tokenUserId = readOwnerUserIdFromToken();
88
+ return {
89
+ configured: false,
90
+ canRepair: !!tokenUserId,
91
+ userId: tokenUserId || '',
92
+ source: tokenUserId ? 'slack_oauth_token' : null,
93
+ };
94
+ }
95
+
96
+ module.exports = {
97
+ OWNER_ENV_KEY,
98
+ getEnvPath,
99
+ getSlackOwnerRepairState,
100
+ normalizeSlackUserId,
101
+ persistEnvVar,
102
+ readOwnerUserIdFromToken,
103
+ repairSlackOwnerIdentity,
104
+ };
@@ -327,7 +327,7 @@
327
327
  <div class="feature-card">
328
328
  <span class="icon">&#129504;</span>
329
329
  <h3>Second Brain</h3>
330
- <p>Automatically ingests Slack, email, calendar, and coding sessions into a searchable memory with knowledge extraction and pattern detection.</p>
330
+ <p>Automatically ingests Slack, email, calendar, and coding sessions into searchable memory with knowledge extraction and pattern detection.</p>
331
331
  </div>
332
332
  <div class="feature-card">
333
333
  <span class="icon">&#9889;</span>
@@ -337,12 +337,12 @@
337
337
  <div class="feature-card">
338
338
  <span class="icon">&#128172;</span>
339
339
  <h3>Chat with Tools</h3>
340
- <p>Talk to Wall-E in the browser. It can search memories, look up people, run skills, and call external tools via MCP.</p>
340
+ <p>Talk to Wall-E in the browser. It can search memories, recall prior coding sessions, look up people, run skills, and call external tools via MCP.</p>
341
341
  </div>
342
342
  <div class="feature-card">
343
343
  <span class="icon">&#128736;</span>
344
- <h3>19 Bundled Skills</h3>
345
- <p>Morning briefing, Slack monitoring, email sync, calendar integration, coding agent, model training, model pricing sync, and more &mdash; all configurable from the UI.</p>
344
+ <h3>20 Bundled Skills</h3>
345
+ <p>Morning briefing, Slack monitoring, email sync, calendar integration, coding agent, memory search, model training, model pricing sync, and more &mdash; all configurable from the UI.</p>
346
346
  </div>
347
347
  <div class="feature-card">
348
348
  <span class="icon">&#127760;</span>
@@ -1,17 +0,0 @@
1
- # Builder Journal
2
-
3
- ## 2026-04-29 — Surface Wall-E AI provider failures
4
-
5
- - Added structured `AI_PROVIDER_ERROR` classification for provider failures, including rate limit, quota, auth, model unavailable, timeout, network, context-window, and unavailable-provider cases.
6
- - Threaded provider error metadata through Wall-E chat, `/api/wall-e/chat` SSE/JSON responses, CTM Wall-E session WebSocket errors, JSONL error parts, and service alerts.
7
- - Updated Wall-E chat UX with a persistent provider-failure banner, inline diagnostic message, setup action, dismiss control, and collapsible raw provider details.
8
- - Updated CTM Wall-E session error notices to render the same provider diagnostic shape instead of collapsing it into a generic string.
9
- - Added focused node tests for provider classification and chat alerting, plus a Playwright rendering scenario for mocked provider 429 errors.
10
-
11
- ## 2026-04-29 — Make default-provider switching feel instant
12
-
13
- - Found the slow path: CTM wrote the new default, then restarted Wall-E so its cached default client would reload, while the UI waited for the whole request before changing the star.
14
- - Changed `/api/setup/set-default` to call Wall-E's live setup config endpoint and only schedule a Wall-E restart if that live update fails.
15
- - Made setup default stars optimistic with rollback on failure, while keeping the selected star visually selected during the in-flight save.
16
- - Raised contrast on provider card borders, default stars, and toggle tracks so the inline styles no longer wash out the controls.
17
- - Added a Playwright setup-card regression for optimistic default switching and computed control colors.