@langchain/google-common
Advanced tools
Comparing version 0.1.4 to 0.1.5
@@ -355,2 +355,3 @@ import { getEnvironmentVariable } from "@langchain/core/utils/env"; | ||
tools, | ||
tool_choice: functionName, | ||
}); | ||
@@ -357,0 +358,0 @@ if (!includeRaw) { |
@@ -19,2 +19,6 @@ import { Embeddings } from "@langchain/core/embeddings"; | ||
} | ||
get modelPublisher() { | ||
// All the embedding models are currently published by "google" | ||
return "google"; | ||
} | ||
async formatData(input, parameters) { | ||
@@ -21,0 +25,0 @@ return { |
@@ -806,6 +806,15 @@ import { v4 as uuidv4 } from "uuid"; | ||
} | ||
if (["auto", "any", "none"].includes(parameters.tool_choice)) { | ||
return { | ||
functionCallingConfig: { | ||
mode: parameters.tool_choice, | ||
allowedFunctionNames: parameters.allowed_function_names, | ||
}, | ||
}; | ||
} | ||
// force tool choice to be a single function name in case of structured output | ||
return { | ||
functionCallingConfig: { | ||
mode: parameters.tool_choice, | ||
allowedFunctionNames: parameters.allowed_function_names, | ||
mode: "any", | ||
allowedFunctionNames: [parameters.tool_choice], | ||
}, | ||
@@ -812,0 +821,0 @@ }; |
{ | ||
"name": "@langchain/google-common", | ||
"version": "0.1.4", | ||
"version": "0.1.5", | ||
"description": "Core types and classes for Google services.", | ||
@@ -5,0 +5,0 @@ "type": "module", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
387406
10487