zigmini 0.9.0-beta.2 → 1.0.0-beta.1
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.ko.md +35 -5
- package/README.md +35 -5
- package/assets/agent/gateway-rules.md +1 -1
- package/assets/android/zigmini.apk +0 -0
- package/assets/android/zigmini.apk.json +3 -3
- package/assets/build.json +1 -1
- package/docs/manual.ko.md +51 -11
- package/docs/manual.md +52 -12
- package/host/omo-bridge/agent-control.ts +274 -0
- package/host/omo-bridge/bridge.ts +1 -1
- package/host/omo-bridge/continuity-control.ts +1 -1
- package/host/omo-bridge/model-control.ts +15 -3
- package/host/omo-bridge/task-control.ts +26 -16
- package/host/omo-check/patches/omo-5.1.48-compaction-recovery.patch +912 -0
- package/host/omo-check/patches/omo-5.1.48-gateway-port.manifest.json +12 -11
- package/host/omo-check/patches/omo-5.1.51-compaction-long-context.patch +92 -0
- package/host/omo-check/patches/omo-5.1.51-compaction-port.patch +2635 -0
- package/host/omo-check/patches/omo-5.1.51-compaction-recovery.patch +911 -0
- package/host/omo-check/patches/omo-5.1.51-gateway-port.manifest.json +363 -0
- package/host/omo-check/patches/omo-5.1.51-provider-failover.patch +50 -0
- package/host/omo-check/patches/omo-5.1.51-provider-port.patch +441 -0
- package/host/omo-check/patches/omo-5.1.51-rpc-port.patch +799 -0
- package/host/omo-check/patches/omo-5.1.51-runtime-compat.patch +31 -0
- package/package.json +3 -2
- package/src/agent/api.ts +215 -0
- package/src/agent/definition.ts +177 -0
- package/src/agent/fields.ts +42 -0
- package/src/agent/files.ts +192 -0
- package/src/agent/legacy-files.ts +46 -0
- package/src/agent/list.ts +21 -0
- package/src/agent-rules.ts +14 -5
- package/src/approvals.ts +6 -1
- package/src/cli/main.ts +33 -0
- package/src/cli/messages.ts +10 -2
- package/src/cli/rotate-main.ts +2 -1
- package/src/cli/scan.ts +414 -0
- package/src/cli/security-import.ts +155 -0
- package/src/compact.ts +22 -0
- package/src/decisions.ts +6 -4
- package/src/engine/compat.json +3 -3
- package/src/engine/index.ts +1 -0
- package/src/engine/schema-guard.ts +12 -4
- package/src/engine/sdk.ts +8 -0
- package/src/formal-verification.ts +366 -0
- package/src/gc.ts +37 -6
- package/src/hub.ts +525 -85
- package/src/main.ts +95 -9
- package/src/maintenance.ts +1 -1
- package/src/manual.ts +9 -2
- package/src/omo/client.ts +2 -0
- package/src/profile-prompt.ts +73 -0
- package/src/profile.ts +33 -10
- package/src/protocol.ts +11 -2
- package/src/question-notifications.ts +4 -1
- package/src/reply-notifications.ts +7 -1
- package/src/repo-security-setting.ts +33 -0
- package/src/runtime/paths.ts +16 -0
- package/src/security/baseline.ts +170 -0
- package/src/security/dex-strings.ts +242 -0
- package/src/security/repo-scan.ts +369 -0
- package/src/security/revision-probe.ts +144 -0
- package/src/security/terms.ts +97 -0
- package/src/security-allow.ts +1 -0
- package/src/security-baseline.ts +113 -0
- package/src/security-check.ts +91 -16
- package/src/server-text.ts +38 -0
- package/src/store.ts +142 -16
- package/src/transcript.ts +7 -1
- package/src/ui-language.ts +33 -0
- package/src/update/check.ts +7 -3
- package/src/update/handoff-system.ts +24 -16
- package/src/update/handoff.ts +23 -12
- package/src/update/helper.ts +72 -36
- package/src/update/request.ts +46 -30
- package/src/update/state.ts +21 -11
- package/src/update/strategy.ts +12 -5
- package/src/update/target.ts +32 -15
- package/src/usage.ts +43 -20
- package/src/version.ts +39 -16
- package/src/voice/agents.ts +8 -3
- package/src/voice/install.ts +29 -18
- package/src/work-watch.ts +40 -18
- package/web/agent-icon.js +15 -9
- package/web/agents.d.ts +201 -0
- package/web/agents.js +813 -0
- package/web/app-download.js +32 -19
- package/web/app.js +1407 -278
- package/web/autocopy.js +6 -1
- package/web/boot.js +27 -8
- package/web/commands.js +20 -11
- package/web/decisions.js +70 -49
- package/web/devlog.js +25 -19
- package/web/diagram.js +8 -3
- package/web/enroll.js +43 -22
- package/web/gc.js +32 -19
- package/web/i18n/agent-icon.js +24 -0
- package/web/i18n/agents.js +48 -0
- package/web/i18n/app-download.js +26 -0
- package/web/i18n/autocopy.js +5 -0
- package/web/i18n/boot.js +24 -0
- package/web/i18n/commands.js +34 -0
- package/web/i18n/decisions.js +24 -0
- package/web/i18n/devlog.js +60 -0
- package/web/i18n/diagram.js +12 -0
- package/web/i18n/enroll.js +22 -0
- package/web/i18n/gc.js +38 -0
- package/web/i18n/lastsent.js +10 -0
- package/web/i18n/main.d.ts +4 -0
- package/web/i18n/main.js +527 -0
- package/web/i18n/manual.d.ts +4 -0
- package/web/i18n/manual.js +14 -0
- package/web/i18n/memo.js +30 -0
- package/web/i18n/notifications.js +16 -0
- package/web/i18n/profile.js +13 -0
- package/web/i18n/reference.js +26 -0
- package/web/i18n/security-inbox.js +40 -0
- package/web/i18n/slash.js +38 -0
- package/web/i18n/turn-stats.js +5 -0
- package/web/i18n/update.js +42 -0
- package/web/i18n/voice.js +28 -0
- package/web/i18n/wake.js +16 -0
- package/web/i18n/workid.js +10 -0
- package/web/i18n/workstatus.js +20 -0
- package/web/i18n.d.ts +20 -0
- package/web/i18n.js +63 -0
- package/web/index.html +156 -96
- package/web/lastsent.js +9 -4
- package/web/manual.d.ts +1 -1
- package/web/manual.js +11 -5
- package/web/memo.js +18 -13
- package/web/notifications.js +12 -7
- package/web/profile.js +42 -17
- package/web/reference.js +20 -15
- package/web/security-inbox.d.ts +18 -1
- package/web/security-inbox.js +173 -4
- package/web/slash.js +23 -13
- package/web/style.css +132 -3
- package/web/tooltip.js +5 -2
- package/web/turn-stats.js +6 -2
- package/web/update.js +31 -23
- package/web/voice.js +18 -8
- package/web/wake.d.ts +4 -0
- package/web/wake.js +7 -3
- package/web/workid.js +12 -2
- package/web/workstatus.js +36 -32
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
{
|
|
2
2
|
"schema": 1,
|
|
3
|
-
"revision":
|
|
3
|
+
"revision": 3,
|
|
4
4
|
"upstream": {
|
|
5
5
|
"omo": "5.1.48",
|
|
6
6
|
"senpi": "2026.10.25-2"
|
|
7
7
|
},
|
|
8
|
-
"candidate": "<zigmini home>/omo/5.1.48-zgw.
|
|
8
|
+
"candidate": "<zigmini home>/omo/5.1.48-zgw.3",
|
|
9
9
|
"pristine": "<zigmini home>/omo/5.1.48",
|
|
10
10
|
"entrypoint": "node_modules/@code-yeongyu/senpi/dist/cli.js",
|
|
11
11
|
"patchRoot": "node_modules",
|
|
@@ -13,7 +13,8 @@
|
|
|
13
13
|
"omo-5.1.48-rpc-port.patch",
|
|
14
14
|
"omo-5.1.48-compaction-port.patch",
|
|
15
15
|
"omo-5.1.48-provider-port.patch",
|
|
16
|
-
"omo-5.1.48-runtime-compat.patch"
|
|
16
|
+
"omo-5.1.48-runtime-compat.patch",
|
|
17
|
+
"omo-5.1.48-compaction-recovery.patch"
|
|
17
18
|
],
|
|
18
19
|
"files": [
|
|
19
20
|
{
|
|
@@ -24,7 +25,7 @@
|
|
|
24
25
|
{
|
|
25
26
|
"path": "node_modules/@code-yeongyu/senpi/dist/core/agent-session.js",
|
|
26
27
|
"originalSha256": "7275ef36a6e5368eaea0d507644208c406f83bfaee2004984b9f94ac348ecc02",
|
|
27
|
-
"patchedSha256": "
|
|
28
|
+
"patchedSha256": "312825f603d98af540512ff0ee1c02da9ae54d081535a7b851fd788c9b65937d"
|
|
28
29
|
},
|
|
29
30
|
{
|
|
30
31
|
"path": "node_modules/@code-yeongyu/senpi/dist/core/auth-storage.js",
|
|
@@ -79,7 +80,7 @@
|
|
|
79
80
|
{
|
|
80
81
|
"path": "node_modules/@code-yeongyu/senpi/dist/core/extensions/builtin/anthropic-subscription/stream.js",
|
|
81
82
|
"originalSha256": "600dd50df1f34d7367636510a5e63106d674024454ac0c0501d97a266098c489",
|
|
82
|
-
"patchedSha256": "
|
|
83
|
+
"patchedSha256": "86436c9ba31895ad99da8fd097b3a7dbbcfd71325a959ae574e93c642a2b4623"
|
|
83
84
|
},
|
|
84
85
|
{
|
|
85
86
|
"path": "node_modules/@code-yeongyu/senpi/dist/core/extensions/builtin/ask-user/pending.js",
|
|
@@ -114,7 +115,7 @@
|
|
|
114
115
|
{
|
|
115
116
|
"path": "node_modules/@code-yeongyu/senpi/dist/core/extensions/builtin/compaction/context-reduction-lifecycle.js",
|
|
116
117
|
"originalSha256": "6c2a30053a0ff1d8c2c16471ac329f9927777c821dd1fb3c5e73a8bbd7c9e06b",
|
|
117
|
-
"patchedSha256": "
|
|
118
|
+
"patchedSha256": "b6ebc56683a9abd768f4bc1dfaddaea28dbdc7a24586254729700836d93f3a5e"
|
|
118
119
|
},
|
|
119
120
|
{
|
|
120
121
|
"path": "node_modules/@code-yeongyu/senpi/dist/core/extensions/builtin/compaction/deterministic-fallback.js",
|
|
@@ -134,7 +135,7 @@
|
|
|
134
135
|
{
|
|
135
136
|
"path": "node_modules/@code-yeongyu/senpi/dist/core/extensions/builtin/compaction/index.js",
|
|
136
137
|
"originalSha256": "090f17d798e47486e038dc673cf5f20fbd66c54fda73460b20f0d8c770793645",
|
|
137
|
-
"patchedSha256": "
|
|
138
|
+
"patchedSha256": "861ecef9412c7dd7014f2424fc9be18fbec5668e65318b5f51075e1efa463489"
|
|
138
139
|
},
|
|
139
140
|
{
|
|
140
141
|
"path": "node_modules/@code-yeongyu/senpi/dist/core/extensions/builtin/compaction/lane-policy.js",
|
|
@@ -194,7 +195,7 @@
|
|
|
194
195
|
{
|
|
195
196
|
"path": "node_modules/@code-yeongyu/senpi/dist/core/extensions/builtin/compaction/speculative-summary.js",
|
|
196
197
|
"originalSha256": "25dc617e8b999f7b38e638287df81790768279aa78a607e692ccd2b108b88ada",
|
|
197
|
-
"patchedSha256": "
|
|
198
|
+
"patchedSha256": "103b36b2a4f2755d6ea349ac4e0c38b84058e88adaa15ddecc5605db15718638"
|
|
198
199
|
},
|
|
199
200
|
{
|
|
200
201
|
"path": "node_modules/@code-yeongyu/senpi/dist/core/extensions/builtin/compaction/speculative.d.ts",
|
|
@@ -204,7 +205,7 @@
|
|
|
204
205
|
{
|
|
205
206
|
"path": "node_modules/@code-yeongyu/senpi/dist/core/extensions/builtin/compaction/speculative.js",
|
|
206
207
|
"originalSha256": "55332e85de550ea1b3f0c25df4898897fbe646c468fe7bf82ddacb16742becc7",
|
|
207
|
-
"patchedSha256": "
|
|
208
|
+
"patchedSha256": "d3a50b066cee5d21a67af0dff3df7c4e1664159f6c2ad1376c405685f102e74a"
|
|
208
209
|
},
|
|
209
210
|
{
|
|
210
211
|
"path": "node_modules/@code-yeongyu/senpi/dist/core/extensions/builtin/compaction/task-intent.js",
|
|
@@ -249,12 +250,12 @@
|
|
|
249
250
|
{
|
|
250
251
|
"path": "node_modules/@code-yeongyu/senpi/dist/core/extensions/runner.js",
|
|
251
252
|
"originalSha256": "bdd693f5c91dcf507b81262b19c48c5e721070033a75a59de3b0407144fe4346",
|
|
252
|
-
"patchedSha256": "
|
|
253
|
+
"patchedSha256": "46ee33b918130620bd08c4ba26f402b8274c71e7f7ccf41f9bdc7ca775a439a7"
|
|
253
254
|
},
|
|
254
255
|
{
|
|
255
256
|
"path": "node_modules/@code-yeongyu/senpi/dist/core/extensions/types.d.ts",
|
|
256
257
|
"originalSha256": "2bce6e8eec55ef835de724b7b62c8b02afda8e445ad873633bf25da07d37ea1a",
|
|
257
|
-
"patchedSha256": "
|
|
258
|
+
"patchedSha256": "359a267b3aec385dacc2f5809addcf6d395eb96610c67cd2914053ecae1fb8ee"
|
|
258
259
|
},
|
|
259
260
|
{
|
|
260
261
|
"path": "node_modules/@code-yeongyu/senpi/dist/core/model-runtime.js",
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
--- a/@code-yeongyu/senpi/dist/core/agent-session.js
|
|
2
|
+
+++ b/@code-yeongyu/senpi/dist/core/agent-session.js
|
|
3
|
+
@@ -65,6 +65,7 @@ import { exportSessionToHtml, renderSessionToHtml, } from "./export-html/index.j
|
|
4
|
+
import { createToolHtmlRenderer } from "./export-html/tool-renderer.js";
|
|
5
|
+
import { reportExtensionHandlerStall } from "./extension-handler-stall-report.js";
|
|
6
|
+
import { ANTHROPIC_SUBSCRIPTION_PROVIDER_ID } from "./extensions/builtin/anthropic-subscription/account-management.js";
|
|
7
|
+
+import { CLAUDE_CODE_DEFAULT_CONTEXT_WINDOW, LEGACY_LONG_CONTEXT_MODEL_IDS } from "./extensions/builtin/anthropic-subscription/context-window.js";
|
|
8
|
+
import { askUserAnswerDisplayText } from "./extensions/builtin/ask-user/format.js";
|
|
9
|
+
import { getPromptCachePrewarmUsage } from "./extensions/builtin/cache-keepalive/prewarm-entry.js";
|
|
10
|
+
import { ModelUsabilityBudgetError, projectModelUsabilityBudget, } from "./extensions/builtin/compaction/model-usability-budget.js";
|
|
11
|
+
@@ -1053,9 +1054,9 @@ export class AgentSession {
|
|
12
|
+
const usable = (model) => chat.some((entry) => same(entry, model)) && (!available.some((entry) => entry.provider === model.provider) || available.some((entry) => same(entry, model))) &&
|
|
13
|
+
!this._retryFallback.isProviderSpent(model.provider) &&
|
|
14
|
+
this._modelRuntime.isFallbackEligible(model.provider);
|
|
15
|
+
- const fits = (model) => {
|
|
16
|
+
- const output = Math.min(32768, model.maxTokens > 0 ? model.maxTokens : 32768, Math.floor(model.contextWindow / 2));
|
|
17
|
+
- return model.contextWindow > 0 && inputTokens + Math.max(settings.reserveTokens, output) <= model.contextWindow;
|
|
18
|
+
+ const fits = (model, window = model.contextWindow) => {
|
|
19
|
+
+ const output = Math.min(32768, model.maxTokens > 0 ? model.maxTokens : 32768, Math.floor(window / 2));
|
|
20
|
+
+ return window > 0 && inputTokens + Math.max(settings.reserveTokens, output) <= window;
|
|
21
|
+
};
|
|
22
|
+
if (explicit) {
|
|
23
|
+
if (typeof override !== "string" || !/^[^/\s]+\/\S+$/.test(override))
|
|
24
|
+
@@ -1080,11 +1081,32 @@ export class AgentSession {
|
|
25
|
+
model.provider === sessionModel.provider && family.test(model.id)) : [];
|
|
26
|
+
// Stable sort preserves registry order within the regular and fast Luna groups.
|
|
27
|
+
preferred.sort((left, right) => Number(/-luna-fast$/.test(left.id)) - Number(/-luna-fast$/.test(right.id)));
|
|
28
|
+
- const candidates = [...(family?.test(sessionModel.id) ? [sessionModel] : []), ...preferred, sessionModel];
|
|
29
|
+
+ // A subscription opens a legacy model's 1M window only with usage credits; a native-1M model needs none.
|
|
30
|
+
+ // Subscription order: the newest Sonnet of the catalog, the main model, the other Sonnets newest first, then any
|
|
31
|
+
+ // other available model, each within the window it opens without credits. Other providers keep light, then main.
|
|
32
|
+
+ const subscription = sessionModel.provider === ANTHROPIC_SUBSCRIPTION_PROVIDER_ID;
|
|
33
|
+
+ const creditFreeWindow = (model) => subscription && LEGACY_LONG_CONTEXT_MODEL_IDS.has(model.id) ? Math.min(model.contextWindow, CLAUDE_CODE_DEFAULT_CONTEXT_WINDOW) : model.contextWindow;
|
|
34
|
+
+ const version = (model) => {
|
|
35
|
+
+ const match = /^claude-sonnet-(\d{1,3})(?:-(\d{1,3}))?(?=-|$)/.exec(model.id);
|
|
36
|
+
+ return match ? Number(match[1]) * 1000 + Number(match[2] ?? 0) : 0;
|
|
37
|
+
+ };
|
|
38
|
+
+ const light = [...(family?.test(sessionModel.id) ? [sessionModel] : []), ...preferred];
|
|
39
|
+
+ const sonnets = subscription ? chat.filter((model) => model.provider === sessionModel.provider && family?.test(model.id)).sort((left, right) => version(right) - version(left)) : [];
|
|
40
|
+
+ const candidates = subscription ? [...sonnets.slice(0, 1), sessionModel, ...sonnets.slice(1), ...available] : [...light, sessionModel];
|
|
41
|
+
+ // A subscription candidate with a recorded summary block yields to the next one; if every fitting
|
|
42
|
+
+ // candidate is blocked, the first block is the reported cause.
|
|
43
|
+
+ let blocked;
|
|
44
|
+
for (const candidate of candidates) {
|
|
45
|
+
- if (candidate.provider === sessionModel.provider && usable(candidate) && fits(candidate))
|
|
46
|
+
+ if (candidate.provider === sessionModel.provider && usable(candidate) && fits(candidate, creditFreeWindow(candidate))) {
|
|
47
|
+
+ if (subscription && summaryUnavailable(this.sessionManager, candidate)) {
|
|
48
|
+
+ blocked ??= candidate;
|
|
49
|
+
+ continue;
|
|
50
|
+
+ }
|
|
51
|
+
return admit(candidate);
|
|
52
|
+
+ }
|
|
53
|
+
}
|
|
54
|
+
+ if (blocked)
|
|
55
|
+
+ return admit(blocked);
|
|
56
|
+
return fail(usable(sessionModel) ? "context_budget" : "model_unavailable");
|
|
57
|
+
}
|
|
58
|
+
_logCompactionModelFallback(override, reason, sessionModel) {
|
|
59
|
+
--- a/@code-yeongyu/senpi/dist/core/extensions/builtin/compaction/speculative.js
|
|
60
|
+
+++ b/@code-yeongyu/senpi/dist/core/extensions/builtin/compaction/speculative.js
|
|
61
|
+
@@ -252,7 +252,31 @@ export function canStartSummary(context, snapshot) {
|
|
62
|
+
return true;
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
+/**
|
|
66
|
+
+ * Gateway: a summary that a quota or account block stops moves once to the next model the resolver offers.
|
|
67
|
+
+ * The failed request recorded its block, so automatic selection skips that model; an explicit model, a model
|
|
68
|
+
+ * already tried and every other failure end the run. When every candidate is blocked the first error is thrown.
|
|
69
|
+
+ */
|
|
70
|
+
export async function runExtensionCompaction(context, snapshot, signal, onProgress) {
|
|
71
|
+
+ const tried = new Set();
|
|
72
|
+
+ let first;
|
|
73
|
+
+ for (;;) {
|
|
74
|
+
+ let selectedModel;
|
|
75
|
+
+ try { ({ selectedModel } = selectSummaryModel(context, snapshot)); }
|
|
76
|
+
+ catch (error) { throw first ?? error; }
|
|
77
|
+
+ const key = selectedModel.provider + "/" + selectedModel.id;
|
|
78
|
+
+ if (tried.has(key))
|
|
79
|
+
+ throw first;
|
|
80
|
+
+ tried.add(key);
|
|
81
|
+
+ try { return await runExtensionCompactionOnce(context, snapshot, signal, onProgress); }
|
|
82
|
+
+ catch (error) {
|
|
83
|
+
+ if (signal?.aborted || (error?.failure?.kind !== "quota" && error?.failure?.kind !== "account_blocked"))
|
|
84
|
+
+ throw error;
|
|
85
|
+
+ first ??= error;
|
|
86
|
+
+ }
|
|
87
|
+
+ }
|
|
88
|
+
+}
|
|
89
|
+
+async function runExtensionCompactionOnce(context, snapshot, signal, onProgress) {
|
|
90
|
+
if (signal?.aborted)
|
|
91
|
+
return undefined;
|
|
92
|
+
const { prompt, messages, inputTokens, selectedModel } = selectSummaryModel(context, snapshot);
|