@k2wanko/gemini-cli-sdk 0.3.0 → 0.5.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/README.md CHANGED
@@ -5,6 +5,7 @@ Built on top of `@google/gemini-cli-core`.
5
5
 
6
6
  ## Features
7
7
 
8
+ - **Sub-agents** — Delegate tasks to specialized child agents via `defineSubAgent()` (programmatic) or `loadSubAgents()` (markdown files), supporting both local Gemini agents and remote A2A protocol agents
8
9
  - **Skill support** — Load skill directories compatible with Gemini CLI's skill format
9
10
  - **Non-interactive by default** — All tool calls are auto-approved, designed for headless agent usage
10
11
  - **Logging control** — Suppress noisy core logs by default (`"silent"`), or route them to a custom logger (pino, winston, etc.) via `logLevel` and `logger` options
package/dist/agent.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { GeminiEventType, type HookDefinition, HookEventName, HookType, type ServerGeminiStreamEvent } from "@google/gemini-cli-core";
1
+ import { Config, GeminiEventType, type HookDefinition, HookEventName, HookType, type ServerGeminiStreamEvent } from "@google/gemini-cli-core";
2
2
  import { type SessionContext } from "./context.js";
3
3
  import { type Logger, type LogLevel } from "./logger.js";
4
4
  import type { SkillRef } from "./skills.js";
@@ -32,6 +32,12 @@ export declare class GeminiAgent {
32
32
  constructor(options: GeminiAgentOptions);
33
33
  /** Return the session ID assigned to this agent instance */
34
34
  getSessionId(): string;
35
+ /**
36
+ * Return the underlying core Config instance.
37
+ * Useful for advanced use cases such as sub-agent execution.
38
+ * The Config is lazily initialized — call after the first sendStream().
39
+ */
40
+ getCoreConfig(): Config;
35
41
  /** List available sessions for the current project */
36
42
  listSessions(): Promise<import("./session.js").SessionInfo[]>;
37
43
  sendStream(prompt: string, signal?: AbortSignal): AsyncGenerator<ServerGeminiStreamEvent>;
package/dist/agent.js CHANGED
@@ -35,6 +35,7 @@ export class GeminiAgent {
35
35
  policyEngineConfig: {
36
36
  defaultDecision: PolicyDecision.ALLOW,
37
37
  },
38
+ disableLoopDetection: true,
38
39
  compressionThreshold: options.compressionThreshold,
39
40
  };
40
41
  this.config = new Config(configParams);
@@ -43,6 +44,14 @@ export class GeminiAgent {
43
44
  getSessionId() {
44
45
  return this.config.getSessionId();
45
46
  }
47
+ /**
48
+ * Return the underlying core Config instance.
49
+ * Useful for advanced use cases such as sub-agent execution.
50
+ * The Config is lazily initialized — call after the first sendStream().
51
+ */
52
+ getCoreConfig() {
53
+ return this.config;
54
+ }
46
55
  /** List available sessions for the current project */
47
56
  async listSessions() {
48
57
  await this.ensureInitialized();
@@ -0,0 +1,24 @@
1
+ import { z } from "zod";
2
+ import { type ToolDef } from "./tool.js";
3
+ export interface ExecuteResult {
4
+ result: unknown;
5
+ error?: string;
6
+ logs?: string[];
7
+ }
8
+ export interface Executor {
9
+ execute(code: string, fns: Record<string, (...args: unknown[]) => Promise<unknown>>): Promise<ExecuteResult>;
10
+ }
11
+ export declare class NodeVMExecutor implements Executor {
12
+ execute(code: string, fns: Record<string, (...args: unknown[]) => Promise<unknown>>): Promise<ExecuteResult>;
13
+ }
14
+ export declare function createCodeModeTool(options: {
15
+ tools: ToolDef<any>[];
16
+ executor?: Executor;
17
+ description?: string;
18
+ }): ToolDef<z.ZodObject<{
19
+ code: z.ZodString;
20
+ }, "strip", z.ZodTypeAny, {
21
+ code: string;
22
+ }, {
23
+ code: string;
24
+ }>>;
@@ -0,0 +1,163 @@
1
+ import { debugLogger } from "@google/gemini-cli-core";
2
+ import { z } from "zod";
3
+ import { zodToJsonSchema } from "zod-to-json-schema";
4
+ import { defineTool } from "./tool.js";
5
+ // ---------------------------------------------------------------------------
6
+ // JSON Schema -> TypeScript type string conversion
7
+ // ---------------------------------------------------------------------------
8
+ function jsonSchemaToTs(schema, depth = 0) {
9
+ if (schema.enum) {
10
+ return schema.enum.map((v) => JSON.stringify(v)).join(" | ");
11
+ }
12
+ if (schema.anyOf ?? schema.oneOf) {
13
+ const variants = (schema.anyOf ?? schema.oneOf ?? []).map((s) => jsonSchemaToTs(s, depth));
14
+ return variants.join(" | ");
15
+ }
16
+ const types = Array.isArray(schema.type)
17
+ ? schema.type
18
+ : schema.type
19
+ ? [schema.type]
20
+ : [];
21
+ if (types.includes("string"))
22
+ return "string";
23
+ if (types.includes("number") || types.includes("integer"))
24
+ return "number";
25
+ if (types.includes("boolean"))
26
+ return "boolean";
27
+ if (types.includes("null"))
28
+ return "null";
29
+ if (types.includes("array") || schema.items) {
30
+ const items = schema.items
31
+ ? jsonSchemaToTs(schema.items, depth)
32
+ : "unknown";
33
+ return `${items}[]`;
34
+ }
35
+ if (types.includes("object") || schema.properties) {
36
+ const props = schema.properties ?? {};
37
+ const required = new Set(schema.required ?? []);
38
+ const indent = " ".repeat(depth + 1);
39
+ const closing = " ".repeat(depth);
40
+ const entries = Object.entries(props).map(([key, val]) => {
41
+ const opt = required.has(key) ? "" : "?";
42
+ const comment = val.description ? `/** ${val.description} */ ` : "";
43
+ return `${indent}${comment}${key}${opt}: ${jsonSchemaToTs(val, depth + 1)}`;
44
+ });
45
+ if (entries.length === 0)
46
+ return "Record<string, unknown>";
47
+ return `{\n${entries.join(";\n")};\n${closing}}`;
48
+ }
49
+ return "unknown";
50
+ }
51
+ // ---------------------------------------------------------------------------
52
+ // API docs generation from ToolDef array (JSDoc-style, for LLM consumption)
53
+ // ---------------------------------------------------------------------------
54
+ function jsonSchemaToParams(schema, prefix = "") {
55
+ const props = schema.properties ?? {};
56
+ const required = new Set(schema.required ?? []);
57
+ return Object.entries(props).map(([key, val]) => {
58
+ const opt = required.has(key) ? "" : "?";
59
+ const type = jsonSchemaToTs(val);
60
+ const desc = val.description ? ` — ${val.description}` : "";
61
+ return `// ${prefix}${key}${opt}: ${type}${desc}`;
62
+ });
63
+ }
64
+ function generateApiDocs(tools) {
65
+ debugLogger.debug?.("[codemode] generateApiDocs: %d tools", tools.length);
66
+ const sections = tools.map((tool) => {
67
+ const schema = zodToJsonSchema(tool.inputSchema);
68
+ const params = jsonSchemaToParams(schema);
69
+ const desc = tool.description ? ` — ${tool.description}` : "";
70
+ const lines = [`// codemode.${tool.name}(input)${desc}`, ...params];
71
+ return lines.join("\n");
72
+ });
73
+ return sections.join("\n//\n");
74
+ }
75
+ // ---------------------------------------------------------------------------
76
+ // NodeVMExecutor
77
+ // ---------------------------------------------------------------------------
78
+ export class NodeVMExecutor {
79
+ async execute(code, fns) {
80
+ debugLogger.debug?.("[codemode:executor] execute called, code length=%d, available fns=%s", code.length, Object.keys(fns).join(", "));
81
+ debugLogger.debug?.("[codemode:executor] code:\n%s", code);
82
+ const logs = [];
83
+ const stringify = (v) => typeof v === "object" && v !== null ? JSON.stringify(v) : String(v);
84
+ const captureConsole = {
85
+ log: (...args) => logs.push(args.map(stringify).join(" ")),
86
+ warn: (...args) => logs.push(`[warn] ${args.map(stringify).join(" ")}`),
87
+ error: (...args) => logs.push(`[error] ${args.map(stringify).join(" ")}`),
88
+ };
89
+ try {
90
+ const AsyncFunction = Object.getPrototypeOf(async () => { })
91
+ .constructor;
92
+ const fn = new AsyncFunction("codemode", "console", code);
93
+ debugLogger.debug?.("[codemode:executor] starting execution");
94
+ const result = await fn(fns, captureConsole);
95
+ debugLogger.debug?.("[codemode:executor] execution completed, result=%s, logs=%d", typeof result, logs.length);
96
+ return {
97
+ result,
98
+ logs: logs.length > 0 ? logs : undefined,
99
+ };
100
+ }
101
+ catch (error) {
102
+ debugLogger.debug?.("[codemode:executor] execution failed: %s", error instanceof Error ? error.message : String(error));
103
+ return {
104
+ result: undefined,
105
+ error: error instanceof Error ? error.message : String(error),
106
+ logs: logs.length > 0 ? logs : undefined,
107
+ };
108
+ }
109
+ }
110
+ }
111
+ // ---------------------------------------------------------------------------
112
+ // createCodeModeTool
113
+ // ---------------------------------------------------------------------------
114
+ export function createCodeModeTool(options) {
115
+ const executor = options.executor ?? new NodeVMExecutor();
116
+ const apiDocs = generateApiDocs(options.tools);
117
+ const description = options.description ??
118
+ `Write and execute plain JavaScript (NOT TypeScript) to orchestrate multiple tools.
119
+
120
+ The \`codemode\` object exposes all available tools as async functions.
121
+ Always end your code with a \`return\` statement to return the final result.
122
+
123
+ Available tools:
124
+ \`\`\`javascript
125
+ ${apiDocs}
126
+ \`\`\`
127
+
128
+ Example:
129
+ \`\`\`javascript
130
+ const result = await codemode.toolName({ param: "value" });
131
+ return result;
132
+ \`\`\``;
133
+ debugLogger.debug?.("[codemode] createCodeModeTool: registering %d tools", options.tools.length);
134
+ return defineTool({
135
+ name: "code",
136
+ description,
137
+ inputSchema: z.object({
138
+ code: z
139
+ .string()
140
+ .describe("JavaScript code to execute. Must use `return` to return the final result."),
141
+ }),
142
+ sendErrorsToModel: true,
143
+ }, async ({ code }, context) => {
144
+ debugLogger.debug?.("[codemode] tool invoked, code length=%d", code.length);
145
+ const fns = {};
146
+ for (const tool of options.tools) {
147
+ fns[tool.name] = (input) => {
148
+ debugLogger.debug?.("[codemode] calling tool '%s' with input: %s", tool.name, JSON.stringify(input));
149
+ return tool.action(input, context);
150
+ };
151
+ }
152
+ const execResult = await executor.execute(code, fns);
153
+ const output = {};
154
+ if (execResult.result !== undefined)
155
+ output.result = execResult.result;
156
+ if (execResult.error)
157
+ output.error = execResult.error;
158
+ if (execResult.logs && execResult.logs.length > 0)
159
+ output.logs = execResult.logs;
160
+ debugLogger.debug?.("[codemode] tool output: %s", JSON.stringify(output));
161
+ return output;
162
+ });
163
+ }
package/dist/index.d.ts CHANGED
@@ -1,6 +1,8 @@
1
1
  export * from "./agent.js";
2
+ export * from "./codemode.js";
2
3
  export * from "./context.js";
3
4
  export * from "./logger.js";
4
5
  export * from "./session.js";
5
6
  export * from "./skills.js";
7
+ export * from "./subagent.js";
6
8
  export * from "./tool.js";
package/dist/index.js CHANGED
@@ -1,6 +1,8 @@
1
1
  export * from "./agent.js";
2
+ export * from "./codemode.js";
2
3
  export * from "./context.js";
3
4
  export * from "./logger.js";
4
5
  export * from "./session.js";
5
6
  export * from "./skills.js";
7
+ export * from "./subagent.js";
6
8
  export * from "./tool.js";
@@ -0,0 +1,58 @@
1
+ import { AgentTerminateMode, type LocalAgentDefinition, type RemoteAgentDefinition, type SubagentActivityEvent } from "@google/gemini-cli-core";
2
+ import { z } from "zod";
3
+ import type { SessionContext } from "./context.js";
4
+ import { type ToolDef } from "./tool.js";
5
+ export { AgentTerminateMode, type SubagentActivityEvent, type LocalAgentDefinition, type RemoteAgentDefinition, };
6
+ /**
7
+ * A prompt value that can be a static string or a function that dynamically
8
+ * resolves at invocation time. The function receives the tool input params
9
+ * and the parent's SessionContext.
10
+ *
11
+ * The resolved string still supports core's `${paramName}` template syntax,
12
+ * so both mechanisms can be combined.
13
+ */
14
+ export type PromptValue<TInput extends z.ZodRawShape> = string | ((params: z.infer<z.ZodObject<TInput>>, ctx: SessionContext) => string | Promise<string>);
15
+ export interface SubAgentOptions<TInput extends z.ZodRawShape> {
16
+ name: string;
17
+ description: string;
18
+ inputSchema: z.ZodObject<TInput>;
19
+ /**
20
+ * System prompt — a static string or a function for dynamic resolution.
21
+ * Supports core's `${paramName}` template syntax (applied after resolution).
22
+ */
23
+ systemPrompt: PromptValue<TInput>;
24
+ /**
25
+ * Initial query — a static string or a function for dynamic resolution.
26
+ * Supports core's `${paramName}` template syntax (applied after resolution).
27
+ * Default: core's "Get Started!"
28
+ */
29
+ query?: PromptValue<TInput>;
30
+ /** Model. Default: "inherit" (parent's active model) */
31
+ model?: string;
32
+ /** Max turns. Omit to use core default. */
33
+ maxTurns?: number;
34
+ /** Max execution time in minutes. Omit to use core default. */
35
+ maxTimeMinutes?: number;
36
+ /**
37
+ * Tools the sub-agent can use (tool names from parent registry).
38
+ * Include "activate_skill" to enable skills.
39
+ * If omitted: inherits ALL parent tools.
40
+ */
41
+ tools?: string[];
42
+ /** Activity callback for observability */
43
+ onActivity?: (event: SubagentActivityEvent) => void;
44
+ }
45
+ /**
46
+ * Define a local sub-agent programmatically. Returns a `ToolDef` compatible
47
+ * with `GeminiAgent.tools`.
48
+ */
49
+ export declare function defineSubAgent<TInput extends z.ZodRawShape>(options: SubAgentOptions<TInput>): ToolDef<z.ZodObject<TInput>>;
50
+ /**
51
+ * Load sub-agent definitions from `.md` files in a directory.
52
+ * Each file becomes a `ToolDef` compatible with `GeminiAgent.tools`.
53
+ *
54
+ * Files starting with `_` are ignored by core's loader.
55
+ */
56
+ export declare function loadSubAgents(dir: string, options?: {
57
+ onActivity?: (event: SubagentActivityEvent) => void;
58
+ }): Promise<ToolDef<any>[]>;
@@ -0,0 +1,223 @@
1
+ import { ClientFactory } from "@a2a-js/sdk/client";
2
+ import { AgentTerminateMode, LocalAgentExecutor, loadAgentsFromDirectory, } from "@google/gemini-cli-core";
3
+ import { z } from "zod";
4
+ import { ToolError } from "./tool.js";
5
+ // ---------------------------------------------------------------------------
6
+ // Re-exports from core
7
+ // ---------------------------------------------------------------------------
8
+ export { AgentTerminateMode, };
9
+ // ---------------------------------------------------------------------------
10
+ // defineSubAgent — Programmatic API
11
+ // ---------------------------------------------------------------------------
12
+ /**
13
+ * Define a local sub-agent programmatically. Returns a `ToolDef` compatible
14
+ * with `GeminiAgent.tools`.
15
+ */
16
+ export function defineSubAgent(options) {
17
+ const hasDynamicPrompt = typeof options.systemPrompt === "function" ||
18
+ typeof options.query === "function";
19
+ // Fast path: when both prompts are static strings, build the definition
20
+ // upfront and delegate to the shared helper.
21
+ if (!hasDynamicPrompt) {
22
+ const def = buildLocalAgentDef(options, options.systemPrompt, options.query);
23
+ return wrapLocalAgentAsTool(def, options.inputSchema, options.onActivity);
24
+ }
25
+ // Dynamic path: resolve prompt values inside the action.
26
+ return {
27
+ name: options.name,
28
+ description: options.description,
29
+ inputSchema: options.inputSchema,
30
+ sendErrorsToModel: true,
31
+ action: async (params, ctx) => {
32
+ const resolvedSystemPrompt = await resolvePromptValue(options.systemPrompt, params, ctx);
33
+ const resolvedQuery = options.query !== undefined
34
+ ? await resolvePromptValue(options.query, params, ctx)
35
+ : undefined;
36
+ const def = buildLocalAgentDef(options, resolvedSystemPrompt, resolvedQuery);
37
+ return executeLocalAgent(def, params, ctx, options.onActivity);
38
+ },
39
+ };
40
+ }
41
+ // ---------------------------------------------------------------------------
42
+ // loadSubAgents — File-based API
43
+ // ---------------------------------------------------------------------------
44
+ /**
45
+ * Load sub-agent definitions from `.md` files in a directory.
46
+ * Each file becomes a `ToolDef` compatible with `GeminiAgent.tools`.
47
+ *
48
+ * Files starting with `_` are ignored by core's loader.
49
+ */
50
+ export async function loadSubAgents(dir, options) {
51
+ const { agents, errors } = await loadAgentsFromDirectory(dir);
52
+ if (errors.length > 0) {
53
+ for (const err of errors) {
54
+ console.error(`[subagent] Failed to load ${err.filePath}: ${err.message}`);
55
+ }
56
+ }
57
+ const querySchema = z.object({
58
+ query: z.string().optional().describe("Input query for the sub-agent"),
59
+ });
60
+ const tools = [];
61
+ for (const def of agents) {
62
+ if (def.kind === "local") {
63
+ tools.push(wrapLocalAgentAsTool(def, querySchema, options?.onActivity));
64
+ }
65
+ else if (def.kind === "remote") {
66
+ tools.push(wrapRemoteAgentAsTool(def, querySchema));
67
+ }
68
+ }
69
+ return tools;
70
+ }
71
+ // ---------------------------------------------------------------------------
72
+ // Internal: prompt resolution
73
+ // ---------------------------------------------------------------------------
74
+ async function resolvePromptValue(value, params, ctx) {
75
+ return typeof value === "function" ? value(params, ctx) : value;
76
+ }
77
+ // ---------------------------------------------------------------------------
78
+ // Internal: build LocalAgentDefinition from SubAgentOptions + resolved strings
79
+ // ---------------------------------------------------------------------------
80
+ function buildLocalAgentDef(options, systemPrompt, query) {
81
+ return {
82
+ kind: "local",
83
+ name: options.name,
84
+ description: options.description,
85
+ inputConfig: {
86
+ inputSchema: zodToJsonSchemaSimple(options.inputSchema),
87
+ },
88
+ promptConfig: {
89
+ systemPrompt,
90
+ ...(query !== undefined && { query }),
91
+ },
92
+ modelConfig: { model: options.model ?? "inherit" },
93
+ runConfig: {
94
+ ...(options.maxTurns !== undefined && { maxTurns: options.maxTurns }),
95
+ ...(options.maxTimeMinutes !== undefined && {
96
+ maxTimeMinutes: options.maxTimeMinutes,
97
+ }),
98
+ },
99
+ ...(options.tools && { toolConfig: { tools: options.tools } }),
100
+ };
101
+ }
102
+ // ---------------------------------------------------------------------------
103
+ // Internal: execute a local agent (shared by wrapLocalAgentAsTool & dynamic path)
104
+ // ---------------------------------------------------------------------------
105
+ async function executeLocalAgent(def, params, ctx, onActivity) {
106
+ const config = ctx.agent.getCoreConfig();
107
+ // Register model config alias — replicates AgentRegistry.registerModelConfigs()
108
+ const alias = `${def.name}-config`;
109
+ config.modelConfigService.registerRuntimeModelConfig(alias, {
110
+ modelConfig: {
111
+ model: def.modelConfig.model === "inherit"
112
+ ? config.getActiveModel()
113
+ : def.modelConfig.model,
114
+ ...(def.modelConfig.generateContentConfig && {
115
+ generateContentConfig: def.modelConfig.generateContentConfig,
116
+ }),
117
+ },
118
+ });
119
+ const executor = await LocalAgentExecutor.create(def, config, onActivity);
120
+ const result = await executor.run(params, new AbortController().signal);
121
+ if (result.terminate_reason !== AgentTerminateMode.GOAL) {
122
+ throw new ToolError(`Sub-agent "${def.name}" terminated: ${result.terminate_reason}`);
123
+ }
124
+ return result.result;
125
+ }
126
+ // ---------------------------------------------------------------------------
127
+ // Internal: wrapLocalAgentAsTool
128
+ // ---------------------------------------------------------------------------
129
+ function wrapLocalAgentAsTool(def, inputSchema, onActivity) {
130
+ return {
131
+ name: def.name,
132
+ description: def.description,
133
+ inputSchema,
134
+ sendErrorsToModel: true,
135
+ action: async (params, ctx) => {
136
+ return executeLocalAgent(def, params, ctx, onActivity);
137
+ },
138
+ };
139
+ }
140
+ // ---------------------------------------------------------------------------
141
+ // Internal: wrapRemoteAgentAsTool
142
+ // ---------------------------------------------------------------------------
143
+ /** Cached ClientFactory instance (shared across all remote agents) */
144
+ let sharedClientFactory;
145
+ function getClientFactory() {
146
+ if (!sharedClientFactory) {
147
+ sharedClientFactory = new ClientFactory();
148
+ }
149
+ return sharedClientFactory;
150
+ }
151
+ function wrapRemoteAgentAsTool(def, inputSchema) {
152
+ return {
153
+ name: def.name,
154
+ description: def.description,
155
+ inputSchema,
156
+ sendErrorsToModel: true,
157
+ action: async (params) => {
158
+ const factory = getClientFactory();
159
+ const client = await factory.createFromUrl(def.agentCardUrl, "");
160
+ const query = typeof params === "object" && params !== null && "query" in params
161
+ ? String(params.query ?? "")
162
+ : JSON.stringify(params);
163
+ const result = await client.sendMessage({
164
+ message: {
165
+ kind: "message",
166
+ messageId: crypto.randomUUID(),
167
+ role: "user",
168
+ parts: [{ kind: "text", text: query }],
169
+ },
170
+ configuration: { blocking: true },
171
+ });
172
+ return extractTextFromResult(result);
173
+ },
174
+ };
175
+ }
176
+ // ---------------------------------------------------------------------------
177
+ // Internal: A2A text extraction
178
+ // ---------------------------------------------------------------------------
179
+ function extractTextFromResult(result) {
180
+ if (result.kind === "message") {
181
+ return extractTextFromParts(result.parts);
182
+ }
183
+ // Task
184
+ const parts = result.status?.message?.parts;
185
+ if (parts) {
186
+ return extractTextFromParts(parts);
187
+ }
188
+ return "";
189
+ }
190
+ function extractTextFromParts(parts) {
191
+ return parts
192
+ .filter((p) => p.kind === "text")
193
+ .map((p) => p.text)
194
+ .join("\n");
195
+ }
196
+ // ---------------------------------------------------------------------------
197
+ // Internal: minimal Zod-to-JSON-Schema for inputConfig
198
+ // ---------------------------------------------------------------------------
199
+ function zodToJsonSchemaSimple(schema) {
200
+ const shape = schema.shape;
201
+ const properties = {};
202
+ const required = [];
203
+ for (const [key, value] of Object.entries(shape)) {
204
+ const zodType = value;
205
+ const prop = { type: "string" };
206
+ if (zodType.description) {
207
+ prop.description = zodType.description;
208
+ }
209
+ // Unwrap optional
210
+ if (zodType instanceof z.ZodOptional) {
211
+ // optional — don't add to required
212
+ }
213
+ else {
214
+ required.push(key);
215
+ }
216
+ properties[key] = prop;
217
+ }
218
+ return {
219
+ type: "object",
220
+ properties,
221
+ ...(required.length > 0 && { required }),
222
+ };
223
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@k2wanko/gemini-cli-sdk",
3
- "version": "0.3.0",
3
+ "version": "0.5.0",
4
4
  "description": "A lightweight SDK for building non-interactive AI agents powered by Google Gemini",
5
5
  "type": "module",
6
6
  "private": false,
@@ -38,12 +38,13 @@
38
38
  },
39
39
  "scripts": {
40
40
  "build": "tsc",
41
- "lint": "biome check && tsc --noEmit",
42
- "fix": "biome check --write . && tsc --noEmit",
41
+ "lint": "biome check && tsc --noEmit && tsc --project tsconfig.examples.json",
42
+ "fix": "biome check --write . && tsc --noEmit && tsc --project tsconfig.examples.json",
43
43
  "test": "bun test"
44
44
  },
45
45
  "dependencies": {
46
- "@google/gemini-cli-core": "0.30.0-nightly.20260218.ce84b3cb5",
46
+ "@a2a-js/sdk": "^0.3.10",
47
+ "@google/gemini-cli-core": "nightly",
47
48
  "zod": "^3.23.8",
48
49
  "zod-to-json-schema": "^3.23.1"
49
50
  },