mirror of
https://github.com/langchain-ai/langgraph.git
synced 2026-09-12 12:47:53 +02:00
Simplify types for additional kwargs
This commit is contained in:
@@ -8,19 +8,10 @@ type MessageContentText = { type: "text"; text: string };
|
||||
type MessageContentComplex = MessageContentText | MessageContentImageUrl;
|
||||
type MessageContent = string | MessageContentComplex[];
|
||||
|
||||
type MessageAdditionalKwargs = {
|
||||
[x: string]: unknown;
|
||||
|
||||
function_call?: { arguments: string; name: string } | undefined;
|
||||
tool_calls?:
|
||||
| {
|
||||
id: string;
|
||||
function: { arguments: string; name: string };
|
||||
type: "function";
|
||||
index?: number | undefined;
|
||||
}[]
|
||||
| undefined;
|
||||
};
|
||||
/**
|
||||
* Model-specific additional kwargs, which is passed back to the underlying LLM.
|
||||
*/
|
||||
type MessageAdditionalKwargs = Record<string, unknown>;
|
||||
|
||||
export type HumanMessage = {
|
||||
type: "human";
|
||||
|
||||
Reference in New Issue
Block a user