@langchain/google-genai 0.2.18 → 1.0.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 (59) hide show
  1. package/CHANGELOG.md +17 -0
  2. package/LICENSE +6 -6
  3. package/README.md +8 -8
  4. package/dist/_virtual/rolldown_runtime.cjs +25 -0
  5. package/dist/chat_models.cjs +688 -847
  6. package/dist/chat_models.cjs.map +1 -0
  7. package/dist/chat_models.d.cts +575 -0
  8. package/dist/chat_models.d.cts.map +1 -0
  9. package/dist/chat_models.d.ts +190 -157
  10. package/dist/chat_models.d.ts.map +1 -0
  11. package/dist/chat_models.js +686 -842
  12. package/dist/chat_models.js.map +1 -0
  13. package/dist/embeddings.cjs +97 -151
  14. package/dist/embeddings.cjs.map +1 -0
  15. package/dist/embeddings.d.cts +104 -0
  16. package/dist/embeddings.d.cts.map +1 -0
  17. package/dist/embeddings.d.ts +76 -70
  18. package/dist/embeddings.d.ts.map +1 -0
  19. package/dist/embeddings.js +93 -144
  20. package/dist/embeddings.js.map +1 -0
  21. package/dist/index.cjs +5 -18
  22. package/dist/index.d.cts +3 -0
  23. package/dist/index.d.ts +3 -2
  24. package/dist/index.js +4 -2
  25. package/dist/output_parsers.cjs +47 -75
  26. package/dist/output_parsers.cjs.map +1 -0
  27. package/dist/output_parsers.js +47 -72
  28. package/dist/output_parsers.js.map +1 -0
  29. package/dist/profiles.cjs +345 -0
  30. package/dist/profiles.cjs.map +1 -0
  31. package/dist/profiles.js +344 -0
  32. package/dist/profiles.js.map +1 -0
  33. package/dist/types.d.cts +8 -0
  34. package/dist/types.d.cts.map +1 -0
  35. package/dist/types.d.ts +7 -2
  36. package/dist/types.d.ts.map +1 -0
  37. package/dist/utils/common.cjs +356 -549
  38. package/dist/utils/common.cjs.map +1 -0
  39. package/dist/utils/common.js +357 -545
  40. package/dist/utils/common.js.map +1 -0
  41. package/dist/utils/tools.cjs +65 -102
  42. package/dist/utils/tools.cjs.map +1 -0
  43. package/dist/utils/tools.js +64 -99
  44. package/dist/utils/tools.js.map +1 -0
  45. package/dist/utils/zod_to_genai_parameters.cjs +31 -49
  46. package/dist/utils/zod_to_genai_parameters.cjs.map +1 -0
  47. package/dist/utils/zod_to_genai_parameters.js +29 -45
  48. package/dist/utils/zod_to_genai_parameters.js.map +1 -0
  49. package/package.json +45 -51
  50. package/dist/output_parsers.d.ts +0 -20
  51. package/dist/types.cjs +0 -2
  52. package/dist/types.js +0 -1
  53. package/dist/utils/common.d.ts +0 -22
  54. package/dist/utils/tools.d.ts +0 -10
  55. package/dist/utils/zod_to_genai_parameters.d.ts +0 -14
  56. package/index.cjs +0 -1
  57. package/index.d.cts +0 -1
  58. package/index.d.ts +0 -1
  59. package/index.js +0 -1
@@ -1,72 +1,47 @@
1
- import { BaseLLMOutputParser, OutputParserException, } from "@langchain/core/output_parsers";
2
- import { interopSafeParseAsync, } from "@langchain/core/utils/types";
3
- export class GoogleGenerativeAIToolsOutputParser extends BaseLLMOutputParser {
4
- static lc_name() {
5
- return "GoogleGenerativeAIToolsOutputParser";
6
- }
7
- constructor(params) {
8
- super(params);
9
- Object.defineProperty(this, "lc_namespace", {
10
- enumerable: true,
11
- configurable: true,
12
- writable: true,
13
- value: ["langchain", "google_genai", "output_parsers"]
14
- });
15
- Object.defineProperty(this, "returnId", {
16
- enumerable: true,
17
- configurable: true,
18
- writable: true,
19
- value: false
20
- });
21
- /** The type of tool calls to return. */
22
- Object.defineProperty(this, "keyName", {
23
- enumerable: true,
24
- configurable: true,
25
- writable: true,
26
- value: void 0
27
- });
28
- /** Whether to return only the first tool call. */
29
- Object.defineProperty(this, "returnSingle", {
30
- enumerable: true,
31
- configurable: true,
32
- writable: true,
33
- value: false
34
- });
35
- Object.defineProperty(this, "zodSchema", {
36
- enumerable: true,
37
- configurable: true,
38
- writable: true,
39
- value: void 0
40
- });
41
- this.keyName = params.keyName;
42
- this.returnSingle = params.returnSingle ?? this.returnSingle;
43
- this.zodSchema = params.zodSchema;
44
- }
45
- async _validateResult(result) {
46
- if (this.zodSchema === undefined) {
47
- return result;
48
- }
49
- const zodParsedResult = await interopSafeParseAsync(this.zodSchema, result);
50
- if (zodParsedResult.success) {
51
- return zodParsedResult.data;
52
- }
53
- else {
54
- throw new OutputParserException(`Failed to parse. Text: "${JSON.stringify(result, null, 2)}". Error: ${JSON.stringify(zodParsedResult.error.issues)}`, JSON.stringify(result, null, 2));
55
- }
56
- }
57
- async parseResult(generations) {
58
- const tools = generations.flatMap((generation) => {
59
- const { message } = generation;
60
- if (!("tool_calls" in message) || !Array.isArray(message.tool_calls)) {
61
- return [];
62
- }
63
- return message.tool_calls;
64
- });
65
- if (tools[0] === undefined) {
66
- throw new Error("No parseable tool calls provided to GoogleGenerativeAIToolsOutputParser.");
67
- }
68
- const [tool] = tools;
69
- const validatedResult = await this._validateResult(tool.args);
70
- return validatedResult;
71
- }
72
- }
1
+ import { interopSafeParseAsync } from "@langchain/core/utils/types";
2
+ import { BaseLLMOutputParser, OutputParserException } from "@langchain/core/output_parsers";
3
+
4
+ //#region src/output_parsers.ts
5
+ var GoogleGenerativeAIToolsOutputParser = class extends BaseLLMOutputParser {
6
+ static lc_name() {
7
+ return "GoogleGenerativeAIToolsOutputParser";
8
+ }
9
+ lc_namespace = [
10
+ "langchain",
11
+ "google_genai",
12
+ "output_parsers"
13
+ ];
14
+ returnId = false;
15
+ /** The type of tool calls to return. */
16
+ keyName;
17
+ /** Whether to return only the first tool call. */
18
+ returnSingle = false;
19
+ zodSchema;
20
+ constructor(params) {
21
+ super(params);
22
+ this.keyName = params.keyName;
23
+ this.returnSingle = params.returnSingle ?? this.returnSingle;
24
+ this.zodSchema = params.zodSchema;
25
+ }
26
+ async _validateResult(result) {
27
+ if (this.zodSchema === void 0) return result;
28
+ const zodParsedResult = await interopSafeParseAsync(this.zodSchema, result);
29
+ if (zodParsedResult.success) return zodParsedResult.data;
30
+ else throw new OutputParserException(`Failed to parse. Text: "${JSON.stringify(result, null, 2)}". Error: ${JSON.stringify(zodParsedResult.error.issues)}`, JSON.stringify(result, null, 2));
31
+ }
32
+ async parseResult(generations) {
33
+ const tools = generations.flatMap((generation) => {
34
+ const { message } = generation;
35
+ if (!("tool_calls" in message) || !Array.isArray(message.tool_calls)) return [];
36
+ return message.tool_calls;
37
+ });
38
+ if (tools[0] === void 0) throw new Error("No parseable tool calls provided to GoogleGenerativeAIToolsOutputParser.");
39
+ const [tool] = tools;
40
+ const validatedResult = await this._validateResult(tool.args);
41
+ return validatedResult;
42
+ }
43
+ };
44
+
45
+ //#endregion
46
+ export { GoogleGenerativeAIToolsOutputParser };
47
+ //# sourceMappingURL=output_parsers.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"output_parsers.js","names":["params: GoogleGenerativeAIToolsOutputParserParams<T>","result: unknown","generations: ChatGeneration[]"],"sources":["../src/output_parsers.ts"],"sourcesContent":["import {\n BaseLLMOutputParser,\n OutputParserException,\n} from \"@langchain/core/output_parsers\";\nimport { ChatGeneration } from \"@langchain/core/outputs\";\nimport { ToolCall } from \"@langchain/core/messages/tool\";\nimport {\n InteropZodType,\n interopSafeParseAsync,\n} from \"@langchain/core/utils/types\";\nimport { JsonOutputKeyToolsParserParamsInterop } from \"@langchain/core/output_parsers/openai_tools\";\n\ninterface GoogleGenerativeAIToolsOutputParserParams<\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n T extends Record<string, any>\n> extends JsonOutputKeyToolsParserParamsInterop<T> {}\n\nexport class GoogleGenerativeAIToolsOutputParser<\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n T extends Record<string, any> = Record<string, any>\n> extends BaseLLMOutputParser<T> {\n static lc_name() {\n return \"GoogleGenerativeAIToolsOutputParser\";\n }\n\n lc_namespace = [\"langchain\", \"google_genai\", \"output_parsers\"];\n\n returnId = false;\n\n /** The type of tool calls to return. */\n keyName: string;\n\n /** Whether to return only the first tool call. */\n returnSingle = false;\n\n zodSchema?: InteropZodType<T>;\n\n constructor(params: GoogleGenerativeAIToolsOutputParserParams<T>) {\n super(params);\n this.keyName = params.keyName;\n this.returnSingle = params.returnSingle ?? this.returnSingle;\n this.zodSchema = params.zodSchema;\n }\n\n protected async _validateResult(result: unknown): Promise<T> {\n if (this.zodSchema === undefined) {\n return result as T;\n }\n const zodParsedResult = await interopSafeParseAsync(this.zodSchema, result);\n if (zodParsedResult.success) {\n return zodParsedResult.data;\n } else {\n throw new OutputParserException(\n `Failed to parse. Text: \"${JSON.stringify(\n result,\n null,\n 2\n )}\". Error: ${JSON.stringify(zodParsedResult.error.issues)}`,\n JSON.stringify(result, null, 2)\n );\n }\n }\n\n async parseResult(generations: ChatGeneration[]): Promise<T> {\n const tools = generations.flatMap((generation) => {\n const { message } = generation;\n if (!(\"tool_calls\" in message) || !Array.isArray(message.tool_calls)) {\n return [];\n }\n return message.tool_calls as ToolCall[];\n });\n if (tools[0] === undefined) {\n throw new Error(\n \"No parseable tool calls provided to GoogleGenerativeAIToolsOutputParser.\"\n );\n }\n const [tool] = tools;\n const validatedResult = await this._validateResult(tool.args);\n return validatedResult;\n }\n}\n"],"mappings":";;;;AAiBA,IAAa,sCAAb,cAGU,oBAAuB;CAC/B,OAAO,UAAU;AACf,SAAO;CACR;CAED,eAAe;EAAC;EAAa;EAAgB;CAAiB;CAE9D,WAAW;;CAGX;;CAGA,eAAe;CAEf;CAEA,YAAYA,QAAsD;EAChE,MAAM,OAAO;EACb,KAAK,UAAU,OAAO;EACtB,KAAK,eAAe,OAAO,gBAAgB,KAAK;EAChD,KAAK,YAAY,OAAO;CACzB;CAED,MAAgB,gBAAgBC,QAA6B;AAC3D,MAAI,KAAK,cAAc,OACrB,QAAO;EAET,MAAM,kBAAkB,MAAM,sBAAsB,KAAK,WAAW,OAAO;AAC3E,MAAI,gBAAgB,QAClB,QAAO,gBAAgB;MAEvB,OAAM,IAAI,sBACR,CAAC,wBAAwB,EAAE,KAAK,UAC9B,QACA,MACA,EACD,CAAC,UAAU,EAAE,KAAK,UAAU,gBAAgB,MAAM,OAAO,EAAE,EAC5D,KAAK,UAAU,QAAQ,MAAM,EAAE;CAGpC;CAED,MAAM,YAAYC,aAA2C;EAC3D,MAAM,QAAQ,YAAY,QAAQ,CAAC,eAAe;GAChD,MAAM,EAAE,SAAS,GAAG;AACpB,OAAI,EAAE,gBAAgB,YAAY,CAAC,MAAM,QAAQ,QAAQ,WAAW,CAClE,QAAO,CAAE;AAEX,UAAO,QAAQ;EAChB,EAAC;AACF,MAAI,MAAM,OAAO,OACf,OAAM,IAAI,MACR;EAGJ,MAAM,CAAC,KAAK,GAAG;EACf,MAAM,kBAAkB,MAAM,KAAK,gBAAgB,KAAK,KAAK;AAC7D,SAAO;CACR;AACF"}
@@ -0,0 +1,345 @@
1
+
2
+ //#region src/profiles.ts
3
+ const PROFILES = {
4
+ "gemini-embedding-001": {
5
+ maxInputTokens: 2048,
6
+ imageInputs: false,
7
+ audioInputs: false,
8
+ pdfInputs: false,
9
+ videoInputs: false,
10
+ maxOutputTokens: 3072,
11
+ reasoningOutput: false,
12
+ imageOutputs: false,
13
+ audioOutputs: false,
14
+ videoOutputs: false,
15
+ toolCalling: false,
16
+ structuredOutput: false
17
+ },
18
+ "gemini-2.5-flash-image": {
19
+ maxInputTokens: 32768,
20
+ imageInputs: true,
21
+ audioInputs: false,
22
+ pdfInputs: false,
23
+ videoInputs: false,
24
+ maxOutputTokens: 32768,
25
+ reasoningOutput: true,
26
+ imageOutputs: true,
27
+ audioOutputs: false,
28
+ videoOutputs: false,
29
+ toolCalling: false,
30
+ structuredOutput: false
31
+ },
32
+ "gemini-2.5-flash-preview-05-20": {
33
+ maxInputTokens: 1048576,
34
+ imageInputs: true,
35
+ audioInputs: true,
36
+ pdfInputs: true,
37
+ videoInputs: true,
38
+ maxOutputTokens: 65536,
39
+ reasoningOutput: true,
40
+ imageOutputs: false,
41
+ audioOutputs: false,
42
+ videoOutputs: false,
43
+ toolCalling: true,
44
+ structuredOutput: true
45
+ },
46
+ "gemini-flash-lite-latest": {
47
+ maxInputTokens: 1048576,
48
+ imageInputs: true,
49
+ audioInputs: true,
50
+ pdfInputs: true,
51
+ videoInputs: true,
52
+ maxOutputTokens: 65536,
53
+ reasoningOutput: true,
54
+ imageOutputs: false,
55
+ audioOutputs: false,
56
+ videoOutputs: false,
57
+ toolCalling: true,
58
+ structuredOutput: true
59
+ },
60
+ "gemini-2.5-flash": {
61
+ maxInputTokens: 1048576,
62
+ imageInputs: true,
63
+ audioInputs: true,
64
+ pdfInputs: true,
65
+ videoInputs: true,
66
+ maxOutputTokens: 65536,
67
+ reasoningOutput: true,
68
+ imageOutputs: false,
69
+ audioOutputs: false,
70
+ videoOutputs: false,
71
+ toolCalling: true,
72
+ structuredOutput: true
73
+ },
74
+ "gemini-flash-latest": {
75
+ maxInputTokens: 1048576,
76
+ imageInputs: true,
77
+ audioInputs: true,
78
+ pdfInputs: true,
79
+ videoInputs: true,
80
+ maxOutputTokens: 65536,
81
+ reasoningOutput: true,
82
+ imageOutputs: false,
83
+ audioOutputs: false,
84
+ videoOutputs: false,
85
+ toolCalling: true,
86
+ structuredOutput: true
87
+ },
88
+ "gemini-2.5-pro-preview-05-06": {
89
+ maxInputTokens: 1048576,
90
+ imageInputs: true,
91
+ audioInputs: true,
92
+ pdfInputs: true,
93
+ videoInputs: true,
94
+ maxOutputTokens: 65536,
95
+ reasoningOutput: true,
96
+ imageOutputs: false,
97
+ audioOutputs: false,
98
+ videoOutputs: false,
99
+ toolCalling: true,
100
+ structuredOutput: true
101
+ },
102
+ "gemini-2.5-flash-preview-tts": {
103
+ maxInputTokens: 8e3,
104
+ imageInputs: false,
105
+ audioInputs: false,
106
+ pdfInputs: false,
107
+ videoInputs: false,
108
+ maxOutputTokens: 16e3,
109
+ reasoningOutput: false,
110
+ imageOutputs: false,
111
+ audioOutputs: true,
112
+ videoOutputs: false,
113
+ toolCalling: false,
114
+ structuredOutput: false
115
+ },
116
+ "gemini-2.0-flash-lite": {
117
+ maxInputTokens: 1048576,
118
+ imageInputs: true,
119
+ audioInputs: true,
120
+ pdfInputs: true,
121
+ videoInputs: true,
122
+ maxOutputTokens: 8192,
123
+ reasoningOutput: false,
124
+ imageOutputs: false,
125
+ audioOutputs: false,
126
+ videoOutputs: false,
127
+ toolCalling: true,
128
+ structuredOutput: true
129
+ },
130
+ "gemini-live-2.5-flash-preview-native-audio": {
131
+ maxInputTokens: 131072,
132
+ imageInputs: false,
133
+ audioInputs: true,
134
+ pdfInputs: false,
135
+ videoInputs: true,
136
+ maxOutputTokens: 65536,
137
+ reasoningOutput: true,
138
+ imageOutputs: false,
139
+ audioOutputs: true,
140
+ videoOutputs: false,
141
+ toolCalling: true,
142
+ structuredOutput: false
143
+ },
144
+ "gemini-2.0-flash": {
145
+ maxInputTokens: 1048576,
146
+ imageInputs: true,
147
+ audioInputs: true,
148
+ pdfInputs: true,
149
+ videoInputs: true,
150
+ maxOutputTokens: 8192,
151
+ reasoningOutput: false,
152
+ imageOutputs: false,
153
+ audioOutputs: false,
154
+ videoOutputs: false,
155
+ toolCalling: true,
156
+ structuredOutput: true
157
+ },
158
+ "gemini-2.5-flash-lite": {
159
+ maxInputTokens: 1048576,
160
+ imageInputs: true,
161
+ audioInputs: true,
162
+ pdfInputs: true,
163
+ videoInputs: true,
164
+ maxOutputTokens: 65536,
165
+ reasoningOutput: true,
166
+ imageOutputs: false,
167
+ audioOutputs: false,
168
+ videoOutputs: false,
169
+ toolCalling: true,
170
+ structuredOutput: true
171
+ },
172
+ "gemini-2.5-pro-preview-06-05": {
173
+ maxInputTokens: 1048576,
174
+ imageInputs: true,
175
+ audioInputs: true,
176
+ pdfInputs: true,
177
+ videoInputs: true,
178
+ maxOutputTokens: 65536,
179
+ reasoningOutput: true,
180
+ imageOutputs: false,
181
+ audioOutputs: false,
182
+ videoOutputs: false,
183
+ toolCalling: true,
184
+ structuredOutput: true
185
+ },
186
+ "gemini-live-2.5-flash": {
187
+ maxInputTokens: 128e3,
188
+ imageInputs: true,
189
+ audioInputs: true,
190
+ pdfInputs: false,
191
+ videoInputs: true,
192
+ maxOutputTokens: 8e3,
193
+ reasoningOutput: true,
194
+ imageOutputs: false,
195
+ audioOutputs: true,
196
+ videoOutputs: false,
197
+ toolCalling: true,
198
+ structuredOutput: false
199
+ },
200
+ "gemini-2.5-flash-lite-preview-06-17": {
201
+ maxInputTokens: 1048576,
202
+ imageInputs: true,
203
+ audioInputs: true,
204
+ pdfInputs: true,
205
+ videoInputs: true,
206
+ maxOutputTokens: 65536,
207
+ reasoningOutput: true,
208
+ imageOutputs: false,
209
+ audioOutputs: false,
210
+ videoOutputs: false,
211
+ toolCalling: true,
212
+ structuredOutput: false
213
+ },
214
+ "gemini-2.5-flash-image-preview": {
215
+ maxInputTokens: 32768,
216
+ imageInputs: true,
217
+ audioInputs: false,
218
+ pdfInputs: false,
219
+ videoInputs: false,
220
+ maxOutputTokens: 32768,
221
+ reasoningOutput: true,
222
+ imageOutputs: true,
223
+ audioOutputs: false,
224
+ videoOutputs: false,
225
+ toolCalling: false,
226
+ structuredOutput: false
227
+ },
228
+ "gemini-2.5-flash-preview-09-2025": {
229
+ maxInputTokens: 1048576,
230
+ imageInputs: true,
231
+ audioInputs: true,
232
+ pdfInputs: true,
233
+ videoInputs: true,
234
+ maxOutputTokens: 65536,
235
+ reasoningOutput: true,
236
+ imageOutputs: false,
237
+ audioOutputs: false,
238
+ videoOutputs: false,
239
+ toolCalling: true,
240
+ structuredOutput: true
241
+ },
242
+ "gemini-2.5-flash-preview-04-17": {
243
+ maxInputTokens: 1048576,
244
+ imageInputs: true,
245
+ audioInputs: true,
246
+ pdfInputs: true,
247
+ videoInputs: true,
248
+ maxOutputTokens: 65536,
249
+ reasoningOutput: true,
250
+ imageOutputs: false,
251
+ audioOutputs: false,
252
+ videoOutputs: false,
253
+ toolCalling: true,
254
+ structuredOutput: false
255
+ },
256
+ "gemini-2.5-pro-preview-tts": {
257
+ maxInputTokens: 8e3,
258
+ imageInputs: false,
259
+ audioInputs: false,
260
+ pdfInputs: false,
261
+ videoInputs: false,
262
+ maxOutputTokens: 16e3,
263
+ reasoningOutput: false,
264
+ imageOutputs: false,
265
+ audioOutputs: true,
266
+ videoOutputs: false,
267
+ toolCalling: false,
268
+ structuredOutput: false
269
+ },
270
+ "gemini-2.5-pro": {
271
+ maxInputTokens: 1048576,
272
+ imageInputs: true,
273
+ audioInputs: true,
274
+ pdfInputs: true,
275
+ videoInputs: true,
276
+ maxOutputTokens: 65536,
277
+ reasoningOutput: true,
278
+ imageOutputs: false,
279
+ audioOutputs: false,
280
+ videoOutputs: false,
281
+ toolCalling: true,
282
+ structuredOutput: true
283
+ },
284
+ "gemini-1.5-flash": {
285
+ maxInputTokens: 1e6,
286
+ imageInputs: true,
287
+ audioInputs: true,
288
+ pdfInputs: false,
289
+ videoInputs: true,
290
+ maxOutputTokens: 8192,
291
+ reasoningOutput: false,
292
+ imageOutputs: false,
293
+ audioOutputs: false,
294
+ videoOutputs: false,
295
+ toolCalling: true,
296
+ structuredOutput: false
297
+ },
298
+ "gemini-1.5-flash-8b": {
299
+ maxInputTokens: 1e6,
300
+ imageInputs: true,
301
+ audioInputs: true,
302
+ pdfInputs: false,
303
+ videoInputs: true,
304
+ maxOutputTokens: 8192,
305
+ reasoningOutput: false,
306
+ imageOutputs: false,
307
+ audioOutputs: false,
308
+ videoOutputs: false,
309
+ toolCalling: true,
310
+ structuredOutput: false
311
+ },
312
+ "gemini-2.5-flash-lite-preview-09-2025": {
313
+ maxInputTokens: 1048576,
314
+ imageInputs: true,
315
+ audioInputs: true,
316
+ pdfInputs: true,
317
+ videoInputs: true,
318
+ maxOutputTokens: 65536,
319
+ reasoningOutput: true,
320
+ imageOutputs: false,
321
+ audioOutputs: false,
322
+ videoOutputs: false,
323
+ toolCalling: true,
324
+ structuredOutput: true
325
+ },
326
+ "gemini-1.5-pro": {
327
+ maxInputTokens: 1e6,
328
+ imageInputs: true,
329
+ audioInputs: true,
330
+ pdfInputs: false,
331
+ videoInputs: true,
332
+ maxOutputTokens: 8192,
333
+ reasoningOutput: false,
334
+ imageOutputs: false,
335
+ audioOutputs: false,
336
+ videoOutputs: false,
337
+ toolCalling: true,
338
+ structuredOutput: false
339
+ }
340
+ };
341
+ var profiles_default = PROFILES;
342
+
343
+ //#endregion
344
+ exports.default = profiles_default;
345
+ //# sourceMappingURL=profiles.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"profiles.cjs","names":["PROFILES: Record<string, ModelProfile>"],"sources":["../src/profiles.ts"],"sourcesContent":["/**\n * This file was automatically generated by an automated script. Do not edit manually.\n */\nimport type { ModelProfile } from \"@langchain/core/language_models/profile\";\nconst PROFILES: Record<string, ModelProfile> = {\n \"gemini-embedding-001\": {\n maxInputTokens: 2048,\n imageInputs: false,\n audioInputs: false,\n pdfInputs: false,\n videoInputs: false,\n maxOutputTokens: 3072,\n reasoningOutput: false,\n imageOutputs: false,\n audioOutputs: false,\n videoOutputs: false,\n toolCalling: false,\n structuredOutput: false,\n },\n \"gemini-2.5-flash-image\": {\n maxInputTokens: 32768,\n imageInputs: true,\n audioInputs: false,\n pdfInputs: false,\n videoInputs: false,\n maxOutputTokens: 32768,\n reasoningOutput: true,\n imageOutputs: true,\n audioOutputs: false,\n videoOutputs: false,\n toolCalling: false,\n structuredOutput: false,\n },\n \"gemini-2.5-flash-preview-05-20\": {\n maxInputTokens: 1048576,\n imageInputs: true,\n audioInputs: true,\n pdfInputs: true,\n videoInputs: true,\n maxOutputTokens: 65536,\n reasoningOutput: true,\n imageOutputs: false,\n audioOutputs: false,\n videoOutputs: false,\n toolCalling: true,\n structuredOutput: true,\n },\n \"gemini-flash-lite-latest\": {\n maxInputTokens: 1048576,\n imageInputs: true,\n audioInputs: true,\n pdfInputs: true,\n videoInputs: true,\n maxOutputTokens: 65536,\n reasoningOutput: true,\n imageOutputs: false,\n audioOutputs: false,\n videoOutputs: false,\n toolCalling: true,\n structuredOutput: true,\n },\n \"gemini-2.5-flash\": {\n maxInputTokens: 1048576,\n imageInputs: true,\n audioInputs: true,\n pdfInputs: true,\n videoInputs: true,\n maxOutputTokens: 65536,\n reasoningOutput: true,\n imageOutputs: false,\n audioOutputs: false,\n videoOutputs: false,\n toolCalling: true,\n structuredOutput: true,\n },\n \"gemini-flash-latest\": {\n maxInputTokens: 1048576,\n imageInputs: true,\n audioInputs: true,\n pdfInputs: true,\n videoInputs: true,\n maxOutputTokens: 65536,\n reasoningOutput: true,\n imageOutputs: false,\n audioOutputs: false,\n videoOutputs: false,\n toolCalling: true,\n structuredOutput: true,\n },\n \"gemini-2.5-pro-preview-05-06\": {\n maxInputTokens: 1048576,\n imageInputs: true,\n audioInputs: true,\n pdfInputs: true,\n videoInputs: true,\n maxOutputTokens: 65536,\n reasoningOutput: true,\n imageOutputs: false,\n audioOutputs: false,\n videoOutputs: false,\n toolCalling: true,\n structuredOutput: true,\n },\n \"gemini-2.5-flash-preview-tts\": {\n maxInputTokens: 8000,\n imageInputs: false,\n audioInputs: false,\n pdfInputs: false,\n videoInputs: false,\n maxOutputTokens: 16000,\n reasoningOutput: false,\n imageOutputs: false,\n audioOutputs: true,\n videoOutputs: false,\n toolCalling: false,\n structuredOutput: false,\n },\n \"gemini-2.0-flash-lite\": {\n maxInputTokens: 1048576,\n imageInputs: true,\n audioInputs: true,\n pdfInputs: true,\n videoInputs: true,\n maxOutputTokens: 8192,\n reasoningOutput: false,\n imageOutputs: false,\n audioOutputs: false,\n videoOutputs: false,\n toolCalling: true,\n structuredOutput: true,\n },\n \"gemini-live-2.5-flash-preview-native-audio\": {\n maxInputTokens: 131072,\n imageInputs: false,\n audioInputs: true,\n pdfInputs: false,\n videoInputs: true,\n maxOutputTokens: 65536,\n reasoningOutput: true,\n imageOutputs: false,\n audioOutputs: true,\n videoOutputs: false,\n toolCalling: true,\n structuredOutput: false,\n },\n \"gemini-2.0-flash\": {\n maxInputTokens: 1048576,\n imageInputs: true,\n audioInputs: true,\n pdfInputs: true,\n videoInputs: true,\n maxOutputTokens: 8192,\n reasoningOutput: false,\n imageOutputs: false,\n audioOutputs: false,\n videoOutputs: false,\n toolCalling: true,\n structuredOutput: true,\n },\n \"gemini-2.5-flash-lite\": {\n maxInputTokens: 1048576,\n imageInputs: true,\n audioInputs: true,\n pdfInputs: true,\n videoInputs: true,\n maxOutputTokens: 65536,\n reasoningOutput: true,\n imageOutputs: false,\n audioOutputs: false,\n videoOutputs: false,\n toolCalling: true,\n structuredOutput: true,\n },\n \"gemini-2.5-pro-preview-06-05\": {\n maxInputTokens: 1048576,\n imageInputs: true,\n audioInputs: true,\n pdfInputs: true,\n videoInputs: true,\n maxOutputTokens: 65536,\n reasoningOutput: true,\n imageOutputs: false,\n audioOutputs: false,\n videoOutputs: false,\n toolCalling: true,\n structuredOutput: true,\n },\n \"gemini-live-2.5-flash\": {\n maxInputTokens: 128000,\n imageInputs: true,\n audioInputs: true,\n pdfInputs: false,\n videoInputs: true,\n maxOutputTokens: 8000,\n reasoningOutput: true,\n imageOutputs: false,\n audioOutputs: true,\n videoOutputs: false,\n toolCalling: true,\n structuredOutput: false,\n },\n \"gemini-2.5-flash-lite-preview-06-17\": {\n maxInputTokens: 1048576,\n imageInputs: true,\n audioInputs: true,\n pdfInputs: true,\n videoInputs: true,\n maxOutputTokens: 65536,\n reasoningOutput: true,\n imageOutputs: false,\n audioOutputs: false,\n videoOutputs: false,\n toolCalling: true,\n structuredOutput: false,\n },\n \"gemini-2.5-flash-image-preview\": {\n maxInputTokens: 32768,\n imageInputs: true,\n audioInputs: false,\n pdfInputs: false,\n videoInputs: false,\n maxOutputTokens: 32768,\n reasoningOutput: true,\n imageOutputs: true,\n audioOutputs: false,\n videoOutputs: false,\n toolCalling: false,\n structuredOutput: false,\n },\n \"gemini-2.5-flash-preview-09-2025\": {\n maxInputTokens: 1048576,\n imageInputs: true,\n audioInputs: true,\n pdfInputs: true,\n videoInputs: true,\n maxOutputTokens: 65536,\n reasoningOutput: true,\n imageOutputs: false,\n audioOutputs: false,\n videoOutputs: false,\n toolCalling: true,\n structuredOutput: true,\n },\n \"gemini-2.5-flash-preview-04-17\": {\n maxInputTokens: 1048576,\n imageInputs: true,\n audioInputs: true,\n pdfInputs: true,\n videoInputs: true,\n maxOutputTokens: 65536,\n reasoningOutput: true,\n imageOutputs: false,\n audioOutputs: false,\n videoOutputs: false,\n toolCalling: true,\n structuredOutput: false,\n },\n \"gemini-2.5-pro-preview-tts\": {\n maxInputTokens: 8000,\n imageInputs: false,\n audioInputs: false,\n pdfInputs: false,\n videoInputs: false,\n maxOutputTokens: 16000,\n reasoningOutput: false,\n imageOutputs: false,\n audioOutputs: true,\n videoOutputs: false,\n toolCalling: false,\n structuredOutput: false,\n },\n \"gemini-2.5-pro\": {\n maxInputTokens: 1048576,\n imageInputs: true,\n audioInputs: true,\n pdfInputs: true,\n videoInputs: true,\n maxOutputTokens: 65536,\n reasoningOutput: true,\n imageOutputs: false,\n audioOutputs: false,\n videoOutputs: false,\n toolCalling: true,\n structuredOutput: true,\n },\n \"gemini-1.5-flash\": {\n maxInputTokens: 1000000,\n imageInputs: true,\n audioInputs: true,\n pdfInputs: false,\n videoInputs: true,\n maxOutputTokens: 8192,\n reasoningOutput: false,\n imageOutputs: false,\n audioOutputs: false,\n videoOutputs: false,\n toolCalling: true,\n structuredOutput: false,\n },\n \"gemini-1.5-flash-8b\": {\n maxInputTokens: 1000000,\n imageInputs: true,\n audioInputs: true,\n pdfInputs: false,\n videoInputs: true,\n maxOutputTokens: 8192,\n reasoningOutput: false,\n imageOutputs: false,\n audioOutputs: false,\n videoOutputs: false,\n toolCalling: true,\n structuredOutput: false,\n },\n \"gemini-2.5-flash-lite-preview-09-2025\": {\n maxInputTokens: 1048576,\n imageInputs: true,\n audioInputs: true,\n pdfInputs: true,\n videoInputs: true,\n maxOutputTokens: 65536,\n reasoningOutput: true,\n imageOutputs: false,\n audioOutputs: false,\n videoOutputs: false,\n toolCalling: true,\n structuredOutput: true,\n },\n \"gemini-1.5-pro\": {\n maxInputTokens: 1000000,\n imageInputs: true,\n audioInputs: true,\n pdfInputs: false,\n videoInputs: true,\n maxOutputTokens: 8192,\n reasoningOutput: false,\n imageOutputs: false,\n audioOutputs: false,\n videoOutputs: false,\n toolCalling: true,\n structuredOutput: false,\n },\n};\nexport default PROFILES;\n"],"mappings":";;AAIA,MAAMA,WAAyC;CAC7C,wBAAwB;EACtB,gBAAgB;EAChB,aAAa;EACb,aAAa;EACb,WAAW;EACX,aAAa;EACb,iBAAiB;EACjB,iBAAiB;EACjB,cAAc;EACd,cAAc;EACd,cAAc;EACd,aAAa;EACb,kBAAkB;CACnB;CACD,0BAA0B;EACxB,gBAAgB;EAChB,aAAa;EACb,aAAa;EACb,WAAW;EACX,aAAa;EACb,iBAAiB;EACjB,iBAAiB;EACjB,cAAc;EACd,cAAc;EACd,cAAc;EACd,aAAa;EACb,kBAAkB;CACnB;CACD,kCAAkC;EAChC,gBAAgB;EAChB,aAAa;EACb,aAAa;EACb,WAAW;EACX,aAAa;EACb,iBAAiB;EACjB,iBAAiB;EACjB,cAAc;EACd,cAAc;EACd,cAAc;EACd,aAAa;EACb,kBAAkB;CACnB;CACD,4BAA4B;EAC1B,gBAAgB;EAChB,aAAa;EACb,aAAa;EACb,WAAW;EACX,aAAa;EACb,iBAAiB;EACjB,iBAAiB;EACjB,cAAc;EACd,cAAc;EACd,cAAc;EACd,aAAa;EACb,kBAAkB;CACnB;CACD,oBAAoB;EAClB,gBAAgB;EAChB,aAAa;EACb,aAAa;EACb,WAAW;EACX,aAAa;EACb,iBAAiB;EACjB,iBAAiB;EACjB,cAAc;EACd,cAAc;EACd,cAAc;EACd,aAAa;EACb,kBAAkB;CACnB;CACD,uBAAuB;EACrB,gBAAgB;EAChB,aAAa;EACb,aAAa;EACb,WAAW;EACX,aAAa;EACb,iBAAiB;EACjB,iBAAiB;EACjB,cAAc;EACd,cAAc;EACd,cAAc;EACd,aAAa;EACb,kBAAkB;CACnB;CACD,gCAAgC;EAC9B,gBAAgB;EAChB,aAAa;EACb,aAAa;EACb,WAAW;EACX,aAAa;EACb,iBAAiB;EACjB,iBAAiB;EACjB,cAAc;EACd,cAAc;EACd,cAAc;EACd,aAAa;EACb,kBAAkB;CACnB;CACD,gCAAgC;EAC9B,gBAAgB;EAChB,aAAa;EACb,aAAa;EACb,WAAW;EACX,aAAa;EACb,iBAAiB;EACjB,iBAAiB;EACjB,cAAc;EACd,cAAc;EACd,cAAc;EACd,aAAa;EACb,kBAAkB;CACnB;CACD,yBAAyB;EACvB,gBAAgB;EAChB,aAAa;EACb,aAAa;EACb,WAAW;EACX,aAAa;EACb,iBAAiB;EACjB,iBAAiB;EACjB,cAAc;EACd,cAAc;EACd,cAAc;EACd,aAAa;EACb,kBAAkB;CACnB;CACD,8CAA8C;EAC5C,gBAAgB;EAChB,aAAa;EACb,aAAa;EACb,WAAW;EACX,aAAa;EACb,iBAAiB;EACjB,iBAAiB;EACjB,cAAc;EACd,cAAc;EACd,cAAc;EACd,aAAa;EACb,kBAAkB;CACnB;CACD,oBAAoB;EAClB,gBAAgB;EAChB,aAAa;EACb,aAAa;EACb,WAAW;EACX,aAAa;EACb,iBAAiB;EACjB,iBAAiB;EACjB,cAAc;EACd,cAAc;EACd,cAAc;EACd,aAAa;EACb,kBAAkB;CACnB;CACD,yBAAyB;EACvB,gBAAgB;EAChB,aAAa;EACb,aAAa;EACb,WAAW;EACX,aAAa;EACb,iBAAiB;EACjB,iBAAiB;EACjB,cAAc;EACd,cAAc;EACd,cAAc;EACd,aAAa;EACb,kBAAkB;CACnB;CACD,gCAAgC;EAC9B,gBAAgB;EAChB,aAAa;EACb,aAAa;EACb,WAAW;EACX,aAAa;EACb,iBAAiB;EACjB,iBAAiB;EACjB,cAAc;EACd,cAAc;EACd,cAAc;EACd,aAAa;EACb,kBAAkB;CACnB;CACD,yBAAyB;EACvB,gBAAgB;EAChB,aAAa;EACb,aAAa;EACb,WAAW;EACX,aAAa;EACb,iBAAiB;EACjB,iBAAiB;EACjB,cAAc;EACd,cAAc;EACd,cAAc;EACd,aAAa;EACb,kBAAkB;CACnB;CACD,uCAAuC;EACrC,gBAAgB;EAChB,aAAa;EACb,aAAa;EACb,WAAW;EACX,aAAa;EACb,iBAAiB;EACjB,iBAAiB;EACjB,cAAc;EACd,cAAc;EACd,cAAc;EACd,aAAa;EACb,kBAAkB;CACnB;CACD,kCAAkC;EAChC,gBAAgB;EAChB,aAAa;EACb,aAAa;EACb,WAAW;EACX,aAAa;EACb,iBAAiB;EACjB,iBAAiB;EACjB,cAAc;EACd,cAAc;EACd,cAAc;EACd,aAAa;EACb,kBAAkB;CACnB;CACD,oCAAoC;EAClC,gBAAgB;EAChB,aAAa;EACb,aAAa;EACb,WAAW;EACX,aAAa;EACb,iBAAiB;EACjB,iBAAiB;EACjB,cAAc;EACd,cAAc;EACd,cAAc;EACd,aAAa;EACb,kBAAkB;CACnB;CACD,kCAAkC;EAChC,gBAAgB;EAChB,aAAa;EACb,aAAa;EACb,WAAW;EACX,aAAa;EACb,iBAAiB;EACjB,iBAAiB;EACjB,cAAc;EACd,cAAc;EACd,cAAc;EACd,aAAa;EACb,kBAAkB;CACnB;CACD,8BAA8B;EAC5B,gBAAgB;EAChB,aAAa;EACb,aAAa;EACb,WAAW;EACX,aAAa;EACb,iBAAiB;EACjB,iBAAiB;EACjB,cAAc;EACd,cAAc;EACd,cAAc;EACd,aAAa;EACb,kBAAkB;CACnB;CACD,kBAAkB;EAChB,gBAAgB;EAChB,aAAa;EACb,aAAa;EACb,WAAW;EACX,aAAa;EACb,iBAAiB;EACjB,iBAAiB;EACjB,cAAc;EACd,cAAc;EACd,cAAc;EACd,aAAa;EACb,kBAAkB;CACnB;CACD,oBAAoB;EAClB,gBAAgB;EAChB,aAAa;EACb,aAAa;EACb,WAAW;EACX,aAAa;EACb,iBAAiB;EACjB,iBAAiB;EACjB,cAAc;EACd,cAAc;EACd,cAAc;EACd,aAAa;EACb,kBAAkB;CACnB;CACD,uBAAuB;EACrB,gBAAgB;EAChB,aAAa;EACb,aAAa;EACb,WAAW;EACX,aAAa;EACb,iBAAiB;EACjB,iBAAiB;EACjB,cAAc;EACd,cAAc;EACd,cAAc;EACd,aAAa;EACb,kBAAkB;CACnB;CACD,yCAAyC;EACvC,gBAAgB;EAChB,aAAa;EACb,aAAa;EACb,WAAW;EACX,aAAa;EACb,iBAAiB;EACjB,iBAAiB;EACjB,cAAc;EACd,cAAc;EACd,cAAc;EACd,aAAa;EACb,kBAAkB;CACnB;CACD,kBAAkB;EAChB,gBAAgB;EAChB,aAAa;EACb,aAAa;EACb,WAAW;EACX,aAAa;EACb,iBAAiB;EACjB,iBAAiB;EACjB,cAAc;EACd,cAAc;EACd,cAAc;EACd,aAAa;EACb,kBAAkB;CACnB;AACF;AACD,uBAAe"}