Bind lifecycle listeners to a Runnable, returning a new Runnable. The Run object contains information about the run, including its id, type, input, output, error, startTime, endTime, and any tags or metadata added to the run.
withListeners(
params: __type
): Runnable<StructuredToolCallInput<ZodObject<__type, "strip", ZodTypeAny, __type, __type>, __type>, any, RunnableConfig<Record<string, any>>>| Name | Type | Description |
|---|---|---|
params* | __type | The object containing the callback functions. |