ccg-workflow 1.7.26 → 1.7.28

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.
Binary file
Binary file
Binary file
Binary file
package/dist/cli.mjs CHANGED
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  import cac from 'cac';
3
3
  import ansis from 'ansis';
4
- import { y as diagnoseMcpConfig, z as isWindows, A as readClaudeCodeConfig, B as fixWindowsMcpConfig, C as writeClaudeCodeConfig, r as readCcgConfig, b as initI18n, s as showMainMenu, i as init, D as configMcp, E as version, a as i18n } from './shared/ccg-workflow.CqFZ5tot.mjs';
4
+ import { y as diagnoseMcpConfig, z as isWindows, A as readClaudeCodeConfig, B as fixWindowsMcpConfig, C as writeClaudeCodeConfig, r as readCcgConfig, b as initI18n, s as showMainMenu, i as init, D as configMcp, E as version, a as i18n } from './shared/ccg-workflow.CJ9Z7dUF.mjs';
5
5
  import 'inquirer';
6
6
  import 'node:child_process';
7
7
  import 'node:util';
package/dist/index.d.mts CHANGED
@@ -52,6 +52,9 @@ interface CcgConfig {
52
52
  provider: string;
53
53
  setup_url: string;
54
54
  };
55
+ performance?: {
56
+ liteMode?: boolean;
57
+ };
55
58
  }
56
59
  interface WorkflowConfig {
57
60
  id: string;
@@ -111,6 +114,7 @@ declare function createDefaultConfig(options: {
111
114
  routing: ModelRouting;
112
115
  installedWorkflows: string[];
113
116
  mcpProvider?: string;
117
+ liteMode?: boolean;
114
118
  }): CcgConfig;
115
119
  declare function createDefaultRouting(): ModelRouting;
116
120
 
@@ -131,6 +135,7 @@ declare function installWorkflows(workflowIds: string[], installDir: string, for
131
135
  models?: string[];
132
136
  };
133
137
  };
138
+ liteMode?: boolean;
134
139
  }): Promise<InstallResult>;
135
140
  /**
136
141
  * Install and configure ace-tool MCP for Claude Code
package/dist/index.d.ts CHANGED
@@ -52,6 +52,9 @@ interface CcgConfig {
52
52
  provider: string;
53
53
  setup_url: string;
54
54
  };
55
+ performance?: {
56
+ liteMode?: boolean;
57
+ };
55
58
  }
56
59
  interface WorkflowConfig {
57
60
  id: string;
@@ -111,6 +114,7 @@ declare function createDefaultConfig(options: {
111
114
  routing: ModelRouting;
112
115
  installedWorkflows: string[];
113
116
  mcpProvider?: string;
117
+ liteMode?: boolean;
114
118
  }): CcgConfig;
115
119
  declare function createDefaultRouting(): ModelRouting;
116
120
 
@@ -131,6 +135,7 @@ declare function installWorkflows(workflowIds: string[], installDir: string, for
131
135
  models?: string[];
132
136
  };
133
137
  };
138
+ liteMode?: boolean;
134
139
  }): Promise<InstallResult>;
135
140
  /**
136
141
  * Install and configure ace-tool MCP for Claude Code
package/dist/index.mjs CHANGED
@@ -1,4 +1,4 @@
1
- export { c as changeLanguage, v as checkForUpdates, x as compareVersions, d as createDefaultConfig, e as createDefaultRouting, g as getCcgDir, f as getConfigPath, q as getCurrentVersion, t as getLatestVersion, j as getWorkflowById, h as getWorkflowConfigs, a as i18n, i as init, b as initI18n, l as installAceTool, k as installWorkflows, o as migrateToV1_4_0, p as needsMigration, r as readCcgConfig, s as showMainMenu, n as uninstallAceTool, m as uninstallWorkflows, u as update, w as writeCcgConfig } from './shared/ccg-workflow.CqFZ5tot.mjs';
1
+ export { c as changeLanguage, v as checkForUpdates, x as compareVersions, d as createDefaultConfig, e as createDefaultRouting, g as getCcgDir, f as getConfigPath, q as getCurrentVersion, t as getLatestVersion, j as getWorkflowById, h as getWorkflowConfigs, a as i18n, i as init, b as initI18n, l as installAceTool, k as installWorkflows, o as migrateToV1_4_0, p as needsMigration, r as readCcgConfig, s as showMainMenu, n as uninstallAceTool, m as uninstallWorkflows, u as update, w as writeCcgConfig } from './shared/ccg-workflow.CJ9Z7dUF.mjs';
2
2
  import 'ansis';
3
3
  import 'inquirer';
4
4
  import 'node:child_process';
@@ -10,7 +10,7 @@ import i18next from 'i18next';
10
10
  import ora from 'ora';
11
11
  import { parse, stringify } from 'smol-toml';
12
12
 
13
- const version = "1.7.26";
13
+ const version = "1.7.28";
14
14
 
15
15
  function isWindows() {
16
16
  return process.platform === "win32";
@@ -365,6 +365,8 @@ function injectConfigVariables(content, config) {
365
365
  processed = processed.replace(/\{\{REVIEW_MODELS\}\}/g, JSON.stringify(reviewModels));
366
366
  const routingMode = routing.mode || "smart";
367
367
  processed = processed.replace(/\{\{ROUTING_MODE\}\}/g, routingMode);
368
+ const liteModeFlag = config.liteMode ? "--lite " : "";
369
+ processed = processed.replace(/\{\{LITE_MODE_FLAG\}\}/g, liteModeFlag);
368
370
  return processed;
369
371
  }
370
372
  function replaceHomePathsInTemplate(content, installDir) {
@@ -390,7 +392,8 @@ async function installWorkflows(workflowIds, installDir, force = false, config)
390
392
  frontend: { models: ["gemini"], primary: "gemini" },
391
393
  backend: { models: ["codex"], primary: "codex" },
392
394
  review: { models: ["codex", "gemini"] }
393
- }
395
+ },
396
+ liteMode: config?.liteMode || false
394
397
  };
395
398
  const result = {
396
399
  success: true,
@@ -1196,6 +1199,9 @@ function createDefaultConfig(options) {
1196
1199
  mcp: {
1197
1200
  provider: options.mcpProvider || "ace-tool",
1198
1201
  setup_url: "https://augmentcode.com/"
1202
+ },
1203
+ performance: {
1204
+ liteMode: options.liteMode || false
1199
1205
  }
1200
1206
  };
1201
1207
  }
@@ -1312,11 +1318,16 @@ async function init(options = {}) {
1312
1318
  const backendModels = ["codex"];
1313
1319
  const mode = "smart";
1314
1320
  const selectedWorkflows = getAllCommandIds();
1321
+ let liteMode = false;
1315
1322
  let mcpProvider = "ace-tool";
1316
1323
  let aceToolBaseUrl = "";
1317
1324
  let aceToolToken = "";
1318
1325
  if (options.skipMcp) {
1319
1326
  mcpProvider = "skip";
1327
+ const existingConfig = await readCcgConfig();
1328
+ if (existingConfig?.performance?.liteMode !== void 0) {
1329
+ liteMode = existingConfig.performance.liteMode;
1330
+ }
1320
1331
  } else if (!options.skipPrompt) {
1321
1332
  console.log();
1322
1333
  console.log(ansis.cyan.bold(` \u{1F527} MCP \u5DE5\u5177\u914D\u7F6E`));
@@ -1390,6 +1401,14 @@ async function init(options = {}) {
1390
1401
  console.log(ansis.gray(` \u2022 \u53EF\u7A0D\u540E\u624B\u52A8\u914D\u7F6E\u4EFB\u4F55 MCP \u670D\u52A1`));
1391
1402
  console.log();
1392
1403
  }
1404
+ console.log();
1405
+ const { enableWebUI } = await inquirer.prompt([{
1406
+ type: "confirm",
1407
+ name: "enableWebUI",
1408
+ message: `\u542F\u7528 Web UI \u5B9E\u65F6\u8F93\u51FA\uFF1F${ansis.gray("(\u7981\u7528\u53EF\u52A0\u901F\u54CD\u5E94)")}`,
1409
+ default: true
1410
+ }]);
1411
+ liteMode = !enableWebUI;
1393
1412
  }
1394
1413
  const routing = {
1395
1414
  frontend: {
@@ -1415,6 +1434,7 @@ async function init(options = {}) {
1415
1434
  console.log(` ${ansis.cyan("\u6A21\u578B\u8DEF\u7531")} ${ansis.green("Gemini")} (\u524D\u7AEF) + ${ansis.blue("Codex")} (\u540E\u7AEF)`);
1416
1435
  console.log(` ${ansis.cyan("\u547D\u4EE4\u6570\u91CF")} ${ansis.yellow(selectedWorkflows.length.toString())} \u4E2A`);
1417
1436
  console.log(` ${ansis.cyan("MCP \u5DE5\u5177")} ${mcpProvider === "ace-tool" ? aceToolToken ? ansis.green("ace-tool") : ansis.yellow("ace-tool (\u5F85\u914D\u7F6E)") : ansis.gray("\u8DF3\u8FC7")}`);
1437
+ console.log(` ${ansis.cyan("Web UI")} ${liteMode ? ansis.gray("\u7981\u7528") : ansis.green("\u542F\u7528")}`);
1418
1438
  console.log(ansis.yellow("\u2501".repeat(50)));
1419
1439
  console.log();
1420
1440
  if (!options.skipPrompt) {
@@ -1464,12 +1484,14 @@ async function init(options = {}) {
1464
1484
  language,
1465
1485
  routing,
1466
1486
  installedWorkflows: selectedWorkflows,
1467
- mcpProvider
1487
+ mcpProvider,
1488
+ liteMode
1468
1489
  });
1469
1490
  await writeCcgConfig(config);
1470
1491
  const installDir = options.installDir || join(homedir(), ".claude");
1471
1492
  const result = await installWorkflows(selectedWorkflows, installDir, options.force, {
1472
- routing
1493
+ routing,
1494
+ liteMode
1473
1495
  });
1474
1496
  if (mcpProvider === "ace-tool" && aceToolToken) {
1475
1497
  spinner.text = i18n.t("init:aceTool.installing");
@@ -1797,7 +1819,7 @@ async function performUpdate(fromVersion, toVersion, isNewVersion) {
1797
1819
  }
1798
1820
  spinner = ora("\u6B63\u5728\u5B89\u88C5\u65B0\u7248\u672C\u5DE5\u4F5C\u6D41\u548C\u4E8C\u8FDB\u5236...").start();
1799
1821
  try {
1800
- await execAsync$1(`npx --yes ccg-workflow@latest init --force --skip-mcp`, {
1822
+ await execAsync$1(`npx --yes ccg-workflow@latest init --force --skip-mcp --skip-prompt`, {
1801
1823
  timeout: 12e4,
1802
1824
  env: {
1803
1825
  ...process.env,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ccg-workflow",
3
- "version": "1.7.26",
3
+ "version": "1.7.28",
4
4
  "description": "Claude-Codex-Gemini 多模型协作系统 - 智能路由多模型开发工作流",
5
5
  "type": "module",
6
6
  "packageManager": "pnpm@10.17.1",
@@ -28,7 +28,7 @@ description: '多模型技术分析(并行执行):Codex 后端视角 + Gem
28
28
 
29
29
  ```
30
30
  Bash({
31
- command: "~/.claude/bin/codeagent-wrapper --backend <codex|gemini> - \"$PWD\" <<'EOF'
31
+ command: "~/.claude/bin/codeagent-wrapper {{LITE_MODE_FLAG}}--backend <codex|gemini> - \"$PWD\" <<'EOF'
32
32
  ROLE_FILE: <角色提示词路径>
33
33
  <TASK>
34
34
  需求:<增强后的需求(如未增强则用 $ARGUMENTS)>
@@ -34,7 +34,7 @@ description: '后端专项工作流(研究→构思→计划→执行→优化
34
34
  ```
35
35
  # 新会话调用
36
36
  Bash({
37
- command: "~/.claude/bin/codeagent-wrapper --backend codex - \"$PWD\" <<'EOF'
37
+ command: "~/.claude/bin/codeagent-wrapper {{LITE_MODE_FLAG}}--backend codex - \"$PWD\" <<'EOF'
38
38
  ROLE_FILE: <角色提示词路径>
39
39
  <TASK>
40
40
  需求:<增强后的需求(如未增强则用 $ARGUMENTS)>
@@ -49,7 +49,7 @@ EOF",
49
49
 
50
50
  # 复用会话调用
51
51
  Bash({
52
- command: "~/.claude/bin/codeagent-wrapper --backend codex resume <SESSION_ID> - \"$PWD\" <<'EOF'
52
+ command: "~/.claude/bin/codeagent-wrapper {{LITE_MODE_FLAG}}--backend codex resume <SESSION_ID> - \"$PWD\" <<'EOF'
53
53
  ROLE_FILE: <角色提示词路径>
54
54
  <TASK>
55
55
  需求:<增强后的需求(如未增强则用 $ARGUMENTS)>
@@ -27,7 +27,7 @@ description: '多模型调试:Codex 后端诊断 + Gemini 前端诊断,交
27
27
 
28
28
  ```
29
29
  Bash({
30
- command: "~/.claude/bin/codeagent-wrapper --backend <codex|gemini> - \"$PWD\" <<'EOF'
30
+ command: "~/.claude/bin/codeagent-wrapper {{LITE_MODE_FLAG}}--backend <codex|gemini> - \"$PWD\" <<'EOF'
31
31
  <TASK>
32
32
  需求:<增强后的需求(如未增强则用 $ARGUMENTS)>
33
33
  上下文:<错误日志、堆栈信息、复现步骤等>
@@ -15,7 +15,7 @@ $ARGUMENTS
15
15
  ```
16
16
  # 新会话调用
17
17
  Bash({
18
- command: "~/.claude/bin/codeagent-wrapper --backend <codex|gemini> - \"$PWD\" <<'EOF'
18
+ command: "~/.claude/bin/codeagent-wrapper {{LITE_MODE_FLAG}}--backend <codex|gemini> - \"$PWD\" <<'EOF'
19
19
  ROLE_FILE: <角色提示词路径>
20
20
  <TASK>
21
21
  需求:<增强后的需求(如未增强则用 $ARGUMENTS)>
@@ -30,7 +30,7 @@ EOF",
30
30
 
31
31
  # 复用会话调用
32
32
  Bash({
33
- command: "~/.claude/bin/codeagent-wrapper --backend <codex|gemini> resume <SESSION_ID> - \"$PWD\" <<'EOF'
33
+ command: "~/.claude/bin/codeagent-wrapper {{LITE_MODE_FLAG}}--backend <codex|gemini> resume <SESSION_ID> - \"$PWD\" <<'EOF'
34
34
  ROLE_FILE: <角色提示词路径>
35
35
  <TASK>
36
36
  需求:<增强后的需求(如未增强则用 $ARGUMENTS)>
@@ -34,7 +34,7 @@ description: '前端专项工作流(研究→构思→计划→执行→优化
34
34
  ```
35
35
  # 新会话调用
36
36
  Bash({
37
- command: "~/.claude/bin/codeagent-wrapper --backend gemini - \"$PWD\" <<'EOF'
37
+ command: "~/.claude/bin/codeagent-wrapper {{LITE_MODE_FLAG}}--backend gemini - \"$PWD\" <<'EOF'
38
38
  ROLE_FILE: <角色提示词路径>
39
39
  <TASK>
40
40
  需求:<增强后的需求(如未增强则用 $ARGUMENTS)>
@@ -49,7 +49,7 @@ EOF",
49
49
 
50
50
  # 复用会话调用
51
51
  Bash({
52
- command: "~/.claude/bin/codeagent-wrapper --backend gemini resume <SESSION_ID> - \"$PWD\" <<'EOF'
52
+ command: "~/.claude/bin/codeagent-wrapper {{LITE_MODE_FLAG}}--backend gemini resume <SESSION_ID> - \"$PWD\" <<'EOF'
53
53
  ROLE_FILE: <角色提示词路径>
54
54
  <TASK>
55
55
  需求:<增强后的需求(如未增强则用 $ARGUMENTS)>
@@ -33,7 +33,7 @@ description: '多模型性能优化:Codex 后端优化 + Gemini 前端优化'
33
33
 
34
34
  ```
35
35
  Bash({
36
- command: "~/.claude/bin/codeagent-wrapper --backend <codex|gemini> - \"$PWD\" <<'EOF'
36
+ command: "~/.claude/bin/codeagent-wrapper {{LITE_MODE_FLAG}}--backend <codex|gemini> - \"$PWD\" <<'EOF'
37
37
  <TASK>
38
38
  需求:<增强后的需求(如未增强则用 $ARGUMENTS)>
39
39
  上下文:<目标代码、现有性能指标等>
@@ -23,7 +23,7 @@ description: '多模型代码审查:无参数时自动审查 git diff,双模
23
23
 
24
24
  ```
25
25
  Bash({
26
- command: "~/.claude/bin/codeagent-wrapper --backend <codex|gemini> - \"$PWD\" <<'EOF'
26
+ command: "~/.claude/bin/codeagent-wrapper {{LITE_MODE_FLAG}}--backend <codex|gemini> - \"$PWD\" <<'EOF'
27
27
  <TASK>
28
28
  审查以下代码变更:
29
29
  <git diff 内容>
@@ -33,7 +33,7 @@ description: '多模型测试生成:智能路由 Codex 后端测试 / Gemini
33
33
 
34
34
  ```
35
35
  Bash({
36
- command: "~/.claude/bin/codeagent-wrapper --backend <codex|gemini> - \"$PWD\" <<'EOF'
36
+ command: "~/.claude/bin/codeagent-wrapper {{LITE_MODE_FLAG}}--backend <codex|gemini> - \"$PWD\" <<'EOF'
37
37
  <TASK>
38
38
  需求:为以下代码生成测试
39
39
  <代码内容>
@@ -38,7 +38,7 @@ description: '多模型协作开发工作流(研究→构思→计划→执行
38
38
  ```
39
39
  # 新会话调用
40
40
  Bash({
41
- command: "~/.claude/bin/codeagent-wrapper --backend <codex|gemini> - \"$PWD\" <<'EOF'
41
+ command: "~/.claude/bin/codeagent-wrapper {{LITE_MODE_FLAG}}--backend <codex|gemini> - \"$PWD\" <<'EOF'
42
42
  ROLE_FILE: <角色提示词路径>
43
43
  <TASK>
44
44
  需求:<增强后的需求(如未增强则用 $ARGUMENTS)>
@@ -53,7 +53,7 @@ EOF",
53
53
 
54
54
  # 复用会话调用
55
55
  Bash({
56
- command: "~/.claude/bin/codeagent-wrapper --backend <codex|gemini> resume <SESSION_ID> - \"$PWD\" <<'EOF'
56
+ command: "~/.claude/bin/codeagent-wrapper {{LITE_MODE_FLAG}}--backend <codex|gemini> resume <SESSION_ID> - \"$PWD\" <<'EOF'
57
57
  ROLE_FILE: <角色提示词路径>
58
58
  <TASK>
59
59
  需求:<增强后的需求(如未增强则用 $ARGUMENTS)>