codemini-cli 0.5.9 → 0.5.11

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 (59) hide show
  1. package/OPERATIONS.md +242 -242
  2. package/README.md +588 -489
  3. package/codemini-web/dist/assets/{highlighted-body-OFNGDK62-HgeDi9HJ.js → highlighted-body-OFNGDK62-CANOG7Xg.js} +1 -1
  4. package/codemini-web/dist/assets/{index-C4tKT3v4.js → index-B71xykPM.js} +108 -108
  5. package/codemini-web/dist/assets/index-Dkq1DdDX.css +2 -0
  6. package/codemini-web/dist/assets/mermaid-GHXKKRXX-Z_w7M93P.js +1 -0
  7. package/codemini-web/dist/index.html +23 -23
  8. package/codemini-web/lib/approval-manager.js +32 -32
  9. package/codemini-web/lib/runtime-bridge.js +17 -11
  10. package/codemini-web/server.js +534 -205
  11. package/deployment.md +212 -212
  12. package/package.json +1 -1
  13. package/skills/brainstorm/SKILL.md +77 -72
  14. package/skills/codemini.skills.json +40 -40
  15. package/skills/grill-me/SKILL.md +30 -30
  16. package/skills/superpowers-lite/SKILL.md +82 -82
  17. package/src/cli.js +74 -74
  18. package/src/commands/chat.js +210 -210
  19. package/src/commands/run.js +313 -313
  20. package/src/commands/skill.js +438 -304
  21. package/src/commands/web.js +57 -57
  22. package/src/core/agent-loop.js +980 -980
  23. package/src/core/ast.js +309 -292
  24. package/src/core/chat-runtime.js +6261 -6240
  25. package/src/core/command-evaluator.js +72 -72
  26. package/src/core/command-loader.js +311 -311
  27. package/src/core/command-policy.js +301 -301
  28. package/src/core/command-risk.js +156 -156
  29. package/src/core/config-store.js +289 -287
  30. package/src/core/constants.js +18 -1
  31. package/src/core/context-compact.js +365 -365
  32. package/src/core/default-system-prompt.js +114 -107
  33. package/src/core/dream-audit.js +105 -105
  34. package/src/core/dream-consolidate.js +229 -229
  35. package/src/core/dream-evaluator.js +185 -185
  36. package/src/core/fff-adapter.js +383 -383
  37. package/src/core/memory-store.js +543 -543
  38. package/src/core/project-index.js +737 -529
  39. package/src/core/project-instructions.js +98 -0
  40. package/src/core/provider/anthropic.js +514 -514
  41. package/src/core/provider/openai-compatible.js +501 -501
  42. package/src/core/reflect-skill.js +178 -178
  43. package/src/core/reply-language.js +40 -40
  44. package/src/core/session-store.js +474 -474
  45. package/src/core/shell-profile.js +237 -237
  46. package/src/core/shell.js +323 -317
  47. package/src/core/soul.js +69 -69
  48. package/src/core/system-prompt-composer.js +52 -42
  49. package/src/core/tool-args.js +199 -154
  50. package/src/core/tool-output.js +184 -184
  51. package/src/core/tool-result-store.js +206 -206
  52. package/src/core/tools.js +3024 -2893
  53. package/src/core/version.js +11 -11
  54. package/src/tui/chat-app.js +5171 -5171
  55. package/src/tui/tool-activity/presenters/misc.js +30 -30
  56. package/src/tui/tool-activity/presenters/system.js +20 -20
  57. package/templates/project-requirements/report-shell.html +582 -582
  58. package/codemini-web/dist/assets/index-BSdIdn3L.css +0 -2
  59. package/codemini-web/dist/assets/mermaid-GHXKKRXX-CDgkkDBg.js +0 -1
@@ -1,57 +1,57 @@
1
- import { spawn } from 'node:child_process';
2
- import fs from 'node:fs';
3
- import path from 'node:path';
4
- import { fileURLToPath } from 'node:url';
5
-
6
- const __dirname = path.dirname(fileURLToPath(import.meta.url));
7
- const ROOT_DIR = path.resolve(__dirname, '../..');
8
- const WEB_SERVER = path.join(ROOT_DIR, 'codemini-web', 'server.js');
9
- const WEB_DIST_INDEX = path.join(ROOT_DIR, 'codemini-web', 'dist', 'index.html');
10
-
11
- function printWebHelp() {
12
- console.log(`Usage:
13
- codemini web [--port <port>] [--project <path>] [--session <id>] [--model <name>] [--no-open]
14
- codemini --web [--port <port>] [--project <path>] [--session <id>] [--model <name>] [--no-open]
15
-
16
- Options:
17
- --port, -p Port for the local Web UI server (default: 3210)
18
- --project, -d Project directory to open first
19
- --session, -s Existing session id to load
20
- --model, -m Override model for this Web UI runtime
21
- --no-open Start the server without opening a browser`);
22
- }
23
-
24
- export async function handleWeb(args = []) {
25
- if (args.includes('--help') || args.includes('-h')) {
26
- printWebHelp();
27
- return;
28
- }
29
-
30
- if (!fs.existsSync(WEB_SERVER)) {
31
- throw new Error('Web UI server is missing from this installation.');
32
- }
33
-
34
- if (!fs.existsSync(WEB_DIST_INDEX)) {
35
- console.warn('codemini warning: built Web UI assets were not found; run the package build before publishing.');
36
- }
37
-
38
- await new Promise((resolve, reject) => {
39
- const child = spawn(process.execPath, [WEB_SERVER, ...args], {
40
- cwd: process.cwd(),
41
- stdio: 'inherit'
42
- });
43
-
44
- child.on('error', reject);
45
- child.on('exit', (code, signal) => {
46
- if (signal) {
47
- resolve();
48
- return;
49
- }
50
- if (code && code !== 0) {
51
- reject(new Error(`Web UI exited with code ${code}`));
52
- return;
53
- }
54
- resolve();
55
- });
56
- });
57
- }
1
+ import { spawn } from 'node:child_process';
2
+ import fs from 'node:fs';
3
+ import path from 'node:path';
4
+ import { fileURLToPath } from 'node:url';
5
+
6
+ const __dirname = path.dirname(fileURLToPath(import.meta.url));
7
+ const ROOT_DIR = path.resolve(__dirname, '../..');
8
+ const WEB_SERVER = path.join(ROOT_DIR, 'codemini-web', 'server.js');
9
+ const WEB_DIST_INDEX = path.join(ROOT_DIR, 'codemini-web', 'dist', 'index.html');
10
+
11
+ function printWebHelp() {
12
+ console.log(`Usage:
13
+ codemini web [--port <port>] [--project <path>] [--session <id>] [--model <name>] [--no-open]
14
+ codemini --web [--port <port>] [--project <path>] [--session <id>] [--model <name>] [--no-open]
15
+
16
+ Options:
17
+ --port, -p Port for the local Web UI server (default: 3210)
18
+ --project, -d Project directory to open first
19
+ --session, -s Existing session id to load
20
+ --model, -m Override model for this Web UI runtime
21
+ --no-open Start the server without opening a browser`);
22
+ }
23
+
24
+ export async function handleWeb(args = []) {
25
+ if (args.includes('--help') || args.includes('-h')) {
26
+ printWebHelp();
27
+ return;
28
+ }
29
+
30
+ if (!fs.existsSync(WEB_SERVER)) {
31
+ throw new Error('Web UI server is missing from this installation.');
32
+ }
33
+
34
+ if (!fs.existsSync(WEB_DIST_INDEX)) {
35
+ console.warn('codemini warning: built Web UI assets were not found; run the package build before publishing.');
36
+ }
37
+
38
+ await new Promise((resolve, reject) => {
39
+ const child = spawn(process.execPath, [WEB_SERVER, ...args], {
40
+ cwd: process.cwd(),
41
+ stdio: 'inherit'
42
+ });
43
+
44
+ child.on('error', reject);
45
+ child.on('exit', (code, signal) => {
46
+ if (signal) {
47
+ resolve();
48
+ return;
49
+ }
50
+ if (code && code !== 0) {
51
+ reject(new Error(`Web UI exited with code ${code}`));
52
+ return;
53
+ }
54
+ resolve();
55
+ });
56
+ });
57
+ }