lody 0.47.0 → 0.47.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.
Files changed (2) hide show
  1. package/dist/index.js +459 -375
  2. package/package.json +4 -4
package/dist/index.js CHANGED
@@ -36820,7 +36820,7 @@ Mongoose Error Code: ${error2.code}` : ""}`
36820
36820
  return client;
36821
36821
  }
36822
36822
  const name = "lody";
36823
- const version$4 = "0.47.0";
36823
+ const version$4 = "0.47.1";
36824
36824
  const description = "Lody Agent CLI tool for managing remote command execution";
36825
36825
  const type = "module";
36826
36826
  const main$3 = "dist/index.js";
@@ -36864,7 +36864,7 @@ Mongoose Error Code: ${error2.code}` : ""}`
36864
36864
  };
36865
36865
  const optionalDependencies = {
36866
36866
  "acp-extension-claude": "0.30.0",
36867
- "acp-extension-codex": "0.12.0"
36867
+ "acp-extension-codex": "0.12.2"
36868
36868
  };
36869
36869
  const devDependencies = {
36870
36870
  "@agentclientprotocol/sdk": "catalog:",
@@ -64257,14 +64257,6 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
64257
64257
  };
64258
64258
  return new ZodObject(def);
64259
64259
  }
64260
- function looseObject(shape, params) {
64261
- return new ZodObject({
64262
- type: "object",
64263
- shape,
64264
- catchall: unknown(),
64265
- ...normalizeParams(params)
64266
- });
64267
- }
64268
64260
  const ZodUnion = $constructor("ZodUnion", (inst, def) => {
64269
64261
  $ZodUnion.init(inst, def);
64270
64262
  ZodType.init(inst, def);
@@ -78827,12 +78819,12 @@ Task description:
78827
78819
  {
78828
78820
  id: "cline",
78829
78821
  name: "Cline",
78830
- version: "2.15.0",
78822
+ version: "2.17.0",
78831
78823
  description: "Autonomous coding agent CLI - capable of creating/editing files, running commands, using the browser, and more",
78832
78824
  icon: "https://cdn.agentclientprotocol.com/registry/v1/latest/cline.svg",
78833
78825
  distribution: {
78834
78826
  npx: {
78835
- package: "cline@2.15.0",
78827
+ package: "cline@2.17.0",
78836
78828
  args: [
78837
78829
  "--acp"
78838
78830
  ]
@@ -78842,12 +78834,12 @@ Task description:
78842
78834
  {
78843
78835
  id: "codebuddy-code",
78844
78836
  name: "Codebuddy Code",
78845
- version: "2.93.1",
78837
+ version: "2.93.7",
78846
78838
  description: "Tencent Cloud's official intelligent coding tool",
78847
78839
  icon: "https://cdn.agentclientprotocol.com/registry/v1/latest/codebuddy-code.svg",
78848
78840
  distribution: {
78849
78841
  npx: {
78850
- package: "@tencent-ai/codebuddy-code@2.93.1",
78842
+ package: "@tencent-ai/codebuddy-code@2.93.7",
78851
78843
  args: [
78852
78844
  "--acp"
78853
78845
  ]
@@ -78887,16 +78879,16 @@ Task description:
78887
78879
  {
78888
78880
  id: "factory-droid",
78889
78881
  name: "Factory Droid",
78890
- version: "0.106.0",
78882
+ version: "0.109.1",
78891
78883
  description: "Factory Droid - AI coding agent powered by Factory AI",
78892
78884
  icon: "https://cdn.agentclientprotocol.com/registry/v1/latest/factory-droid.svg",
78893
78885
  distribution: {
78894
78886
  npx: {
78895
- package: "droid@0.106.0",
78887
+ package: "droid@0.109.1",
78896
78888
  args: [
78897
78889
  "exec",
78898
78890
  "--output-format",
78899
- "acp"
78891
+ "acp-daemon"
78900
78892
  ],
78901
78893
  env: {
78902
78894
  DROID_DISABLE_AUTO_UPDATE: "true",
@@ -78908,12 +78900,12 @@ Task description:
78908
78900
  {
78909
78901
  id: "gemini",
78910
78902
  name: "Gemini CLI",
78911
- version: "0.38.2",
78903
+ version: "0.39.1",
78912
78904
  description: "Google's official CLI for Gemini",
78913
78905
  icon: "https://cdn.agentclientprotocol.com/registry/v1/latest/gemini.svg",
78914
78906
  distribution: {
78915
78907
  npx: {
78916
- package: "@google/gemini-cli@0.38.2",
78908
+ package: "@google/gemini-cli@0.39.1",
78917
78909
  args: [
78918
78910
  "--acp"
78919
78911
  ]
@@ -78923,12 +78915,12 @@ Task description:
78923
78915
  {
78924
78916
  id: "github-copilot-cli",
78925
78917
  name: "GitHub Copilot",
78926
- version: "1.0.34",
78918
+ version: "1.0.36",
78927
78919
  description: "GitHub's AI pair programmer",
78928
78920
  icon: "https://cdn.agentclientprotocol.com/registry/v1/latest/github-copilot-cli.svg",
78929
78921
  distribution: {
78930
78922
  npx: {
78931
- package: "@github/copilot@1.0.34",
78923
+ package: "@github/copilot@1.0.36",
78932
78924
  args: [
78933
78925
  "--acp"
78934
78926
  ]
@@ -78938,7 +78930,7 @@ Task description:
78938
78930
  {
78939
78931
  id: "goose",
78940
78932
  name: "goose",
78941
- version: "1.31.1",
78933
+ version: "1.32.0",
78942
78934
  description: "A local, extensible, open source AI agent that automates engineering tasks",
78943
78935
  icon: "https://cdn.agentclientprotocol.com/registry/v1/latest/goose.svg",
78944
78936
  distribution: {
@@ -78974,12 +78966,12 @@ Task description:
78974
78966
  {
78975
78967
  id: "kilo",
78976
78968
  name: "Kilo",
78977
- version: "7.2.14",
78969
+ version: "7.2.24",
78978
78970
  description: "The open source coding agent",
78979
78971
  icon: "https://cdn.agentclientprotocol.com/registry/v1/latest/kilo.svg",
78980
78972
  distribution: {
78981
78973
  npx: {
78982
- package: "@kilocode/cli@7.2.14",
78974
+ package: "@kilocode/cli@7.2.24",
78983
78975
  args: [
78984
78976
  "acp"
78985
78977
  ]
@@ -78989,7 +78981,7 @@ Task description:
78989
78981
  {
78990
78982
  id: "kimi",
78991
78983
  name: "Kimi CLI",
78992
- version: "1.37.0",
78984
+ version: "1.39.0",
78993
78985
  description: "Moonshot AI's coding assistant",
78994
78986
  icon: "https://cdn.agentclientprotocol.com/registry/v1/latest/kimi.svg",
78995
78987
  distribution: {
@@ -79056,7 +79048,7 @@ Task description:
79056
79048
  {
79057
79049
  id: "opencode",
79058
79050
  name: "OpenCode",
79059
- version: "1.14.20",
79051
+ version: "1.14.28",
79060
79052
  description: "The open source coding agent",
79061
79053
  icon: "https://cdn.agentclientprotocol.com/registry/v1/latest/opencode.svg",
79062
79054
  distribution: {
@@ -79086,12 +79078,12 @@ Task description:
79086
79078
  {
79087
79079
  id: "qoder",
79088
79080
  name: "Qoder CLI",
79089
- version: "0.1.46",
79081
+ version: "0.1.48",
79090
79082
  description: "AI coding assistant with agentic capabilities",
79091
79083
  icon: "https://cdn.agentclientprotocol.com/registry/v1/latest/qoder.svg",
79092
79084
  distribution: {
79093
79085
  npx: {
79094
- package: "@qoder-ai/qodercli@0.1.46",
79086
+ package: "@qoder-ai/qodercli@0.1.48",
79095
79087
  args: [
79096
79088
  "--acp"
79097
79089
  ]
@@ -79101,12 +79093,12 @@ Task description:
79101
79093
  {
79102
79094
  id: "qwen-code",
79103
79095
  name: "Qwen Code",
79104
- version: "0.14.5",
79096
+ version: "0.15.3",
79105
79097
  description: "Alibaba's Qwen coding assistant",
79106
79098
  icon: "https://cdn.agentclientprotocol.com/registry/v1/latest/qwen-code.svg",
79107
79099
  distribution: {
79108
79100
  npx: {
79109
- package: "@qwen-code/qwen-code@0.14.5",
79101
+ package: "@qwen-code/qwen-code@0.15.3",
79110
79102
  args: [
79111
79103
  "--acp",
79112
79104
  "--experimental-skills"
@@ -79291,24 +79283,24 @@ Task description:
79291
79283
  const record2 = meta;
79292
79284
  return record2.claudeCode !== void 0;
79293
79285
  };
79294
- const zAuthCapabilities = looseObject({
79286
+ const zAuthCapabilities = object({
79295
79287
  _meta: record(string$2(), unknown()).nullish(),
79296
79288
  terminal: boolean().optional().default(false)
79297
79289
  });
79298
- const zAuthEnvVar = looseObject({
79290
+ const zAuthEnvVar = object({
79299
79291
  _meta: record(string$2(), unknown()).nullish(),
79300
79292
  label: string$2().nullish(),
79301
79293
  name: string$2(),
79302
79294
  optional: boolean().optional().default(false),
79303
79295
  secret: boolean().optional().default(true)
79304
79296
  });
79305
- const zAuthMethodAgent = looseObject({
79297
+ const zAuthMethodAgent = object({
79306
79298
  _meta: record(string$2(), unknown()).nullish(),
79307
79299
  description: string$2().nullish(),
79308
79300
  id: string$2(),
79309
79301
  name: string$2()
79310
79302
  });
79311
- const zAuthMethodEnvVar = looseObject({
79303
+ const zAuthMethodEnvVar = object({
79312
79304
  _meta: record(string$2(), unknown()).nullish(),
79313
79305
  description: string$2().nullish(),
79314
79306
  id: string$2(),
@@ -79316,7 +79308,7 @@ Task description:
79316
79308
  name: string$2(),
79317
79309
  vars: array$3(zAuthEnvVar)
79318
79310
  });
79319
- const zAuthMethodTerminal = looseObject({
79311
+ const zAuthMethodTerminal = object({
79320
79312
  _meta: record(string$2(), unknown()).nullish(),
79321
79313
  args: array$3(string$2()).optional(),
79322
79314
  description: string$2().nullish(),
@@ -79325,52 +79317,59 @@ Task description:
79325
79317
  name: string$2()
79326
79318
  });
79327
79319
  const zAuthMethod = union$3([
79328
- zAuthMethodEnvVar.and(looseObject({
79320
+ zAuthMethodEnvVar.and(object({
79329
79321
  type: literal("env_var")
79330
79322
  })),
79331
- zAuthMethodTerminal.and(looseObject({
79323
+ zAuthMethodTerminal.and(object({
79332
79324
  type: literal("terminal")
79333
79325
  })),
79334
79326
  zAuthMethodAgent
79335
79327
  ]);
79336
- const zAuthenticateRequest = looseObject({
79328
+ const zAuthenticateRequest = object({
79337
79329
  _meta: record(string$2(), unknown()).nullish(),
79338
79330
  methodId: string$2()
79339
79331
  });
79340
- const zAuthenticateResponse = looseObject({
79332
+ const zAuthenticateResponse = object({
79341
79333
  _meta: record(string$2(), unknown()).nullish()
79342
79334
  });
79343
- const zBlobResourceContents = looseObject({
79335
+ const zBlobResourceContents = object({
79344
79336
  _meta: record(string$2(), unknown()).nullish(),
79345
79337
  blob: string$2(),
79346
79338
  mimeType: string$2().nullish(),
79347
79339
  uri: string$2()
79348
79340
  });
79349
- const zBooleanPropertySchema = looseObject({
79341
+ const zBooleanPropertySchema = object({
79350
79342
  default: boolean().nullish(),
79351
79343
  description: string$2().nullish(),
79352
79344
  title: string$2().nullish()
79353
79345
  });
79354
- const zCloseNesResponse = looseObject({
79346
+ const zCloseNesResponse = object({
79355
79347
  _meta: record(string$2(), unknown()).nullish()
79356
79348
  });
79357
- const zCloseSessionResponse = looseObject({
79349
+ const zCloseSessionResponse = object({
79358
79350
  _meta: record(string$2(), unknown()).nullish()
79359
79351
  });
79360
- const zCost = looseObject({
79352
+ const zCost = object({
79361
79353
  amount: number$3(),
79362
79354
  currency: string$2()
79363
79355
  });
79364
- const zCreateTerminalResponse = looseObject({
79356
+ const zCreateTerminalResponse = object({
79365
79357
  _meta: record(string$2(), unknown()).nullish(),
79366
79358
  terminalId: string$2()
79367
79359
  });
79368
- const zDiff = looseObject({
79360
+ const zDiff = object({
79369
79361
  _meta: record(string$2(), unknown()).nullish(),
79370
79362
  newText: string$2(),
79371
79363
  oldText: string$2().nullish(),
79372
79364
  path: string$2()
79373
79365
  });
79366
+ const zDisableProvidersRequest = object({
79367
+ _meta: record(string$2(), unknown()).nullish(),
79368
+ id: string$2()
79369
+ });
79370
+ const zDisableProvidersResponse = object({
79371
+ _meta: record(string$2(), unknown()).nullish()
79372
+ });
79374
79373
  const zElicitationContentValue = union$3([
79375
79374
  string$2(),
79376
79375
  number$3(),
@@ -79378,51 +79377,45 @@ Task description:
79378
79377
  boolean(),
79379
79378
  array$3(string$2())
79380
79379
  ]);
79381
- const zElicitationAcceptAction = looseObject({
79380
+ const zElicitationAcceptAction = object({
79382
79381
  content: record(string$2(), zElicitationContentValue).nullish()
79383
79382
  });
79384
- const zElicitationAction = union$3([
79385
- zElicitationAcceptAction.and(looseObject({
79383
+ const zCreateElicitationResponse = intersection(union$3([
79384
+ zElicitationAcceptAction.and(object({
79386
79385
  action: literal("accept")
79387
79386
  })),
79388
- looseObject({
79387
+ object({
79389
79388
  action: literal("decline")
79390
79389
  }),
79391
- looseObject({
79390
+ object({
79392
79391
  action: literal("cancel")
79393
79392
  })
79394
- ]);
79395
- const zElicitationFormCapabilities = looseObject({
79393
+ ]), object({
79394
+ _meta: record(string$2(), unknown()).nullish()
79395
+ }));
79396
+ const zElicitationFormCapabilities = object({
79396
79397
  _meta: record(string$2(), unknown()).nullish()
79397
79398
  });
79398
79399
  const zElicitationId = string$2();
79399
- const zElicitationCompleteNotification = looseObject({
79400
+ const zCompleteElicitationNotification = object({
79400
79401
  _meta: record(string$2(), unknown()).nullish(),
79401
79402
  elicitationId: zElicitationId
79402
79403
  });
79403
- const zElicitationResponse = looseObject({
79404
- _meta: record(string$2(), unknown()).nullish(),
79405
- action: zElicitationAction
79406
- });
79407
79404
  const zElicitationSchemaType = literal("object");
79408
79405
  const zElicitationStringType = literal("string");
79409
- const zElicitationUrlCapabilities = looseObject({
79406
+ const zElicitationUrlCapabilities = object({
79410
79407
  _meta: record(string$2(), unknown()).nullish()
79411
79408
  });
79412
- const zElicitationCapabilities = looseObject({
79409
+ const zElicitationCapabilities = object({
79413
79410
  _meta: record(string$2(), unknown()).nullish(),
79414
79411
  form: zElicitationFormCapabilities.nullish(),
79415
79412
  url: zElicitationUrlCapabilities.nullish()
79416
79413
  });
79417
- const zElicitationUrlMode = looseObject({
79418
- elicitationId: zElicitationId,
79419
- url: string$2().url()
79420
- });
79421
- const zEnumOption = looseObject({
79414
+ const zEnumOption = object({
79422
79415
  const: string$2(),
79423
79416
  title: string$2()
79424
79417
  });
79425
- const zEnvVariable = looseObject({
79418
+ const zEnvVariable = object({
79426
79419
  _meta: record(string$2(), unknown()).nullish(),
79427
79420
  name: string$2(),
79428
79421
  value: string$2()
@@ -79443,7 +79436,7 @@ Task description:
79443
79436
  message: "Invalid value: Expected int32 to be <= 2147483647"
79444
79437
  })
79445
79438
  ]);
79446
- const zError = looseObject({
79439
+ const zError = object({
79447
79440
  code: zErrorCode,
79448
79441
  data: unknown().optional(),
79449
79442
  message: string$2()
@@ -79451,69 +79444,80 @@ Task description:
79451
79444
  const zExtNotification = unknown();
79452
79445
  const zExtRequest = unknown();
79453
79446
  const zExtResponse = unknown();
79454
- const zFileSystemCapabilities = looseObject({
79447
+ const zFileSystemCapabilities = object({
79455
79448
  _meta: record(string$2(), unknown()).nullish(),
79456
79449
  readTextFile: boolean().optional().default(false),
79457
79450
  writeTextFile: boolean().optional().default(false)
79458
79451
  });
79459
- const zHttpHeader = looseObject({
79452
+ const zHttpHeader = object({
79460
79453
  _meta: record(string$2(), unknown()).nullish(),
79461
79454
  name: string$2(),
79462
79455
  value: string$2()
79463
79456
  });
79464
- const zImplementation = looseObject({
79457
+ const zImplementation = object({
79465
79458
  _meta: record(string$2(), unknown()).nullish(),
79466
79459
  name: string$2(),
79467
79460
  title: string$2().nullish(),
79468
79461
  version: string$2()
79469
79462
  });
79470
- const zIntegerPropertySchema = looseObject({
79463
+ const zIntegerPropertySchema = object({
79471
79464
  default: number$3().nullish(),
79472
79465
  description: string$2().nullish(),
79473
79466
  maximum: number$3().nullish(),
79474
79467
  minimum: number$3().nullish(),
79475
79468
  title: string$2().nullish()
79476
79469
  });
79477
- const zKillTerminalResponse = looseObject({
79470
+ const zKillTerminalResponse = object({
79478
79471
  _meta: record(string$2(), unknown()).nullish()
79479
79472
  });
79480
- const zListSessionsRequest = looseObject({
79473
+ const zListProvidersRequest = object({
79474
+ _meta: record(string$2(), unknown()).nullish()
79475
+ });
79476
+ const zListSessionsRequest = object({
79481
79477
  _meta: record(string$2(), unknown()).nullish(),
79482
79478
  additionalDirectories: array$3(string$2()).optional(),
79483
79479
  cursor: string$2().nullish(),
79484
79480
  cwd: string$2().nullish()
79485
79481
  });
79486
- const zLogoutCapabilities = looseObject({
79482
+ const zLlmProtocol = union$3([
79483
+ literal("anthropic"),
79484
+ literal("openai"),
79485
+ literal("azure"),
79486
+ literal("vertex"),
79487
+ literal("bedrock"),
79488
+ string$2()
79489
+ ]);
79490
+ const zLogoutCapabilities = object({
79487
79491
  _meta: record(string$2(), unknown()).nullish()
79488
79492
  });
79489
- const zAgentAuthCapabilities = looseObject({
79493
+ const zAgentAuthCapabilities = object({
79490
79494
  _meta: record(string$2(), unknown()).nullish(),
79491
79495
  logout: zLogoutCapabilities.nullish()
79492
79496
  });
79493
- const zLogoutRequest = looseObject({
79497
+ const zLogoutRequest = object({
79494
79498
  _meta: record(string$2(), unknown()).nullish()
79495
79499
  });
79496
- const zLogoutResponse = looseObject({
79500
+ const zLogoutResponse = object({
79497
79501
  _meta: record(string$2(), unknown()).nullish()
79498
79502
  });
79499
- const zMcpCapabilities = looseObject({
79503
+ const zMcpCapabilities = object({
79500
79504
  _meta: record(string$2(), unknown()).nullish(),
79501
79505
  http: boolean().optional().default(false),
79502
79506
  sse: boolean().optional().default(false)
79503
79507
  });
79504
- const zMcpServerHttp = looseObject({
79508
+ const zMcpServerHttp = object({
79505
79509
  _meta: record(string$2(), unknown()).nullish(),
79506
79510
  headers: array$3(zHttpHeader),
79507
79511
  name: string$2(),
79508
79512
  url: string$2()
79509
79513
  });
79510
- const zMcpServerSse = looseObject({
79514
+ const zMcpServerSse = object({
79511
79515
  _meta: record(string$2(), unknown()).nullish(),
79512
79516
  headers: array$3(zHttpHeader),
79513
79517
  name: string$2(),
79514
79518
  url: string$2()
79515
79519
  });
79516
- const zMcpServerStdio = looseObject({
79520
+ const zMcpServerStdio = object({
79517
79521
  _meta: record(string$2(), unknown()).nullish(),
79518
79522
  args: array$3(string$2()),
79519
79523
  command: string$2(),
@@ -79521,16 +79525,16 @@ Task description:
79521
79525
  name: string$2()
79522
79526
  });
79523
79527
  const zMcpServer = union$3([
79524
- zMcpServerHttp.and(looseObject({
79528
+ zMcpServerHttp.and(object({
79525
79529
  type: literal("http")
79526
79530
  })),
79527
- zMcpServerSse.and(looseObject({
79531
+ zMcpServerSse.and(object({
79528
79532
  type: literal("sse")
79529
79533
  })),
79530
79534
  zMcpServerStdio
79531
79535
  ]);
79532
79536
  const zModelId = string$2();
79533
- const zModelInfo = looseObject({
79537
+ const zModelInfo = object({
79534
79538
  _meta: record(string$2(), unknown()).nullish(),
79535
79539
  description: string$2().nullish(),
79536
79540
  modelId: zModelId,
@@ -79542,32 +79546,32 @@ Task description:
79542
79546
  literal("information"),
79543
79547
  literal("hint")
79544
79548
  ]);
79545
- const zNesDiagnosticsCapabilities = looseObject({
79549
+ const zNesDiagnosticsCapabilities = object({
79546
79550
  _meta: record(string$2(), unknown()).nullish()
79547
79551
  });
79548
- const zNesDocumentDidCloseCapabilities = looseObject({
79552
+ const zNesDocumentDidCloseCapabilities = object({
79549
79553
  _meta: record(string$2(), unknown()).nullish()
79550
79554
  });
79551
- const zNesDocumentDidFocusCapabilities = looseObject({
79555
+ const zNesDocumentDidFocusCapabilities = object({
79552
79556
  _meta: record(string$2(), unknown()).nullish()
79553
79557
  });
79554
- const zNesDocumentDidOpenCapabilities = looseObject({
79558
+ const zNesDocumentDidOpenCapabilities = object({
79555
79559
  _meta: record(string$2(), unknown()).nullish()
79556
79560
  });
79557
- const zNesDocumentDidSaveCapabilities = looseObject({
79561
+ const zNesDocumentDidSaveCapabilities = object({
79558
79562
  _meta: record(string$2(), unknown()).nullish()
79559
79563
  });
79560
- const zNesEditHistoryCapabilities = looseObject({
79564
+ const zNesEditHistoryCapabilities = object({
79561
79565
  _meta: record(string$2(), unknown()).nullish(),
79562
79566
  maxCount: number$3().int().gte(0).max(4294967295, {
79563
79567
  message: "Invalid value: Expected uint32 to be <= 4294967295"
79564
79568
  }).nullish()
79565
79569
  });
79566
- const zNesEditHistoryEntry = looseObject({
79570
+ const zNesEditHistoryEntry = object({
79567
79571
  diff: string$2(),
79568
79572
  uri: string$2()
79569
79573
  });
79570
- const zNesExcerpt = looseObject({
79574
+ const zNesExcerpt = object({
79571
79575
  endLine: number$3().int().gte(0).max(4294967295, {
79572
79576
  message: "Invalid value: Expected uint32 to be <= 4294967295"
79573
79577
  }),
@@ -79576,18 +79580,18 @@ Task description:
79576
79580
  }),
79577
79581
  text: string$2()
79578
79582
  });
79579
- const zNesJumpCapabilities = looseObject({
79583
+ const zNesJumpCapabilities = object({
79580
79584
  _meta: record(string$2(), unknown()).nullish()
79581
79585
  });
79582
- const zNesOpenFilesCapabilities = looseObject({
79586
+ const zNesOpenFilesCapabilities = object({
79583
79587
  _meta: record(string$2(), unknown()).nullish()
79584
79588
  });
79585
- const zNesRecentFile = looseObject({
79589
+ const zNesRecentFile = object({
79586
79590
  languageId: string$2(),
79587
79591
  text: string$2(),
79588
79592
  uri: string$2()
79589
79593
  });
79590
- const zNesRecentFilesCapabilities = looseObject({
79594
+ const zNesRecentFilesCapabilities = object({
79591
79595
  _meta: record(string$2(), unknown()).nullish(),
79592
79596
  maxCount: number$3().int().gte(0).max(4294967295, {
79593
79597
  message: "Invalid value: Expected uint32 to be <= 4294967295"
@@ -79599,31 +79603,31 @@ Task description:
79599
79603
  literal("replaced"),
79600
79604
  literal("cancelled")
79601
79605
  ]);
79602
- const zNesRelatedSnippet = looseObject({
79606
+ const zNesRelatedSnippet = object({
79603
79607
  excerpts: array$3(zNesExcerpt),
79604
79608
  uri: string$2()
79605
79609
  });
79606
- const zNesRelatedSnippetsCapabilities = looseObject({
79610
+ const zNesRelatedSnippetsCapabilities = object({
79607
79611
  _meta: record(string$2(), unknown()).nullish()
79608
79612
  });
79609
- const zNesRenameCapabilities = looseObject({
79613
+ const zNesRenameCapabilities = object({
79610
79614
  _meta: record(string$2(), unknown()).nullish()
79611
79615
  });
79612
- const zNesRepository = looseObject({
79616
+ const zNesRepository = object({
79613
79617
  name: string$2(),
79614
79618
  owner: string$2(),
79615
79619
  remoteUrl: string$2()
79616
79620
  });
79617
- const zNesSearchAndReplaceCapabilities = looseObject({
79621
+ const zNesSearchAndReplaceCapabilities = object({
79618
79622
  _meta: record(string$2(), unknown()).nullish()
79619
79623
  });
79620
- const zClientNesCapabilities = looseObject({
79624
+ const zClientNesCapabilities = object({
79621
79625
  _meta: record(string$2(), unknown()).nullish(),
79622
79626
  jump: zNesJumpCapabilities.nullish(),
79623
79627
  rename: zNesRenameCapabilities.nullish(),
79624
79628
  searchAndReplace: zNesSearchAndReplaceCapabilities.nullish()
79625
79629
  });
79626
- const zNesSearchAndReplaceSuggestion = looseObject({
79630
+ const zNesSearchAndReplaceSuggestion = object({
79627
79631
  id: string$2(),
79628
79632
  isRegex: boolean().nullish(),
79629
79633
  replace: string$2(),
@@ -79635,13 +79639,13 @@ Task description:
79635
79639
  literal("diagnostic"),
79636
79640
  literal("manual")
79637
79641
  ]);
79638
- const zNesUserActionsCapabilities = looseObject({
79642
+ const zNesUserActionsCapabilities = object({
79639
79643
  _meta: record(string$2(), unknown()).nullish(),
79640
79644
  maxCount: number$3().int().gte(0).max(4294967295, {
79641
79645
  message: "Invalid value: Expected uint32 to be <= 4294967295"
79642
79646
  }).nullish()
79643
79647
  });
79644
- const zNesContextCapabilities = looseObject({
79648
+ const zNesContextCapabilities = object({
79645
79649
  _meta: record(string$2(), unknown()).nullish(),
79646
79650
  diagnostics: zNesDiagnosticsCapabilities.nullish(),
79647
79651
  editHistory: zNesEditHistoryCapabilities.nullish(),
@@ -79650,13 +79654,13 @@ Task description:
79650
79654
  relatedSnippets: zNesRelatedSnippetsCapabilities.nullish(),
79651
79655
  userActions: zNesUserActionsCapabilities.nullish()
79652
79656
  });
79653
- const zNewSessionRequest = looseObject({
79657
+ const zNewSessionRequest = object({
79654
79658
  _meta: record(string$2(), unknown()).nullish(),
79655
79659
  additionalDirectories: array$3(string$2()).optional(),
79656
79660
  cwd: string$2(),
79657
79661
  mcpServers: array$3(zMcpServer)
79658
79662
  });
79659
- const zNumberPropertySchema = looseObject({
79663
+ const zNumberPropertySchema = object({
79660
79664
  default: number$3().nullish(),
79661
79665
  description: string$2().nullish(),
79662
79666
  maximum: number$3().nullish(),
@@ -79670,7 +79674,7 @@ Task description:
79670
79674
  literal("reject_once"),
79671
79675
  literal("reject_always")
79672
79676
  ]);
79673
- const zPermissionOption = looseObject({
79677
+ const zPermissionOption = object({
79674
79678
  _meta: record(string$2(), unknown()).nullish(),
79675
79679
  kind: zPermissionOptionKind,
79676
79680
  name: string$2(),
@@ -79686,17 +79690,17 @@ Task description:
79686
79690
  literal("in_progress"),
79687
79691
  literal("completed")
79688
79692
  ]);
79689
- const zPlanEntry = looseObject({
79693
+ const zPlanEntry = object({
79690
79694
  _meta: record(string$2(), unknown()).nullish(),
79691
79695
  content: string$2(),
79692
79696
  priority: zPlanEntryPriority,
79693
79697
  status: zPlanEntryStatus
79694
79698
  });
79695
- const zPlan = looseObject({
79699
+ const zPlan = object({
79696
79700
  _meta: record(string$2(), unknown()).nullish(),
79697
79701
  entries: array$3(zPlanEntry)
79698
79702
  });
79699
- const zPosition = looseObject({
79703
+ const zPosition = object({
79700
79704
  character: number$3().int().gte(0).max(4294967295, {
79701
79705
  message: "Invalid value: Expected uint32 to be <= 4294967295"
79702
79706
  }),
@@ -79704,18 +79708,18 @@ Task description:
79704
79708
  message: "Invalid value: Expected uint32 to be <= 4294967295"
79705
79709
  })
79706
79710
  });
79707
- const zNesJumpSuggestion = looseObject({
79711
+ const zNesJumpSuggestion = object({
79708
79712
  id: string$2(),
79709
79713
  position: zPosition,
79710
79714
  uri: string$2()
79711
79715
  });
79712
- const zNesRenameSuggestion = looseObject({
79716
+ const zNesRenameSuggestion = object({
79713
79717
  id: string$2(),
79714
79718
  newName: string$2(),
79715
79719
  position: zPosition,
79716
79720
  uri: string$2()
79717
79721
  });
79718
- const zNesUserAction = looseObject({
79722
+ const zNesUserAction = object({
79719
79723
  action: string$2(),
79720
79724
  position: zPosition,
79721
79725
  timestampMs: number$3(),
@@ -79726,7 +79730,7 @@ Task description:
79726
79730
  literal("utf-32"),
79727
79731
  literal("utf-8")
79728
79732
  ]);
79729
- const zClientCapabilities = looseObject({
79733
+ const zClientCapabilities = object({
79730
79734
  _meta: record(string$2(), unknown()).nullish(),
79731
79735
  auth: zAuthCapabilities.optional().default({
79732
79736
  terminal: false
@@ -79740,14 +79744,14 @@ Task description:
79740
79744
  positionEncodings: array$3(zPositionEncodingKind).optional(),
79741
79745
  terminal: boolean().optional().default(false)
79742
79746
  });
79743
- const zPromptCapabilities = looseObject({
79747
+ const zPromptCapabilities = object({
79744
79748
  _meta: record(string$2(), unknown()).nullish(),
79745
79749
  audio: boolean().optional().default(false),
79746
79750
  embeddedContext: boolean().optional().default(false),
79747
79751
  image: boolean().optional().default(false)
79748
79752
  });
79749
79753
  const zProtocolVersion = number$3().int().gte(0).lte(65535);
79750
- const zInitializeRequest = looseObject({
79754
+ const zInitializeRequest = object({
79751
79755
  _meta: record(string$2(), unknown()).nullish(),
79752
79756
  clientCapabilities: zClientCapabilities.optional().default({
79753
79757
  auth: {
@@ -79762,23 +79766,41 @@ Task description:
79762
79766
  clientInfo: zImplementation.nullish(),
79763
79767
  protocolVersion: zProtocolVersion
79764
79768
  });
79765
- const zRange = looseObject({
79769
+ const zProviderCurrentConfig = object({
79770
+ apiType: zLlmProtocol,
79771
+ baseUrl: string$2()
79772
+ });
79773
+ const zProviderInfo = object({
79774
+ _meta: record(string$2(), unknown()).nullish(),
79775
+ current: zProviderCurrentConfig.nullish(),
79776
+ id: string$2(),
79777
+ required: boolean(),
79778
+ supported: array$3(zLlmProtocol)
79779
+ });
79780
+ const zListProvidersResponse = object({
79781
+ _meta: record(string$2(), unknown()).nullish(),
79782
+ providers: array$3(zProviderInfo)
79783
+ });
79784
+ const zProvidersCapabilities = object({
79785
+ _meta: record(string$2(), unknown()).nullish()
79786
+ });
79787
+ const zRange = object({
79766
79788
  end: zPosition,
79767
79789
  start: zPosition
79768
79790
  });
79769
- const zNesDiagnostic = looseObject({
79791
+ const zNesDiagnostic = object({
79770
79792
  message: string$2(),
79771
79793
  range: zRange,
79772
79794
  severity: zNesDiagnosticSeverity,
79773
79795
  uri: string$2()
79774
79796
  });
79775
- const zNesOpenFile = looseObject({
79797
+ const zNesOpenFile = object({
79776
79798
  languageId: string$2(),
79777
79799
  lastFocusedMs: number$3().nullish(),
79778
79800
  uri: string$2(),
79779
79801
  visibleRange: zRange.nullish()
79780
79802
  });
79781
- const zNesSuggestContext = looseObject({
79803
+ const zNesSuggestContext = object({
79782
79804
  _meta: record(string$2(), unknown()).nullish(),
79783
79805
  diagnostics: array$3(zNesDiagnostic).nullish(),
79784
79806
  editHistory: array$3(zNesEditHistoryEntry).nullish(),
@@ -79787,69 +79809,72 @@ Task description:
79787
79809
  relatedSnippets: array$3(zNesRelatedSnippet).nullish(),
79788
79810
  userActions: array$3(zNesUserAction).nullish()
79789
79811
  });
79790
- const zNesTextEdit = looseObject({
79812
+ const zNesTextEdit = object({
79791
79813
  newText: string$2(),
79792
79814
  range: zRange
79793
79815
  });
79794
- const zNesEditSuggestion = looseObject({
79816
+ const zNesEditSuggestion = object({
79795
79817
  cursorPosition: zPosition.nullish(),
79796
79818
  edits: array$3(zNesTextEdit),
79797
79819
  id: string$2(),
79798
79820
  uri: string$2()
79799
79821
  });
79800
79822
  const zNesSuggestion = union$3([
79801
- zNesEditSuggestion.and(looseObject({
79823
+ zNesEditSuggestion.and(object({
79802
79824
  kind: literal("edit")
79803
79825
  })),
79804
- zNesJumpSuggestion.and(looseObject({
79826
+ zNesJumpSuggestion.and(object({
79805
79827
  kind: literal("jump")
79806
79828
  })),
79807
- zNesRenameSuggestion.and(looseObject({
79829
+ zNesRenameSuggestion.and(object({
79808
79830
  kind: literal("rename")
79809
79831
  })),
79810
- zNesSearchAndReplaceSuggestion.and(looseObject({
79832
+ zNesSearchAndReplaceSuggestion.and(object({
79811
79833
  kind: literal("searchAndReplace")
79812
79834
  }))
79813
79835
  ]);
79814
- const zReadTextFileResponse = looseObject({
79836
+ const zReadTextFileResponse = object({
79815
79837
  _meta: record(string$2(), unknown()).nullish(),
79816
79838
  content: string$2()
79817
79839
  });
79818
- const zReleaseTerminalResponse = looseObject({
79840
+ const zReleaseTerminalResponse = object({
79819
79841
  _meta: record(string$2(), unknown()).nullish()
79820
79842
  });
79821
79843
  const zRequestId = union$3([
79822
79844
  number$3(),
79823
79845
  string$2()
79824
79846
  ]).nullable();
79825
- looseObject({
79847
+ object({
79826
79848
  _meta: record(string$2(), unknown()).nullish(),
79827
79849
  requestId: zRequestId
79828
79850
  });
79851
+ const zElicitationRequestScope = object({
79852
+ requestId: zRequestId
79853
+ });
79829
79854
  const zRole = _enum([
79830
79855
  "assistant",
79831
79856
  "user"
79832
79857
  ]);
79833
- const zAnnotations = looseObject({
79858
+ const zAnnotations = object({
79834
79859
  _meta: record(string$2(), unknown()).nullish(),
79835
79860
  audience: array$3(zRole).nullish(),
79836
79861
  lastModified: string$2().nullish(),
79837
79862
  priority: number$3().nullish()
79838
79863
  });
79839
- const zAudioContent = looseObject({
79864
+ const zAudioContent = object({
79840
79865
  _meta: record(string$2(), unknown()).nullish(),
79841
79866
  annotations: zAnnotations.nullish(),
79842
79867
  data: string$2(),
79843
79868
  mimeType: string$2()
79844
79869
  });
79845
- const zImageContent = looseObject({
79870
+ const zImageContent = object({
79846
79871
  _meta: record(string$2(), unknown()).nullish(),
79847
79872
  annotations: zAnnotations.nullish(),
79848
79873
  data: string$2(),
79849
79874
  mimeType: string$2(),
79850
79875
  uri: string$2().nullish()
79851
79876
  });
79852
- const zResourceLink = looseObject({
79877
+ const zResourceLink = object({
79853
79878
  _meta: record(string$2(), unknown()).nullish(),
79854
79879
  annotations: zAnnotations.nullish(),
79855
79880
  description: string$2().nullish(),
@@ -79859,29 +79884,29 @@ Task description:
79859
79884
  title: string$2().nullish(),
79860
79885
  uri: string$2()
79861
79886
  });
79862
- const zSelectedPermissionOutcome = looseObject({
79887
+ const zSelectedPermissionOutcome = object({
79863
79888
  _meta: record(string$2(), unknown()).nullish(),
79864
79889
  optionId: zPermissionOptionId
79865
79890
  });
79866
79891
  const zRequestPermissionOutcome = union$3([
79867
- looseObject({
79892
+ object({
79868
79893
  outcome: literal("cancelled")
79869
79894
  }),
79870
- zSelectedPermissionOutcome.and(looseObject({
79895
+ zSelectedPermissionOutcome.and(object({
79871
79896
  outcome: literal("selected")
79872
79897
  }))
79873
79898
  ]);
79874
- const zRequestPermissionResponse = looseObject({
79899
+ const zRequestPermissionResponse = object({
79875
79900
  _meta: record(string$2(), unknown()).nullish(),
79876
79901
  outcome: zRequestPermissionOutcome
79877
79902
  });
79878
- const zSessionAdditionalDirectoriesCapabilities = looseObject({
79903
+ const zSessionAdditionalDirectoriesCapabilities = object({
79879
79904
  _meta: record(string$2(), unknown()).nullish()
79880
79905
  });
79881
- const zSessionCloseCapabilities = looseObject({
79906
+ const zSessionCloseCapabilities = object({
79882
79907
  _meta: record(string$2(), unknown()).nullish()
79883
79908
  });
79884
- const zSessionConfigBoolean = looseObject({
79909
+ const zSessionConfigBoolean = object({
79885
79910
  currentValue: boolean()
79886
79911
  });
79887
79912
  const zSessionConfigGroupId = string$2();
@@ -79893,13 +79918,13 @@ Task description:
79893
79918
  string$2()
79894
79919
  ]);
79895
79920
  const zSessionConfigValueId = string$2();
79896
- const zSessionConfigSelectOption = looseObject({
79921
+ const zSessionConfigSelectOption = object({
79897
79922
  _meta: record(string$2(), unknown()).nullish(),
79898
79923
  description: string$2().nullish(),
79899
79924
  name: string$2(),
79900
79925
  value: zSessionConfigValueId
79901
79926
  });
79902
- const zSessionConfigSelectGroup = looseObject({
79927
+ const zSessionConfigSelectGroup = object({
79903
79928
  _meta: record(string$2(), unknown()).nullish(),
79904
79929
  group: zSessionConfigGroupId,
79905
79930
  name: string$2(),
@@ -79909,50 +79934,50 @@ Task description:
79909
79934
  array$3(zSessionConfigSelectOption),
79910
79935
  array$3(zSessionConfigSelectGroup)
79911
79936
  ]);
79912
- const zSessionConfigSelect = looseObject({
79937
+ const zSessionConfigSelect = object({
79913
79938
  currentValue: zSessionConfigValueId,
79914
79939
  options: zSessionConfigSelectOptions
79915
79940
  });
79916
79941
  const zSessionConfigOption = intersection(union$3([
79917
- zSessionConfigSelect.and(looseObject({
79942
+ zSessionConfigSelect.and(object({
79918
79943
  type: literal("select")
79919
79944
  })),
79920
- zSessionConfigBoolean.and(looseObject({
79945
+ zSessionConfigBoolean.and(object({
79921
79946
  type: literal("boolean")
79922
79947
  }))
79923
- ]), looseObject({
79948
+ ]), object({
79924
79949
  _meta: record(string$2(), unknown()).nullish(),
79925
79950
  category: zSessionConfigOptionCategory.nullish(),
79926
79951
  description: string$2().nullish(),
79927
79952
  id: zSessionConfigId,
79928
79953
  name: string$2()
79929
79954
  }));
79930
- const zConfigOptionUpdate = looseObject({
79955
+ const zConfigOptionUpdate = object({
79931
79956
  _meta: record(string$2(), unknown()).nullish(),
79932
79957
  configOptions: array$3(zSessionConfigOption)
79933
79958
  });
79934
- const zSessionForkCapabilities = looseObject({
79959
+ const zSessionForkCapabilities = object({
79935
79960
  _meta: record(string$2(), unknown()).nullish()
79936
79961
  });
79937
79962
  const zSessionId = string$2();
79938
- const zAcceptNesNotification = looseObject({
79963
+ const zAcceptNesNotification = object({
79939
79964
  _meta: record(string$2(), unknown()).nullish(),
79940
79965
  id: string$2(),
79941
79966
  sessionId: zSessionId
79942
79967
  });
79943
- const zCancelNotification = looseObject({
79968
+ const zCancelNotification = object({
79944
79969
  _meta: record(string$2(), unknown()).nullish(),
79945
79970
  sessionId: zSessionId
79946
79971
  });
79947
- const zCloseNesRequest = looseObject({
79972
+ const zCloseNesRequest = object({
79948
79973
  _meta: record(string$2(), unknown()).nullish(),
79949
79974
  sessionId: zSessionId
79950
79975
  });
79951
- const zCloseSessionRequest = looseObject({
79976
+ const zCloseSessionRequest = object({
79952
79977
  _meta: record(string$2(), unknown()).nullish(),
79953
79978
  sessionId: zSessionId
79954
79979
  });
79955
- const zCreateTerminalRequest = looseObject({
79980
+ const zCreateTerminalRequest = object({
79956
79981
  _meta: record(string$2(), unknown()).nullish(),
79957
79982
  args: array$3(string$2()).optional(),
79958
79983
  command: string$2(),
@@ -79961,12 +79986,12 @@ Task description:
79961
79986
  outputByteLimit: number$3().nullish(),
79962
79987
  sessionId: zSessionId
79963
79988
  });
79964
- const zDidCloseDocumentNotification = looseObject({
79989
+ const zDidCloseDocumentNotification = object({
79965
79990
  _meta: record(string$2(), unknown()).nullish(),
79966
79991
  sessionId: zSessionId,
79967
79992
  uri: string$2()
79968
79993
  });
79969
- const zDidFocusDocumentNotification = looseObject({
79994
+ const zDidFocusDocumentNotification = object({
79970
79995
  _meta: record(string$2(), unknown()).nullish(),
79971
79996
  position: zPosition,
79972
79997
  sessionId: zSessionId,
@@ -79974,7 +79999,7 @@ Task description:
79974
79999
  version: number$3(),
79975
80000
  visibleRange: zRange
79976
80001
  });
79977
- const zDidOpenDocumentNotification = looseObject({
80002
+ const zDidOpenDocumentNotification = object({
79978
80003
  _meta: record(string$2(), unknown()).nullish(),
79979
80004
  languageId: string$2(),
79980
80005
  sessionId: zSessionId,
@@ -79982,31 +80007,31 @@ Task description:
79982
80007
  uri: string$2(),
79983
80008
  version: number$3()
79984
80009
  });
79985
- const zDidSaveDocumentNotification = looseObject({
80010
+ const zDidSaveDocumentNotification = object({
79986
80011
  _meta: record(string$2(), unknown()).nullish(),
79987
80012
  sessionId: zSessionId,
79988
80013
  uri: string$2()
79989
80014
  });
79990
- const zForkSessionRequest = looseObject({
80015
+ const zForkSessionRequest = object({
79991
80016
  _meta: record(string$2(), unknown()).nullish(),
79992
80017
  additionalDirectories: array$3(string$2()).optional(),
79993
80018
  cwd: string$2(),
79994
80019
  mcpServers: array$3(zMcpServer).optional(),
79995
80020
  sessionId: zSessionId
79996
80021
  });
79997
- const zKillTerminalRequest = looseObject({
80022
+ const zKillTerminalRequest = object({
79998
80023
  _meta: record(string$2(), unknown()).nullish(),
79999
80024
  sessionId: zSessionId,
80000
80025
  terminalId: string$2()
80001
80026
  });
80002
- const zLoadSessionRequest = looseObject({
80027
+ const zLoadSessionRequest = object({
80003
80028
  _meta: record(string$2(), unknown()).nullish(),
80004
80029
  additionalDirectories: array$3(string$2()).optional(),
80005
80030
  cwd: string$2(),
80006
80031
  mcpServers: array$3(zMcpServer),
80007
80032
  sessionId: zSessionId
80008
80033
  });
80009
- const zReadTextFileRequest = looseObject({
80034
+ const zReadTextFileRequest = object({
80010
80035
  _meta: record(string$2(), unknown()).nullish(),
80011
80036
  limit: number$3().int().gte(0).max(4294967295, {
80012
80037
  message: "Invalid value: Expected uint32 to be <= 4294967295"
@@ -80017,25 +80042,25 @@ Task description:
80017
80042
  path: string$2(),
80018
80043
  sessionId: zSessionId
80019
80044
  });
80020
- const zRejectNesNotification = looseObject({
80045
+ const zRejectNesNotification = object({
80021
80046
  _meta: record(string$2(), unknown()).nullish(),
80022
80047
  id: string$2(),
80023
80048
  reason: zNesRejectReason.nullish(),
80024
80049
  sessionId: zSessionId
80025
80050
  });
80026
- const zReleaseTerminalRequest = looseObject({
80051
+ const zReleaseTerminalRequest = object({
80027
80052
  _meta: record(string$2(), unknown()).nullish(),
80028
80053
  sessionId: zSessionId,
80029
80054
  terminalId: string$2()
80030
80055
  });
80031
- const zResumeSessionRequest = looseObject({
80056
+ const zResumeSessionRequest = object({
80032
80057
  _meta: record(string$2(), unknown()).nullish(),
80033
80058
  additionalDirectories: array$3(string$2()).optional(),
80034
80059
  cwd: string$2(),
80035
80060
  mcpServers: array$3(zMcpServer).optional(),
80036
80061
  sessionId: zSessionId
80037
80062
  });
80038
- const zSessionInfo = looseObject({
80063
+ const zSessionInfo = object({
80039
80064
  _meta: record(string$2(), unknown()).nullish(),
80040
80065
  additionalDirectories: array$3(string$2()).optional(),
80041
80066
  cwd: string$2(),
@@ -80043,70 +80068,70 @@ Task description:
80043
80068
  title: string$2().nullish(),
80044
80069
  updatedAt: string$2().nullish()
80045
80070
  });
80046
- const zListSessionsResponse = looseObject({
80071
+ const zListSessionsResponse = object({
80047
80072
  _meta: record(string$2(), unknown()).nullish(),
80048
80073
  nextCursor: string$2().nullish(),
80049
80074
  sessions: array$3(zSessionInfo)
80050
80075
  });
80051
- const zSessionInfoUpdate = looseObject({
80076
+ const zSessionInfoUpdate = object({
80052
80077
  _meta: record(string$2(), unknown()).nullish(),
80053
80078
  title: string$2().nullish(),
80054
80079
  updatedAt: string$2().nullish()
80055
80080
  });
80056
- const zSessionListCapabilities = looseObject({
80081
+ const zSessionListCapabilities = object({
80057
80082
  _meta: record(string$2(), unknown()).nullish()
80058
80083
  });
80059
80084
  const zSessionModeId = string$2();
80060
- const zCurrentModeUpdate = looseObject({
80085
+ const zCurrentModeUpdate = object({
80061
80086
  _meta: record(string$2(), unknown()).nullish(),
80062
80087
  currentModeId: zSessionModeId
80063
80088
  });
80064
- const zSessionMode = looseObject({
80089
+ const zSessionMode = object({
80065
80090
  _meta: record(string$2(), unknown()).nullish(),
80066
80091
  description: string$2().nullish(),
80067
80092
  id: zSessionModeId,
80068
80093
  name: string$2()
80069
80094
  });
80070
- const zSessionModeState = looseObject({
80095
+ const zSessionModeState = object({
80071
80096
  _meta: record(string$2(), unknown()).nullish(),
80072
80097
  availableModes: array$3(zSessionMode),
80073
80098
  currentModeId: zSessionModeId
80074
80099
  });
80075
- const zSessionModelState = looseObject({
80100
+ const zSessionModelState = object({
80076
80101
  _meta: record(string$2(), unknown()).nullish(),
80077
80102
  availableModels: array$3(zModelInfo),
80078
80103
  currentModelId: zModelId
80079
80104
  });
80080
- const zForkSessionResponse = looseObject({
80105
+ const zForkSessionResponse = object({
80081
80106
  _meta: record(string$2(), unknown()).nullish(),
80082
80107
  configOptions: array$3(zSessionConfigOption).nullish(),
80083
80108
  models: zSessionModelState.nullish(),
80084
80109
  modes: zSessionModeState.nullish(),
80085
80110
  sessionId: zSessionId
80086
80111
  });
80087
- const zLoadSessionResponse = looseObject({
80112
+ const zLoadSessionResponse = object({
80088
80113
  _meta: record(string$2(), unknown()).nullish(),
80089
80114
  configOptions: array$3(zSessionConfigOption).nullish(),
80090
80115
  models: zSessionModelState.nullish(),
80091
80116
  modes: zSessionModeState.nullish()
80092
80117
  });
80093
- const zNewSessionResponse = looseObject({
80118
+ const zNewSessionResponse = object({
80094
80119
  _meta: record(string$2(), unknown()).nullish(),
80095
80120
  configOptions: array$3(zSessionConfigOption).nullish(),
80096
80121
  models: zSessionModelState.nullish(),
80097
80122
  modes: zSessionModeState.nullish(),
80098
80123
  sessionId: zSessionId
80099
80124
  });
80100
- const zResumeSessionResponse = looseObject({
80125
+ const zResumeSessionResponse = object({
80101
80126
  _meta: record(string$2(), unknown()).nullish(),
80102
80127
  configOptions: array$3(zSessionConfigOption).nullish(),
80103
80128
  models: zSessionModelState.nullish(),
80104
80129
  modes: zSessionModeState.nullish()
80105
80130
  });
80106
- const zSessionResumeCapabilities = looseObject({
80131
+ const zSessionResumeCapabilities = object({
80107
80132
  _meta: record(string$2(), unknown()).nullish()
80108
80133
  });
80109
- const zSessionCapabilities = looseObject({
80134
+ const zSessionCapabilities = object({
80110
80135
  _meta: record(string$2(), unknown()).nullish(),
80111
80136
  additionalDirectories: zSessionAdditionalDirectoriesCapabilities.nullish(),
80112
80137
  close: zSessionCloseCapabilities.nullish(),
@@ -80114,40 +80139,50 @@ Task description:
80114
80139
  list: zSessionListCapabilities.nullish(),
80115
80140
  resume: zSessionResumeCapabilities.nullish()
80116
80141
  });
80142
+ const zSetProvidersRequest = object({
80143
+ _meta: record(string$2(), unknown()).nullish(),
80144
+ apiType: zLlmProtocol,
80145
+ baseUrl: string$2(),
80146
+ headers: record(string$2(), string$2()).optional(),
80147
+ id: string$2()
80148
+ });
80149
+ const zSetProvidersResponse = object({
80150
+ _meta: record(string$2(), unknown()).nullish()
80151
+ });
80117
80152
  const zSetSessionConfigOptionRequest = intersection(union$3([
80118
- looseObject({
80153
+ object({
80119
80154
  type: literal("boolean"),
80120
80155
  value: boolean()
80121
80156
  }),
80122
- looseObject({
80157
+ object({
80123
80158
  value: zSessionConfigValueId
80124
80159
  })
80125
- ]), looseObject({
80160
+ ]), object({
80126
80161
  _meta: record(string$2(), unknown()).nullish(),
80127
80162
  configId: zSessionConfigId,
80128
80163
  sessionId: zSessionId
80129
80164
  }));
80130
- const zSetSessionConfigOptionResponse = looseObject({
80165
+ const zSetSessionConfigOptionResponse = object({
80131
80166
  _meta: record(string$2(), unknown()).nullish(),
80132
80167
  configOptions: array$3(zSessionConfigOption)
80133
80168
  });
80134
- const zSetSessionModeRequest = looseObject({
80169
+ const zSetSessionModeRequest = object({
80135
80170
  _meta: record(string$2(), unknown()).nullish(),
80136
80171
  modeId: zSessionModeId,
80137
80172
  sessionId: zSessionId
80138
80173
  });
80139
- const zSetSessionModeResponse = looseObject({
80174
+ const zSetSessionModeResponse = object({
80140
80175
  _meta: record(string$2(), unknown()).nullish()
80141
80176
  });
80142
- const zSetSessionModelRequest = looseObject({
80177
+ const zSetSessionModelRequest = object({
80143
80178
  _meta: record(string$2(), unknown()).nullish(),
80144
80179
  modelId: zModelId,
80145
80180
  sessionId: zSessionId
80146
80181
  });
80147
- const zSetSessionModelResponse = looseObject({
80182
+ const zSetSessionModelResponse = object({
80148
80183
  _meta: record(string$2(), unknown()).nullish()
80149
80184
  });
80150
- const zStartNesResponse = looseObject({
80185
+ const zStartNesResponse = object({
80151
80186
  _meta: record(string$2(), unknown()).nullish(),
80152
80187
  sessionId: zSessionId
80153
80188
  });
@@ -80164,7 +80199,7 @@ Task description:
80164
80199
  literal("date"),
80165
80200
  literal("date-time")
80166
80201
  ]);
80167
- const zStringPropertySchema = looseObject({
80202
+ const zStringPropertySchema = object({
80168
80203
  default: string$2().nullish(),
80169
80204
  description: string$2().nullish(),
80170
80205
  enum: array$3(string$2()).nullish(),
@@ -80179,7 +80214,7 @@ Task description:
80179
80214
  pattern: string$2().nullish(),
80180
80215
  title: string$2().nullish()
80181
80216
  });
80182
- const zSuggestNesRequest = looseObject({
80217
+ const zSuggestNesRequest = object({
80183
80218
  _meta: record(string$2(), unknown()).nullish(),
80184
80219
  context: zNesSuggestContext.nullish(),
80185
80220
  position: zPosition,
@@ -80189,49 +80224,49 @@ Task description:
80189
80224
  uri: string$2(),
80190
80225
  version: number$3()
80191
80226
  });
80192
- const zSuggestNesResponse = looseObject({
80227
+ const zSuggestNesResponse = object({
80193
80228
  _meta: record(string$2(), unknown()).nullish(),
80194
80229
  suggestions: array$3(zNesSuggestion)
80195
80230
  });
80196
- const zTerminal = looseObject({
80231
+ const zTerminal = object({
80197
80232
  _meta: record(string$2(), unknown()).nullish(),
80198
80233
  terminalId: string$2()
80199
80234
  });
80200
- const zTerminalExitStatus = looseObject({
80235
+ const zTerminalExitStatus = object({
80201
80236
  _meta: record(string$2(), unknown()).nullish(),
80202
80237
  exitCode: number$3().int().gte(0).max(4294967295, {
80203
80238
  message: "Invalid value: Expected uint32 to be <= 4294967295"
80204
80239
  }).nullish(),
80205
80240
  signal: string$2().nullish()
80206
80241
  });
80207
- const zTerminalOutputRequest = looseObject({
80242
+ const zTerminalOutputRequest = object({
80208
80243
  _meta: record(string$2(), unknown()).nullish(),
80209
80244
  sessionId: zSessionId,
80210
80245
  terminalId: string$2()
80211
80246
  });
80212
- const zTerminalOutputResponse = looseObject({
80247
+ const zTerminalOutputResponse = object({
80213
80248
  _meta: record(string$2(), unknown()).nullish(),
80214
80249
  exitStatus: zTerminalExitStatus.nullish(),
80215
80250
  output: string$2(),
80216
80251
  truncated: boolean()
80217
80252
  });
80218
- const zTextContent = looseObject({
80253
+ const zTextContent = object({
80219
80254
  _meta: record(string$2(), unknown()).nullish(),
80220
80255
  annotations: zAnnotations.nullish(),
80221
80256
  text: string$2()
80222
80257
  });
80223
- const zTextDocumentContentChangeEvent = looseObject({
80258
+ const zTextDocumentContentChangeEvent = object({
80224
80259
  range: zRange.nullish(),
80225
80260
  text: string$2()
80226
80261
  });
80227
- const zDidChangeDocumentNotification = looseObject({
80262
+ const zDidChangeDocumentNotification = object({
80228
80263
  _meta: record(string$2(), unknown()).nullish(),
80229
80264
  contentChanges: array$3(zTextDocumentContentChangeEvent),
80230
80265
  sessionId: zSessionId,
80231
80266
  uri: string$2(),
80232
80267
  version: number$3()
80233
80268
  });
80234
- looseObject({
80269
+ object({
80235
80270
  method: string$2(),
80236
80271
  params: union$3([
80237
80272
  zCancelNotification,
@@ -80249,11 +80284,11 @@ Task description:
80249
80284
  literal("full"),
80250
80285
  literal("incremental")
80251
80286
  ]);
80252
- const zNesDocumentDidChangeCapabilities = looseObject({
80287
+ const zNesDocumentDidChangeCapabilities = object({
80253
80288
  _meta: record(string$2(), unknown()).nullish(),
80254
80289
  syncKind: zTextDocumentSyncKind
80255
80290
  });
80256
- const zNesDocumentEventCapabilities = looseObject({
80291
+ const zNesDocumentEventCapabilities = object({
80257
80292
  _meta: record(string$2(), unknown()).nullish(),
80258
80293
  didChange: zNesDocumentDidChangeCapabilities.nullish(),
80259
80294
  didClose: zNesDocumentDidCloseCapabilities.nullish(),
@@ -80261,16 +80296,16 @@ Task description:
80261
80296
  didOpen: zNesDocumentDidOpenCapabilities.nullish(),
80262
80297
  didSave: zNesDocumentDidSaveCapabilities.nullish()
80263
80298
  });
80264
- const zNesEventCapabilities = looseObject({
80299
+ const zNesEventCapabilities = object({
80265
80300
  _meta: record(string$2(), unknown()).nullish(),
80266
80301
  document: zNesDocumentEventCapabilities.nullish()
80267
80302
  });
80268
- const zNesCapabilities = looseObject({
80303
+ const zNesCapabilities = object({
80269
80304
  _meta: record(string$2(), unknown()).nullish(),
80270
80305
  context: zNesContextCapabilities.nullish(),
80271
80306
  events: zNesEventCapabilities.nullish()
80272
80307
  });
80273
- const zAgentCapabilities = looseObject({
80308
+ const zAgentCapabilities = object({
80274
80309
  _meta: record(string$2(), unknown()).nullish(),
80275
80310
  auth: zAgentAuthCapabilities.optional().default({}),
80276
80311
  loadSession: boolean().optional().default(false),
@@ -80285,9 +80320,10 @@ Task description:
80285
80320
  embeddedContext: false,
80286
80321
  image: false
80287
80322
  }),
80323
+ providers: zProvidersCapabilities.nullish(),
80288
80324
  sessionCapabilities: zSessionCapabilities.optional().default({})
80289
80325
  });
80290
- const zInitializeResponse = looseObject({
80326
+ const zInitializeResponse = object({
80291
80327
  _meta: record(string$2(), unknown()).nullish(),
80292
80328
  agentCapabilities: zAgentCapabilities.optional().default({
80293
80329
  auth: {},
@@ -80307,7 +80343,7 @@ Task description:
80307
80343
  authMethods: array$3(zAuthMethod).optional().default([]),
80308
80344
  protocolVersion: zProtocolVersion
80309
80345
  });
80310
- const zTextResourceContents = looseObject({
80346
+ const zTextResourceContents = object({
80311
80347
  _meta: record(string$2(), unknown()).nullish(),
80312
80348
  mimeType: string$2().nullish(),
80313
80349
  text: string$2(),
@@ -80317,59 +80353,70 @@ Task description:
80317
80353
  zTextResourceContents,
80318
80354
  zBlobResourceContents
80319
80355
  ]);
80320
- const zEmbeddedResource = looseObject({
80356
+ const zEmbeddedResource = object({
80321
80357
  _meta: record(string$2(), unknown()).nullish(),
80322
80358
  annotations: zAnnotations.nullish(),
80323
80359
  resource: zEmbeddedResourceResource
80324
80360
  });
80325
80361
  const zContentBlock = union$3([
80326
- zTextContent.and(looseObject({
80362
+ zTextContent.and(object({
80327
80363
  type: literal("text")
80328
80364
  })),
80329
- zImageContent.and(looseObject({
80365
+ zImageContent.and(object({
80330
80366
  type: literal("image")
80331
80367
  })),
80332
- zAudioContent.and(looseObject({
80368
+ zAudioContent.and(object({
80333
80369
  type: literal("audio")
80334
80370
  })),
80335
- zResourceLink.and(looseObject({
80371
+ zResourceLink.and(object({
80336
80372
  type: literal("resource_link")
80337
80373
  })),
80338
- zEmbeddedResource.and(looseObject({
80374
+ zEmbeddedResource.and(object({
80339
80375
  type: literal("resource")
80340
80376
  }))
80341
80377
  ]);
80342
- const zContent = looseObject({
80378
+ const zContent = object({
80343
80379
  _meta: record(string$2(), unknown()).nullish(),
80344
80380
  content: zContentBlock
80345
80381
  });
80346
- const zContentChunk = looseObject({
80382
+ const zContentChunk = object({
80347
80383
  _meta: record(string$2(), unknown()).nullish(),
80348
80384
  content: zContentBlock,
80349
80385
  messageId: string$2().nullish()
80350
80386
  });
80351
- const zPromptRequest = looseObject({
80387
+ const zPromptRequest = object({
80352
80388
  _meta: record(string$2(), unknown()).nullish(),
80353
80389
  messageId: string$2().nullish(),
80354
80390
  prompt: array$3(zContentBlock),
80355
80391
  sessionId: zSessionId
80356
80392
  });
80357
- const zTitledMultiSelectItems = looseObject({
80393
+ const zTitledMultiSelectItems = object({
80358
80394
  anyOf: array$3(zEnumOption)
80359
80395
  });
80360
80396
  const zToolCallContent = union$3([
80361
- zContent.and(looseObject({
80397
+ zContent.and(object({
80362
80398
  type: literal("content")
80363
80399
  })),
80364
- zDiff.and(looseObject({
80400
+ zDiff.and(object({
80365
80401
  type: literal("diff")
80366
80402
  })),
80367
- zTerminal.and(looseObject({
80403
+ zTerminal.and(object({
80368
80404
  type: literal("terminal")
80369
80405
  }))
80370
80406
  ]);
80371
80407
  const zToolCallId = string$2();
80372
- const zToolCallLocation = looseObject({
80408
+ const zElicitationSessionScope = object({
80409
+ sessionId: zSessionId,
80410
+ toolCallId: zToolCallId.nullish()
80411
+ });
80412
+ const zElicitationUrlMode = intersection(union$3([
80413
+ zElicitationSessionScope,
80414
+ zElicitationRequestScope
80415
+ ]), object({
80416
+ elicitationId: zElicitationId,
80417
+ url: string$2().url()
80418
+ }));
80419
+ const zToolCallLocation = object({
80373
80420
  _meta: record(string$2(), unknown()).nullish(),
80374
80421
  line: number$3().int().gte(0).max(4294967295, {
80375
80422
  message: "Invalid value: Expected uint32 to be <= 4294967295"
@@ -80394,7 +80441,7 @@ Task description:
80394
80441
  literal("switch_mode"),
80395
80442
  literal("other")
80396
80443
  ]);
80397
- const zToolCall = looseObject({
80444
+ const zToolCall = object({
80398
80445
  _meta: record(string$2(), unknown()).nullish(),
80399
80446
  content: array$3(zToolCallContent).optional(),
80400
80447
  kind: zToolKind.optional(),
@@ -80405,7 +80452,7 @@ Task description:
80405
80452
  title: string$2(),
80406
80453
  toolCallId: zToolCallId
80407
80454
  });
80408
- const zToolCallUpdate = looseObject({
80455
+ const zToolCallUpdate = object({
80409
80456
  _meta: record(string$2(), unknown()).nullish(),
80410
80457
  content: array$3(zToolCallContent).nullish(),
80411
80458
  kind: zToolKind.nullish(),
@@ -80416,28 +80463,28 @@ Task description:
80416
80463
  title: string$2().nullish(),
80417
80464
  toolCallId: zToolCallId
80418
80465
  });
80419
- const zRequestPermissionRequest = looseObject({
80466
+ const zRequestPermissionRequest = object({
80420
80467
  _meta: record(string$2(), unknown()).nullish(),
80421
80468
  options: array$3(zPermissionOption),
80422
80469
  sessionId: zSessionId,
80423
80470
  toolCall: zToolCallUpdate
80424
80471
  });
80425
- const zUnstructuredCommandInput = looseObject({
80472
+ const zUnstructuredCommandInput = object({
80426
80473
  _meta: record(string$2(), unknown()).nullish(),
80427
80474
  hint: string$2()
80428
80475
  });
80429
80476
  const zAvailableCommandInput = zUnstructuredCommandInput;
80430
- const zAvailableCommand = looseObject({
80477
+ const zAvailableCommand = object({
80431
80478
  _meta: record(string$2(), unknown()).nullish(),
80432
80479
  description: string$2(),
80433
80480
  input: zAvailableCommandInput.nullish(),
80434
80481
  name: string$2()
80435
80482
  });
80436
- const zAvailableCommandsUpdate = looseObject({
80483
+ const zAvailableCommandsUpdate = object({
80437
80484
  _meta: record(string$2(), unknown()).nullish(),
80438
80485
  availableCommands: array$3(zAvailableCommand)
80439
80486
  });
80440
- const zUntitledMultiSelectItems = looseObject({
80487
+ const zUntitledMultiSelectItems = object({
80441
80488
  enum: array$3(string$2()),
80442
80489
  type: zElicitationStringType
80443
80490
  });
@@ -80445,7 +80492,7 @@ Task description:
80445
80492
  zUntitledMultiSelectItems,
80446
80493
  zTitledMultiSelectItems
80447
80494
  ]);
80448
- const zMultiSelectPropertySchema = looseObject({
80495
+ const zMultiSelectPropertySchema = object({
80449
80496
  default: array$3(string$2()).nullish(),
80450
80497
  description: string$2().nullish(),
80451
80498
  items: zMultiSelectItems,
@@ -80454,45 +80501,47 @@ Task description:
80454
80501
  title: string$2().nullish()
80455
80502
  });
80456
80503
  const zElicitationPropertySchema = union$3([
80457
- zStringPropertySchema.and(looseObject({
80504
+ zStringPropertySchema.and(object({
80458
80505
  type: literal("string")
80459
80506
  })),
80460
- zNumberPropertySchema.and(looseObject({
80507
+ zNumberPropertySchema.and(object({
80461
80508
  type: literal("number")
80462
80509
  })),
80463
- zIntegerPropertySchema.and(looseObject({
80510
+ zIntegerPropertySchema.and(object({
80464
80511
  type: literal("integer")
80465
80512
  })),
80466
- zBooleanPropertySchema.and(looseObject({
80513
+ zBooleanPropertySchema.and(object({
80467
80514
  type: literal("boolean")
80468
80515
  })),
80469
- zMultiSelectPropertySchema.and(looseObject({
80516
+ zMultiSelectPropertySchema.and(object({
80470
80517
  type: literal("array")
80471
80518
  }))
80472
80519
  ]);
80473
- const zElicitationSchema = looseObject({
80520
+ const zElicitationSchema = object({
80474
80521
  description: string$2().nullish(),
80475
80522
  properties: record(string$2(), zElicitationPropertySchema).optional().default({}),
80476
80523
  required: array$3(string$2()).nullish(),
80477
80524
  title: string$2().nullish(),
80478
80525
  type: zElicitationSchemaType.optional().default("object")
80479
80526
  });
80480
- const zElicitationFormMode = looseObject({
80527
+ const zElicitationFormMode = intersection(union$3([
80528
+ zElicitationSessionScope,
80529
+ zElicitationRequestScope
80530
+ ]), object({
80481
80531
  requestedSchema: zElicitationSchema
80482
- });
80483
- const zElicitationRequest = intersection(union$3([
80484
- zElicitationFormMode.and(looseObject({
80532
+ }));
80533
+ const zCreateElicitationRequest = intersection(union$3([
80534
+ zElicitationFormMode.and(object({
80485
80535
  mode: literal("form")
80486
80536
  })),
80487
- zElicitationUrlMode.and(looseObject({
80537
+ zElicitationUrlMode.and(object({
80488
80538
  mode: literal("url")
80489
80539
  }))
80490
- ]), looseObject({
80540
+ ]), object({
80491
80541
  _meta: record(string$2(), unknown()).nullish(),
80492
- message: string$2(),
80493
- sessionId: zSessionId
80542
+ message: string$2()
80494
80543
  }));
80495
- const zUsage = looseObject({
80544
+ const zUsage = object({
80496
80545
  cachedReadTokens: number$3().nullish(),
80497
80546
  cachedWriteTokens: number$3().nullish(),
80498
80547
  inputTokens: number$3(),
@@ -80500,18 +80549,21 @@ Task description:
80500
80549
  thoughtTokens: number$3().nullish(),
80501
80550
  totalTokens: number$3()
80502
80551
  });
80503
- const zPromptResponse = looseObject({
80552
+ const zPromptResponse = object({
80504
80553
  _meta: record(string$2(), unknown()).nullish(),
80505
80554
  stopReason: zStopReason,
80506
80555
  usage: zUsage.nullish(),
80507
80556
  userMessageId: string$2().nullish()
80508
80557
  });
80509
80558
  union$3([
80510
- looseObject({
80559
+ object({
80511
80560
  id: zRequestId,
80512
80561
  result: union$3([
80513
80562
  zInitializeResponse,
80514
80563
  zAuthenticateResponse,
80564
+ zListProvidersResponse,
80565
+ zSetProvidersResponse,
80566
+ zDisableProvidersResponse,
80515
80567
  zLogoutResponse,
80516
80568
  zNewSessionResponse,
80517
80569
  zLoadSessionResponse,
@@ -80529,93 +80581,96 @@ Task description:
80529
80581
  zExtResponse
80530
80582
  ])
80531
80583
  }),
80532
- looseObject({
80584
+ object({
80533
80585
  error: zError,
80534
80586
  id: zRequestId
80535
80587
  })
80536
80588
  ]);
80537
- const zUsageUpdate = looseObject({
80589
+ const zUsageUpdate = object({
80538
80590
  _meta: record(string$2(), unknown()).nullish(),
80539
80591
  cost: zCost.nullish(),
80540
80592
  size: number$3(),
80541
80593
  used: number$3()
80542
80594
  });
80543
80595
  const zSessionUpdate = union$3([
80544
- zContentChunk.and(looseObject({
80596
+ zContentChunk.and(object({
80545
80597
  sessionUpdate: literal("user_message_chunk")
80546
80598
  })),
80547
- zContentChunk.and(looseObject({
80599
+ zContentChunk.and(object({
80548
80600
  sessionUpdate: literal("agent_message_chunk")
80549
80601
  })),
80550
- zContentChunk.and(looseObject({
80602
+ zContentChunk.and(object({
80551
80603
  sessionUpdate: literal("agent_thought_chunk")
80552
80604
  })),
80553
- zToolCall.and(looseObject({
80605
+ zToolCall.and(object({
80554
80606
  sessionUpdate: literal("tool_call")
80555
80607
  })),
80556
- zToolCallUpdate.and(looseObject({
80608
+ zToolCallUpdate.and(object({
80557
80609
  sessionUpdate: literal("tool_call_update")
80558
80610
  })),
80559
- zPlan.and(looseObject({
80611
+ zPlan.and(object({
80560
80612
  sessionUpdate: literal("plan")
80561
80613
  })),
80562
- zAvailableCommandsUpdate.and(looseObject({
80614
+ zAvailableCommandsUpdate.and(object({
80563
80615
  sessionUpdate: literal("available_commands_update")
80564
80616
  })),
80565
- zCurrentModeUpdate.and(looseObject({
80617
+ zCurrentModeUpdate.and(object({
80566
80618
  sessionUpdate: literal("current_mode_update")
80567
80619
  })),
80568
- zConfigOptionUpdate.and(looseObject({
80620
+ zConfigOptionUpdate.and(object({
80569
80621
  sessionUpdate: literal("config_option_update")
80570
80622
  })),
80571
- zSessionInfoUpdate.and(looseObject({
80623
+ zSessionInfoUpdate.and(object({
80572
80624
  sessionUpdate: literal("session_info_update")
80573
80625
  })),
80574
- zUsageUpdate.and(looseObject({
80626
+ zUsageUpdate.and(object({
80575
80627
  sessionUpdate: literal("usage_update")
80576
80628
  }))
80577
80629
  ]);
80578
- const zSessionNotification = looseObject({
80630
+ const zSessionNotification = object({
80579
80631
  _meta: record(string$2(), unknown()).nullish(),
80580
80632
  sessionId: zSessionId,
80581
80633
  update: zSessionUpdate
80582
80634
  });
80583
- looseObject({
80635
+ object({
80584
80636
  method: string$2(),
80585
80637
  params: union$3([
80586
80638
  zSessionNotification,
80587
- zElicitationCompleteNotification,
80639
+ zCompleteElicitationNotification,
80588
80640
  zExtNotification
80589
80641
  ]).nullish()
80590
80642
  });
80591
- const zWaitForTerminalExitRequest = looseObject({
80643
+ const zWaitForTerminalExitRequest = object({
80592
80644
  _meta: record(string$2(), unknown()).nullish(),
80593
80645
  sessionId: zSessionId,
80594
80646
  terminalId: string$2()
80595
80647
  });
80596
- const zWaitForTerminalExitResponse = looseObject({
80648
+ const zWaitForTerminalExitResponse = object({
80597
80649
  _meta: record(string$2(), unknown()).nullish(),
80598
80650
  exitCode: number$3().int().gte(0).max(4294967295, {
80599
80651
  message: "Invalid value: Expected uint32 to be <= 4294967295"
80600
80652
  }).nullish(),
80601
80653
  signal: string$2().nullish()
80602
80654
  });
80603
- const zWorkspaceFolder = looseObject({
80655
+ const zWorkspaceFolder = object({
80604
80656
  name: string$2(),
80605
80657
  uri: string$2()
80606
80658
  });
80607
- const zStartNesRequest = looseObject({
80659
+ const zStartNesRequest = object({
80608
80660
  _meta: record(string$2(), unknown()).nullish(),
80609
80661
  repository: zNesRepository.nullish(),
80610
80662
  workspaceFolders: array$3(zWorkspaceFolder).nullish(),
80611
80663
  workspaceUri: string$2().nullish()
80612
80664
  });
80613
- looseObject({
80665
+ object({
80614
80666
  id: zRequestId,
80615
80667
  method: string$2(),
80616
80668
  params: union$3([
80617
80669
  zInitializeRequest,
80618
80670
  zAuthenticateRequest,
80671
+ zListProvidersRequest,
80672
+ zSetProvidersRequest,
80673
+ zDisableProvidersRequest,
80619
80674
  zLogoutRequest,
80620
80675
  zNewSessionRequest,
80621
80676
  zLoadSessionRequest,
@@ -80633,13 +80688,13 @@ Task description:
80633
80688
  zExtRequest
80634
80689
  ]).nullish()
80635
80690
  });
80636
- const zWriteTextFileRequest = looseObject({
80691
+ const zWriteTextFileRequest = object({
80637
80692
  _meta: record(string$2(), unknown()).nullish(),
80638
80693
  content: string$2(),
80639
80694
  path: string$2(),
80640
80695
  sessionId: zSessionId
80641
80696
  });
80642
- looseObject({
80697
+ object({
80643
80698
  id: zRequestId,
80644
80699
  method: string$2(),
80645
80700
  params: union$3([
@@ -80651,15 +80706,15 @@ Task description:
80651
80706
  zReleaseTerminalRequest,
80652
80707
  zWaitForTerminalExitRequest,
80653
80708
  zKillTerminalRequest,
80654
- zElicitationRequest,
80709
+ zCreateElicitationRequest,
80655
80710
  zExtRequest
80656
80711
  ]).nullish()
80657
80712
  });
80658
- const zWriteTextFileResponse = looseObject({
80713
+ const zWriteTextFileResponse = object({
80659
80714
  _meta: record(string$2(), unknown()).nullish()
80660
80715
  });
80661
80716
  union$3([
80662
- looseObject({
80717
+ object({
80663
80718
  id: zRequestId,
80664
80719
  result: union$3([
80665
80720
  zWriteTextFileResponse,
@@ -80670,11 +80725,11 @@ Task description:
80670
80725
  zReleaseTerminalResponse,
80671
80726
  zWaitForTerminalExitResponse,
80672
80727
  zKillTerminalResponse,
80673
- zElicitationResponse,
80728
+ zCreateElicitationResponse,
80674
80729
  zExtResponse
80675
80730
  ])
80676
80731
  }),
80677
- looseObject({
80732
+ object({
80678
80733
  error: zError,
80679
80734
  id: zRequestId
80680
80735
  })
@@ -116836,6 +116891,8 @@ ${this.stack.split("\n").slice(1).join("\n")}` : this.toString();
116836
116891
  session_set_model: "session/set_model"
116837
116892
  };
116838
116893
  const CLIENT_METHODS = {
116894
+ elicitation_complete: "elicitation/complete",
116895
+ elicitation_create: "elicitation/create",
116839
116896
  fs_read_text_file: "fs/read_text_file",
116840
116897
  fs_write_text_file: "fs/write_text_file",
116841
116898
  session_request_permission: "session/request_permission",
@@ -116858,6 +116915,7 @@ ${this.stack.split("\n").slice(1).join("\n")}` : this.toString();
116858
116915
  while (true) {
116859
116916
  const { value, done: done2 } = await reader2.read();
116860
116917
  if (done2) {
116918
+ content += textDecoder2.decode();
116861
116919
  break;
116862
116920
  }
116863
116921
  if (!value) {
@@ -116869,17 +116927,26 @@ ${this.stack.split("\n").slice(1).join("\n")}` : this.toString();
116869
116927
  const lines2 = content.split("\n");
116870
116928
  content = lines2.pop() || "";
116871
116929
  for (const line3 of lines2) {
116872
- const trimmedLine = line3.trim();
116873
- if (trimmedLine) {
116930
+ const trimmedLine2 = line3.trim();
116931
+ if (trimmedLine2) {
116874
116932
  try {
116875
- const message = JSON.parse(trimmedLine);
116933
+ const message = JSON.parse(trimmedLine2);
116876
116934
  controller.enqueue(message);
116877
116935
  } catch (err2) {
116878
- console.error("Failed to parse JSON message:", trimmedLine, err2);
116936
+ console.error("Failed to parse JSON message:", trimmedLine2, err2);
116879
116937
  }
116880
116938
  }
116881
116939
  }
116882
116940
  }
116941
+ const trimmedLine = content.trim();
116942
+ if (trimmedLine) {
116943
+ try {
116944
+ const message = JSON.parse(trimmedLine);
116945
+ controller.enqueue(message);
116946
+ } catch (err2) {
116947
+ console.error("Failed to parse JSON message:", trimmedLine, err2);
116948
+ }
116949
+ }
116883
116950
  } catch (err2) {
116884
116951
  controller.error(err2);
116885
116952
  return;
@@ -116906,7 +116973,7 @@ ${this.stack.split("\n").slice(1).join("\n")}` : this.toString();
116906
116973
  };
116907
116974
  }
116908
116975
  class ClientSideConnection {
116909
- #connection;
116976
+ connection;
116910
116977
  constructor(toClient, stream2) {
116911
116978
  const client = toClient(this);
116912
116979
  const requestHandler = async (method, params) => {
@@ -116945,6 +117012,13 @@ ${this.stack.split("\n").slice(1).join("\n")}` : this.toString();
116945
117012
  const result = await client.killTerminal?.(validatedParams);
116946
117013
  return result ?? {};
116947
117014
  }
117015
+ case CLIENT_METHODS.elicitation_create: {
117016
+ if (!client.unstable_createElicitation) {
117017
+ throw RequestError.methodNotFound(method);
117018
+ }
117019
+ const validatedParams = zCreateElicitationRequest.parse(params);
117020
+ return client.unstable_createElicitation(validatedParams);
117021
+ }
116948
117022
  default:
116949
117023
  if (client.extMethod) {
116950
117024
  return client.extMethod(method, params);
@@ -116958,6 +117032,11 @@ ${this.stack.split("\n").slice(1).join("\n")}` : this.toString();
116958
117032
  const validatedParams = zSessionNotification.parse(params);
116959
117033
  return client.sessionUpdate(validatedParams);
116960
117034
  }
117035
+ case CLIENT_METHODS.elicitation_complete: {
117036
+ if (!client.unstable_completeElicitation) return;
117037
+ const validatedParams = zCompleteElicitationNotification.parse(params);
117038
+ return client.unstable_completeElicitation(validatedParams);
117039
+ }
116961
117040
  default:
116962
117041
  if (client.extNotification) {
116963
117042
  return client.extNotification(method, params);
@@ -116965,123 +117044,123 @@ ${this.stack.split("\n").slice(1).join("\n")}` : this.toString();
116965
117044
  throw RequestError.methodNotFound(method);
116966
117045
  }
116967
117046
  };
116968
- this.#connection = new Connection(requestHandler, notificationHandler, stream2);
117047
+ this.connection = new Connection(requestHandler, notificationHandler, stream2);
116969
117048
  }
116970
117049
  async initialize(params) {
116971
- return await this.#connection.sendRequest(AGENT_METHODS.initialize, params);
117050
+ return await this.connection.sendRequest(AGENT_METHODS.initialize, params);
116972
117051
  }
116973
117052
  async newSession(params) {
116974
- return await this.#connection.sendRequest(AGENT_METHODS.session_new, params);
117053
+ return await this.connection.sendRequest(AGENT_METHODS.session_new, params);
116975
117054
  }
116976
117055
  async loadSession(params) {
116977
- return await this.#connection.sendRequest(AGENT_METHODS.session_load, params) ?? {};
117056
+ return await this.connection.sendRequest(AGENT_METHODS.session_load, params) ?? {};
116978
117057
  }
116979
117058
  async unstable_forkSession(params) {
116980
- return await this.#connection.sendRequest(AGENT_METHODS.session_fork, params);
117059
+ return await this.connection.sendRequest(AGENT_METHODS.session_fork, params);
116981
117060
  }
116982
117061
  async listSessions(params) {
116983
- return await this.#connection.sendRequest(AGENT_METHODS.session_list, params);
117062
+ return await this.connection.sendRequest(AGENT_METHODS.session_list, params);
116984
117063
  }
116985
- async unstable_resumeSession(params) {
116986
- return await this.#connection.sendRequest(AGENT_METHODS.session_resume, params);
117064
+ async resumeSession(params) {
117065
+ return await this.connection.sendRequest(AGENT_METHODS.session_resume, params);
116987
117066
  }
116988
- async unstable_closeSession(params) {
116989
- return await this.#connection.sendRequest(AGENT_METHODS.session_close, params);
117067
+ async closeSession(params) {
117068
+ return await this.connection.sendRequest(AGENT_METHODS.session_close, params);
116990
117069
  }
116991
117070
  async setSessionMode(params) {
116992
- return await this.#connection.sendRequest(AGENT_METHODS.session_set_mode, params) ?? {};
117071
+ return await this.connection.sendRequest(AGENT_METHODS.session_set_mode, params) ?? {};
116993
117072
  }
116994
117073
  async unstable_setSessionModel(params) {
116995
- return await this.#connection.sendRequest(AGENT_METHODS.session_set_model, params) ?? {};
117074
+ return await this.connection.sendRequest(AGENT_METHODS.session_set_model, params) ?? {};
116996
117075
  }
116997
117076
  async setSessionConfigOption(params) {
116998
- return await this.#connection.sendRequest(AGENT_METHODS.session_set_config_option, params);
117077
+ return await this.connection.sendRequest(AGENT_METHODS.session_set_config_option, params);
116999
117078
  }
117000
117079
  async authenticate(params) {
117001
- return await this.#connection.sendRequest(AGENT_METHODS.authenticate, params) ?? {};
117080
+ return await this.connection.sendRequest(AGENT_METHODS.authenticate, params) ?? {};
117002
117081
  }
117003
117082
  async unstable_logout(params) {
117004
- return await this.#connection.sendRequest(AGENT_METHODS.logout, params) ?? {};
117083
+ return await this.connection.sendRequest(AGENT_METHODS.logout, params) ?? {};
117005
117084
  }
117006
117085
  async prompt(params) {
117007
- return await this.#connection.sendRequest(AGENT_METHODS.session_prompt, params);
117086
+ return await this.connection.sendRequest(AGENT_METHODS.session_prompt, params);
117008
117087
  }
117009
117088
  async cancel(params) {
117010
- return await this.#connection.sendNotification(AGENT_METHODS.session_cancel, params);
117089
+ return await this.connection.sendNotification(AGENT_METHODS.session_cancel, params);
117011
117090
  }
117012
117091
  async unstable_startNes(params) {
117013
- return await this.#connection.sendRequest(AGENT_METHODS.nes_start, params);
117092
+ return await this.connection.sendRequest(AGENT_METHODS.nes_start, params);
117014
117093
  }
117015
117094
  async unstable_suggestNes(params) {
117016
- return await this.#connection.sendRequest(AGENT_METHODS.nes_suggest, params);
117095
+ return await this.connection.sendRequest(AGENT_METHODS.nes_suggest, params);
117017
117096
  }
117018
117097
  async unstable_closeNes(params) {
117019
- return await this.#connection.sendRequest(AGENT_METHODS.nes_close, params) ?? {};
117098
+ return await this.connection.sendRequest(AGENT_METHODS.nes_close, params) ?? {};
117020
117099
  }
117021
117100
  async unstable_didOpenDocument(params) {
117022
- return await this.#connection.sendNotification(AGENT_METHODS.document_did_open, params);
117101
+ return await this.connection.sendNotification(AGENT_METHODS.document_did_open, params);
117023
117102
  }
117024
117103
  async unstable_didChangeDocument(params) {
117025
- return await this.#connection.sendNotification(AGENT_METHODS.document_did_change, params);
117104
+ return await this.connection.sendNotification(AGENT_METHODS.document_did_change, params);
117026
117105
  }
117027
117106
  async unstable_didCloseDocument(params) {
117028
- return await this.#connection.sendNotification(AGENT_METHODS.document_did_close, params);
117107
+ return await this.connection.sendNotification(AGENT_METHODS.document_did_close, params);
117029
117108
  }
117030
117109
  async unstable_didSaveDocument(params) {
117031
- return await this.#connection.sendNotification(AGENT_METHODS.document_did_save, params);
117110
+ return await this.connection.sendNotification(AGENT_METHODS.document_did_save, params);
117032
117111
  }
117033
117112
  async unstable_didFocusDocument(params) {
117034
- return await this.#connection.sendNotification(AGENT_METHODS.document_did_focus, params);
117113
+ return await this.connection.sendNotification(AGENT_METHODS.document_did_focus, params);
117035
117114
  }
117036
117115
  async unstable_acceptNes(params) {
117037
- return await this.#connection.sendNotification(AGENT_METHODS.nes_accept, params);
117116
+ return await this.connection.sendNotification(AGENT_METHODS.nes_accept, params);
117038
117117
  }
117039
117118
  async unstable_rejectNes(params) {
117040
- return await this.#connection.sendNotification(AGENT_METHODS.nes_reject, params);
117119
+ return await this.connection.sendNotification(AGENT_METHODS.nes_reject, params);
117041
117120
  }
117042
117121
  async extMethod(method, params) {
117043
- return await this.#connection.sendRequest(method, params);
117122
+ return await this.connection.sendRequest(method, params);
117044
117123
  }
117045
117124
  async extNotification(method, params) {
117046
- return await this.#connection.sendNotification(method, params);
117125
+ return await this.connection.sendNotification(method, params);
117047
117126
  }
117048
117127
  get signal() {
117049
- return this.#connection.signal;
117128
+ return this.connection.signal;
117050
117129
  }
117051
117130
  get closed() {
117052
- return this.#connection.closed;
117131
+ return this.connection.closed;
117053
117132
  }
117054
117133
  }
117055
117134
  class Connection {
117056
- #pendingResponses = /* @__PURE__ */ new Map();
117057
- #nextRequestId = 0;
117058
- #requestHandler;
117059
- #notificationHandler;
117060
- #stream;
117061
- #writeQueue = Promise.resolve();
117062
- #abortController = new AbortController();
117063
- #closedPromise;
117135
+ pendingResponses = /* @__PURE__ */ new Map();
117136
+ nextRequestId = 0;
117137
+ requestHandler;
117138
+ notificationHandler;
117139
+ stream;
117140
+ writeQueue = Promise.resolve();
117141
+ abortController = new AbortController();
117142
+ closedPromise;
117064
117143
  constructor(requestHandler, notificationHandler, stream2) {
117065
- this.#requestHandler = requestHandler;
117066
- this.#notificationHandler = notificationHandler;
117067
- this.#stream = stream2;
117068
- this.#closedPromise = new Promise((resolve2) => {
117069
- this.#abortController.signal.addEventListener("abort", () => resolve2());
117144
+ this.requestHandler = requestHandler;
117145
+ this.notificationHandler = notificationHandler;
117146
+ this.stream = stream2;
117147
+ this.closedPromise = new Promise((resolve2) => {
117148
+ this.abortController.signal.addEventListener("abort", () => resolve2());
117070
117149
  });
117071
- void this.#receive();
117150
+ void this.receive();
117072
117151
  }
117073
117152
  get signal() {
117074
- return this.#abortController.signal;
117153
+ return this.abortController.signal;
117075
117154
  }
117076
117155
  get closed() {
117077
- return this.#closedPromise;
117156
+ return this.closedPromise;
117078
117157
  }
117079
- async #receive() {
117158
+ async receive() {
117080
117159
  let closeError = void 0;
117081
117160
  try {
117082
- const reader2 = this.#stream.readable.getReader();
117161
+ const reader2 = this.stream.readable.getReader();
117083
117162
  try {
117084
- while (!this.#abortController.signal.aborted) {
117163
+ while (!this.abortController.signal.aborted) {
117085
117164
  const { value: message, done: done2 } = await reader2.read();
117086
117165
  if (done2) {
117087
117166
  break;
@@ -117090,11 +117169,11 @@ ${this.stack.split("\n").slice(1).join("\n")}` : this.toString();
117090
117169
  continue;
117091
117170
  }
117092
117171
  try {
117093
- this.#processMessage(message);
117172
+ this.processMessage(message);
117094
117173
  } catch (err2) {
117095
117174
  console.error("Unexpected error during message processing:", message, err2);
117096
117175
  if ("id" in message && message.id !== void 0) {
117097
- this.#sendMessage({
117176
+ this.sendMessage({
117098
117177
  jsonrpc: "2.0",
117099
117178
  id: message.id,
117100
117179
  error: {
@@ -117111,47 +117190,47 @@ ${this.stack.split("\n").slice(1).join("\n")}` : this.toString();
117111
117190
  } catch (error2) {
117112
117191
  closeError = error2;
117113
117192
  } finally {
117114
- this.#close(closeError);
117193
+ this.close(closeError);
117115
117194
  }
117116
117195
  }
117117
- #close(error2) {
117118
- if (this.#abortController.signal.aborted) {
117196
+ close(error2) {
117197
+ if (this.abortController.signal.aborted) {
117119
117198
  return;
117120
117199
  }
117121
117200
  const closeError = error2 ?? new Error("ACP connection closed");
117122
- for (const pendingResponse of this.#pendingResponses.values()) {
117201
+ for (const pendingResponse of this.pendingResponses.values()) {
117123
117202
  pendingResponse.reject(closeError);
117124
117203
  }
117125
- this.#pendingResponses.clear();
117126
- this.#abortController.abort(closeError);
117204
+ this.pendingResponses.clear();
117205
+ this.abortController.abort(closeError);
117127
117206
  }
117128
- async #processMessage(message) {
117207
+ async processMessage(message) {
117129
117208
  if ("method" in message && "id" in message) {
117130
- const response = await this.#tryCallRequestHandler(message.method, message.params);
117209
+ const response = await this.tryCallRequestHandler(message.method, message.params);
117131
117210
  if ("error" in response) {
117132
117211
  console.error("Error handling request", message, response.error);
117133
117212
  }
117134
- await this.#sendMessage({
117213
+ await this.sendMessage({
117135
117214
  jsonrpc: "2.0",
117136
117215
  id: message.id,
117137
117216
  ...response
117138
117217
  });
117139
117218
  } else if ("method" in message) {
117140
- const response = await this.#tryCallNotificationHandler(message.method, message.params);
117219
+ const response = await this.tryCallNotificationHandler(message.method, message.params);
117141
117220
  if ("error" in response) {
117142
117221
  console.error("Error handling notification", message, response.error);
117143
117222
  }
117144
117223
  } else if ("id" in message) {
117145
- this.#handleResponse(message);
117224
+ this.handleResponse(message);
117146
117225
  } else {
117147
117226
  console.error("Invalid message", {
117148
117227
  message
117149
117228
  });
117150
117229
  }
117151
117230
  }
117152
- async #tryCallRequestHandler(method, params) {
117231
+ async tryCallRequestHandler(method, params) {
117153
117232
  try {
117154
- const result = await this.#requestHandler(method, params);
117233
+ const result = await this.requestHandler(method, params);
117155
117234
  return {
117156
117235
  result: result ?? null
117157
117236
  };
@@ -117177,9 +117256,9 @@ ${this.stack.split("\n").slice(1).join("\n")}` : this.toString();
117177
117256
  }
117178
117257
  }
117179
117258
  }
117180
- async #tryCallNotificationHandler(method, params) {
117259
+ async tryCallNotificationHandler(method, params) {
117181
117260
  try {
117182
- await this.#notificationHandler(method, params);
117261
+ await this.notificationHandler(method, params);
117183
117262
  return {
117184
117263
  result: null
117185
117264
  };
@@ -117205,8 +117284,8 @@ ${this.stack.split("\n").slice(1).join("\n")}` : this.toString();
117205
117284
  }
117206
117285
  }
117207
117286
  }
117208
- #handleResponse(response) {
117209
- const pendingResponse = this.#pendingResponses.get(response.id);
117287
+ handleResponse(response) {
117288
+ const pendingResponse = this.pendingResponses.get(response.id);
117210
117289
  if (pendingResponse) {
117211
117290
  if ("result" in response) {
117212
117291
  pendingResponse.resolve(response.result);
@@ -117214,21 +117293,23 @@ ${this.stack.split("\n").slice(1).join("\n")}` : this.toString();
117214
117293
  const { code: code2, message, data } = response.error;
117215
117294
  pendingResponse.reject(new RequestError(code2, message, data));
117216
117295
  }
117217
- this.#pendingResponses.delete(response.id);
117296
+ this.pendingResponses.delete(response.id);
117218
117297
  } else {
117219
117298
  console.error("Got response to unknown request", response.id);
117220
117299
  }
117221
117300
  }
117222
- async sendRequest(method, params) {
117223
- this.#throwIfClosed();
117224
- const id = this.#nextRequestId++;
117301
+ sendRequest(method, params) {
117302
+ this.throwIfClosed();
117303
+ const id = this.nextRequestId++;
117225
117304
  const responsePromise = new Promise((resolve2, reject) => {
117226
- this.#pendingResponses.set(id, {
117305
+ this.pendingResponses.set(id, {
117227
117306
  resolve: resolve2,
117228
117307
  reject
117229
117308
  });
117230
117309
  });
117231
- await this.#sendMessage({
117310
+ responsePromise.catch(() => {
117311
+ });
117312
+ void this.sendMessage({
117232
117313
  jsonrpc: "2.0",
117233
117314
  id,
117234
117315
  method,
@@ -117237,30 +117318,30 @@ ${this.stack.split("\n").slice(1).join("\n")}` : this.toString();
117237
117318
  return responsePromise;
117238
117319
  }
117239
117320
  async sendNotification(method, params) {
117240
- this.#throwIfClosed();
117241
- await this.#sendMessage({
117321
+ this.throwIfClosed();
117322
+ await this.sendMessage({
117242
117323
  jsonrpc: "2.0",
117243
117324
  method,
117244
117325
  params
117245
117326
  });
117246
117327
  }
117247
- #throwIfClosed() {
117248
- if (this.#abortController.signal.aborted) {
117249
- throw this.#abortController.signal.reason ?? new Error("ACP connection closed");
117328
+ throwIfClosed() {
117329
+ if (this.abortController.signal.aborted) {
117330
+ throw this.abortController.signal.reason ?? new Error("ACP connection closed");
117250
117331
  }
117251
117332
  }
117252
- async #sendMessage(message) {
117253
- this.#writeQueue = this.#writeQueue.then(async () => {
117254
- const writer = this.#stream.writable.getWriter();
117333
+ async sendMessage(message) {
117334
+ this.writeQueue = this.writeQueue.then(async () => {
117335
+ const writer = this.stream.writable.getWriter();
117255
117336
  try {
117256
117337
  await writer.write(message);
117257
117338
  } finally {
117258
117339
  writer.releaseLock();
117259
117340
  }
117260
117341
  }).catch((error2) => {
117261
- this.#close(error2);
117342
+ this.close(error2);
117262
117343
  });
117263
- return this.#writeQueue;
117344
+ return this.writeQueue;
117264
117345
  }
117265
117346
  }
117266
117347
  class RequestError extends Error {
@@ -117532,6 +117613,13 @@ ${this.stack.split("\n").slice(1).join("\n")}` : this.toString();
117532
117613
  return {};
117533
117614
  }
117534
117615
  async extMethod(method, params) {
117616
+ this.handleExtensionMessage(method, params);
117617
+ return {};
117618
+ }
117619
+ async extNotification(method, params) {
117620
+ this.handleExtensionMessage(method, params);
117621
+ }
117622
+ handleExtensionMessage(method, params) {
117535
117623
  const resolvedMethod = method.startsWith("_") ? method.slice(1) : method;
117536
117624
  switch (resolvedMethod) {
117537
117625
  case "acp_ext:session_usage_update": {
@@ -117552,10 +117640,6 @@ ${this.stack.split("\n").slice(1).join("\n")}` : this.toString();
117552
117640
  break;
117553
117641
  }
117554
117642
  }
117555
- return {};
117556
- }
117557
- async extNotification(_method, _params) {
117558
- throw new Error("Method not implemented.");
117559
117643
  }
117560
117644
  async startSession(stream2, workdir, resumeSessionId, timeoutOptions = {}, startupAbort) {
117561
117645
  const connection = new ClientSideConnection(() => this, stream2);
@@ -117588,10 +117672,10 @@ ${this.stack.split("\n").slice(1).join("\n")}` : this.toString();
117588
117672
  const hasLoadSessionMethod = typeof connection.loadSession === "function";
117589
117673
  const resumeCapability = initResponse.agentCapabilities?.sessionCapabilities?.resume;
117590
117674
  this.supportsResume = !!resumeCapability;
117591
- const hasResumeMethod = typeof connection.unstable_resumeSession === "function";
117675
+ const hasResumeMethod = typeof connection.resumeSession === "function";
117592
117676
  const closeCapability = initResponse.agentCapabilities?.sessionCapabilities?.close;
117593
117677
  this.supportsClose = !!closeCapability;
117594
- const hasCloseMethod = typeof connection.unstable_closeSession === "function";
117678
+ const hasCloseMethod = typeof connection.closeSession === "function";
117595
117679
  this.logger.debug(`[${this.options.sessionId}] ACP capabilities (loadSession=${this.supportsLoadSession ? "yes" : "no"} loadSessionMethod=${hasLoadSessionMethod ? "yes" : "no"} resume=${this.supportsResume ? "yes" : "no"} resumeMethod=${hasResumeMethod ? "yes" : "no"} close=${this.supportsClose ? "yes" : "no"} closeMethod=${hasCloseMethod ? "yes" : "no"})`);
117596
117680
  this.logger.debug(`[${this.options.sessionId}] About to start new ACP session`);
117597
117681
  const newSessionStart = performance$1.now();
@@ -117608,7 +117692,7 @@ ${this.stack.split("\n").slice(1).join("\n")}` : this.toString();
117608
117692
  reasons.push("agent_did_not_advertise_resume_or_loadSession");
117609
117693
  }
117610
117694
  if (!hasLoadSessionMethod && !hasResumeMethod) {
117611
- reasons.push("sdk_missing_loadSession_and_unstable_resumeSession");
117695
+ reasons.push("sdk_missing_loadSession_and_resumeSession");
117612
117696
  }
117613
117697
  const reason = reasons.join(", ");
117614
117698
  this.logger.error(`[${this.options.sessionId}] ACP resume unsupported (${reason}): ${resumeSessionId}`);
@@ -117644,7 +117728,7 @@ ${this.stack.split("\n").slice(1).join("\n")}` : this.toString();
117644
117728
  const resumeStart = performance$1.now();
117645
117729
  try {
117646
117730
  this.logger.debug(`[${this.options.sessionId}] Attempting ACP resume (acpSessionId=${resumeSessionId})`);
117647
- const resumeResponse = await withAbort(connection.unstable_resumeSession({
117731
+ const resumeResponse = await withAbort(connection.resumeSession({
117648
117732
  sessionId: resumeSessionId,
117649
117733
  cwd: workdir,
117650
117734
  mcpServers: []
@@ -117758,15 +117842,15 @@ ${this.stack.split("\n").slice(1).join("\n")}` : this.toString();
117758
117842
  this.logger.debug(`[${this.options.sessionId}] Skipping ACP session close: agent did not advertise session.close`);
117759
117843
  return false;
117760
117844
  }
117761
- const closeSession2 = this.connection?.unstable_closeSession;
117845
+ const closeSession2 = this.connection?.closeSession;
117762
117846
  if (typeof closeSession2 !== "function") {
117763
- this.logger.debug(`[${this.options.sessionId}] Skipping ACP session close: SDK connection has no unstable_closeSession`);
117847
+ this.logger.debug(`[${this.options.sessionId}] Skipping ACP session close: SDK connection has no closeSession`);
117764
117848
  return false;
117765
117849
  }
117766
117850
  this.logger.debug(`[${this.options.sessionId}] Closing ACP session (acpSessionId=${sessionId} timeoutMs=${timeoutMs})`);
117767
117851
  await withTimeout(closeSession2.call(this.connection, {
117768
117852
  sessionId
117769
- }), this.logger, "connection.unstable_closeSession", this.options.sessionId, timeoutMs, Math.min(timeoutMs, 1e3));
117853
+ }), this.logger, "connection.closeSession", this.options.sessionId, timeoutMs, Math.min(timeoutMs, 1e3));
117770
117854
  this.logger.debug(`[${this.options.sessionId}] ACP session close finished (acpSessionId=${sessionId})`);
117771
117855
  return true;
117772
117856
  }
@@ -117902,7 +117986,7 @@ ${this.stack.split("\n").slice(1).join("\n")}` : this.toString();
117902
117986
  },
117903
117987
  codex: {
117904
117988
  packageName: "acp-extension-codex",
117905
- version: "0.12.0",
117989
+ version: "0.12.2",
117906
117990
  binName: "acp-extension-codex",
117907
117991
  args: [
117908
117992
  "-c",