@github/copilot-sdk 1.0.7-preview.3 → 1.0.8-preview.0

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/types.d.ts CHANGED
@@ -471,6 +471,14 @@ export interface Tool<TArgs = unknown> {
471
471
  * Optional; defaults to `"auto"`.
472
472
  */
473
473
  defer?: "auto" | "never";
474
+ /**
475
+ * Opaque, host-defined metadata associated with the tool definition.
476
+ *
477
+ * Keys are namespaced and are not part of the stable public API. Values are
478
+ * not interpreted and may be recognized to inform host-specific behavior.
479
+ * Unknown keys are preserved and round-tripped untouched.
480
+ */
481
+ metadata?: Record<string, unknown>;
474
482
  }
475
483
  /**
476
484
  * Helper to define a tool with Zod schema and get type inference for the handler.
@@ -483,6 +491,7 @@ export declare function defineTool<T = unknown>(name: string, config: {
483
491
  overridesBuiltInTool?: boolean;
484
492
  skipPermission?: boolean;
485
493
  defer?: "auto" | "never";
494
+ metadata?: Record<string, unknown>;
486
495
  }): Tool<T>;
487
496
  /**
488
497
  * SDK-supplied override for the runtime's built-in tool-search behavior.
@@ -1291,6 +1300,12 @@ export interface CustomAgentConfig {
1291
1300
  * falling back to the parent session model if unavailable.
1292
1301
  */
1293
1302
  model?: string;
1303
+ /**
1304
+ * Reasoning effort level for this agent's model.
1305
+ * When omitted, no per-agent override is sent and the backend chooses its
1306
+ * default. The parent session effort is not inherited.
1307
+ */
1308
+ reasoningEffort?: ReasoningEffort;
1294
1309
  }
1295
1310
  /**
1296
1311
  * Configuration for the default agent (the built-in agent that handles
@@ -1483,6 +1498,42 @@ export interface CapiSessionOptions {
1483
1498
  */
1484
1499
  enableWebSocketResponses?: boolean;
1485
1500
  }
1501
+ /**
1502
+ * A single ExP (Experiment Platform) flag value. ExP assignments resolve to a
1503
+ * string, number, boolean, or `null`.
1504
+ */
1505
+ export type ExpFlagValue = string | number | boolean | null;
1506
+ /**
1507
+ * A single configuration entry in a {@link CopilotExpAssignmentResponse}. Each
1508
+ * entry carries an identifier and a bag of typed parameter values.
1509
+ */
1510
+ export interface ExpConfigEntry {
1511
+ /** Identifier of the configuration entry. */
1512
+ Id: string;
1513
+ /** Parameter values keyed by parameter name. */
1514
+ Parameters: Record<string, ExpFlagValue>;
1515
+ }
1516
+ /**
1517
+ * ExP ("flight") assignment data, in the same JSON shape the Copilot CLI
1518
+ * fetches from the experimentation service. Field names are PascalCase to match
1519
+ * the on-the-wire contract consumed by the runtime.
1520
+ */
1521
+ export interface CopilotExpAssignmentResponse {
1522
+ /** Enabled feature names. */
1523
+ Features: string[];
1524
+ /** Assigned flights keyed by flight name. */
1525
+ Flights: Record<string, string>;
1526
+ /** Configuration entries carrying typed parameter values. */
1527
+ Configs: ExpConfigEntry[];
1528
+ /** Opaque parameter-group payload passed through untouched. */
1529
+ ParameterGroups?: unknown;
1530
+ /** Version of the flighting configuration. */
1531
+ FlightingVersion?: number;
1532
+ /** Impression identifier for the assignment. */
1533
+ ImpressionId?: string;
1534
+ /** Assignment context string forwarded to CAPI and telemetry. */
1535
+ AssignmentContext: string;
1536
+ }
1486
1537
  /**
1487
1538
  * Shared configuration fields used by both {@link SessionConfig} (for
1488
1539
  * creating a new session) and {@link ResumeSessionConfig} (for resuming
package/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "type": "git",
5
5
  "url": "https://github.com/github/copilot-sdk.git"
6
6
  },
7
- "version": "1.0.7-preview.3",
7
+ "version": "1.0.8-preview.0",
8
8
  "description": "TypeScript SDK for programmatic control of GitHub Copilot CLI via JSON-RPC",
9
9
  "main": "./dist/cjs/index.js",
10
10
  "types": "./dist/index.d.ts",
@@ -56,7 +56,7 @@
56
56
  "author": "GitHub",
57
57
  "license": "MIT",
58
58
  "dependencies": {
59
- "@github/copilot": "^1.0.71-2",
59
+ "@github/copilot": "^1.0.72",
60
60
  "koffi": "^3.1.0",
61
61
  "vscode-jsonrpc": "^8.2.1",
62
62
  "zod": "^4.3.6"