import { ... } from "langchain/browser";All matcher functions bundled for convenient use with expect.extend().
LangChain utilities
LangChain Testing Utilities
LangChain Messages
Initialize a ChatModel from the model name and provider. Must have the integration package corresponding to the model provider installed.
LangChain Tools
LangChain Messages
LangChain Messages
Represents a chunk of an AI message, which can be concatenated with other AI message chunks.
Base class for all types of messages in a conversation. It includes
properties like content, name, and additional_kwargs. It also
includes methods like toDict() and _getType().
Represents a chunk of a message, which can be concatenated with other
message chunks. It includes a method _merge_kwargs_dict() for merging
additional keyword arguments from another BaseMessageChunk into this
one. It also overrides the __add__() method to support concatenation
of BaseMessageChunk instances.
Interface for interacting with a document.
A tool that can be created dynamically from a function, name, and description, designed to work with structured data. It extends the StructuredTool class and overrides the _call method to execute the provided function when the tool is called.
Schema can be passed as Zod or JSON schema. The tool will not validate input if JSON schema is passed.
A tool that can be created dynamically from a function, name, and description.
Represents a human message in a conversation.
Represents a chunk of a human message, which can be concatenated with other human message chunks.
In-memory implementation of the BaseStore using a dictionary. Used for storing key-value pairs in memory.
Base class for Tools that accept input of any shape defined by a Zod schema.
Represents a system message in a conversation.
Represents a chunk of a system message, which can be concatenated with other system message chunks.
Base class for Tools that accept input as a string.
Represents a tool message in a conversation.
Represents a chunk of a tool message, which can be concatenated with other tool message chunks.
LangChain Messages
LangChain Documents
LangChain Testing Utilities