Socket
Socket
Sign inDemoInstall

@langchain/core

Package Overview
Dependencies
Maintainers
11
Versions
165
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@langchain/core - npm Package Compare versions

Comparing version 0.3.10 to 0.3.11

4

dist/context.d.ts

@@ -51,3 +51,3 @@ /**

*/
export declare function setContextVariable(name: PropertyKey, value: any): void;
export declare function setContextVariable<T>(name: PropertyKey, value: T): void;
/**

@@ -102,2 +102,2 @@ * Get the value of a previously set context variable. Context variables

*/
export declare function getContextVariable(name: PropertyKey): any;
export declare function getContextVariable<T = any>(name: PropertyKey): T | undefined;

@@ -300,5 +300,19 @@ import { z } from "zod";

`${fields.name} tool`,
// TS doesn't restrict the type here based on the guard above
// eslint-disable-next-line @typescript-eslint/no-explicit-any
func: func,
func: async (input, runManager, config) => {
return new Promise((resolve, reject) => {
const childConfig = patchConfig(config, {
callbacks: runManager?.getChild(),
});
void AsyncLocalStorageProviderSingleton.runWithConfig(childConfig, async () => {
try {
// TS doesn't restrict the type here based on the guard above
// eslint-disable-next-line @typescript-eslint/no-explicit-any
resolve(func(input, childConfig));
}
catch (e) {
reject(e);
}
});
});
},
});

@@ -305,0 +319,0 @@ }

{
"name": "@langchain/core",
"version": "0.3.10",
"version": "0.3.11",
"description": "Core LangChain.js abstractions and schemas",

@@ -71,3 +71,3 @@ "type": "module",

"typescript": "~5.1.6",
"web-streams-polyfill": "^3.3.3"
"web-streams-polyfill": "^4.0.0"
},

@@ -74,0 +74,0 @@ "publishConfig": {

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc