xkzoom 1.5.4 → 1.5.5
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.
- package/README.md +29 -0
- package/dist/{chunk-4JXTPCOE.mjs → chunk-2NBVNRMZ.mjs} +1 -1
- package/dist/{chunk-VIZQURO5.mjs → chunk-2PWU4VN6.mjs} +7 -7
- package/dist/{chunk-F35EHL5U.mjs → chunk-3K6WOVYD.mjs} +6 -6
- package/dist/{chunk-76MFE24I.mjs → chunk-3TTLV2GM.mjs} +1 -1
- package/dist/{chunk-GIC2RBVM.mjs → chunk-4BCLMOYG.mjs} +1 -1
- package/dist/{chunk-HAI7DJD2.mjs → chunk-54GVKP6B.mjs} +6 -6
- package/dist/{chunk-I7O5UR24.mjs → chunk-5IAQOOZ2.mjs} +5 -5
- package/dist/{chunk-MRTQWCNC.mjs → chunk-5U4JST47.mjs} +1 -1
- package/dist/{chunk-2IQAT3PE.mjs → chunk-64QYTQH7.mjs} +3 -3
- package/dist/{chunk-WPMJCKI2.mjs → chunk-6SYECCCG.mjs} +8 -8
- package/dist/{chunk-TADSGGK2.mjs → chunk-6VSIGHGI.mjs} +7 -7
- package/dist/{chunk-M3ISDSQP.mjs → chunk-APQRVOZQ.mjs} +5 -5
- package/dist/{chunk-QADC4VKT.mjs → chunk-CRYBNNZU.mjs} +10 -10
- package/dist/{chunk-PW3ULDNL.mjs → chunk-CVIZMDMZ.mjs} +1 -1
- package/dist/{chunk-GIAML5K5.mjs → chunk-DQ7J7RST.mjs} +1 -1
- package/dist/{chunk-YYDDQEY4.mjs → chunk-DXPZNBSQ.mjs} +1 -1
- package/dist/{chunk-VNEPNUBZ.mjs → chunk-DZDEUZD2.mjs} +11 -11
- package/dist/{chunk-5SE4JOKE.mjs → chunk-EBVVOJVN.mjs} +15 -15
- package/dist/{chunk-DCSERRXG.mjs → chunk-ED4H2DM7.mjs} +1 -1
- package/dist/{chunk-CQUISJWG.mjs → chunk-EYK3W2NV.mjs} +1 -1
- package/dist/{chunk-3KJHUTOO.mjs → chunk-FAB2ZZYB.mjs} +2 -2
- package/dist/{chunk-Q33JD64H.mjs → chunk-FCK6QFJB.mjs} +1 -1
- package/dist/{chunk-UXEZFEB3.mjs → chunk-FZ7NLBVP.mjs} +13 -13
- package/dist/{chunk-MDZUWIBH.mjs → chunk-G4JWJKD7.mjs} +13 -13
- package/dist/{chunk-GZJMFCRG.mjs → chunk-G5LQ2PQ6.mjs} +2 -2
- package/dist/{chunk-6W4W5JLG.mjs → chunk-GSIZ5FR6.mjs} +2 -2
- package/dist/{chunk-27BXVTXH.mjs → chunk-H4BNL7XG.mjs} +1 -1
- package/dist/{chunk-FG6QCRVN.mjs → chunk-H7DNHHNA.mjs} +1 -1
- package/dist/{chunk-7LEEVP5O.mjs → chunk-HVDIL2V7.mjs} +11 -11
- package/dist/{chunk-PJKLQF3K.mjs → chunk-INFZEMQK.mjs} +1 -1
- package/dist/{chunk-IDQ5B572.mjs → chunk-JK5ZK32E.mjs} +5 -5
- package/dist/{chunk-LFZAVCVW.mjs → chunk-LJ6RMHC6.mjs} +1 -1
- package/dist/{chunk-L252ASZW.mjs → chunk-LKHL3NCW.mjs} +1 -1
- package/dist/{chunk-PS6X3CND.mjs → chunk-LKSRZTSL.mjs} +1 -0
- package/dist/{chunk-LESS4N25.mjs → chunk-LMIEVEGA.mjs} +5 -5
- package/dist/{chunk-COYZO24J.mjs → chunk-MCD5TOFD.mjs} +1 -1
- package/dist/{chunk-JBKRS62W.mjs → chunk-MFIBP6MD.mjs} +4 -4
- package/dist/{chunk-CFZVBILR.mjs → chunk-MIXYB6BH.mjs} +1 -1
- package/dist/{chunk-3ZH273T7.mjs → chunk-MLHV7EMJ.mjs} +33 -33
- package/dist/{chunk-ZMQ3UOGP.mjs → chunk-MMWLRPKT.mjs} +13 -1
- package/dist/{chunk-OBYPZT2S.mjs → chunk-MTRG3ZME.mjs} +7 -7
- package/dist/{chunk-J5AXFEDQ.mjs → chunk-N6VFFREI.mjs} +52 -52
- package/dist/{chunk-TVH4LII3.mjs → chunk-ND44D2ZA.mjs} +1 -1
- package/dist/{chunk-JG3K4N5B.mjs → chunk-NIV5GVCE.mjs} +1 -1
- package/dist/{chunk-MPGMU75K.mjs → chunk-NUXJHSSQ.mjs} +5 -5
- package/dist/{chunk-JFFBD5TV.mjs → chunk-O7MFL7L4.mjs} +10 -10
- package/dist/{chunk-PETWGCGB.mjs → chunk-OMLMLZUY.mjs} +2 -2
- package/dist/{chunk-B4YKXZ5W.mjs → chunk-OQMIECO2.mjs} +1 -1
- package/dist/{chunk-ZTKJR7OC.mjs → chunk-OWIXULFQ.mjs} +1 -1
- package/dist/{chunk-JXDHNASC.mjs → chunk-P4WX5RWE.mjs} +20 -20
- package/dist/{chunk-JJKRD5DL.mjs → chunk-PN6I6DTV.mjs} +4 -4
- package/dist/{chunk-5YEFG7BF.mjs → chunk-QEED7NAG.mjs} +31 -31
- package/dist/{chunk-HYSOWPIC.mjs → chunk-RVW5XO4A.mjs} +4 -4
- package/dist/{chunk-NHICONJ3.mjs → chunk-RYSPXH7G.mjs} +2 -2
- package/dist/{chunk-IGDJGBAI.mjs → chunk-S5ROBD7X.mjs} +2 -2
- package/dist/{chunk-RKZ56GST.mjs → chunk-SKQOHRBI.mjs} +2 -2
- package/dist/{chunk-TQBVFKCT.mjs → chunk-SLBCSYGP.mjs} +8 -8
- package/dist/{chunk-W75Z6CZR.mjs → chunk-TER7DFHP.mjs} +1 -1
- package/dist/{chunk-NIU6GWKB.mjs → chunk-TNBK63NV.mjs} +4 -4
- package/dist/{chunk-K7RZQIPZ.mjs → chunk-U6ONSC6B.mjs} +1 -1
- package/dist/{chunk-2DR5RT3I.mjs → chunk-UAUV2GYH.mjs} +101 -101
- package/dist/{chunk-VWAUDB4X.mjs → chunk-UFURP7VS.mjs} +1 -1
- package/dist/{chunk-76TKUYY3.mjs → chunk-UPD527M4.mjs} +6 -6
- package/dist/{chunk-YPKHMAO4.mjs → chunk-VHRFLCMY.mjs} +1 -1
- package/dist/{chunk-M5IU6U3O.mjs → chunk-W6JEB555.mjs} +2 -2
- package/dist/{chunk-KPDVZFJY.mjs → chunk-WOHFGPTL.mjs} +1 -1
- package/dist/{chunk-24GJWXMG.mjs → chunk-WQFYA2BW.mjs} +3 -3
- package/dist/{chunk-E2TTUY6R.mjs → chunk-XADONCIM.mjs} +10 -10
- package/dist/{chunk-3VA3YDYL.mjs → chunk-XDR276NG.mjs} +1 -1
- package/dist/{chunk-MWRQORKQ.mjs → chunk-XF4EURDX.mjs} +1 -1
- package/dist/{chunk-JI67TW4E.mjs → chunk-YFKOQIA7.mjs} +1 -1
- package/dist/{chunk-MBOWNG3A.mjs → chunk-YKACMPVT.mjs} +1 -1
- package/dist/{chunk-D3N7EHB2.mjs → chunk-YSLLUNNZ.mjs} +9 -9
- package/dist/chunk-YTBKWX7J.mjs +102 -0
- package/dist/{chunk-2VSERWT6.mjs → chunk-YW5STVWH.mjs} +1 -1
- package/dist/{chunk-ETD5LGJY.mjs → chunk-Z3COATFF.mjs} +1 -1
- package/dist/{chunk-MQKREMOB.mjs → chunk-ZE6GJFY7.mjs} +7 -7
- package/dist/index.js +262 -162
- package/dist/index.mjs +182 -181
- package/dist/mobile/action-planner.mjs +105 -105
- package/dist/mobile/agent-capabilities.mjs +106 -106
- package/dist/mobile/agent-shop/handlers.mjs +3 -3
- package/dist/mobile/agents-watch.js +346 -0
- package/dist/mobile/agents-watch.mjs +13 -0
- package/dist/mobile/anthropic-incremental-deliver.mjs +3 -3
- package/dist/mobile/anthropic-messages-turn-runner.mjs +115 -115
- package/dist/mobile/anthropic-owned-tool-executor.mjs +114 -114
- package/dist/mobile/api.mjs +63 -63
- package/dist/mobile/auth.mjs +1 -1
- package/dist/mobile/bucket-events/emit-bucket-frame.js +327 -0
- package/dist/mobile/bucket-events/emit-bucket-frame.mjs +8 -3
- package/dist/mobile/bucket-events/register-bucket-gateway-bridge.js +320 -3
- package/dist/mobile/bucket-events/register-bucket-gateway-bridge.mjs +9 -4
- package/dist/mobile/channel.mjs +2 -2
- package/dist/mobile/context-compact/compact-artifact-enrich.mjs +14 -14
- package/dist/mobile/context-compact/compact-artifact-writer.mjs +3 -3
- package/dist/mobile/context-compact/compact-engine-artifacts.mjs +4 -4
- package/dist/mobile/context-compact/compact-memory-distill-job.mjs +3 -3
- package/dist/mobile/context-compact/compact-message-collector.mjs +2 -2
- package/dist/mobile/context-compact/compact-orchestrator.mjs +29 -29
- package/dist/mobile/context-compact/compact-resume-prefetch.mjs +3 -3
- package/dist/mobile/context-compact/compact-summarizer-engine-artifact.mjs +15 -15
- package/dist/mobile/context-compact/compact-summarizer-llm-request.mjs +10 -10
- package/dist/mobile/context-compact/compact-summarizer-llm.mjs +11 -11
- package/dist/mobile/context-compact/compact-summarizer.mjs +13 -13
- package/dist/mobile/context-compact/compact-write-verifier.mjs +2 -2
- package/dist/mobile/context-compact/runtime-compact-hook.mjs +109 -109
- package/dist/mobile/group/conductor-llm.mjs +13 -13
- package/dist/mobile/group/conductor-plan-llm.mjs +19 -19
- package/dist/mobile/group/delivery-verification.mjs +4 -4
- package/dist/mobile/group/direct-chat-group-context.mjs +1 -1
- package/dist/mobile/group/execution-plan.mjs +5 -5
- package/dist/mobile/group/floor-scheduler.mjs +6 -6
- package/dist/mobile/group/floor-state-store.mjs +6 -6
- package/dist/mobile/group/group-api-handlers.mjs +45 -45
- package/dist/mobile/group/group-peer-private-context.mjs +1 -1
- package/dist/mobile/group/group-session.mjs +18 -18
- package/dist/mobile/group/index.mjs +39 -39
- package/dist/mobile/group/memory-supplement.mjs +9 -9
- package/dist/mobile/group/orchestrator.mjs +35 -35
- package/dist/mobile/group/pipeline-ceo-dept-mention-parse.mjs +3 -3
- package/dist/mobile/group/pipeline-handoff-verification.mjs +3 -3
- package/dist/mobile/group/pipeline-turn-outcome.mjs +2 -2
- package/dist/mobile/group/plan-runtime.mjs +17 -17
- package/dist/mobile/group/relation-distill.mjs +7 -7
- package/dist/mobile/group/runtime-integration.mjs +43 -43
- package/dist/mobile/group/team-memory-runtime.mjs +3 -3
- package/dist/mobile/index.js +277 -155
- package/dist/mobile/index.mjs +177 -176
- package/dist/mobile/memory-contract-r1-prefetch.mjs +10 -10
- package/dist/mobile/memory-contract-r5-empty-result.mjs +11 -11
- package/dist/mobile/memory-runtime-v2/eval-runner.mjs +11 -11
- package/dist/mobile/memory-runtime-v2/evidence-plan.mjs +13 -13
- package/dist/mobile/memory-runtime-v2/index.mjs +38 -38
- package/dist/mobile/memory-runtime-v2/local-source-import.mjs +3 -3
- package/dist/mobile/memory-runtime-v2/memory-control-plane.mjs +13 -13
- package/dist/mobile/memory-runtime-v2/memory-readiness.mjs +13 -13
- package/dist/mobile/memory-runtime-v2/orchestrator.mjs +4 -4
- package/dist/mobile/memory-runtime-v2/project-tool-event.mjs +2 -2
- package/dist/mobile/memory-runtime-v2/public-api.mjs +16 -16
- package/dist/mobile/memory-runtime-v2/retrieval.mjs +2 -2
- package/dist/mobile/native-anthropic-messages-stream.mjs +11 -11
- package/dist/mobile/native-openai-text-stream.mjs +2 -2
- package/dist/mobile/native-reply-route.mjs +10 -10
- package/dist/mobile/native-reply-system-prompt-layers.mjs +106 -106
- package/dist/mobile/native-stream-block-emit.mjs +2 -2
- package/dist/mobile/openai-completions-turn-runner.mjs +115 -115
- package/dist/mobile/reply-dispatch-warmup.mjs +5 -5
- package/dist/mobile/runtime.js +160 -39
- package/dist/mobile/runtime.mjs +174 -173
- package/dist/mobile/session-dispatch/mobile-session-agent-event-bridge.mjs +1 -1
- package/dist/mobile/tool-use-input-normalize.mjs +108 -108
- package/dist/mobile/tools/mobile-compact-tool-bridge.mjs +108 -108
- package/dist/mobile/types.js +1 -0
- package/dist/mobile/types.mjs +1 -1
- package/dist/mobile/websocket.js +327 -0
- package/dist/mobile/websocket.mjs +7 -2
- package/dist/org/dept-context.mjs +4 -4
- package/dist/org/index.mjs +8 -8
- package/dist/owned-tools/agents-list.mjs +1 -1
- package/dist/owned-tools/ceo-confirm-requirements.mjs +12 -12
- package/dist/owned-tools/ceo-decision.mjs +18 -18
- package/dist/owned-tools/ceo-ops-brief.mjs +12 -12
- package/dist/owned-tools/ceo-redirect.mjs +44 -44
- package/dist/owned-tools/commit-stack-lesson.mjs +13 -13
- package/dist/owned-tools/compact/execute.mjs +106 -106
- package/dist/owned-tools/compact/gateway-tool-factory.mjs +107 -107
- package/dist/owned-tools/compact/registry.mjs +105 -105
- package/dist/owned-tools/context-compact.mjs +46 -46
- package/dist/owned-tools/groups-history.mjs +2 -2
- package/dist/owned-tools/handoff.mjs +17 -17
- package/dist/owned-tools/media-asset-library.mjs +1 -1
- package/dist/owned-tools/memory-control.mjs +15 -15
- package/dist/owned-tools/memory-runtime-eval.mjs +14 -14
- package/dist/owned-tools/message.mjs +3 -3
- package/dist/owned-tools/models-list.mjs +2 -2
- package/dist/owned-tools/owned-reply.mjs +1 -1
- package/dist/owned-tools/providers/minimax-files.mjs +2 -2
- package/dist/owned-tools/providers/minimax-video-generate.mjs +3 -3
- package/dist/owned-tools/providers/minimax-voice.mjs +3 -3
- package/dist/owned-tools/register-owned-providers.mjs +7 -7
- package/dist/owned-tools/registry.mjs +104 -104
- package/dist/owned-tools/router.mjs +105 -105
- package/dist/owned-tools/runtime-bridge.mjs +106 -106
- package/dist/owned-tools/runtime-data.mjs +1 -1
- package/dist/owned-tools/session-status.mjs +1 -1
- package/dist/owned-tools/sessions-history-resolver.mjs +2 -2
- package/dist/owned-tools/sessions-history.mjs +2 -2
- package/dist/owned-tools/sessions-list.mjs +1 -1
- package/dist/owned-tools/sessions-send.mjs +1 -1
- package/dist/owned-tools/skills-create.mjs +1 -1
- package/dist/owned-tools/subagents.mjs +1 -1
- package/dist/owned-tools/tool-contract-prompt.mjs +105 -105
- package/dist/owned-tools/tool-result-envelope.mjs +107 -107
- package/dist/owned-tools/tool-usage-guide.mjs +104 -104
- package/dist/owned-tools/tts.mjs +3 -3
- package/dist/owned-tools/web-smoke.mjs +6 -6
- package/dist/project/file-tool-scope-default.mjs +6 -6
- package/dist/project-pipeline/handlers.mjs +44 -44
- package/dist/project-pipeline/index.mjs +47 -47
- package/dist/project-pipeline/pipeline-routing.mjs +2 -2
- package/dist/project-pipeline/post-close-skill-evolution.mjs +5 -5
- package/dist/project-pipeline/project-store.mjs +5 -5
- package/package.json +2 -2
- package/gateway-core/README.md +0 -6
- package/dist/{chunk-UNZ3D3B3.mjs → chunk-3OXBG4OP.mjs} +5 -5
- package/dist/{chunk-QM7MTC5Q.mjs → chunk-522D52FC.mjs} +3 -3
- package/dist/{chunk-NRJWLPTI.mjs → chunk-6AY6OPO5.mjs} +3 -3
- package/dist/{chunk-JA65ZG3H.mjs → chunk-6ZWKLMY3.mjs} +4 -4
- package/dist/{chunk-T23H5D4O.mjs → chunk-AINHKBJW.mjs} +3 -3
- package/dist/{chunk-MKYCBV3H.mjs → chunk-BHT6B2TV.mjs} +6 -6
- package/dist/{chunk-PX55IRYL.mjs → chunk-F5KN3REF.mjs} +4 -4
- package/dist/{chunk-2QCX6RPN.mjs → chunk-KCZIK3TH.mjs} +3 -3
- package/dist/{chunk-WPLDZLAL.mjs → chunk-L7PMYQN5.mjs} +3 -3
- package/dist/{chunk-5LUTMHVL.mjs → chunk-NXKHSX4M.mjs} +3 -3
- package/dist/{chunk-UR6LPERL.mjs → chunk-Q7NYATKS.mjs} +3 -3
- package/dist/{chunk-MGWYJD5Q.mjs → chunk-QCSNRVL2.mjs} +8 -8
- package/dist/{chunk-HWGRW6YP.mjs → chunk-VS2URZFN.mjs} +3 -3
|
@@ -13,38 +13,41 @@ import {
|
|
|
13
13
|
import {
|
|
14
14
|
dispatchNontextReplyFromExtracted
|
|
15
15
|
} from "./chunk-TKW3XDFP.mjs";
|
|
16
|
+
import {
|
|
17
|
+
callConductorPlanLlm
|
|
18
|
+
} from "./chunk-OMLMLZUY.mjs";
|
|
16
19
|
import {
|
|
17
20
|
buildDirectChatGroupContextBlock
|
|
18
21
|
} from "./chunk-LGNLS7ZN.mjs";
|
|
22
|
+
import {
|
|
23
|
+
createFinalTraceLogger,
|
|
24
|
+
previewFinalTraceText
|
|
25
|
+
} from "./chunk-5PZJDP37.mjs";
|
|
19
26
|
import {
|
|
20
27
|
inferMobileUpstreamDispatchFailureMeta
|
|
21
28
|
} from "./chunk-7L46MOG4.mjs";
|
|
22
29
|
import {
|
|
23
30
|
callPostAgentIntentLlm
|
|
24
|
-
} from "./chunk-
|
|
25
|
-
import {
|
|
26
|
-
callConductorPlanLlm
|
|
27
|
-
} from "./chunk-PETWGCGB.mjs";
|
|
31
|
+
} from "./chunk-VHRFLCMY.mjs";
|
|
28
32
|
import {
|
|
29
33
|
buildRunningSummaryContextBlock
|
|
30
34
|
} from "./chunk-42NDWKUN.mjs";
|
|
31
35
|
import {
|
|
32
36
|
detectCompactDoneFromAssistantText,
|
|
33
37
|
evaluateAndMaybeRunContextCompact
|
|
34
|
-
} from "./chunk-
|
|
35
|
-
import {
|
|
36
|
-
createFinalTraceLogger,
|
|
37
|
-
previewFinalTraceText
|
|
38
|
-
} from "./chunk-5PZJDP37.mjs";
|
|
38
|
+
} from "./chunk-3K6WOVYD.mjs";
|
|
39
39
|
import {
|
|
40
40
|
registerXreBucketGatewayBridge
|
|
41
|
-
} from "./chunk-
|
|
41
|
+
} from "./chunk-INFZEMQK.mjs";
|
|
42
42
|
import {
|
|
43
43
|
resolveDefaultFileToolScopeForTurn
|
|
44
|
-
} from "./chunk-
|
|
44
|
+
} from "./chunk-NIV5GVCE.mjs";
|
|
45
45
|
import {
|
|
46
46
|
applyStateRootHygiene
|
|
47
47
|
} from "./chunk-BAS4J57E.mjs";
|
|
48
|
+
import {
|
|
49
|
+
detectToolChoicePolicyForTurn
|
|
50
|
+
} from "./chunk-O6YH4BTO.mjs";
|
|
48
51
|
import {
|
|
49
52
|
buildToolResultMediaUrlList,
|
|
50
53
|
mapRawSourcePerDeliveredPart,
|
|
@@ -52,11 +55,17 @@ import {
|
|
|
52
55
|
} from "./chunk-BIEZNK2B.mjs";
|
|
53
56
|
import {
|
|
54
57
|
getMobileWebSocketServer
|
|
55
|
-
} from "./chunk-
|
|
58
|
+
} from "./chunk-MMWLRPKT.mjs";
|
|
56
59
|
import {
|
|
57
60
|
resolveWorkspaceStartupBlock,
|
|
58
61
|
shouldAttachWorkspaceStartup
|
|
59
62
|
} from "./chunk-WQSQXDUL.mjs";
|
|
63
|
+
import {
|
|
64
|
+
sliceSessionMessagesV2Page
|
|
65
|
+
} from "./chunk-M2WHIUNH.mjs";
|
|
66
|
+
import {
|
|
67
|
+
settleMobileReasoningDeliverAfterInboundIdle
|
|
68
|
+
} from "./chunk-GSWQMKOE.mjs";
|
|
60
69
|
import {
|
|
61
70
|
buildMobileSystemPromptSnapshot
|
|
62
71
|
} from "./chunk-AP4WVS6L.mjs";
|
|
@@ -65,35 +74,33 @@ import {
|
|
|
65
74
|
healStaleToolCallsAfterStreamFinalize
|
|
66
75
|
} from "./chunk-ZNRN6DTK.mjs";
|
|
67
76
|
import {
|
|
68
|
-
|
|
69
|
-
|
|
77
|
+
detectFakeProviderImageUrl,
|
|
78
|
+
rehostRemoteImageUrlIfNeeded
|
|
79
|
+
} from "./chunk-E6MVUDMP.mjs";
|
|
80
|
+
import {
|
|
81
|
+
createOwnedReplyTextCapture
|
|
82
|
+
} from "./chunk-EOWUJO75.mjs";
|
|
70
83
|
import {
|
|
71
84
|
ensureReplyDispatchWarmupComplete,
|
|
72
85
|
startReplyDispatchWarmup
|
|
73
|
-
} from "./chunk-
|
|
86
|
+
} from "./chunk-MCD5TOFD.mjs";
|
|
74
87
|
import {
|
|
75
88
|
resolveWebchatSendSessionKeyFromSessions
|
|
76
89
|
} from "./chunk-BD3VJKX4.mjs";
|
|
77
90
|
import {
|
|
78
|
-
|
|
79
|
-
} from "./chunk-
|
|
80
|
-
import {
|
|
81
|
-
settleMobileReasoningDeliverAfterInboundIdle
|
|
82
|
-
} from "./chunk-GSWQMKOE.mjs";
|
|
91
|
+
composeNativeReplySystemPrompt
|
|
92
|
+
} from "./chunk-3STOFADV.mjs";
|
|
83
93
|
import {
|
|
84
94
|
appendMobileOfflineBatchGatewayTranscriptMaybe,
|
|
85
95
|
offlineSyncPartToGatewayPlainText
|
|
86
96
|
} from "./chunk-CYVEZZL5.mjs";
|
|
87
97
|
import {
|
|
88
98
|
runNativeOpenAiCompletionsTurnToDispatcher
|
|
89
|
-
} from "./chunk-
|
|
90
|
-
import {
|
|
91
|
-
detectFakeProviderImageUrl,
|
|
92
|
-
rehostRemoteImageUrlIfNeeded
|
|
93
|
-
} from "./chunk-E6MVUDMP.mjs";
|
|
99
|
+
} from "./chunk-SLBCSYGP.mjs";
|
|
94
100
|
import {
|
|
95
|
-
|
|
96
|
-
|
|
101
|
+
isMobileSuppressFinalBlockAssistTextDeliverEnabled,
|
|
102
|
+
shouldSuppressAssistTextFromNativeDeliver
|
|
103
|
+
} from "./chunk-ZJEZUSIG.mjs";
|
|
97
104
|
import {
|
|
98
105
|
promoteExactOutboundPathTextToNativeReply
|
|
99
106
|
} from "./chunk-IWVFK6JY.mjs";
|
|
@@ -103,33 +110,19 @@ import {
|
|
|
103
110
|
resolveNativeReplyRoute,
|
|
104
111
|
resolveNativeReplyRouteAsync,
|
|
105
112
|
shouldResolveNativeReplyRouteAsync
|
|
106
|
-
} from "./chunk-
|
|
113
|
+
} from "./chunk-G5LQ2PQ6.mjs";
|
|
107
114
|
import {
|
|
108
115
|
buildNativeAnthropicTurnToolBlocks,
|
|
109
116
|
buildNativeOpenAiTurnToolBlocks,
|
|
110
117
|
buildNativeReplyRuntimeContextBlocks,
|
|
111
118
|
buildOwnedNativeReplyChildTurnBlocks
|
|
112
|
-
} from "./chunk-
|
|
113
|
-
import {
|
|
114
|
-
composeNativeReplySystemPrompt
|
|
115
|
-
} from "./chunk-3STOFADV.mjs";
|
|
116
|
-
import {
|
|
117
|
-
formatNativeAnthropicTurnUserMessage
|
|
118
|
-
} from "./chunk-EE3NRJLQ.mjs";
|
|
119
|
-
import {
|
|
120
|
-
isMobileSuppressFinalBlockAssistTextDeliverEnabled,
|
|
121
|
-
shouldSuppressAssistTextFromNativeDeliver
|
|
122
|
-
} from "./chunk-ZJEZUSIG.mjs";
|
|
123
|
-
import {
|
|
124
|
-
MOBILE_PLUGIN_HTTP_ROUTE_DEFS
|
|
125
|
-
} from "./chunk-VMM5GYS2.mjs";
|
|
119
|
+
} from "./chunk-2NBVNRMZ.mjs";
|
|
126
120
|
import {
|
|
127
121
|
buildMobileReasoningReplyOptions
|
|
128
122
|
} from "./chunk-46TY43IV.mjs";
|
|
129
123
|
import {
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
} from "./chunk-6MOIFLPP.mjs";
|
|
124
|
+
formatNativeAnthropicTurnUserMessage
|
|
125
|
+
} from "./chunk-EE3NRJLQ.mjs";
|
|
133
126
|
import {
|
|
134
127
|
buildMemoryContractR3StrongDeliveryHint,
|
|
135
128
|
buildR3AuditNote,
|
|
@@ -138,25 +131,10 @@ import {
|
|
|
138
131
|
} from "./chunk-CTOIVB2P.mjs";
|
|
139
132
|
import {
|
|
140
133
|
runR5EmptyResultInvestigation
|
|
141
|
-
} from "./chunk-
|
|
142
|
-
import {
|
|
143
|
-
prefetchMemoryR1Block
|
|
144
|
-
} from "./chunk-PW3ULDNL.mjs";
|
|
134
|
+
} from "./chunk-H4BNL7XG.mjs";
|
|
145
135
|
import {
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
} from "./chunk-USRORWYS.mjs";
|
|
149
|
-
import {
|
|
150
|
-
resolveOutboundLocalMediaAbsolutePath
|
|
151
|
-
} from "./chunk-I77V2ROO.mjs";
|
|
152
|
-
import {
|
|
153
|
-
tryInlineLocalImageAsDataUrl
|
|
154
|
-
} from "./chunk-JOT5IE27.mjs";
|
|
155
|
-
import {
|
|
156
|
-
deriveFileMetaFromUrlOrPath,
|
|
157
|
-
parseAnyDataUrlPayload,
|
|
158
|
-
tryInlineLocalMediaAsDataUrl
|
|
159
|
-
} from "./chunk-5HQXZCIX.mjs";
|
|
136
|
+
MOBILE_PLUGIN_HTTP_ROUTE_DEFS
|
|
137
|
+
} from "./chunk-VMM5GYS2.mjs";
|
|
160
138
|
import {
|
|
161
139
|
buildInterruptedTurnResumeContextBlock,
|
|
162
140
|
classifyTurnTimeoutKind,
|
|
@@ -171,8 +149,12 @@ import {
|
|
|
171
149
|
expandMediaUrlWildcards
|
|
172
150
|
} from "./chunk-RXRZEWNK.mjs";
|
|
173
151
|
import {
|
|
174
|
-
|
|
175
|
-
} from "./chunk-
|
|
152
|
+
prefetchMemoryR1Block
|
|
153
|
+
} from "./chunk-CVIZMDMZ.mjs";
|
|
154
|
+
import {
|
|
155
|
+
buildMemoryContractR1ExtraSystemPrompt,
|
|
156
|
+
shouldAttachMemoryContractR1Prompt
|
|
157
|
+
} from "./chunk-6MOIFLPP.mjs";
|
|
176
158
|
import {
|
|
177
159
|
tryExtractContextUsageRatioFromDeliverPayload
|
|
178
160
|
} from "./chunk-OCARTQYW.mjs";
|
|
@@ -198,6 +180,21 @@ import {
|
|
|
198
180
|
createChatAbortOpsFromContext,
|
|
199
181
|
tryParseGatewayChatAbortContext
|
|
200
182
|
} from "./chunk-CI47MU64.mjs";
|
|
183
|
+
import {
|
|
184
|
+
rehydrateChatMessageForClient,
|
|
185
|
+
rehydrateChatMessagesForClient
|
|
186
|
+
} from "./chunk-USRORWYS.mjs";
|
|
187
|
+
import {
|
|
188
|
+
resolveOutboundLocalMediaAbsolutePath
|
|
189
|
+
} from "./chunk-I77V2ROO.mjs";
|
|
190
|
+
import {
|
|
191
|
+
tryInlineLocalImageAsDataUrl
|
|
192
|
+
} from "./chunk-JOT5IE27.mjs";
|
|
193
|
+
import {
|
|
194
|
+
deriveFileMetaFromUrlOrPath,
|
|
195
|
+
parseAnyDataUrlPayload,
|
|
196
|
+
tryInlineLocalMediaAsDataUrl
|
|
197
|
+
} from "./chunk-5HQXZCIX.mjs";
|
|
201
198
|
import {
|
|
202
199
|
createEmptyMobileBodyHuntRoundTrace,
|
|
203
200
|
formatBodyHuntPreview
|
|
@@ -207,13 +204,13 @@ import {
|
|
|
207
204
|
isMobileChannelEnabled,
|
|
208
205
|
resolveMobileInboundIdentity,
|
|
209
206
|
resolveMobileRouteAgent
|
|
210
|
-
} from "./chunk-
|
|
207
|
+
} from "./chunk-OQMIECO2.mjs";
|
|
211
208
|
import {
|
|
212
|
-
|
|
213
|
-
} from "./chunk-
|
|
209
|
+
mergeComposerContextUsageForFinalize
|
|
210
|
+
} from "./chunk-37TO75LW.mjs";
|
|
214
211
|
import {
|
|
215
212
|
createMobileApiRequestHandler
|
|
216
|
-
} from "./chunk-
|
|
213
|
+
} from "./chunk-MFIBP6MD.mjs";
|
|
217
214
|
import {
|
|
218
215
|
consumeInboundMobileUploadRef,
|
|
219
216
|
looksLikeXkzoomMediaRefV1
|
|
@@ -223,12 +220,15 @@ import {
|
|
|
223
220
|
} from "./chunk-FU5NWQEP.mjs";
|
|
224
221
|
import {
|
|
225
222
|
buildAgentCapabilities
|
|
226
|
-
} from "./chunk-
|
|
223
|
+
} from "./chunk-LMIEVEGA.mjs";
|
|
224
|
+
import {
|
|
225
|
+
runNativeAnthropicMessagesTurnToDispatcher
|
|
226
|
+
} from "./chunk-EBVVOJVN.mjs";
|
|
227
227
|
import {
|
|
228
228
|
OWNED_TURN_TOOL_NAMES,
|
|
229
229
|
buildOwnedToolsCatalog,
|
|
230
230
|
buildOwnedTurnToolSchemas
|
|
231
|
-
} from "./chunk-
|
|
231
|
+
} from "./chunk-MLHV7EMJ.mjs";
|
|
232
232
|
import {
|
|
233
233
|
buildSessionTranscriptMeterFromMessages
|
|
234
234
|
} from "./chunk-4IWTTXQE.mjs";
|
|
@@ -248,7 +248,13 @@ import {
|
|
|
248
248
|
} from "./chunk-P262PAGZ.mjs";
|
|
249
249
|
import {
|
|
250
250
|
runNativeAnthropicMessagesStreamToDispatcher
|
|
251
|
-
} from "./chunk-
|
|
251
|
+
} from "./chunk-FZ7NLBVP.mjs";
|
|
252
|
+
import {
|
|
253
|
+
enforceR2Write
|
|
254
|
+
} from "./chunk-GU4CQC5I.mjs";
|
|
255
|
+
import {
|
|
256
|
+
enforceR6IndexAfterWrite
|
|
257
|
+
} from "./chunk-GOSSEVA6.mjs";
|
|
252
258
|
import {
|
|
253
259
|
MemoryContractR1Tracker,
|
|
254
260
|
MemoryContractR2Tracker,
|
|
@@ -258,35 +264,15 @@ import {
|
|
|
258
264
|
isMemoryContractRuntimeEnforceEnabled,
|
|
259
265
|
logMemoryContractR6Deferred
|
|
260
266
|
} from "./chunk-XQFQO4EA.mjs";
|
|
261
|
-
import {
|
|
262
|
-
enforceR2Write
|
|
263
|
-
} from "./chunk-GU4CQC5I.mjs";
|
|
264
|
-
import {
|
|
265
|
-
enforceR6IndexAfterWrite
|
|
266
|
-
} from "./chunk-GOSSEVA6.mjs";
|
|
267
267
|
import {
|
|
268
268
|
buildRecentDiaryContextBlock,
|
|
269
269
|
buildRecentDiaryInjectSummary
|
|
270
270
|
} from "./chunk-BW737ZQN.mjs";
|
|
271
|
-
import {
|
|
272
|
-
runNativeOpenAiTextStreamToDispatcher
|
|
273
|
-
} from "./chunk-MKYCBV3H.mjs";
|
|
274
|
-
import {
|
|
275
|
-
diagnoseNativeReplyRouteMiss,
|
|
276
|
-
formatNativeReplyRouteMissMessage
|
|
277
|
-
} from "./chunk-NEDXMES6.mjs";
|
|
278
|
-
import {
|
|
279
|
-
applyModelOverrideToGatewayConfig,
|
|
280
|
-
gatewayAgentWantsFullToolLoop,
|
|
281
|
-
init_native_gateway_config,
|
|
282
|
-
normalizeModelOverrideKey,
|
|
283
|
-
resolveGatewayAgentToolsProfile
|
|
284
|
-
} from "./chunk-LR5GC3NZ.mjs";
|
|
285
271
|
import {
|
|
286
272
|
dispatchGroupSessionMessage,
|
|
287
273
|
forceStopGroupFloorState,
|
|
288
274
|
initGroupCollaborationEngine
|
|
289
|
-
} from "./chunk-
|
|
275
|
+
} from "./chunk-O7MFL7L4.mjs";
|
|
290
276
|
import {
|
|
291
277
|
buildGroupPeerTranscriptProjection
|
|
292
278
|
} from "./chunk-BSG6WLML.mjs";
|
|
@@ -299,13 +285,13 @@ import {
|
|
|
299
285
|
} from "./chunk-4POYX4AW.mjs";
|
|
300
286
|
import {
|
|
301
287
|
buildContextPackForTurn
|
|
302
|
-
} from "./chunk-
|
|
303
|
-
import {
|
|
304
|
-
renderContextPackStablePrefixForProviderCache
|
|
305
|
-
} from "./chunk-XL3MUGFG.mjs";
|
|
288
|
+
} from "./chunk-NUXJHSSQ.mjs";
|
|
306
289
|
import {
|
|
307
290
|
maybeCheckpointRunLedger
|
|
308
291
|
} from "./chunk-EL6TOIFZ.mjs";
|
|
292
|
+
import {
|
|
293
|
+
renderContextPackStablePrefixForProviderCache
|
|
294
|
+
} from "./chunk-XL3MUGFG.mjs";
|
|
309
295
|
import {
|
|
310
296
|
updateRunLedger
|
|
311
297
|
} from "./chunk-4WWT6OC2.mjs";
|
|
@@ -318,12 +304,12 @@ import {
|
|
|
318
304
|
import {
|
|
319
305
|
getMobileChatStore
|
|
320
306
|
} from "./chunk-CVXJ45WI.mjs";
|
|
321
|
-
import {
|
|
322
|
-
SessionIdAgentConflictError
|
|
323
|
-
} from "./chunk-KPJOJH6H.mjs";
|
|
324
307
|
import {
|
|
325
308
|
registerMobileOutboundBridge
|
|
326
309
|
} from "./chunk-LCR7EVVU.mjs";
|
|
310
|
+
import {
|
|
311
|
+
SessionIdAgentConflictError
|
|
312
|
+
} from "./chunk-KPJOJH6H.mjs";
|
|
327
313
|
import {
|
|
328
314
|
buildNativeReplyOpenAiMessages,
|
|
329
315
|
buildNativeReplyTranscriptMessages,
|
|
@@ -336,7 +322,21 @@ import {
|
|
|
336
322
|
GATEWAY_WEBCHAT_CHANNEL_ID,
|
|
337
323
|
MOBILE_SOURCE,
|
|
338
324
|
XKZOOM_CHAT_CHANNEL_ID
|
|
339
|
-
} from "./chunk-
|
|
325
|
+
} from "./chunk-LKSRZTSL.mjs";
|
|
326
|
+
import {
|
|
327
|
+
runNativeOpenAiTextStreamToDispatcher
|
|
328
|
+
} from "./chunk-BHT6B2TV.mjs";
|
|
329
|
+
import {
|
|
330
|
+
diagnoseNativeReplyRouteMiss,
|
|
331
|
+
formatNativeReplyRouteMissMessage
|
|
332
|
+
} from "./chunk-NEDXMES6.mjs";
|
|
333
|
+
import {
|
|
334
|
+
applyModelOverrideToGatewayConfig,
|
|
335
|
+
gatewayAgentWantsFullToolLoop,
|
|
336
|
+
init_native_gateway_config,
|
|
337
|
+
normalizeModelOverrideKey,
|
|
338
|
+
resolveGatewayAgentToolsProfile
|
|
339
|
+
} from "./chunk-LR5GC3NZ.mjs";
|
|
340
340
|
import {
|
|
341
341
|
init_state_dir,
|
|
342
342
|
resolveXkzoomStateDirForProcess
|
|
@@ -9,13 +9,13 @@ import {
|
|
|
9
9
|
tryKickPipelinePostCloseRound,
|
|
10
10
|
tryRedirectPipelineFloor,
|
|
11
11
|
tryStopPipelineAfterTerminalDecision
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-O7MFL7L4.mjs";
|
|
13
13
|
import {
|
|
14
14
|
isOrgProjectPipelineEnabled
|
|
15
15
|
} from "./chunk-AZVEPDT6.mjs";
|
|
16
16
|
import {
|
|
17
17
|
enqueuePostCloseDebrief
|
|
18
|
-
} from "./chunk-
|
|
18
|
+
} from "./chunk-ED4H2DM7.mjs";
|
|
19
19
|
import {
|
|
20
20
|
acceptHandoff,
|
|
21
21
|
confirmCeoProjectRequirements,
|
|
@@ -33,15 +33,15 @@ import {
|
|
|
33
33
|
submitAuditVerdict,
|
|
34
34
|
submitCeoDecisionRouted,
|
|
35
35
|
submitProjectBrief
|
|
36
|
-
} from "./chunk-
|
|
37
|
-
import {
|
|
38
|
-
isPipelineDepartmentId
|
|
39
|
-
} from "./chunk-LREFRIQQ.mjs";
|
|
36
|
+
} from "./chunk-3OXBG4OP.mjs";
|
|
40
37
|
import {
|
|
41
38
|
loadPipelineCharter,
|
|
42
39
|
resolveDeptLeadAgentId,
|
|
43
40
|
resolveDeptMemberAgentIds
|
|
44
41
|
} from "./chunk-KHQZ35IL.mjs";
|
|
42
|
+
import {
|
|
43
|
+
isPipelineDepartmentId
|
|
44
|
+
} from "./chunk-LREFRIQQ.mjs";
|
|
45
45
|
import {
|
|
46
46
|
loadTeamCharter
|
|
47
47
|
} from "./chunk-KDZWHGGN.mjs";
|
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
buildMemoryReadinessReport,
|
|
4
4
|
readLastMemoryReadinessGate,
|
|
5
5
|
readLastMemoryReadinessReport
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-MTRG3ZME.mjs";
|
|
7
7
|
import {
|
|
8
8
|
buildMemorySoakEvidenceSummary,
|
|
9
9
|
completeMemorySoakSession,
|
|
@@ -22,7 +22,7 @@ import {
|
|
|
22
22
|
import {
|
|
23
23
|
readLastMemoryRuntimeEvalReport,
|
|
24
24
|
runMemoryRuntimeV2SelfEval
|
|
25
|
-
} from "./chunk-
|
|
25
|
+
} from "./chunk-P4WX5RWE.mjs";
|
|
26
26
|
import {
|
|
27
27
|
buildSkillRegistryReport,
|
|
28
28
|
formatSkillRegistryBlock,
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
assessDeliveryVerification
|
|
3
|
-
} from "./chunk-ETD5LGJY.mjs";
|
|
4
1
|
import {
|
|
5
2
|
patchTeamTaskBoard
|
|
6
3
|
} from "./chunk-BHA3SMKH.mjs";
|
|
4
|
+
import {
|
|
5
|
+
assessDeliveryVerification
|
|
6
|
+
} from "./chunk-Z3COATFF.mjs";
|
|
7
7
|
import {
|
|
8
8
|
parseCompactSummarizerJsonLenient
|
|
9
9
|
} from "./chunk-EGCSHXCF.mjs";
|
|
@@ -3,11 +3,11 @@ import {
|
|
|
3
3
|
} from "./chunk-NZPFW3RO.mjs";
|
|
4
4
|
import {
|
|
5
5
|
createInitialFloorState
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-DXPZNBSQ.mjs";
|
|
7
7
|
import {
|
|
8
8
|
getGroupFloorState,
|
|
9
9
|
setGroupFloorState
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-LJ6RMHC6.mjs";
|
|
11
11
|
import {
|
|
12
12
|
GROUP_FLOOR_PLAN_SCHEDULING_REASON
|
|
13
13
|
} from "./chunk-INHFVKZY.mjs";
|
|
@@ -22,16 +22,10 @@ import {
|
|
|
22
22
|
linkTeamToProject,
|
|
23
23
|
submitProjectBrief,
|
|
24
24
|
updateOrgProjectCeoSettings
|
|
25
|
-
} from "./chunk-
|
|
25
|
+
} from "./chunk-3OXBG4OP.mjs";
|
|
26
26
|
import {
|
|
27
27
|
isOrgPipelineCharter
|
|
28
|
-
} from "./chunk-
|
|
29
|
-
import {
|
|
30
|
-
ORG_PIPELINE_CHARTER_RULES,
|
|
31
|
-
ORG_PIPELINE_DEPT_ORDER,
|
|
32
|
-
ORG_PIPELINE_TEMPLATE_ID,
|
|
33
|
-
resolveDeptRoleAssignments
|
|
34
|
-
} from "./chunk-LREFRIQQ.mjs";
|
|
28
|
+
} from "./chunk-6SYECCCG.mjs";
|
|
35
29
|
import {
|
|
36
30
|
PipelineCharterValidationError,
|
|
37
31
|
buildMembersFromDepartments,
|
|
@@ -42,6 +36,12 @@ import {
|
|
|
42
36
|
import {
|
|
43
37
|
parseDynamicDeptSlugFromPhase
|
|
44
38
|
} from "./chunk-6XBAYBWZ.mjs";
|
|
39
|
+
import {
|
|
40
|
+
ORG_PIPELINE_CHARTER_RULES,
|
|
41
|
+
ORG_PIPELINE_DEPT_ORDER,
|
|
42
|
+
ORG_PIPELINE_TEMPLATE_ID,
|
|
43
|
+
resolveDeptRoleAssignments
|
|
44
|
+
} from "./chunk-LREFRIQQ.mjs";
|
|
45
45
|
import {
|
|
46
46
|
ensureOrgPipelineCharter,
|
|
47
47
|
ensureTeamCharterFromMembers,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
assessPipelineHandoffFromToolCalls
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-AINHKBJW.mjs";
|
|
4
4
|
|
|
5
5
|
// src/mobile/group/pipeline-handoff-verification.ts
|
|
6
6
|
var PIPELINE_HANDOFF_CLAIM_PATTERN = /(?:已交接|已经完成交接|交接给|交给(?:产品|研发|审计|调研)|handoff(?:\s*工具)?(?:已|成功)|(?:product|research|dev|audit)_active|流水线(?:已|正常)推进|下游(?:部门)?已激活|补交\s*handoff)/i;
|
|
@@ -1,3 +1,12 @@
|
|
|
1
|
+
import {
|
|
2
|
+
init_minimax_video_generate,
|
|
3
|
+
minimaxVideoGenerate
|
|
4
|
+
} from "./chunk-CRYBNNZU.mjs";
|
|
5
|
+
import {
|
|
6
|
+
init_minimax_voice,
|
|
7
|
+
minimaxVoiceClone,
|
|
8
|
+
minimaxVoiceDesign
|
|
9
|
+
} from "./chunk-5IAQOOZ2.mjs";
|
|
1
10
|
import {
|
|
2
11
|
init_minimax_web_search,
|
|
3
12
|
minimaxWebSearch
|
|
@@ -26,15 +35,6 @@ import {
|
|
|
26
35
|
init_minimax_music_generate,
|
|
27
36
|
minimaxMusicGenerate
|
|
28
37
|
} from "./chunk-YUB67QUF.mjs";
|
|
29
|
-
import {
|
|
30
|
-
init_minimax_video_generate,
|
|
31
|
-
minimaxVideoGenerate
|
|
32
|
-
} from "./chunk-QADC4VKT.mjs";
|
|
33
|
-
import {
|
|
34
|
-
init_minimax_voice,
|
|
35
|
-
minimaxVoiceClone,
|
|
36
|
-
minimaxVoiceDesign
|
|
37
|
-
} from "./chunk-I7O5UR24.mjs";
|
|
38
38
|
import {
|
|
39
39
|
braveWebSearch,
|
|
40
40
|
init_brave_web_search
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
import {
|
|
2
|
+
init_resolver,
|
|
3
|
+
standardPaths
|
|
4
|
+
} from "./chunk-73YFGE5V.mjs";
|
|
5
|
+
import {
|
|
6
|
+
getXkRootPath,
|
|
7
|
+
init_root
|
|
8
|
+
} from "./chunk-LMB7TNJB.mjs";
|
|
9
|
+
|
|
10
|
+
// src/mobile/agents-watch.ts
|
|
11
|
+
init_root();
|
|
12
|
+
init_resolver();
|
|
13
|
+
import { watch, existsSync } from "fs";
|
|
14
|
+
var DEBOUNCE_MS = 400;
|
|
15
|
+
var agentsDirWatcher = null;
|
|
16
|
+
var stateRootWatcher = null;
|
|
17
|
+
var debounceTimer = null;
|
|
18
|
+
var started = false;
|
|
19
|
+
function normalizeRel(filename) {
|
|
20
|
+
return (filename ?? "").replace(/\\/g, "/");
|
|
21
|
+
}
|
|
22
|
+
function isRelevantAgentsPath(filename) {
|
|
23
|
+
const rel = normalizeRel(filename);
|
|
24
|
+
if (!rel) {
|
|
25
|
+
return true;
|
|
26
|
+
}
|
|
27
|
+
if (!rel.includes("/")) {
|
|
28
|
+
return true;
|
|
29
|
+
}
|
|
30
|
+
return rel.endsWith("/IDENTITY.md");
|
|
31
|
+
}
|
|
32
|
+
function startAgentsChangeWatch(onChange) {
|
|
33
|
+
if (started) {
|
|
34
|
+
return;
|
|
35
|
+
}
|
|
36
|
+
started = true;
|
|
37
|
+
const fire = () => {
|
|
38
|
+
if (debounceTimer) {
|
|
39
|
+
clearTimeout(debounceTimer);
|
|
40
|
+
}
|
|
41
|
+
debounceTimer = setTimeout(() => {
|
|
42
|
+
debounceTimer = null;
|
|
43
|
+
try {
|
|
44
|
+
onChange();
|
|
45
|
+
} catch {
|
|
46
|
+
}
|
|
47
|
+
}, DEBOUNCE_MS);
|
|
48
|
+
};
|
|
49
|
+
try {
|
|
50
|
+
const agentsDir = standardPaths.agents();
|
|
51
|
+
if (existsSync(agentsDir)) {
|
|
52
|
+
agentsDirWatcher = watch(agentsDir, { recursive: true }, (_event, filename) => {
|
|
53
|
+
if (isRelevantAgentsPath(filename)) {
|
|
54
|
+
fire();
|
|
55
|
+
}
|
|
56
|
+
});
|
|
57
|
+
agentsDirWatcher.on("error", () => {
|
|
58
|
+
});
|
|
59
|
+
agentsDirWatcher.unref();
|
|
60
|
+
}
|
|
61
|
+
} catch {
|
|
62
|
+
agentsDirWatcher = null;
|
|
63
|
+
}
|
|
64
|
+
try {
|
|
65
|
+
const stateRoot = getXkRootPath();
|
|
66
|
+
if (existsSync(stateRoot)) {
|
|
67
|
+
stateRootWatcher = watch(stateRoot, { recursive: false }, (_event, filename) => {
|
|
68
|
+
const rel = normalizeRel(filename);
|
|
69
|
+
if (!rel || rel === "xkzoom.json") {
|
|
70
|
+
fire();
|
|
71
|
+
}
|
|
72
|
+
});
|
|
73
|
+
stateRootWatcher.on("error", () => {
|
|
74
|
+
});
|
|
75
|
+
stateRootWatcher.unref();
|
|
76
|
+
}
|
|
77
|
+
} catch {
|
|
78
|
+
stateRootWatcher = null;
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
function stopAgentsChangeWatch() {
|
|
82
|
+
started = false;
|
|
83
|
+
if (debounceTimer) {
|
|
84
|
+
clearTimeout(debounceTimer);
|
|
85
|
+
debounceTimer = null;
|
|
86
|
+
}
|
|
87
|
+
try {
|
|
88
|
+
agentsDirWatcher?.close();
|
|
89
|
+
} catch {
|
|
90
|
+
}
|
|
91
|
+
try {
|
|
92
|
+
stateRootWatcher?.close();
|
|
93
|
+
} catch {
|
|
94
|
+
}
|
|
95
|
+
agentsDirWatcher = null;
|
|
96
|
+
stateRootWatcher = null;
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
export {
|
|
100
|
+
startAgentsChangeWatch,
|
|
101
|
+
stopAgentsChangeWatch
|
|
102
|
+
};
|