happy-imou-cloud 2.0.17 → 2.0.18

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 (26) hide show
  1. package/dist/{BaseReasoningProcessor-wqWUBiEJ.mjs → BaseReasoningProcessor-DajL_jtA.mjs} +3 -3
  2. package/dist/{BaseReasoningProcessor-BdbyUAZR.cjs → BaseReasoningProcessor-DrAN-2bw.cjs} +3 -3
  3. package/dist/{ProviderSelectionHandler-GuW6S0tQ.cjs → ProviderSelectionHandler-BOAcP_CE.cjs} +2 -2
  4. package/dist/{ProviderSelectionHandler-oz9NjR_r.mjs → ProviderSelectionHandler-DiHuEbf_.mjs} +2 -2
  5. package/dist/{api-D7DleJYY.mjs → api-DLI3Zloa.mjs} +2 -2
  6. package/dist/{api-BZ2U3k-r.cjs → api-eDp10nsY.cjs} +2 -2
  7. package/dist/{command-D-GEzmAl.cjs → command-BJu-MaCp.cjs} +3 -3
  8. package/dist/{command-DsMlcxQd.mjs → command-BYxsn0_c.mjs} +3 -3
  9. package/dist/{index-Cdi5KxhK.mjs → index-CjWtQyJu.mjs} +8 -8
  10. package/dist/{index-sJfKgN1y.cjs → index-bzGCZJLB.cjs} +11 -11
  11. package/dist/index.cjs +3 -3
  12. package/dist/index.mjs +3 -3
  13. package/dist/lib.cjs +1 -1
  14. package/dist/lib.mjs +1 -1
  15. package/dist/{persistence-JEXs_kBA.cjs → persistence-CSaoFYvt.cjs} +1 -1
  16. package/dist/{persistence-C0nC4mEU.mjs → persistence-DicQpgl6.mjs} +1 -1
  17. package/dist/{registerKillSessionHandler-BRfDcq3x.mjs → registerKillSessionHandler-BWCjaf5S.mjs} +3 -3
  18. package/dist/{registerKillSessionHandler-Qw8jZB2x.cjs → registerKillSessionHandler-BeMsOt9D.cjs} +3 -3
  19. package/dist/{runClaude-B6fsu9Sl.mjs → runClaude-BaDVGV4k.mjs} +5 -5
  20. package/dist/{runClaude-pSj5zGWV.cjs → runClaude-CERpGT0L.cjs} +5 -5
  21. package/dist/{runCodex-DJrzw9x8.mjs → runCodex-Bik9wE7F.mjs} +24 -9
  22. package/dist/{runCodex-ClpKXo66.cjs → runCodex-Z12g3g5P.cjs} +24 -9
  23. package/dist/{runGemini-C7xlDIfO.mjs → runGemini-Bh59hP_q.mjs} +5 -5
  24. package/dist/{runGemini-DA5v_0X_.cjs → runGemini-Chas-o_m.cjs} +5 -5
  25. package/package.json +1 -1
  26. package/scripts/release-smoke.mjs +14 -14
@@ -1,6 +1,6 @@
1
- import { p as publishSessionRegistration } from './index-Cdi5KxhK.mjs';
2
- import { s as startOfflineReconnection, c as configuration, i as isAuthenticationRequiredError, l as logger } from './api-D7DleJYY.mjs';
3
- import { c as createSessionMetadata } from './registerKillSessionHandler-BRfDcq3x.mjs';
1
+ import { p as publishSessionRegistration } from './index-CjWtQyJu.mjs';
2
+ import { s as startOfflineReconnection, c as configuration, i as isAuthenticationRequiredError, l as logger } from './api-DLI3Zloa.mjs';
3
+ import { c as createSessionMetadata } from './registerKillSessionHandler-BWCjaf5S.mjs';
4
4
  import { EventEmitter } from 'node:events';
5
5
  import { randomUUID } from 'node:crypto';
6
6
 
@@ -1,8 +1,8 @@
1
1
  'use strict';
2
2
 
3
- var index = require('./index-sJfKgN1y.cjs');
4
- var api = require('./api-BZ2U3k-r.cjs');
5
- var registerKillSessionHandler = require('./registerKillSessionHandler-Qw8jZB2x.cjs');
3
+ var index = require('./index-bzGCZJLB.cjs');
4
+ var api = require('./api-eDp10nsY.cjs');
5
+ var registerKillSessionHandler = require('./registerKillSessionHandler-BeMsOt9D.cjs');
6
6
  var node_events = require('node:events');
7
7
  var node_crypto = require('node:crypto');
8
8
 
@@ -1,7 +1,7 @@
1
1
  'use strict';
2
2
 
3
- var api = require('./api-BZ2U3k-r.cjs');
4
- var registerKillSessionHandler = require('./registerKillSessionHandler-Qw8jZB2x.cjs');
3
+ var api = require('./api-eDp10nsY.cjs');
4
+ var registerKillSessionHandler = require('./registerKillSessionHandler-BeMsOt9D.cjs');
5
5
 
6
6
  async function runModeLoop(opts) {
7
7
  let currentMode = opts.startingMode;
@@ -1,5 +1,5 @@
1
- import { l as logger } from './api-D7DleJYY.mjs';
2
- import { g as getPendingInteractionTimeoutMs, I as INTERACTION_SUPERSEDED_ERROR, a as INTERACTION_TIMED_OUT_ERROR } from './registerKillSessionHandler-BRfDcq3x.mjs';
1
+ import { l as logger } from './api-DLI3Zloa.mjs';
2
+ import { g as getPendingInteractionTimeoutMs, I as INTERACTION_SUPERSEDED_ERROR, a as INTERACTION_TIMED_OUT_ERROR } from './registerKillSessionHandler-BWCjaf5S.mjs';
3
3
 
4
4
  async function runModeLoop(opts) {
5
5
  let currentMode = opts.startingMode;
@@ -16,7 +16,7 @@ import { spawn } from 'node:child_process';
16
16
  import { Expo } from 'expo-server-sdk';
17
17
 
18
18
  var name = "happy-imou-cloud";
19
- var version = "2.0.17";
19
+ var version = "2.0.18";
20
20
  var description = "hicloud - Imou 企业定制版。关键是 happy!移动端远程 AI 编程工具,支持 Claude Code、Codex 和 Gemini CLI";
21
21
  var author = "long.zhu";
22
22
  var license = "MIT";
@@ -430,7 +430,7 @@ async function listDaemonLogFiles(limit = 50) {
430
430
  return { file, path: fullPath, modified: stats.mtime };
431
431
  }).sort((a, b) => b.modified.getTime() - a.modified.getTime());
432
432
  try {
433
- const { readDaemonState } = await import('./persistence-C0nC4mEU.mjs');
433
+ const { readDaemonState } = await import('./persistence-DicQpgl6.mjs');
434
434
  const state = await readDaemonState();
435
435
  if (!state) {
436
436
  return logs;
@@ -18,7 +18,7 @@ var node_child_process = require('node:child_process');
18
18
  var expoServerSdk = require('expo-server-sdk');
19
19
 
20
20
  var name = "happy-imou-cloud";
21
- var version = "2.0.17";
21
+ var version = "2.0.18";
22
22
  var description = "hicloud - Imou 企业定制版。关键是 happy!移动端远程 AI 编程工具,支持 Claude Code、Codex 和 Gemini CLI";
23
23
  var author = "long.zhu";
24
24
  var license = "MIT";
@@ -432,7 +432,7 @@ async function listDaemonLogFiles(limit = 50) {
432
432
  return { file, path: fullPath, modified: stats.mtime };
433
433
  }).sort((a, b) => b.modified.getTime() - a.modified.getTime());
434
434
  try {
435
- const { readDaemonState } = await Promise.resolve().then(function () { return require('./persistence-JEXs_kBA.cjs'); });
435
+ const { readDaemonState } = await Promise.resolve().then(function () { return require('./persistence-CSaoFYvt.cjs'); });
436
436
  const state = await readDaemonState();
437
437
  if (!state) {
438
438
  return logs;
@@ -1,8 +1,8 @@
1
1
  'use strict';
2
2
 
3
- var index = require('./index-sJfKgN1y.cjs');
3
+ var index = require('./index-bzGCZJLB.cjs');
4
4
  require('chalk');
5
- require('./api-BZ2U3k-r.cjs');
5
+ require('./api-eDp10nsY.cjs');
6
6
  require('axios');
7
7
  require('fs');
8
8
  require('node:fs');
@@ -18,7 +18,7 @@ require('crypto');
18
18
  require('path');
19
19
  require('node:child_process');
20
20
  require('expo-server-sdk');
21
- require('./persistence-JEXs_kBA.cjs');
21
+ require('./persistence-CSaoFYvt.cjs');
22
22
  require('node:fs/promises');
23
23
  require('os');
24
24
  require('tmp');
@@ -1,6 +1,6 @@
1
- import { c as createDefaultRuntimeShell } from './index-Cdi5KxhK.mjs';
1
+ import { c as createDefaultRuntimeShell } from './index-CjWtQyJu.mjs';
2
2
  import 'chalk';
3
- import './api-D7DleJYY.mjs';
3
+ import './api-DLI3Zloa.mjs';
4
4
  import 'axios';
5
5
  import 'fs';
6
6
  import 'node:fs';
@@ -16,7 +16,7 @@ import 'crypto';
16
16
  import 'path';
17
17
  import 'node:child_process';
18
18
  import 'expo-server-sdk';
19
- import './persistence-C0nC4mEU.mjs';
19
+ import './persistence-DicQpgl6.mjs';
20
20
  import 'node:fs/promises';
21
21
  import 'os';
22
22
  import 'tmp';
@@ -1,6 +1,6 @@
1
1
  import{createRequire as _pkgrollCR}from"node:module";const require=_pkgrollCR(import.meta.url);import chalk from 'chalk';
2
- import { l as logger, e as encodeBase64, c as configuration, h as buildAuthenticatedHeaders, S as SigningBootstrapRequiredError, j as SIGNING_BOOTSTRAP_REQUIRED_MESSAGE, k as encodeBase64Url, f as delay, m as buildClientHeaders, n as decodeBase64, H as HAPPY_CLOUD_DAEMON_PORT, p as packageJson, A as ApiClient, o as HeadTailPreviewBuffer, q as getLatestDaemonLog } from './api-D7DleJYY.mjs';
3
- import { writeCredentialsLegacy, writeCredentialsDataKey, readCredentials, readSettings, updateSettings, readDaemonState, clearDaemonState, acquireDaemonLock, writeDaemonState, releaseDaemonLock, validateProfileForAgent, getProfileEnvironmentVariables, clearCredentials, clearMachineId } from './persistence-C0nC4mEU.mjs';
2
+ import { l as logger, e as encodeBase64, c as configuration, h as buildAuthenticatedHeaders, S as SigningBootstrapRequiredError, j as SIGNING_BOOTSTRAP_REQUIRED_MESSAGE, k as encodeBase64Url, f as delay, m as buildClientHeaders, n as decodeBase64, H as HAPPY_CLOUD_DAEMON_PORT, p as packageJson, A as ApiClient, o as HeadTailPreviewBuffer, q as getLatestDaemonLog } from './api-DLI3Zloa.mjs';
3
+ import { writeCredentialsLegacy, writeCredentialsDataKey, readCredentials, readSettings, updateSettings, readDaemonState, clearDaemonState, acquireDaemonLock, writeDaemonState, releaseDaemonLock, validateProfileForAgent, getProfileEnvironmentVariables, clearCredentials, clearMachineId } from './persistence-DicQpgl6.mjs';
4
4
  import { z } from 'zod';
5
5
  import fs, { writeFile as writeFile$1, rename, unlink as unlink$1 } from 'fs/promises';
6
6
  import os, { homedir } from 'os';
@@ -8755,11 +8755,11 @@ var launch = /*#__PURE__*/Object.freeze({
8755
8755
 
8756
8756
  const unifiedProviderExecutors = {
8757
8757
  claude: async (opts) => {
8758
- const { runClaude } = await import('./runClaude-B6fsu9Sl.mjs');
8758
+ const { runClaude } = await import('./runClaude-BaDVGV4k.mjs');
8759
8759
  await runClaude(opts.credentials, opts.claudeOptions ?? {});
8760
8760
  },
8761
8761
  codex: async (opts) => {
8762
- const { runCodex } = await import('./runCodex-DJrzw9x8.mjs');
8762
+ const { runCodex } = await import('./runCodex-Bik9wE7F.mjs');
8763
8763
  await runCodex({
8764
8764
  credentials: opts.credentials,
8765
8765
  startedBy: opts.startedBy,
@@ -8768,7 +8768,7 @@ const unifiedProviderExecutors = {
8768
8768
  });
8769
8769
  },
8770
8770
  gemini: async (opts) => {
8771
- const { runGemini } = await import('./runGemini-C7xlDIfO.mjs');
8771
+ const { runGemini } = await import('./runGemini-Bh59hP_q.mjs');
8772
8772
  await runGemini({
8773
8773
  credentials: opts.credentials,
8774
8774
  startedBy: opts.startedBy
@@ -8844,7 +8844,7 @@ function shouldRunMainClaudeFlow(opts) {
8844
8844
  return;
8845
8845
  } else if (subcommand === "runtime") {
8846
8846
  if (args[1] === "providers") {
8847
- const { renderRuntimeProviders } = await import('./command-DsMlcxQd.mjs');
8847
+ const { renderRuntimeProviders } = await import('./command-BYxsn0_c.mjs');
8848
8848
  console.log(renderRuntimeProviders());
8849
8849
  return;
8850
8850
  }
@@ -9022,8 +9022,8 @@ function shouldRunMainClaudeFlow(opts) {
9022
9022
  const projectId = args[3];
9023
9023
  try {
9024
9024
  const { saveGoogleCloudProjectToConfig } = await Promise.resolve().then(function () { return config; });
9025
- const { readCredentials: readCredentials2 } = await import('./persistence-C0nC4mEU.mjs');
9026
- const { ApiClient: ApiClient2 } = await import('./api-D7DleJYY.mjs').then(function (n) { return n.r; });
9025
+ const { readCredentials: readCredentials2 } = await import('./persistence-DicQpgl6.mjs');
9026
+ const { ApiClient: ApiClient2 } = await import('./api-DLI3Zloa.mjs').then(function (n) { return n.r; });
9027
9027
  let userEmail = void 0;
9028
9028
  try {
9029
9029
  const credentials = await readCredentials2();
@@ -1,8 +1,8 @@
1
1
  'use strict';
2
2
 
3
3
  var chalk = require('chalk');
4
- var api = require('./api-BZ2U3k-r.cjs');
5
- var persistence = require('./persistence-JEXs_kBA.cjs');
4
+ var api = require('./api-eDp10nsY.cjs');
5
+ var persistence = require('./persistence-CSaoFYvt.cjs');
6
6
  var z = require('zod');
7
7
  var fs$2 = require('fs/promises');
8
8
  var os$1 = require('os');
@@ -72,7 +72,7 @@ async function openBrowser(url) {
72
72
  }
73
73
  }
74
74
 
75
- const require$1 = node_module.createRequire((typeof document === 'undefined' ? require('u' + 'rl').pathToFileURL(__filename).href : (_documentCurrentScript && _documentCurrentScript.tagName.toUpperCase() === 'SCRIPT' && _documentCurrentScript.src || new URL('index-sJfKgN1y.cjs', document.baseURI).href)));
75
+ const require$1 = node_module.createRequire((typeof document === 'undefined' ? require('u' + 'rl').pathToFileURL(__filename).href : (_documentCurrentScript && _documentCurrentScript.tagName.toUpperCase() === 'SCRIPT' && _documentCurrentScript.src || new URL('index-bzGCZJLB.cjs', document.baseURI).href)));
76
76
  const QRCode = require$1("qrcode-terminal/vendor/QRCode");
77
77
  const QRErrorCorrectLevel = require$1("qrcode-terminal/vendor/QRCode/QRErrorCorrectLevel");
78
78
  const pendingTempFiles = /* @__PURE__ */ new Set();
@@ -695,7 +695,7 @@ function setupCleanupHandlers() {
695
695
  });
696
696
  }
697
697
 
698
- const __dirname$2 = path$1.dirname(url.fileURLToPath((typeof document === 'undefined' ? require('u' + 'rl').pathToFileURL(__filename).href : (_documentCurrentScript && _documentCurrentScript.tagName.toUpperCase() === 'SCRIPT' && _documentCurrentScript.src || new URL('index-sJfKgN1y.cjs', document.baseURI).href))));
698
+ const __dirname$2 = path$1.dirname(url.fileURLToPath((typeof document === 'undefined' ? require('u' + 'rl').pathToFileURL(__filename).href : (_documentCurrentScript && _documentCurrentScript.tagName.toUpperCase() === 'SCRIPT' && _documentCurrentScript.src || new URL('index-bzGCZJLB.cjs', document.baseURI).href))));
699
699
  function projectPath() {
700
700
  const path = path$1.resolve(__dirname$2, "..");
701
701
  return path;
@@ -7526,7 +7526,7 @@ class AbortError extends Error {
7526
7526
  }
7527
7527
  }
7528
7528
 
7529
- const __filename$1 = node_url.fileURLToPath((typeof document === 'undefined' ? require('u' + 'rl').pathToFileURL(__filename).href : (_documentCurrentScript && _documentCurrentScript.tagName.toUpperCase() === 'SCRIPT' && _documentCurrentScript.src || new URL('index-sJfKgN1y.cjs', document.baseURI).href)));
7529
+ const __filename$1 = node_url.fileURLToPath((typeof document === 'undefined' ? require('u' + 'rl').pathToFileURL(__filename).href : (_documentCurrentScript && _documentCurrentScript.tagName.toUpperCase() === 'SCRIPT' && _documentCurrentScript.src || new URL('index-bzGCZJLB.cjs', document.baseURI).href)));
7530
7530
  const __dirname$1 = path.join(__filename$1, "..");
7531
7531
  function getGlobalClaudeVersion() {
7532
7532
  try {
@@ -8777,11 +8777,11 @@ var launch = /*#__PURE__*/Object.freeze({
8777
8777
 
8778
8778
  const unifiedProviderExecutors = {
8779
8779
  claude: async (opts) => {
8780
- const { runClaude } = await Promise.resolve().then(function () { return require('./runClaude-pSj5zGWV.cjs'); });
8780
+ const { runClaude } = await Promise.resolve().then(function () { return require('./runClaude-CERpGT0L.cjs'); });
8781
8781
  await runClaude(opts.credentials, opts.claudeOptions ?? {});
8782
8782
  },
8783
8783
  codex: async (opts) => {
8784
- const { runCodex } = await Promise.resolve().then(function () { return require('./runCodex-ClpKXo66.cjs'); });
8784
+ const { runCodex } = await Promise.resolve().then(function () { return require('./runCodex-Z12g3g5P.cjs'); });
8785
8785
  await runCodex({
8786
8786
  credentials: opts.credentials,
8787
8787
  startedBy: opts.startedBy,
@@ -8790,7 +8790,7 @@ const unifiedProviderExecutors = {
8790
8790
  });
8791
8791
  },
8792
8792
  gemini: async (opts) => {
8793
- const { runGemini } = await Promise.resolve().then(function () { return require('./runGemini-DA5v_0X_.cjs'); });
8793
+ const { runGemini } = await Promise.resolve().then(function () { return require('./runGemini-Chas-o_m.cjs'); });
8794
8794
  await runGemini({
8795
8795
  credentials: opts.credentials,
8796
8796
  startedBy: opts.startedBy
@@ -8866,7 +8866,7 @@ function shouldRunMainClaudeFlow(opts) {
8866
8866
  return;
8867
8867
  } else if (subcommand === "runtime") {
8868
8868
  if (args[1] === "providers") {
8869
- const { renderRuntimeProviders } = await Promise.resolve().then(function () { return require('./command-D-GEzmAl.cjs'); });
8869
+ const { renderRuntimeProviders } = await Promise.resolve().then(function () { return require('./command-BJu-MaCp.cjs'); });
8870
8870
  console.log(renderRuntimeProviders());
8871
8871
  return;
8872
8872
  }
@@ -9044,8 +9044,8 @@ function shouldRunMainClaudeFlow(opts) {
9044
9044
  const projectId = args[3];
9045
9045
  try {
9046
9046
  const { saveGoogleCloudProjectToConfig } = await Promise.resolve().then(function () { return config; });
9047
- const { readCredentials: readCredentials2 } = await Promise.resolve().then(function () { return require('./persistence-JEXs_kBA.cjs'); });
9048
- const { ApiClient: ApiClient2 } = await Promise.resolve().then(function () { return require('./api-BZ2U3k-r.cjs'); }).then(function (n) { return n.api; });
9047
+ const { readCredentials: readCredentials2 } = await Promise.resolve().then(function () { return require('./persistence-CSaoFYvt.cjs'); });
9048
+ const { ApiClient: ApiClient2 } = await Promise.resolve().then(function () { return require('./api-eDp10nsY.cjs'); }).then(function (n) { return n.api; });
9049
9049
  let userEmail = void 0;
9050
9050
  try {
9051
9051
  const credentials = await readCredentials2();
package/dist/index.cjs CHANGED
@@ -1,10 +1,10 @@
1
1
  'use strict';
2
2
 
3
3
  require('chalk');
4
- require('./api-BZ2U3k-r.cjs');
5
- require('./persistence-JEXs_kBA.cjs');
4
+ require('./api-eDp10nsY.cjs');
5
+ require('./persistence-CSaoFYvt.cjs');
6
6
  require('zod');
7
- require('./index-sJfKgN1y.cjs');
7
+ require('./index-bzGCZJLB.cjs');
8
8
  require('node:child_process');
9
9
  require('node:fs');
10
10
  require('cross-spawn');
package/dist/index.mjs CHANGED
@@ -1,8 +1,8 @@
1
1
  import 'chalk';
2
- import './api-D7DleJYY.mjs';
3
- import './persistence-C0nC4mEU.mjs';
2
+ import './api-DLI3Zloa.mjs';
3
+ import './persistence-DicQpgl6.mjs';
4
4
  import 'zod';
5
- import './index-Cdi5KxhK.mjs';
5
+ import './index-CjWtQyJu.mjs';
6
6
  import 'node:child_process';
7
7
  import 'node:fs';
8
8
  import 'cross-spawn';
package/dist/lib.cjs CHANGED
@@ -1,6 +1,6 @@
1
1
  'use strict';
2
2
 
3
- var api = require('./api-BZ2U3k-r.cjs');
3
+ var api = require('./api-eDp10nsY.cjs');
4
4
  var types = require('./types-DVk3crez.cjs');
5
5
  require('axios');
6
6
  require('chalk');
package/dist/lib.mjs CHANGED
@@ -1,4 +1,4 @@
1
- export { A as ApiClient, a as ApiSessionClient, c as configuration, l as logger } from './api-D7DleJYY.mjs';
1
+ export { A as ApiClient, a as ApiSessionClient, c as configuration, l as logger } from './api-DLI3Zloa.mjs';
2
2
  export { R as RawJSONLinesSchema } from './types-CiliQpqS.mjs';
3
3
  import 'axios';
4
4
  import 'chalk';
@@ -3,7 +3,7 @@
3
3
  var promises = require('node:fs/promises');
4
4
  var fs = require('node:fs');
5
5
  var path = require('node:path');
6
- var api = require('./api-BZ2U3k-r.cjs');
6
+ var api = require('./api-eDp10nsY.cjs');
7
7
  var z = require('zod');
8
8
  require('axios');
9
9
  require('chalk');
@@ -1,7 +1,7 @@
1
1
  import { unlink, readFile, mkdir, open, stat, writeFile, rename } from 'node:fs/promises';
2
2
  import { existsSync, unlinkSync, readdirSync, constants, writeFileSync, readFileSync } from 'node:fs';
3
3
  import { join, dirname } from 'node:path';
4
- import { c as configuration, l as logger, e as encodeBase64 } from './api-D7DleJYY.mjs';
4
+ import { c as configuration, l as logger, e as encodeBase64 } from './api-DLI3Zloa.mjs';
5
5
  import * as z from 'zod';
6
6
  import 'axios';
7
7
  import 'chalk';
@@ -1,8 +1,8 @@
1
- import { i as initialMachineMetadata, e as projectPath, R as RuntimeShell, h as resolveCanonicalToolNameV2, f as formatDisplayMessage } from './index-Cdi5KxhK.mjs';
2
- import { readSettings } from './persistence-C0nC4mEU.mjs';
1
+ import { i as initialMachineMetadata, e as projectPath, R as RuntimeShell, h as resolveCanonicalToolNameV2, f as formatDisplayMessage } from './index-CjWtQyJu.mjs';
2
+ import { readSettings } from './persistence-DicQpgl6.mjs';
3
3
  import os from 'node:os';
4
4
  import { resolve } from 'node:path';
5
- import { c as configuration, p as packageJson, l as logger } from './api-D7DleJYY.mjs';
5
+ import { c as configuration, p as packageJson, l as logger } from './api-DLI3Zloa.mjs';
6
6
  import { randomUUID } from 'node:crypto';
7
7
  import { createHash } from 'crypto';
8
8
  import 'axios';
@@ -1,10 +1,10 @@
1
1
  'use strict';
2
2
 
3
- var index = require('./index-sJfKgN1y.cjs');
4
- var persistence = require('./persistence-JEXs_kBA.cjs');
3
+ var index = require('./index-bzGCZJLB.cjs');
4
+ var persistence = require('./persistence-CSaoFYvt.cjs');
5
5
  var os = require('node:os');
6
6
  var path = require('node:path');
7
- var api = require('./api-BZ2U3k-r.cjs');
7
+ var api = require('./api-eDp10nsY.cjs');
8
8
  var node_crypto = require('node:crypto');
9
9
  var crypto = require('crypto');
10
10
  require('axios');
@@ -1,8 +1,8 @@
1
1
  import { randomUUID } from 'node:crypto';
2
- import { l as logger, d as backoff, f as delay, g as AsyncLock, c as configuration, s as startOfflineReconnection, b as connectionState, A as ApiClient, i as isAuthenticationRequiredError } from './api-D7DleJYY.mjs';
2
+ import { l as logger, d as backoff, f as delay, g as AsyncLock, c as configuration, s as startOfflineReconnection, b as connectionState, A as ApiClient, i as isAuthenticationRequiredError } from './api-DLI3Zloa.mjs';
3
3
  import 'cross-spawn';
4
4
  import '@agentclientprotocol/sdk';
5
- import { j as getProjectPath, F as Future, k as claudeLocal, E as ExitCodeError, l as trimIdent, m as createClaudeBackend, f as formatDisplayMessage, t as truncateDisplayMessage, n as claudeCheckSession, e as projectPath, o as mapToClaudeMode, P as PushableAsyncIterable, q as query, A as AbortError, b as stopCaffeinate, p as publishSessionRegistration, u as getEnvironmentInfo, w as startCaffeinate } from './index-Cdi5KxhK.mjs';
5
+ import { j as getProjectPath, F as Future, k as claudeLocal, E as ExitCodeError, l as trimIdent, m as createClaudeBackend, f as formatDisplayMessage, t as truncateDisplayMessage, n as claudeCheckSession, e as projectPath, o as mapToClaudeMode, P as PushableAsyncIterable, q as query, A as AbortError, b as stopCaffeinate, p as publishSessionRegistration, u as getEnvironmentInfo, w as startCaffeinate } from './index-CjWtQyJu.mjs';
6
6
  import 'ps-list';
7
7
  import 'fs';
8
8
  import 'path';
@@ -13,7 +13,7 @@ import { dirname, basename, join, resolve } from 'node:path';
13
13
  import { homedir } from 'node:os';
14
14
  import { execSync } from 'node:child_process';
15
15
  import 'node:readline';
16
- import './persistence-C0nC4mEU.mjs';
16
+ import './persistence-DicQpgl6.mjs';
17
17
  import { readFile } from 'node:fs/promises';
18
18
  import { stat, watch, access } from 'fs/promises';
19
19
  import 'crypto';
@@ -24,9 +24,9 @@ import 'tweetnacl';
24
24
  import 'open';
25
25
  import React, { useState, useRef, useEffect, useCallback } from 'react';
26
26
  import { useStdout, useInput, Box, Text, render } from 'ink';
27
- import { c as createKeepAliveController, P as ProviderSelectionHandler, r as runModeLoop } from './ProviderSelectionHandler-oz9NjR_r.mjs';
27
+ import { c as createKeepAliveController, P as ProviderSelectionHandler, r as runModeLoop } from './ProviderSelectionHandler-DiHuEbf_.mjs';
28
28
  import { R as RawJSONLinesSchema } from './types-CiliQpqS.mjs';
29
- import { B as BasePermissionHandler, d as MessageBuffer, C as ConversationHistory$1, w as waitForResponseCompleteWithAbort, l as launchRuntimeHandleWithFactoryResult, j as forwardAgentMessageToProviderSession, s as syncControlledByUserState, e as ensureManagedProviderMachine, M as MissingMachineIdError, c as createSessionMetadata, b as MessageQueue2, h as hashObject, r as registerKillSessionHandler, f as closeProviderSession } from './registerKillSessionHandler-BRfDcq3x.mjs';
29
+ import { B as BasePermissionHandler, d as MessageBuffer, C as ConversationHistory$1, w as waitForResponseCompleteWithAbort, l as launchRuntimeHandleWithFactoryResult, j as forwardAgentMessageToProviderSession, s as syncControlledByUserState, e as ensureManagedProviderMachine, M as MissingMachineIdError, c as createSessionMetadata, b as MessageQueue2, h as hashObject, r as registerKillSessionHandler, f as closeProviderSession } from './registerKillSessionHandler-BWCjaf5S.mjs';
30
30
  import 'socket.io-client';
31
31
  import 'expo-server-sdk';
32
32
  import { isDeepStrictEqual } from 'node:util';
@@ -1,10 +1,10 @@
1
1
  'use strict';
2
2
 
3
3
  var node_crypto = require('node:crypto');
4
- var api = require('./api-BZ2U3k-r.cjs');
4
+ var api = require('./api-eDp10nsY.cjs');
5
5
  require('cross-spawn');
6
6
  require('@agentclientprotocol/sdk');
7
- var index = require('./index-sJfKgN1y.cjs');
7
+ var index = require('./index-bzGCZJLB.cjs');
8
8
  require('ps-list');
9
9
  require('fs');
10
10
  require('path');
@@ -15,7 +15,7 @@ var path = require('node:path');
15
15
  var os = require('node:os');
16
16
  var node_child_process = require('node:child_process');
17
17
  require('node:readline');
18
- require('./persistence-JEXs_kBA.cjs');
18
+ require('./persistence-CSaoFYvt.cjs');
19
19
  var promises = require('node:fs/promises');
20
20
  var fs = require('fs/promises');
21
21
  require('crypto');
@@ -26,9 +26,9 @@ require('tweetnacl');
26
26
  require('open');
27
27
  var React = require('react');
28
28
  var ink = require('ink');
29
- var ProviderSelectionHandler = require('./ProviderSelectionHandler-GuW6S0tQ.cjs');
29
+ var ProviderSelectionHandler = require('./ProviderSelectionHandler-BOAcP_CE.cjs');
30
30
  var types = require('./types-DVk3crez.cjs');
31
- var registerKillSessionHandler = require('./registerKillSessionHandler-Qw8jZB2x.cjs');
31
+ var registerKillSessionHandler = require('./registerKillSessionHandler-BeMsOt9D.cjs');
32
32
  require('socket.io-client');
33
33
  require('expo-server-sdk');
34
34
  var node_util = require('node:util');
@@ -1,7 +1,7 @@
1
1
  import { randomUUID } from 'node:crypto';
2
- import { l as logger, b as connectionState, A as ApiClient } from './api-D7DleJYY.mjs';
3
- import { B as BasePermissionHandler, h as hashObject, d as MessageBuffer, C as ConversationHistory$1, w as waitForResponseCompleteWithAbort, r as registerKillSessionHandler, l as launchRuntimeHandleWithFactoryResult, i as inferToolResultError, j as forwardAgentMessageToProviderSession, f as closeProviderSession, e as ensureManagedProviderMachine, M as MissingMachineIdError, b as MessageQueue2, s as syncControlledByUserState } from './registerKillSessionHandler-BRfDcq3x.mjs';
4
- import { f as formatDisplayMessage, v as validateCodexAcpSpawn, d as createCodexBackend, t as truncateDisplayMessage, b as stopCaffeinate } from './index-Cdi5KxhK.mjs';
2
+ import { l as logger, b as connectionState, A as ApiClient } from './api-DLI3Zloa.mjs';
3
+ import { B as BasePermissionHandler, h as hashObject, d as MessageBuffer, C as ConversationHistory$1, w as waitForResponseCompleteWithAbort, r as registerKillSessionHandler, l as launchRuntimeHandleWithFactoryResult, i as inferToolResultError, j as forwardAgentMessageToProviderSession, f as closeProviderSession, e as ensureManagedProviderMachine, M as MissingMachineIdError, b as MessageQueue2, s as syncControlledByUserState } from './registerKillSessionHandler-BWCjaf5S.mjs';
4
+ import { f as formatDisplayMessage, v as validateCodexAcpSpawn, d as createCodexBackend, t as truncateDisplayMessage, b as stopCaffeinate } from './index-CjWtQyJu.mjs';
5
5
  import 'cross-spawn';
6
6
  import '@agentclientprotocol/sdk';
7
7
  import 'ps-list';
@@ -14,7 +14,7 @@ import 'node:path';
14
14
  import 'node:os';
15
15
  import 'node:child_process';
16
16
  import 'node:readline';
17
- import './persistence-C0nC4mEU.mjs';
17
+ import './persistence-DicQpgl6.mjs';
18
18
  import 'node:fs/promises';
19
19
  import 'fs/promises';
20
20
  import 'crypto';
@@ -25,8 +25,8 @@ import 'tweetnacl';
25
25
  import 'open';
26
26
  import React, { useState, useRef, useEffect, useCallback } from 'react';
27
27
  import { useStdout, useInput, Box, Text, render } from 'ink';
28
- import { c as createKeepAliveController, P as ProviderSelectionHandler, r as runModeLoop } from './ProviderSelectionHandler-oz9NjR_r.mjs';
29
- import { B as BaseReasoningProcessor, b as bootstrapManagedProviderSession } from './BaseReasoningProcessor-wqWUBiEJ.mjs';
28
+ import { c as createKeepAliveController, P as ProviderSelectionHandler, r as runModeLoop } from './ProviderSelectionHandler-DiHuEbf_.mjs';
29
+ import { B as BaseReasoningProcessor, b as bootstrapManagedProviderSession } from './BaseReasoningProcessor-DajL_jtA.mjs';
30
30
  import 'socket.io-client';
31
31
  import 'zod';
32
32
  import 'expo-server-sdk';
@@ -483,6 +483,7 @@ async function codexRemoteLauncher(session) {
483
483
  let pending = null;
484
484
  let readyAlreadySent = false;
485
485
  let accumulatedResponse = "";
486
+ let emittedResponseLength = 0;
486
487
  let isResponseInProgress = false;
487
488
  let taskStartedSent = false;
488
489
  let shouldInjectHistoryOnNextSession = false;
@@ -515,6 +516,7 @@ async function codexRemoteLauncher(session) {
515
516
  const resetTurnState = () => {
516
517
  reasoningProcessor.abort();
517
518
  accumulatedResponse = "";
519
+ emittedResponseLength = 0;
518
520
  isResponseInProgress = false;
519
521
  taskStartedSent = false;
520
522
  shouldCommitAccumulatedResponse = false;
@@ -575,13 +577,23 @@ async function codexRemoteLauncher(session) {
575
577
  return;
576
578
  }
577
579
  conversationHistory.addAssistantMessage(accumulatedResponse);
580
+ emitPendingAssistantMessageDelta();
581
+ accumulatedResponse = "";
582
+ emittedResponseLength = 0;
583
+ isResponseInProgress = false;
584
+ };
585
+ const emitPendingAssistantMessageDelta = () => {
586
+ const nextMessage = accumulatedResponse.slice(emittedResponseLength);
587
+ if (!nextMessage.trim()) {
588
+ return false;
589
+ }
578
590
  session.runtimeSession.sendCodexMessage({
579
591
  type: "message",
580
- message: accumulatedResponse,
592
+ message: nextMessage,
581
593
  id: randomUUID()
582
594
  });
583
- accumulatedResponse = "";
584
- isResponseInProgress = false;
595
+ emittedResponseLength = accumulatedResponse.length;
596
+ return true;
585
597
  };
586
598
  const setupRuntimeMessageHandler = (activeRuntimeHandle) => {
587
599
  const forwardAgentMessage = (agentMessage) => {
@@ -631,10 +643,12 @@ async function codexRemoteLauncher(session) {
631
643
  return;
632
644
  }
633
645
  if (msg.status === "idle" || msg.status === "stopped") {
646
+ emitPendingAssistantMessageDelta();
634
647
  reasoningProcessor.completeCurrent();
635
648
  return;
636
649
  }
637
650
  if (msg.status === "error") {
651
+ emitPendingAssistantMessageDelta();
638
652
  const errorMessage = normalizeCodexBackendError(msg.detail);
639
653
  messageBuffer.addMessage(`Error: ${errorMessage}`, "status");
640
654
  return;
@@ -642,6 +656,7 @@ async function codexRemoteLauncher(session) {
642
656
  return;
643
657
  }
644
658
  case "tool-call": {
659
+ emitPendingAssistantMessageDelta();
645
660
  const toolArgs = msg.args ? truncateDisplayMessage(msg.args, 100) : "";
646
661
  messageBuffer.addMessage(
647
662
  `Executing: ${msg.toolName}${toolArgs ? ` ${toolArgs}` : ""}`,
@@ -1,9 +1,9 @@
1
1
  'use strict';
2
2
 
3
3
  var node_crypto = require('node:crypto');
4
- var api = require('./api-BZ2U3k-r.cjs');
5
- var registerKillSessionHandler = require('./registerKillSessionHandler-Qw8jZB2x.cjs');
6
- var index = require('./index-sJfKgN1y.cjs');
4
+ var api = require('./api-eDp10nsY.cjs');
5
+ var registerKillSessionHandler = require('./registerKillSessionHandler-BeMsOt9D.cjs');
6
+ var index = require('./index-bzGCZJLB.cjs');
7
7
  require('cross-spawn');
8
8
  require('@agentclientprotocol/sdk');
9
9
  require('ps-list');
@@ -16,7 +16,7 @@ require('node:path');
16
16
  require('node:os');
17
17
  require('node:child_process');
18
18
  require('node:readline');
19
- require('./persistence-JEXs_kBA.cjs');
19
+ require('./persistence-CSaoFYvt.cjs');
20
20
  require('node:fs/promises');
21
21
  require('fs/promises');
22
22
  require('crypto');
@@ -27,8 +27,8 @@ require('tweetnacl');
27
27
  require('open');
28
28
  var React = require('react');
29
29
  var ink = require('ink');
30
- var ProviderSelectionHandler = require('./ProviderSelectionHandler-GuW6S0tQ.cjs');
31
- var BaseReasoningProcessor = require('./BaseReasoningProcessor-BdbyUAZR.cjs');
30
+ var ProviderSelectionHandler = require('./ProviderSelectionHandler-BOAcP_CE.cjs');
31
+ var BaseReasoningProcessor = require('./BaseReasoningProcessor-DrAN-2bw.cjs');
32
32
  require('socket.io-client');
33
33
  require('zod');
34
34
  require('expo-server-sdk');
@@ -485,6 +485,7 @@ async function codexRemoteLauncher(session) {
485
485
  let pending = null;
486
486
  let readyAlreadySent = false;
487
487
  let accumulatedResponse = "";
488
+ let emittedResponseLength = 0;
488
489
  let isResponseInProgress = false;
489
490
  let taskStartedSent = false;
490
491
  let shouldInjectHistoryOnNextSession = false;
@@ -517,6 +518,7 @@ async function codexRemoteLauncher(session) {
517
518
  const resetTurnState = () => {
518
519
  reasoningProcessor.abort();
519
520
  accumulatedResponse = "";
521
+ emittedResponseLength = 0;
520
522
  isResponseInProgress = false;
521
523
  taskStartedSent = false;
522
524
  shouldCommitAccumulatedResponse = false;
@@ -577,13 +579,23 @@ async function codexRemoteLauncher(session) {
577
579
  return;
578
580
  }
579
581
  conversationHistory.addAssistantMessage(accumulatedResponse);
582
+ emitPendingAssistantMessageDelta();
583
+ accumulatedResponse = "";
584
+ emittedResponseLength = 0;
585
+ isResponseInProgress = false;
586
+ };
587
+ const emitPendingAssistantMessageDelta = () => {
588
+ const nextMessage = accumulatedResponse.slice(emittedResponseLength);
589
+ if (!nextMessage.trim()) {
590
+ return false;
591
+ }
580
592
  session.runtimeSession.sendCodexMessage({
581
593
  type: "message",
582
- message: accumulatedResponse,
594
+ message: nextMessage,
583
595
  id: node_crypto.randomUUID()
584
596
  });
585
- accumulatedResponse = "";
586
- isResponseInProgress = false;
597
+ emittedResponseLength = accumulatedResponse.length;
598
+ return true;
587
599
  };
588
600
  const setupRuntimeMessageHandler = (activeRuntimeHandle) => {
589
601
  const forwardAgentMessage = (agentMessage) => {
@@ -633,10 +645,12 @@ async function codexRemoteLauncher(session) {
633
645
  return;
634
646
  }
635
647
  if (msg.status === "idle" || msg.status === "stopped") {
648
+ emitPendingAssistantMessageDelta();
636
649
  reasoningProcessor.completeCurrent();
637
650
  return;
638
651
  }
639
652
  if (msg.status === "error") {
653
+ emitPendingAssistantMessageDelta();
640
654
  const errorMessage = normalizeCodexBackendError(msg.detail);
641
655
  messageBuffer.addMessage(`Error: ${errorMessage}`, "status");
642
656
  return;
@@ -644,6 +658,7 @@ async function codexRemoteLauncher(session) {
644
658
  return;
645
659
  }
646
660
  case "tool-call": {
661
+ emitPendingAssistantMessageDelta();
647
662
  const toolArgs = msg.args ? index.truncateDisplayMessage(msg.args, 100) : "";
648
663
  messageBuffer.addMessage(
649
664
  `Executing: ${msg.toolName}${toolArgs ? ` ${toolArgs}` : ""}`,
@@ -1,10 +1,10 @@
1
1
  import { useStdout, useInput, Box, Text, render } from 'ink';
2
2
  import React, { useState, useRef, useEffect, useCallback } from 'react';
3
3
  import { randomUUID } from 'node:crypto';
4
- import { l as logger, b as connectionState, A as ApiClient } from './api-D7DleJYY.mjs';
5
- import { B as BasePermissionHandler, C as ConversationHistory$1, e as ensureManagedProviderMachine, M as MissingMachineIdError, s as syncControlledByUserState, b as MessageQueue2, h as hashObject, d as MessageBuffer, r as registerKillSessionHandler, w as waitForResponseCompleteWithAbort, f as closeProviderSession, l as launchRuntimeHandleWithFactoryResult, i as inferToolResultError, j as forwardAgentMessageToProviderSession } from './registerKillSessionHandler-BRfDcq3x.mjs';
6
- import { g as getInitialGeminiModel, r as readGeminiLocalConfig, G as GEMINI_MODEL_ENV, s as saveGeminiModelToConfig, a as createGeminiBackend, b as stopCaffeinate } from './index-Cdi5KxhK.mjs';
7
- import { B as BaseReasoningProcessor, b as bootstrapManagedProviderSession } from './BaseReasoningProcessor-wqWUBiEJ.mjs';
4
+ import { l as logger, b as connectionState, A as ApiClient } from './api-DLI3Zloa.mjs';
5
+ import { B as BasePermissionHandler, C as ConversationHistory$1, e as ensureManagedProviderMachine, M as MissingMachineIdError, s as syncControlledByUserState, b as MessageQueue2, h as hashObject, d as MessageBuffer, r as registerKillSessionHandler, w as waitForResponseCompleteWithAbort, f as closeProviderSession, l as launchRuntimeHandleWithFactoryResult, i as inferToolResultError, j as forwardAgentMessageToProviderSession } from './registerKillSessionHandler-BWCjaf5S.mjs';
6
+ import { g as getInitialGeminiModel, r as readGeminiLocalConfig, G as GEMINI_MODEL_ENV, s as saveGeminiModelToConfig, a as createGeminiBackend, b as stopCaffeinate } from './index-CjWtQyJu.mjs';
7
+ import { B as BaseReasoningProcessor, b as bootstrapManagedProviderSession } from './BaseReasoningProcessor-DajL_jtA.mjs';
8
8
  import 'cross-spawn';
9
9
  import '@agentclientprotocol/sdk';
10
10
  import 'ps-list';
@@ -15,7 +15,7 @@ import 'node:child_process';
15
15
  import 'node:readline';
16
16
  import 'tweetnacl';
17
17
  import 'axios';
18
- import './persistence-C0nC4mEU.mjs';
18
+ import './persistence-DicQpgl6.mjs';
19
19
  import 'open';
20
20
  import 'chalk';
21
21
  import 'fs';
@@ -3,10 +3,10 @@
3
3
  var ink = require('ink');
4
4
  var React = require('react');
5
5
  var node_crypto = require('node:crypto');
6
- var api = require('./api-BZ2U3k-r.cjs');
7
- var registerKillSessionHandler = require('./registerKillSessionHandler-Qw8jZB2x.cjs');
8
- var index = require('./index-sJfKgN1y.cjs');
9
- var BaseReasoningProcessor = require('./BaseReasoningProcessor-BdbyUAZR.cjs');
6
+ var api = require('./api-eDp10nsY.cjs');
7
+ var registerKillSessionHandler = require('./registerKillSessionHandler-BeMsOt9D.cjs');
8
+ var index = require('./index-bzGCZJLB.cjs');
9
+ var BaseReasoningProcessor = require('./BaseReasoningProcessor-DrAN-2bw.cjs');
10
10
  require('cross-spawn');
11
11
  require('@agentclientprotocol/sdk');
12
12
  require('ps-list');
@@ -17,7 +17,7 @@ require('node:child_process');
17
17
  require('node:readline');
18
18
  require('tweetnacl');
19
19
  require('axios');
20
- require('./persistence-JEXs_kBA.cjs');
20
+ require('./persistence-CSaoFYvt.cjs');
21
21
  require('open');
22
22
  require('chalk');
23
23
  require('fs');
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "happy-imou-cloud",
3
- "version": "2.0.17",
3
+ "version": "2.0.18",
4
4
  "description": "hicloud - Imou 企业定制版。关键是 happy!移动端远程 AI 编程工具,支持 Claude Code、Codex 和 Gemini CLI",
5
5
  "author": "long.zhu",
6
6
  "license": "MIT",
@@ -169,20 +169,20 @@ function main() {
169
169
  '20000',
170
170
  'src/agent/acp/AcpBackend.test.ts',
171
171
  'src/agent/acp/AcpBackend.startup.test.ts',
172
- 'src/agent/acp/AcpBackend.waitForResponseComplete.test.ts',
173
- 'src/agent/acp/AcpBackend.initDelay.test.ts',
174
- 'src/agent/acp/acpSpawn.test.ts',
175
- 'src/agent/acp/createAcpFilteredStdoutReadable.multiline.test.ts',
176
- 'src/agent/acp/killProcessTree.test.ts',
177
- 'src/modules/common/runShellCommand.test.ts',
178
- 'src/modules/common/registerCommonHandlers.test.ts',
179
- 'src/utils/HeadTailPreviewBuffer.test.ts',
180
- 'src/runtime/executeProvider.test.ts',
181
- 'src/runtime/ensureManagedProviderMachine.test.ts',
182
- 'src/runtime/bootstrapManagedProviderSession.test.ts',
183
- 'src/runtime/command.test.ts',
184
- 'src/runtime/launch.test.ts',
185
- 'src/runtime/launchWithFactoryResult.test.ts',
172
+ 'src/agent/acp/AcpBackend.waitForResponseComplete.test.ts',
173
+ 'src/agent/acp/AcpBackend.initDelay.test.ts',
174
+ 'src/agent/acp/acpSpawn.test.ts',
175
+ 'src/agent/acp/createAcpFilteredStdoutReadable.multiline.test.ts',
176
+ 'src/agent/acp/killProcessTree.test.ts',
177
+ 'src/modules/common/runShellCommand.test.ts',
178
+ 'src/modules/common/registerCommonHandlers.test.ts',
179
+ 'src/utils/HeadTailPreviewBuffer.test.ts',
180
+ 'src/runtime/executeProvider.test.ts',
181
+ 'src/runtime/ensureManagedProviderMachine.test.ts',
182
+ 'src/runtime/bootstrapManagedProviderSession.test.ts',
183
+ 'src/runtime/command.test.ts',
184
+ 'src/runtime/launch.test.ts',
185
+ 'src/runtime/launchWithFactoryResult.test.ts',
186
186
  'src/runtime/providerMessageBridge.test.ts',
187
187
  'src/runtime/runModeLoop.test.ts',
188
188
  'src/runtime/createKeepAliveController.test.ts',