@yukino.js/yukino 0.0.2 → 0.0.3-dev

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 (35) hide show
  1. package/README.md +34 -27
  2. package/dist/{acp-GPESP7MI.js → acp-J6EPN6TP.js} +6 -6
  3. package/dist/{agent-MPSZKLGX.js → agent-LA65FOAB.js} +1 -1
  4. package/dist/{anthropic-D7RVWNCE.js → anthropic-YP6DY2F3.js} +1 -1
  5. package/dist/{chunk-UPNNYP7M.js → chunk-2UNWKNDU.js} +1 -1
  6. package/dist/{chunk-IXRJQ6NU.js → chunk-675L7SRF.js} +96 -96
  7. package/dist/{chunk-RC3MYRC3.js → chunk-7CVY4FXY.js} +1 -1
  8. package/dist/{chunk-MY5FSQD6.js → chunk-CT773IEX.js} +3 -3
  9. package/dist/{chunk-Z2OKAF7A.js → chunk-JEOQXHOX.js} +24 -24
  10. package/dist/chunk-M5H5EYXN.js +5 -0
  11. package/dist/{chunk-SAJCBGHL.js → chunk-P77AEADG.js} +1 -1
  12. package/dist/{chunk-XO7ITAWR.js → chunk-Y6COQ5UY.js} +1 -1
  13. package/dist/{chunk-RCXKUD3Y.js → chunk-ZQP5DTJA.js} +1 -1
  14. package/dist/{esm-ZTIYTMTS.js → esm-NCEEJIH3.js} +3 -3
  15. package/dist/lib/{agent-H42OYQUH.js → agent-KDWPLLAV.js} +3 -3
  16. package/dist/lib/{anthropic-GTRJZUG3.js → anthropic-OJALXK4E.js} +2 -2
  17. package/dist/lib/{chunk-UOQV7CZM.js → chunk-2DEH6DOX.js} +1 -1
  18. package/dist/lib/{chunk-OMEH2HQI.js → chunk-77FSPN6Y.js} +8 -8
  19. package/dist/lib/{chunk-AR6FQWXI.js → chunk-7G4AI2PP.js} +1 -1
  20. package/dist/lib/{chunk-PY2WWTDH.js → chunk-SS7OJYHN.js} +15 -6
  21. package/dist/lib/{chunk-AEGITC5R.js → chunk-WOMWIFSN.js} +2 -2
  22. package/dist/lib/{chunk-MDX24JQ5.js → chunk-ZF52ER22.js} +1 -1
  23. package/dist/lib/index.d.ts +52 -43
  24. package/dist/lib/index.js +52 -43
  25. package/dist/lib/{openai-UQC5X2TR.js → openai-FB7BBZVN.js} +2 -2
  26. package/dist/lib/{permissions-Q4FBU5VD.js → permissions-BZRN4RES.js} +1 -1
  27. package/dist/lib/{providers-UA4VT5HA.js → providers-7ZGRBCQ4.js} +1 -1
  28. package/dist/main.js +223 -217
  29. package/dist/{openai-AEXTBM62.js → openai-2FE77NB2.js} +1 -1
  30. package/dist/{permissions-VCDMNX3L.js → permissions-R7P7RWZU.js} +1 -1
  31. package/dist/{providers-JRGWHWTS.js → providers-EZFC2EPW.js} +1 -1
  32. package/dist/{server-SAJ7FDJQ.js → server-54LNMGWU.js} +1 -1
  33. package/package.json +16 -8
  34. package/postinstall.mjs +80 -0
  35. package/dist/chunk-7UAMH7BZ.js +0 -5
@@ -2,10 +2,10 @@ import {
2
2
  Agent,
3
3
  events_exports,
4
4
  streaming_executor_exports
5
- } from "./chunk-OMEH2HQI.js";
6
- import "./chunk-AEGITC5R.js";
5
+ } from "./chunk-77FSPN6Y.js";
6
+ import "./chunk-WOMWIFSN.js";
7
7
  import "./chunk-F2YJG72O.js";
8
- import "./chunk-PY2WWTDH.js";
8
+ import "./chunk-SS7OJYHN.js";
9
9
  import "./chunk-6AKRDUQF.js";
10
10
  import "./chunk-7SU77J32.js";
11
11
  import "./chunk-MLKGABMK.js";
@@ -4,9 +4,9 @@ import {
4
4
  markLastUserTailForCache,
5
5
  markToolsForCache,
6
6
  needsToolSearchBeta
7
- } from "./chunk-AR6FQWXI.js";
7
+ } from "./chunk-7G4AI2PP.js";
8
8
  import "./chunk-F2YJG72O.js";
9
- import "./chunk-PY2WWTDH.js";
9
+ import "./chunk-SS7OJYHN.js";
10
10
  import "./chunk-6AKRDUQF.js";
11
11
  import "./chunk-7SU77J32.js";
12
12
  import "./chunk-MLKGABMK.js";
@@ -12,7 +12,7 @@ import {
12
12
  getThinkingLevel,
13
13
  resolveAPIKey,
14
14
  toReasoningEffort
15
- } from "./chunk-PY2WWTDH.js";
15
+ } from "./chunk-SS7OJYHN.js";
16
16
  import {
17
17
  asRecord,
18
18
  asString,
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  providers_exports
3
- } from "./chunk-AEGITC5R.js";
3
+ } from "./chunk-WOMWIFSN.js";
4
4
  import {
5
5
  normalizeToolResultContentBlock
6
6
  } from "./chunk-F2YJG72O.js";
@@ -11,7 +11,7 @@ import {
11
11
  REJECTED_TOOL_RESULT,
12
12
  RateLimitError,
13
13
  pairing_exports
14
- } from "./chunk-PY2WWTDH.js";
14
+ } from "./chunk-SS7OJYHN.js";
15
15
  import {
16
16
  McpCallTool
17
17
  } from "./chunk-6AKRDUQF.js";
@@ -106,7 +106,7 @@ async function initializeTelemetry() {
106
106
  if (!shouldInitialize()) {
107
107
  return;
108
108
  }
109
- initialization = import("./providers-UA4VT5HA.js").then(async ({ createTelemetryRuntime }) => {
109
+ initialization = import("./providers-7ZGRBCQ4.js").then(async ({ createTelemetryRuntime }) => {
110
110
  runtime = await createTelemetryRuntime();
111
111
  runtime.setMode(mode);
112
112
  process.once("beforeExit", () => {
@@ -1425,7 +1425,7 @@ import { join as join4 } from "path";
1425
1425
  import z, { parse, safeParse } from "zod";
1426
1426
  var COMPACT_BOUNDARY = "compact_boundary";
1427
1427
  var SESSION_EXPIRY_DAYS = 30;
1428
- var ToolUseRecordSchema = z.object({
1428
+ var ToolUseRecordSchema = z.looseObject({
1429
1429
  tool_use_id: z.string(),
1430
1430
  tool_name: z.string(),
1431
1431
  arguments: z.record(z.string(), z.unknown()).optional(),
@@ -1435,13 +1435,13 @@ var ContentSchema = z.union([
1435
1435
  z.string(),
1436
1436
  z.array(z.record(z.string(), z.unknown()))
1437
1437
  ]);
1438
- var ToolResultRecordSchema = z.object({
1438
+ var ToolResultRecordSchema = z.looseObject({
1439
1439
  tool_use_id: z.string(),
1440
1440
  content: ContentSchema,
1441
1441
  content_blocks: z.array(z.unknown()).optional(),
1442
1442
  is_error: z.boolean().optional()
1443
1443
  });
1444
- var SessionMessageSchema = z.object({
1444
+ var SessionMessageSchema = z.looseObject({
1445
1445
  role: z.string(),
1446
1446
  content: ContentSchema.default(""),
1447
1447
  timestamp: z.number(),
@@ -1449,7 +1449,7 @@ var SessionMessageSchema = z.object({
1449
1449
  tool_uses: z.array(ToolUseRecordSchema).optional(),
1450
1450
  tool_results: z.array(ToolResultRecordSchema).optional()
1451
1451
  });
1452
- var KeptMessageSchema = z.object({
1452
+ var KeptMessageSchema = z.looseObject({
1453
1453
  role: z.string(),
1454
1454
  content: ContentSchema,
1455
1455
  tool_uses: z.array(ToolUseRecordSchema).optional(),
@@ -1471,7 +1471,7 @@ function toolResultsToRecords(toolResults) {
1471
1471
  ...tr.isError ? { is_error: true } : {}
1472
1472
  }));
1473
1473
  }
1474
- var CompactBoundaryPayloadSchema = z.object({
1474
+ var CompactBoundaryPayloadSchema = z.looseObject({
1475
1475
  summary: z.string(),
1476
1476
  keep: z.array(KeptMessageSchema)
1477
1477
  });
@@ -18,7 +18,7 @@ import {
18
18
  thinkingBudgetForLevel,
19
19
  toAnthropicThinkingEffort,
20
20
  toReasoningEffort
21
- } from "./chunk-PY2WWTDH.js";
21
+ } from "./chunk-SS7OJYHN.js";
22
22
  import {
23
23
  MCP_TOOL_PREFIX,
24
24
  isMcpToolLike
@@ -219,7 +219,7 @@ function resolveAPIKey(p) {
219
219
  }
220
220
  return process.env[envVar] ?? "";
221
221
  }
222
- var MCPServerConfigSchema = z.object({
222
+ var MCPServerConfigSchema = z.looseObject({
223
223
  name: z.string(),
224
224
  command: z.string().optional(),
225
225
  args: z.array(z.string()).optional(),
@@ -228,11 +228,11 @@ var MCPServerConfigSchema = z.object({
228
228
  headers: z.record(z.string(), z.string()).optional(),
229
229
  env: z.record(z.string(), z.string()).optional()
230
230
  });
231
- var HookConfigSchema = z.object({
231
+ var HookConfigSchema = z.looseObject({
232
232
  id: z.string().optional(),
233
233
  event: z.string(),
234
234
  condition: z.string().optional(),
235
- action: z.object({
235
+ action: z.looseObject({
236
236
  type: z.string(),
237
237
  command: z.string().optional(),
238
238
  url: z.string().optional(),
@@ -244,13 +244,14 @@ var HookConfigSchema = z.object({
244
244
  async: z.boolean().optional(),
245
245
  on_error: z.string().optional()
246
246
  });
247
- var SandboxYamlConfigSchema = z.object({
247
+ var SandboxYamlConfigSchema = z.looseObject({
248
248
  enabled: z.boolean().optional(),
249
249
  backend: z.enum(["native", "sandbox-runtime"]).optional(),
250
250
  auto_allow: z.boolean().optional(),
251
251
  network_enabled: z.boolean().optional()
252
252
  });
253
253
  var AppConfigSchema = z.looseObject({
254
+ default_provider: z.number().default(0),
254
255
  providers: z.array(ProviderConfigSchema),
255
256
  permission_mode: z.string().optional(),
256
257
  mcp_servers: z.array(MCPServerConfigSchema).default([]),
@@ -276,7 +277,7 @@ function loadSingleFile(path) {
276
277
  const raw = yaml.load(data);
277
278
  if (!isRecord(raw)) {
278
279
  log.error({ path }, "invalid yaml");
279
- return { providers: [], mcp_servers: [], hooks: [] };
280
+ return { default_provider: 0, providers: [], mcp_servers: [], hooks: [] };
280
281
  }
281
282
  const parsed = safeParse(AppConfigSchema, raw);
282
283
  if (parsed.success) {
@@ -287,6 +288,7 @@ function loadSingleFile(path) {
287
288
  };
288
289
  }
289
290
  log.error({ error: parsed.error }, "config error");
291
+ let defaultProvider = 0;
290
292
  let providers = [];
291
293
  let permissionMode;
292
294
  let mcpServers = [];
@@ -294,6 +296,12 @@ function loadSingleFile(path) {
294
296
  let sandbox = void 0;
295
297
  let enableCoordinatorMode = false;
296
298
  let enableFork = true;
299
+ if ("default_provider" in raw) {
300
+ const parsed2 = safeParse(z.number(), raw.default_provider);
301
+ if (parsed2.success) {
302
+ defaultProvider = parsed2.data;
303
+ }
304
+ }
297
305
  if ("providers" in raw) {
298
306
  const parsed2 = safeParse(z.array(ProviderConfigSchema), raw.providers);
299
307
  if (parsed2.success) {
@@ -340,6 +348,7 @@ function loadSingleFile(path) {
340
348
  enableFork = Boolean(raw.enable_fork);
341
349
  }
342
350
  return {
351
+ default_provider: defaultProvider,
343
352
  providers,
344
353
  permission_mode: permissionMode,
345
354
  mcp_servers: mcpServers,
@@ -510,7 +519,7 @@ function loadConfig(path, options = {}) {
510
519
  const candidate = globalConfigPath();
511
520
  if (!existsSync(candidate)) {
512
521
  if (options.allowEmptyProviders) {
513
- return { providers: [], mcp_servers: [], hooks: [] };
522
+ return { default_provider: 0, providers: [], mcp_servers: [], hooks: [] };
514
523
  }
515
524
  throw new ConfigError(`No config file found, expected ${candidate}.`);
516
525
  }
@@ -47,12 +47,12 @@ import { readFileSync } from "fs";
47
47
  import path from "path";
48
48
  import { fileURLToPath } from "url";
49
49
  import { z } from "zod";
50
- var PackageJsonSchema = z.object({
50
+ var PackageJsonSchema = z.looseObject({
51
51
  version: z.string()
52
52
  });
53
53
  function resolveVersion() {
54
54
  if (true) {
55
- return "0.0.2";
55
+ return "0.0.3-dev";
56
56
  }
57
57
  const here = path.dirname(fileURLToPath(import.meta.url));
58
58
  for (const levels of ["..", "../.."]) {
@@ -313,7 +313,7 @@ function loadRulesFile(path) {
313
313
  }
314
314
  return [];
315
315
  }
316
- const YamlEntrySchema = z.object({
316
+ const YamlEntrySchema = z.looseObject({
317
317
  rule: z.string().optional(),
318
318
  effect: z.string().optional()
319
319
  });
@@ -734,7 +734,7 @@ declare const ToolUseRecordSchema: z.ZodObject<{
734
734
  tool_name: z.ZodString;
735
735
  arguments: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
736
736
  provider_item_id: z.ZodOptional<z.ZodString>;
737
- }, z.core.$strip>;
737
+ }, z.core.$loose>;
738
738
  type ToolUseRecord = z.infer<typeof ToolUseRecordSchema>;
739
739
  /** Persisted form of a tool result, paired with a ToolUseRecord via tool_use_id. */
740
740
  declare const ToolResultRecordSchema: z.ZodObject<{
@@ -742,7 +742,7 @@ declare const ToolResultRecordSchema: z.ZodObject<{
742
742
  content: z.ZodUnion<readonly [z.ZodString, z.ZodArray<z.ZodRecord<z.ZodString, z.ZodUnknown>>]>;
743
743
  content_blocks: z.ZodOptional<z.ZodArray<z.ZodUnknown>>;
744
744
  is_error: z.ZodOptional<z.ZodBoolean>;
745
- }, z.core.$strip>;
745
+ }, z.core.$loose>;
746
746
  type ToolResultRecord = z.infer<typeof ToolResultRecordSchema>;
747
747
  declare const SessionMessageSchema: z.ZodObject<{
748
748
  role: z.ZodString;
@@ -754,14 +754,14 @@ declare const SessionMessageSchema: z.ZodObject<{
754
754
  tool_name: z.ZodString;
755
755
  arguments: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
756
756
  provider_item_id: z.ZodOptional<z.ZodString>;
757
- }, z.core.$strip>>>;
757
+ }, z.core.$loose>>>;
758
758
  tool_results: z.ZodOptional<z.ZodArray<z.ZodObject<{
759
759
  tool_use_id: z.ZodString;
760
760
  content: z.ZodUnion<readonly [z.ZodString, z.ZodArray<z.ZodRecord<z.ZodString, z.ZodUnknown>>]>;
761
761
  content_blocks: z.ZodOptional<z.ZodArray<z.ZodUnknown>>;
762
762
  is_error: z.ZodOptional<z.ZodBoolean>;
763
- }, z.core.$strip>>>;
764
- }, z.core.$strip>;
763
+ }, z.core.$loose>>>;
764
+ }, z.core.$loose>;
765
765
  type SessionMessage = z.infer<typeof SessionMessageSchema>;
766
766
  declare const KeptMessageSchema: z.ZodObject<{
767
767
  role: z.ZodString;
@@ -771,14 +771,14 @@ declare const KeptMessageSchema: z.ZodObject<{
771
771
  tool_name: z.ZodString;
772
772
  arguments: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
773
773
  provider_item_id: z.ZodOptional<z.ZodString>;
774
- }, z.core.$strip>>>;
774
+ }, z.core.$loose>>>;
775
775
  tool_results: z.ZodOptional<z.ZodArray<z.ZodObject<{
776
776
  tool_use_id: z.ZodString;
777
777
  content: z.ZodUnion<readonly [z.ZodString, z.ZodArray<z.ZodRecord<z.ZodString, z.ZodUnknown>>]>;
778
778
  content_blocks: z.ZodOptional<z.ZodArray<z.ZodUnknown>>;
779
779
  is_error: z.ZodOptional<z.ZodBoolean>;
780
- }, z.core.$strip>>>;
781
- }, z.core.$strip>;
780
+ }, z.core.$loose>>>;
781
+ }, z.core.$loose>;
782
782
  type KeptMessage = z.infer<typeof KeptMessageSchema>;
783
783
  /** Conversation-layer tool blocks (camelCase) → persisted records (snake_case); empty values are omitted. */
784
784
  declare function toolUsesToRecords(toolUses?: {
@@ -798,15 +798,15 @@ declare const CompactBoundaryPayloadSchema: z.ZodObject<{
798
798
  tool_name: z.ZodString;
799
799
  arguments: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
800
800
  provider_item_id: z.ZodOptional<z.ZodString>;
801
- }, z.core.$strip>>>;
801
+ }, z.core.$loose>>>;
802
802
  tool_results: z.ZodOptional<z.ZodArray<z.ZodObject<{
803
803
  tool_use_id: z.ZodString;
804
804
  content: z.ZodUnion<readonly [z.ZodString, z.ZodArray<z.ZodRecord<z.ZodString, z.ZodUnknown>>]>;
805
805
  content_blocks: z.ZodOptional<z.ZodArray<z.ZodUnknown>>;
806
806
  is_error: z.ZodOptional<z.ZodBoolean>;
807
- }, z.core.$strip>>>;
808
- }, z.core.$strip>>;
809
- }, z.core.$strip>;
807
+ }, z.core.$loose>>>;
808
+ }, z.core.$loose>>;
809
+ }, z.core.$loose>;
810
810
  type CompactBoundaryPayload = z.infer<typeof CompactBoundaryPayloadSchema>;
811
811
  interface SessionInfo {
812
812
  id: string;
@@ -1386,7 +1386,7 @@ declare const MCPServerConfigSchema: z$1.ZodObject<{
1386
1386
  transport: z$1.ZodOptional<z$1.ZodString>;
1387
1387
  headers: z$1.ZodOptional<z$1.ZodRecord<z$1.ZodString, z$1.ZodString>>;
1388
1388
  env: z$1.ZodOptional<z$1.ZodRecord<z$1.ZodString, z$1.ZodString>>;
1389
- }, z$1.core.$strip>;
1389
+ }, z$1.core.$loose>;
1390
1390
  type MCPServerConfig = z$1.infer<typeof MCPServerConfigSchema>;
1391
1391
  declare const HookConfigSchema: z$1.ZodObject<{
1392
1392
  id: z$1.ZodOptional<z$1.ZodString>;
@@ -1398,12 +1398,12 @@ declare const HookConfigSchema: z$1.ZodObject<{
1398
1398
  url: z$1.ZodOptional<z$1.ZodString>;
1399
1399
  method: z$1.ZodOptional<z$1.ZodString>;
1400
1400
  prompt: z$1.ZodOptional<z$1.ZodString>;
1401
- }, z$1.core.$strip>;
1401
+ }, z$1.core.$loose>;
1402
1402
  reject: z$1.ZodOptional<z$1.ZodBoolean>;
1403
1403
  once: z$1.ZodOptional<z$1.ZodBoolean>;
1404
1404
  async: z$1.ZodOptional<z$1.ZodBoolean>;
1405
1405
  on_error: z$1.ZodOptional<z$1.ZodString>;
1406
- }, z$1.core.$strip>;
1406
+ }, z$1.core.$loose>;
1407
1407
  type HookConfig = z$1.infer<typeof HookConfigSchema>;
1408
1408
  declare const SandboxYamlConfigSchema: z$1.ZodObject<{
1409
1409
  enabled: z$1.ZodOptional<z$1.ZodBoolean>;
@@ -1413,9 +1413,10 @@ declare const SandboxYamlConfigSchema: z$1.ZodObject<{
1413
1413
  }>>;
1414
1414
  auto_allow: z$1.ZodOptional<z$1.ZodBoolean>;
1415
1415
  network_enabled: z$1.ZodOptional<z$1.ZodBoolean>;
1416
- }, z$1.core.$strip>;
1416
+ }, z$1.core.$loose>;
1417
1417
  type SandboxYamlConfig = z$1.infer<typeof SandboxYamlConfigSchema>;
1418
1418
  declare const AppConfigSchema: z$1.ZodObject<{
1419
+ default_provider: z$1.ZodDefault<z$1.ZodNumber>;
1419
1420
  providers: z$1.ZodArray<z$1.ZodObject<{
1420
1421
  name: z$1.ZodString;
1421
1422
  protocol: z$1.ZodEnum<{
@@ -1509,7 +1510,7 @@ declare const AppConfigSchema: z$1.ZodObject<{
1509
1510
  transport: z$1.ZodOptional<z$1.ZodString>;
1510
1511
  headers: z$1.ZodOptional<z$1.ZodRecord<z$1.ZodString, z$1.ZodString>>;
1511
1512
  env: z$1.ZodOptional<z$1.ZodRecord<z$1.ZodString, z$1.ZodString>>;
1512
- }, z$1.core.$strip>>>;
1513
+ }, z$1.core.$loose>>>;
1513
1514
  hooks: z$1.ZodDefault<z$1.ZodArray<z$1.ZodObject<{
1514
1515
  id: z$1.ZodOptional<z$1.ZodString>;
1515
1516
  event: z$1.ZodString;
@@ -1520,12 +1521,12 @@ declare const AppConfigSchema: z$1.ZodObject<{
1520
1521
  url: z$1.ZodOptional<z$1.ZodString>;
1521
1522
  method: z$1.ZodOptional<z$1.ZodString>;
1522
1523
  prompt: z$1.ZodOptional<z$1.ZodString>;
1523
- }, z$1.core.$strip>;
1524
+ }, z$1.core.$loose>;
1524
1525
  reject: z$1.ZodOptional<z$1.ZodBoolean>;
1525
1526
  once: z$1.ZodOptional<z$1.ZodBoolean>;
1526
1527
  async: z$1.ZodOptional<z$1.ZodBoolean>;
1527
1528
  on_error: z$1.ZodOptional<z$1.ZodString>;
1528
- }, z$1.core.$strip>>>;
1529
+ }, z$1.core.$loose>>>;
1529
1530
  sandbox: z$1.ZodOptional<z$1.ZodObject<{
1530
1531
  enabled: z$1.ZodOptional<z$1.ZodBoolean>;
1531
1532
  backend: z$1.ZodOptional<z$1.ZodEnum<{
@@ -1534,7 +1535,7 @@ declare const AppConfigSchema: z$1.ZodObject<{
1534
1535
  }>>;
1535
1536
  auto_allow: z$1.ZodOptional<z$1.ZodBoolean>;
1536
1537
  network_enabled: z$1.ZodOptional<z$1.ZodBoolean>;
1537
- }, z$1.core.$strip>>;
1538
+ }, z$1.core.$loose>>;
1538
1539
  enable_coordinator_mode: z$1.ZodOptional<z$1.ZodBoolean>;
1539
1540
  enable_fork: z$1.ZodOptional<z$1.ZodBoolean>;
1540
1541
  }, z$1.core.$loose>;
@@ -2990,7 +2991,7 @@ declare const FileMailMessageSchema: z.ZodObject<{
2990
2991
  type: z.ZodOptional<z.ZodString>;
2991
2992
  requestId: z.ZodOptional<z.ZodString>;
2992
2993
  approve: z.ZodOptional<z.ZodBoolean>;
2993
- }, z.core.$strip>;
2994
+ }, z.core.$loose>;
2994
2995
  type FileMailMessage = z.infer<typeof FileMailMessageSchema>;
2995
2996
  declare class FileMailbox {
2996
2997
  private filePath;
@@ -3042,12 +3043,12 @@ declare const ToolActivitySchema: z$1.ZodObject<{
3042
3043
  toolName: z$1.ZodString;
3043
3044
  input: z$1.ZodRecord<z$1.ZodString, z$1.ZodUnknown>;
3044
3045
  activityDescription: z$1.ZodString;
3045
- }, z$1.core.$strip>;
3046
+ }, z$1.core.$loose>;
3046
3047
  type ToolActivity = z$1.infer<typeof ToolActivitySchema>;
3047
3048
  declare const ActiveToolSchema: z$1.ZodObject<{
3048
3049
  toolId: z$1.ZodString;
3049
3050
  toolName: z$1.ZodString;
3050
- }, z$1.core.$strip>;
3051
+ }, z$1.core.$loose>;
3051
3052
  type ActiveTool = z$1.infer<typeof ActiveToolSchema>;
3052
3053
  declare const AgentProgressSchema: z$1.ZodObject<{
3053
3054
  toolUseCount: z$1.ZodNumber;
@@ -3056,18 +3057,18 @@ declare const AgentProgressSchema: z$1.ZodObject<{
3056
3057
  activeTools: z$1.ZodArray<z$1.ZodObject<{
3057
3058
  toolId: z$1.ZodString;
3058
3059
  toolName: z$1.ZodString;
3059
- }, z$1.core.$strip>>;
3060
+ }, z$1.core.$loose>>;
3060
3061
  lastActivity: z$1.ZodOptional<z$1.ZodObject<{
3061
3062
  toolName: z$1.ZodString;
3062
3063
  input: z$1.ZodRecord<z$1.ZodString, z$1.ZodUnknown>;
3063
3064
  activityDescription: z$1.ZodString;
3064
- }, z$1.core.$strip>>;
3065
+ }, z$1.core.$loose>>;
3065
3066
  recentActivities: z$1.ZodArray<z$1.ZodObject<{
3066
3067
  toolName: z$1.ZodString;
3067
3068
  input: z$1.ZodRecord<z$1.ZodString, z$1.ZodUnknown>;
3068
3069
  activityDescription: z$1.ZodString;
3069
- }, z$1.core.$strip>>;
3070
- }, z$1.core.$strip>;
3070
+ }, z$1.core.$loose>>;
3071
+ }, z$1.core.$loose>;
3071
3072
  type AgentProgress = z$1.infer<typeof AgentProgressSchema>;
3072
3073
  declare const TeammateUIStateSchema: z$1.ZodObject<{
3073
3074
  name: z$1.ZodString;
@@ -3086,23 +3087,23 @@ declare const TeammateUIStateSchema: z$1.ZodObject<{
3086
3087
  activeTools: z$1.ZodArray<z$1.ZodObject<{
3087
3088
  toolId: z$1.ZodString;
3088
3089
  toolName: z$1.ZodString;
3089
- }, z$1.core.$strip>>;
3090
+ }, z$1.core.$loose>>;
3090
3091
  lastActivity: z$1.ZodOptional<z$1.ZodObject<{
3091
3092
  toolName: z$1.ZodString;
3092
3093
  input: z$1.ZodRecord<z$1.ZodString, z$1.ZodUnknown>;
3093
3094
  activityDescription: z$1.ZodString;
3094
- }, z$1.core.$strip>>;
3095
+ }, z$1.core.$loose>>;
3095
3096
  recentActivities: z$1.ZodArray<z$1.ZodObject<{
3096
3097
  toolName: z$1.ZodString;
3097
3098
  input: z$1.ZodRecord<z$1.ZodString, z$1.ZodUnknown>;
3098
3099
  activityDescription: z$1.ZodString;
3099
- }, z$1.core.$strip>>;
3100
- }, z$1.core.$strip>;
3100
+ }, z$1.core.$loose>>;
3101
+ }, z$1.core.$loose>;
3101
3102
  originToolCallId: z$1.ZodOptional<z$1.ZodString>;
3102
3103
  startTime: z$1.ZodNumber;
3103
3104
  spinnerVerb: z$1.ZodString;
3104
3105
  lastMessage: z$1.ZodOptional<z$1.ZodString>;
3105
- }, z$1.core.$strip>;
3106
+ }, z$1.core.$loose>;
3106
3107
  type TeammateUIState = z$1.infer<typeof TeammateUIStateSchema>;
3107
3108
  declare function createProgress(): AgentProgress;
3108
3109
  declare function recordToolUse(p: AgentProgress, toolName: string, input: Record<string, unknown>): void;
@@ -3244,7 +3245,7 @@ declare const TeamMemberEntrySchema: z.ZodObject<{
3244
3245
  worktreePath: z.ZodOptional<z.ZodString>;
3245
3246
  backendType: z.ZodOptional<z.ZodString>;
3246
3247
  isActive: z.ZodOptional<z.ZodBoolean>;
3247
- }, z.core.$strip>;
3248
+ }, z.core.$loose>;
3248
3249
  type TeamMemberEntry = z.infer<typeof TeamMemberEntrySchema>;
3249
3250
  /**
3250
3251
  * On-disk representation of team configuration, stored at <teamsBaseDir>/<slug>/config.json.
@@ -3271,8 +3272,8 @@ declare const TeamFileSchema: z.ZodObject<{
3271
3272
  worktreePath: z.ZodOptional<z.ZodString>;
3272
3273
  backendType: z.ZodOptional<z.ZodString>;
3273
3274
  isActive: z.ZodOptional<z.ZodBoolean>;
3274
- }, z.core.$strip>>;
3275
- }, z.core.$strip>;
3275
+ }, z.core.$loose>>;
3276
+ }, z.core.$loose>;
3276
3277
  type TeamFile = z.infer<typeof TeamFileSchema>;
3277
3278
  /**
3278
3279
  * Root directory for all team data. Placed under the user's home directory rather than
@@ -3926,13 +3927,13 @@ declare const TranscriptEntrySchema: z.ZodObject<{
3926
3927
  tool_use_id: z.ZodString;
3927
3928
  tool_name: z.ZodString;
3928
3929
  arguments: z.ZodRecord<z.ZodString, z.ZodUnknown>;
3929
- }, z.core.$strip>>>;
3930
+ }, z.core.$loose>>>;
3930
3931
  tool_results: z.ZodOptional<z.ZodArray<z.ZodObject<{
3931
3932
  tool_use_id: z.ZodString;
3932
3933
  content: z.ZodString;
3933
3934
  is_error: z.ZodOptional<z.ZodBoolean>;
3934
- }, z.core.$strip>>>;
3935
- }, z.core.$strip>;
3935
+ }, z.core.$loose>>>;
3936
+ }, z.core.$loose>;
3936
3937
  type TranscriptEntry = z.infer<typeof TranscriptEntrySchema>;
3937
3938
  /**
3938
3939
  * Persists a teammate's conversation history to disk for debugging and troubleshooting.
@@ -4187,7 +4188,7 @@ declare const CodeReviewTeamSchema: z.ZodObject<{
4187
4188
  }, z.core.$strip>>;
4188
4189
  createdAt: z.ZodString;
4189
4190
  lastActive: z.ZodString;
4190
- }, z.core.$strip>;
4191
+ }, z.core.$loose>;
4191
4192
  type CodeReviewTeam = z.infer<typeof CodeReviewTeamSchema>;
4192
4193
  declare class CodeReviewManager {
4193
4194
  private teams;
@@ -4782,12 +4783,20 @@ declare function saveProvider(input: unknown, available: ProviderConfig[]): {
4782
4783
  * the endpoint is absent so callers can surface a clear error.
4783
4784
  */
4784
4785
  declare function persistThinkingLevel(baseUrl: string, level: ThinkingLevel): void;
4786
+ /**
4787
+ * Persist the index (into the config's providers array) of the provider the
4788
+ * user selected last, so the next start selects it directly instead of showing
4789
+ * the provider picker. No-op when the stored index already matches, so the file
4790
+ * is not rewritten (and reformatted) on every selection.
4791
+ */
4792
+ declare function persistDefaultProvider(index: number): void;
4785
4793
 
4786
4794
  declare const providerLogin_ProviderLoginSchema: typeof ProviderLoginSchema;
4795
+ declare const providerLogin_persistDefaultProvider: typeof persistDefaultProvider;
4787
4796
  declare const providerLogin_persistThinkingLevel: typeof persistThinkingLevel;
4788
4797
  declare const providerLogin_saveProvider: typeof saveProvider;
4789
4798
  declare namespace providerLogin {
4790
- export { providerLogin_ProviderLoginSchema as ProviderLoginSchema, providerLogin_persistThinkingLevel as persistThinkingLevel, providerLogin_saveProvider as saveProvider };
4799
+ export { providerLogin_ProviderLoginSchema as ProviderLoginSchema, providerLogin_persistDefaultProvider as persistDefaultProvider, providerLogin_persistThinkingLevel as persistThinkingLevel, providerLogin_saveProvider as saveProvider };
4791
4800
  }
4792
4801
 
4793
4802
  /**
@@ -5017,7 +5026,7 @@ declare const ModelSchema: z$1.ZodObject<{
5017
5026
  id: z$1.ZodString;
5018
5027
  display_name: z$1.ZodOptional<z$1.ZodString>;
5019
5028
  name: z$1.ZodOptional<z$1.ZodString>;
5020
- }, z$1.core.$strip>;
5029
+ }, z$1.core.$loose>;
5021
5030
  type DiscoveryConfig = Pick<ProviderConfig, "protocol" | "base_url" | "api_key">;
5022
5031
  type DiscoveredModel = z$1.infer<typeof ModelSchema>;
5023
5032
  declare function modelListUrl(protocol: ProviderConfig["protocol"], baseUrl: string): string | undefined;
@@ -6221,7 +6230,7 @@ declare namespace log {
6221
6230
  declare const QuestionOptionSchema: z$1.ZodObject<{
6222
6231
  label: z$1.ZodString;
6223
6232
  description: z$1.ZodOptional<z$1.ZodString>;
6224
- }, z$1.core.$strip>;
6233
+ }, z$1.core.$loose>;
6225
6234
  type QuestionOption = z$1.infer<typeof QuestionOptionSchema>;
6226
6235
  declare const QuestionSchema: z$1.ZodObject<{
6227
6236
  question: z$1.ZodString;
@@ -6229,7 +6238,7 @@ declare const QuestionSchema: z$1.ZodObject<{
6229
6238
  options: z$1.ZodArray<z$1.ZodObject<{
6230
6239
  label: z$1.ZodString;
6231
6240
  description: z$1.ZodOptional<z$1.ZodString>;
6232
- }, z$1.core.$strip>>;
6241
+ }, z$1.core.$loose>>;
6233
6242
  multiSelect: z$1.ZodBoolean;
6234
6243
  }, z$1.core.$strip>;
6235
6244
  type Question = z$1.infer<typeof QuestionSchema>;