@aspectlylabs/mikka 0.0.714 → 0.0.716

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/main.js CHANGED
@@ -1147,16 +1147,16 @@ var require_range = __commonJS({
1147
1147
  };
1148
1148
  var replaceTilde = (comp, options) => {
1149
1149
  const r = options.loose ? re[t.TILDELOOSE] : re[t.TILDE];
1150
- const z37 = options.includePrerelease ? "-0" : "";
1150
+ const z38 = options.includePrerelease ? "-0" : "";
1151
1151
  return comp.replace(r, (_, M, m, p, pr) => {
1152
1152
  debug("tilde", comp, _, M, m, p, pr);
1153
1153
  let ret;
1154
1154
  if (isX(M)) {
1155
1155
  ret = "";
1156
1156
  } else if (isX(m)) {
1157
- ret = `>=${M}.0.0${z37} <${+M + 1}.0.0-0`;
1157
+ ret = `>=${M}.0.0${z38} <${+M + 1}.0.0-0`;
1158
1158
  } else if (isX(p)) {
1159
- ret = `>=${M}.${m}.0${z37} <${M}.${+m + 1}.0-0`;
1159
+ ret = `>=${M}.${m}.0${z38} <${M}.${+m + 1}.0-0`;
1160
1160
  } else if (pr) {
1161
1161
  debug("replaceTilde pr", pr);
1162
1162
  ret = `>=${M}.${m}.${p}-${pr} <${M}.${+m + 1}.0-0`;
@@ -1173,19 +1173,19 @@ var require_range = __commonJS({
1173
1173
  var replaceCaret = (comp, options) => {
1174
1174
  debug("caret", comp, options);
1175
1175
  const r = options.loose ? re[t.CARETLOOSE] : re[t.CARET];
1176
- const z37 = options.includePrerelease ? "-0" : "";
1176
+ const z38 = options.includePrerelease ? "-0" : "";
1177
1177
  return comp.replace(r, (_, M, m, p, pr) => {
1178
1178
  debug("caret", comp, _, M, m, p, pr);
1179
1179
  let ret;
1180
1180
  if (isX(M)) {
1181
1181
  ret = "";
1182
1182
  } else if (isX(m)) {
1183
- ret = `>=${M}.0.0${z37} <${+M + 1}.0.0-0`;
1183
+ ret = `>=${M}.0.0${z38} <${+M + 1}.0.0-0`;
1184
1184
  } else if (isX(p)) {
1185
1185
  if (M === "0") {
1186
- ret = `>=${M}.${m}.0${z37} <${M}.${+m + 1}.0-0`;
1186
+ ret = `>=${M}.${m}.0${z38} <${M}.${+m + 1}.0-0`;
1187
1187
  } else {
1188
- ret = `>=${M}.${m}.0${z37} <${+M + 1}.0.0-0`;
1188
+ ret = `>=${M}.${m}.0${z38} <${+M + 1}.0.0-0`;
1189
1189
  }
1190
1190
  } else if (pr) {
1191
1191
  debug("replaceCaret pr", pr);
@@ -2221,6 +2221,14 @@ var USER_ERROR_CODES = {
2221
2221
  "adapter_start_failed",
2222
2222
  "cleanup_failed"
2223
2223
  ],
2224
+ /** Agent/Bot interop: reads, sends and Drive across threads and Bots (decision 2026-11-19-2200). */
2225
+ interop_not_found: [],
2226
+ interop_invalid_request: [],
2227
+ interop_scope_required: [],
2228
+ interop_send_unavailable: ["run_not_active", "thread_replaced", "thread_cannot_continue", "delivery_unavailable", "delivery_uncertain", "bot_unavailable", "continuation_requires_grant"],
2229
+ interop_diff_unavailable: ["no_checkpoint", "masked"],
2230
+ interop_drive_conflict: [],
2231
+ interop_drive_unavailable: ["file_too_large"],
2224
2232
  cloud_machine_unfunded: []
2225
2233
  };
2226
2234
 
@@ -6064,7 +6072,7 @@ import { join } from "node:path";
6064
6072
  // package.json
6065
6073
  var package_default = {
6066
6074
  name: "@mikka/daemon",
6067
- version: "0.0.714",
6075
+ version: "0.0.716",
6068
6076
  description: "Local Mikka daemon: runs agents through the user's own CLIs",
6069
6077
  type: "module",
6070
6078
  private: true,
@@ -6132,7 +6140,7 @@ var package_default = {
6132
6140
  engines: {
6133
6141
  node: ">=22"
6134
6142
  },
6135
- gitHead: "514b921155adbf4717ac3d71a5f842a6cfd3b1bc"
6143
+ gitHead: "c0661a23ac7ffd231ef10ad15ce379b20991c120"
6136
6144
  };
6137
6145
 
6138
6146
  // src/paths.ts
@@ -16883,6 +16891,7 @@ var RunSupervisor = class {
16883
16891
  const masker = this.maskers.get(runId);
16884
16892
  const checkpoint = taken?.checkpoint ? masker ? masker.checkpoint(taken.checkpoint) : taken.checkpoint : void 0;
16885
16893
  if (checkpoint) await save(runId, checkpoint);
16894
+ if (checkpoint) await run3.drive?.push();
16886
16895
  if (taken) {
16887
16896
  run3.lastCheckpointTree = taken.tree;
16888
16897
  run3.lastCheckpointHead = taken.head;
@@ -16910,6 +16919,7 @@ var RunSupervisor = class {
16910
16919
  const accepted = runCheckpointReceiptSchema.safeParse(await save(id5, checkpoint2));
16911
16920
  if (accepted.success && accepted.data.runId === id5) receipt = accepted.data;
16912
16921
  }, Date.now(), true);
16922
+ if (!this.stopping) await run3.drive?.push();
16913
16923
  const checkpoint = ready && receipt ? { checkpoint: "ready", checkpointTakenAt: receipt.takenAt } : { checkpoint: "unavailable" };
16914
16924
  if (finishingComplete && run3.sessionExited && !this.stopping)
16915
16925
  run3.safePoint = { session: "exited", observedAt: receipt?.takenAt ?? (/* @__PURE__ */ new Date()).toISOString(), ...checkpoint };
@@ -18118,7 +18128,13 @@ var RunSupervisor = class {
18118
18128
  throw error;
18119
18129
  }
18120
18130
  }
18121
- let prompt = [assignment.prompt, run3.secretBridge?.instructions].filter(Boolean).join("\n\n");
18131
+ if (!run3.drive && this.deps.prepareRunDrive) {
18132
+ run3.drive = await this.deps.prepareRunDrive(assignment, run3.abort.signal).catch(() => void 0);
18133
+ await run3.drive?.pull();
18134
+ }
18135
+ const driveBrief = run3.drive?.folders.length ? `Shared Drive folders on this machine (synced at checkpoints and when you finish; a version conflict keeps your copy beside the newer one):
18136
+ ${run3.drive.folders.map((folder) => `- ${folder.scope}: ${folder.path}${folder.write ? "" : " (read-only)"}`).join("\n")}` : void 0;
18137
+ let prompt = [assignment.prompt, run3.secretBridge?.instructions, driveBrief].filter(Boolean).join("\n\n");
18122
18138
  let followUp = assignment.followUp;
18123
18139
  if (splitChatFiles(prompt).files.length || followUp && splitChatFiles(followUp).files.length) {
18124
18140
  if (!this.deps.downloadChatFile || !this.deps.adapterStateDir) throw Error("Run attachments unavailable");
@@ -18708,8 +18724,20 @@ var DeviceSession = class {
18708
18724
  };
18709
18725
 
18710
18726
  // src/server-link-http.ts
18727
+ import { z as z37 } from "zod";
18728
+
18729
+ // src/run-drive.ts
18711
18730
  import { z as z36 } from "zod";
18712
- var deviceSessionRejection = z36.object({ error: z36.enum(["Unauthorized", "authRequired"]) }).strict();
18731
+ var READ_LIMIT = 1024 * 1024;
18732
+ var WRITE_LIMIT = 4 * 1024 * 1024;
18733
+ var scopeSchema = z36.object({ scope: z36.enum(["bot", "thread", "environment", "workspace"]), scopeId: z36.uuid(), write: z36.boolean() }).strict();
18734
+ var listingSchema = z36.object({
18735
+ volume: z36.object({ id: z36.string(), headDigest: z36.string(), entries: z36.array(z36.object({ path: z36.string(), sizeBytes: z36.number(), sha256: z36.string() })) }).nullable()
18736
+ }).passthrough();
18737
+ var stateSchema = z36.object({ volumeId: z36.string().nullable(), headDigest: z36.string().nullable(), files: z36.record(z36.string(), z36.string()) }).strict();
18738
+
18739
+ // src/server-link-http.ts
18740
+ var deviceSessionRejection = z37.object({ error: z37.enum(["Unauthorized", "authRequired"]) }).strict();
18713
18741
  var deviceSessionHeaders = { [DEVICE_SESSION_HEADER]: String(DEVICE_SESSION_VERSION) };
18714
18742
  var SessionRejectedError = class extends DaemonError {
18715
18743
  constructor() {
@@ -22688,6 +22716,7 @@ var Daemon = class {
22688
22716
  startCredential: hosted?.start,
22689
22717
  prepareSubscription: hosted?.prepare,
22690
22718
  prepareRunMailbox: this.options.link.prepareRunMailbox?.bind(this.options.link),
22719
+ prepareRunDrive: this.options.link.prepareRunDrive?.bind(this.options.link),
22691
22720
  prepareRunToolApproval: this.options.link.prepareRunToolApproval?.bind(this.options.link),
22692
22721
  prepareRunGitHub: hosted ? void 0 : (assignment, signal, onCredential) => prepareLocalGitHub(assignment, {
22693
22722
  stateDir: join35(this.paths.adapterState, "github"),
@@ -1,11 +1,11 @@
1
1
  {
2
2
  "version": 1,
3
- "sourceSha": "514b921155adbf4717ac3d71a5f842a6cfd3b1bc",
3
+ "sourceSha": "c0661a23ac7ffd231ef10ad15ce379b20991c120",
4
4
  "repository": "alexj11324/Mikka",
5
- "buildRunId": "44714167305",
5
+ "buildRunId": "44755615370",
6
6
  "buildKind": "github-actions-main",
7
7
  "sourceLockSha256": "d2a25d5f34f8a1c59ba60a46560b538423a04cda426738da995b428ba87648f0",
8
- "createdAt": "2026-11-20T09:57:18.786Z",
8
+ "createdAt": "2026-11-20T14:45:15.323Z",
9
9
  "sbom": "sbom.cdx.json",
10
10
  "files": [
11
11
  {
@@ -35,13 +35,13 @@
35
35
  },
36
36
  {
37
37
  "path": "cli.js",
38
- "size": 1092027,
39
- "sha256": "f268dacef85959e6c76afe9b72e66d630d4b1800744dd4758dcce3d08d11f6bf"
38
+ "size": 1105358,
39
+ "sha256": "eb766ea6e3a89a6b9da2d91f1da6ae3734c7973a59416fb70d7bc296c90033bf"
40
40
  },
41
41
  {
42
42
  "path": "client.js",
43
- "size": 211730,
44
- "sha256": "baa2e1137054c188a9236a2f67073e68777e4f7075b1598b95ac8f99b3d9be40"
43
+ "size": 212244,
44
+ "sha256": "6ec36fdd9812f42c7ee787cf13936af30405e31c317e59d5e439fe919c4f09de"
45
45
  },
46
46
  {
47
47
  "path": "computer/driver.mjs",
@@ -160,8 +160,8 @@
160
160
  },
161
161
  {
162
162
  "path": "http-link.js",
163
- "size": 308239,
164
- "sha256": "cba789c2a71951a4d89a8bb04e2b7f0d9495365c1345c014a106e732b47e4a0d"
163
+ "size": 320629,
164
+ "sha256": "946bf712a4717f17c88b0f8b610f82fe178d93557d83697a7b29651837958e0a"
165
165
  },
166
166
  {
167
167
  "path": "log.js",
@@ -170,13 +170,13 @@
170
170
  },
171
171
  {
172
172
  "path": "login.js",
173
- "size": 269192,
174
- "sha256": "dfe5986cb2870c6340a4324e5bcb2392b54ca6048621a03fed12718d4f7338fe"
173
+ "size": 270370,
174
+ "sha256": "d657e8474f0ce953db3203985b12838c174609eec5dd58de7ce2b206aac08f43"
175
175
  },
176
176
  {
177
177
  "path": "main.js",
178
- "size": 1031222,
179
- "sha256": "818250e9bae445e74d1d277ba694347576fd52d37f1c989b5964e738b3852d09"
178
+ "size": 1033142,
179
+ "sha256": "c226d503a5678ab1237a10a58d5295247be8d3d2d4b1f6e9ec59f2fd487b6928"
180
180
  },
181
181
  {
182
182
  "path": "mcp-stdio-launcher.mjs",
@@ -205,23 +205,23 @@
205
205
  },
206
206
  {
207
207
  "path": "mikka.js",
208
- "size": 1092043,
209
- "sha256": "a11a5a2e0fe64d6bd4c360dc84afc05cf25c3643104a17c2202655b7e5d803c8"
208
+ "size": 1105374,
209
+ "sha256": "8fe3eec128265fb6e5d7e567f8314557e826109e2bfa9353f7b69821fcdc1cd6"
210
210
  },
211
211
  {
212
212
  "path": "npm-shrinkwrap.json",
213
213
  "size": 85380,
214
- "sha256": "65b627b10320a182c0cce9a492d4a220c5b433c9e954403dafdd2f5dd1bb1f1e"
214
+ "sha256": "58ef0d1622df6082e81797459a8428062f8d5f48e3a036f4861345a36d988ab6"
215
215
  },
216
216
  {
217
217
  "path": "package.json",
218
218
  "size": 1551,
219
- "sha256": "6d8954a7fcbcf120dd87882536021335ee53e121f2289cbbf7c2ea81a6f939be"
219
+ "sha256": "72812efeb7147bf413fc343774eb285538619fe1b43a373e8541b5a2b068b1dc"
220
220
  },
221
221
  {
222
222
  "path": "paths.js",
223
223
  "size": 4585,
224
- "sha256": "2075cddc068ad0e0b24486d7ff73b613178aded53ae620b28cb8d88e6232bef8"
224
+ "sha256": "c5545845f17d2966062f0be5c5b232dbd8cd29485f86217e047e813745102dac"
225
225
  },
226
226
  {
227
227
  "path": "sandbox.js",
@@ -231,7 +231,7 @@
231
231
  {
232
232
  "path": "sbom.cdx.json",
233
233
  "size": 155701,
234
- "sha256": "6172f0e24dd87f1170b1dac3ccc0a9e7c5559f0c704264bbecb473a1d253da94"
234
+ "sha256": "d43a572be81f424ed0c6b00a6e9a392babb8dc868ea5ade1ecc31a6a3d32989d"
235
235
  }
236
236
  ]
237
237
  }