@kilocode/sdk 1.0.24 → 7.0.27

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/server.js CHANGED
@@ -39,7 +39,9 @@ export async function createOpencodeServer(options) {
39
39
  const args = [`serve`, `--hostname=${options.hostname}`, `--port=${options.port}`];
40
40
  if (options.config?.logLevel)
41
41
  args.push(`--log-level=${options.config.logLevel}`);
42
- const proc = spawn(`opencode`, args, {
42
+ // kilocode_change start
43
+ const proc = spawn(`kilo`, args, {
44
+ // kilocode_change end
43
45
  signal: options.signal,
44
46
  env: {
45
47
  ...process.env,
@@ -111,7 +113,9 @@ export function createOpencodeTui(options) {
111
113
  if (options?.agent) {
112
114
  args.push(`--agent=${options.agent}`);
113
115
  }
114
- const proc = spawn(`opencode`, args, {
116
+ // kilocode_change start
117
+ const proc = spawn(`kilo`, args, {
118
+ // kilocode_change end
115
119
  signal: options?.signal,
116
120
  stdio: "inherit",
117
121
  env: {
@@ -468,6 +468,13 @@ export declare class Session extends HeyApiClient {
468
468
  format?: OutputFormat;
469
469
  system?: string;
470
470
  variant?: string;
471
+ editorContext?: {
472
+ visibleFiles?: Array<string>;
473
+ openTabs?: Array<string>;
474
+ activeFile?: string;
475
+ shell?: string;
476
+ timezone?: string;
477
+ };
471
478
  parts?: Array<TextPartInput | FilePartInput | AgentPartInput | SubtaskPartInput>;
472
479
  }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionPromptResponses, SessionPromptErrors, ThrowOnError, "fields">;
473
480
  /**
@@ -501,6 +508,13 @@ export declare class Session extends HeyApiClient {
501
508
  format?: OutputFormat;
502
509
  system?: string;
503
510
  variant?: string;
511
+ editorContext?: {
512
+ visibleFiles?: Array<string>;
513
+ openTabs?: Array<string>;
514
+ activeFile?: string;
515
+ shell?: string;
516
+ timezone?: string;
517
+ };
504
518
  parts?: Array<TextPartInput | FilePartInput | AgentPartInput | SubtaskPartInput>;
505
519
  }, options?: Options<never, ThrowOnError>): import("./client/types.gen.js").RequestResult<SessionPromptAsyncResponses, SessionPromptAsyncErrors, ThrowOnError, "fields">;
506
520
  /**
@@ -892,6 +892,7 @@ export class Session extends HeyApiClient {
892
892
  { in: "body", key: "format" },
893
893
  { in: "body", key: "system" },
894
894
  { in: "body", key: "variant" },
895
+ { in: "body", key: "editorContext" },
895
896
  { in: "body", key: "parts" },
896
897
  ],
897
898
  },
@@ -947,6 +948,7 @@ export class Session extends HeyApiClient {
947
948
  { in: "body", key: "format" },
948
949
  { in: "body", key: "system" },
949
950
  { in: "body", key: "variant" },
951
+ { in: "body", key: "editorContext" },
950
952
  { in: "body", key: "parts" },
951
953
  ],
952
954
  },
@@ -120,6 +120,13 @@ export type UserMessage = {
120
120
  [key: string]: boolean;
121
121
  };
122
122
  variant?: string;
123
+ editorContext?: {
124
+ visibleFiles?: Array<string>;
125
+ openTabs?: Array<string>;
126
+ activeFile?: string;
127
+ shell?: string;
128
+ timezone?: string;
129
+ };
123
130
  };
124
131
  export type ProviderAuthError = {
125
132
  name: "ProviderAuthError";
@@ -452,7 +459,16 @@ export type EventMessagePartUpdated = {
452
459
  type: "message.part.updated";
453
460
  properties: {
454
461
  part: Part;
455
- delta?: string;
462
+ };
463
+ };
464
+ export type EventMessagePartDelta = {
465
+ type: "message.part.delta";
466
+ properties: {
467
+ sessionID: string;
468
+ messageID: string;
469
+ partID: string;
470
+ field: string;
471
+ delta: string;
456
472
  };
457
473
  };
458
474
  export type EventMessagePartRemoved = {
@@ -606,10 +622,6 @@ export type Todo = {
606
622
  * Priority level of the task: high, medium, low
607
623
  */
608
624
  priority: string;
609
- /**
610
- * Unique identifier for the todo item
611
- */
612
- id: string;
613
625
  };
614
626
  export type EventTodoUpdated = {
615
627
  type: "todo.updated";
@@ -809,7 +821,7 @@ export type EventWorktreeFailed = {
809
821
  message: string;
810
822
  };
811
823
  };
812
- export type Event = EventInstallationUpdated | EventInstallationUpdateAvailable | EventProjectUpdated | EventServerInstanceDisposed | EventServerConnected | EventGlobalDisposed | EventLspClientDiagnostics | EventLspUpdated | EventFileEdited | EventMessageUpdated | EventMessageRemoved | EventMessagePartUpdated | EventMessagePartRemoved | EventPermissionAsked | EventPermissionReplied | EventSessionStatus | EventSessionIdle | EventQuestionAsked | EventQuestionReplied | EventQuestionRejected | EventSessionCompacted | EventFileWatcherUpdated | EventTodoUpdated | EventTuiPromptAppend | EventTuiCommandExecute | EventTuiToastShow | EventTuiSessionSelect | EventMcpToolsChanged | EventMcpBrowserOpenFailed | EventCommandExecuted | EventSessionCreated | EventSessionUpdated | EventSessionDeleted | EventSessionDiff | EventSessionError | EventSessionTurnOpen | EventSessionTurnClose | EventVcsBranchUpdated | EventPtyCreated | EventPtyUpdated | EventPtyExited | EventPtyDeleted | EventWorktreeReady | EventWorktreeFailed;
824
+ export type Event = EventInstallationUpdated | EventInstallationUpdateAvailable | EventProjectUpdated | EventServerInstanceDisposed | EventServerConnected | EventGlobalDisposed | EventLspClientDiagnostics | EventLspUpdated | EventFileEdited | EventMessageUpdated | EventMessageRemoved | EventMessagePartUpdated | EventMessagePartDelta | EventMessagePartRemoved | EventPermissionAsked | EventPermissionReplied | EventSessionStatus | EventSessionIdle | EventQuestionAsked | EventQuestionReplied | EventQuestionRejected | EventSessionCompacted | EventFileWatcherUpdated | EventTodoUpdated | EventTuiPromptAppend | EventTuiCommandExecute | EventTuiToastShow | EventTuiSessionSelect | EventMcpToolsChanged | EventMcpBrowserOpenFailed | EventCommandExecuted | EventSessionCreated | EventSessionUpdated | EventSessionDeleted | EventSessionDiff | EventSessionError | EventSessionTurnOpen | EventSessionTurnClose | EventVcsBranchUpdated | EventPtyCreated | EventPtyUpdated | EventPtyExited | EventPtyDeleted | EventWorktreeReady | EventWorktreeFailed;
813
825
  export type GlobalEvent = {
814
826
  directory: string;
815
827
  payload: Event;
@@ -3000,6 +3012,13 @@ export type SessionPromptData = {
3000
3012
  format?: OutputFormat;
3001
3013
  system?: string;
3002
3014
  variant?: string;
3015
+ editorContext?: {
3016
+ visibleFiles?: Array<string>;
3017
+ openTabs?: Array<string>;
3018
+ activeFile?: string;
3019
+ shell?: string;
3020
+ timezone?: string;
3021
+ };
3003
3022
  parts: Array<TextPartInput | FilePartInput | AgentPartInput | SubtaskPartInput>;
3004
3023
  };
3005
3024
  path: {
@@ -3168,6 +3187,13 @@ export type SessionPromptAsyncData = {
3168
3187
  format?: OutputFormat;
3169
3188
  system?: string;
3170
3189
  variant?: string;
3190
+ editorContext?: {
3191
+ visibleFiles?: Array<string>;
3192
+ openTabs?: Array<string>;
3193
+ activeFile?: string;
3194
+ shell?: string;
3195
+ timezone?: string;
3196
+ };
3171
3197
  parts: Array<TextPartInput | FilePartInput | AgentPartInput | SubtaskPartInput>;
3172
3198
  };
3173
3199
  path: {
package/package.json CHANGED
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "$schema": "https://json.schemastore.org/package.json",
3
3
  "name": "@kilocode/sdk",
4
- "version": "1.0.24",
4
+ "version": "7.0.27",
5
5
  "type": "module",
6
6
  "license": "MIT",
7
7
  "repository": {
8
8
  "type": "git",
9
- "url": "https://github.com/Kilo-Org/kilo",
9
+ "url": "https://github.com/Kilo-Org/kilocode",
10
10
  "directory": "packages/sdk/js"
11
11
  },
12
12
  "scripts": {