Preparing search index...
The search index is not available
@iqai/adk API Documentation
@iqai/adk API Documentation
Plugins
LangfusePlugin
Class LangfusePlugin
Hierarchy (
view full
)
BasePlugin
LangfusePlugin
Index
Constructors
constructor
Properties
name
Methods
to
Plain
Text
on
User
Message
Callback
before
Run
Callback
on
Event
Callback
after
Run
Callback
before
Agent
Callback
after
Agent
Callback
before
Model
Callback
after
Model
Callback
on
Model
Error
Callback
before
Tool
Callback
after
Tool
Callback
on
Tool
Error
Callback
flush
close
Constructors
constructor
new
Langfuse
Plugin
(
options
)
:
LangfusePlugin
Parameters
options
:
LangfusePluginOptions
Returns
LangfusePlugin
Properties
Readonly
name
name
:
string
Methods
to
Plain
Text
to
Plain
Text
(
data
)
:
string
Converts any data to plain text, handling various formats
Parameters
data
:
any
Returns
string
on
User
Message
Callback
on
User
Message
Callback
(
params
)
:
Promise
<
Content
>
Parameters
params
:
{
invocationContext
:
InvocationContext
;
userMessage
:
Content
;
}
invocation
Context
:
InvocationContext
user
Message
:
Content
Returns
Promise
<
Content
>
before
Run
Callback
before
Run
Callback
(
params
)
:
Promise
<
Event
>
Parameters
params
:
{
invocationContext
:
InvocationContext
;
}
invocation
Context
:
InvocationContext
Returns
Promise
<
Event
>
on
Event
Callback
on
Event
Callback
(
params
)
:
Promise
<
Event
>
Parameters
params
:
{
invocationContext
:
InvocationContext
;
event
:
Event
;
}
invocation
Context
:
InvocationContext
event
:
Event
Returns
Promise
<
Event
>
after
Run
Callback
after
Run
Callback
(
params
)
:
Promise
<
void
>
Parameters
params
:
{
invocationContext
:
InvocationContext
;
result
?:
any
;
}
invocation
Context
:
InvocationContext
Optional
result
?:
any
Returns
Promise
<
void
>
before
Agent
Callback
before
Agent
Callback
(
params
)
:
Promise
<
Content
>
Parameters
params
:
{
agent
:
BaseAgent
;
callbackContext
:
CallbackContext
;
}
agent
:
BaseAgent
callback
Context
:
CallbackContext
Returns
Promise
<
Content
>
after
Agent
Callback
after
Agent
Callback
(
params
)
:
Promise
<
Content
>
Parameters
params
:
{
agent
:
BaseAgent
;
callbackContext
:
CallbackContext
;
result
?:
any
;
}
agent
:
BaseAgent
callback
Context
:
CallbackContext
Optional
result
?:
any
Returns
Promise
<
Content
>
before
Model
Callback
before
Model
Callback
(
params
)
:
Promise
<
LlmResponse
>
Parameters
params
:
{
callbackContext
:
CallbackContext
;
llmRequest
:
LlmRequest
;
}
callback
Context
:
CallbackContext
llm
Request
:
LlmRequest
Returns
Promise
<
LlmResponse
>
after
Model
Callback
after
Model
Callback
(
params
)
:
Promise
<
LlmResponse
>
Parameters
params
:
{
callbackContext
:
CallbackContext
;
llmResponse
:
LlmResponse
;
llmRequest
?:
LlmRequest
;
}
callback
Context
:
CallbackContext
llm
Response
:
LlmResponse
Optional
llm
Request
?:
LlmRequest
Returns
Promise
<
LlmResponse
>
on
Model
Error
Callback
on
Model
Error
Callback
(
params
)
:
Promise
<
LlmResponse
>
Parameters
params
:
{
callbackContext
:
CallbackContext
;
llmRequest
:
LlmRequest
;
error
:
unknown
;
}
callback
Context
:
CallbackContext
llm
Request
:
LlmRequest
error
:
unknown
Returns
Promise
<
LlmResponse
>
before
Tool
Callback
before
Tool
Callback
(
params
)
:
Promise
<
Record
<
string
,
any
>
>
Parameters
params
:
{
tool
:
BaseTool
;
toolArgs
:
Record
<
string
,
any
>
;
toolContext
:
ToolContext
;
}
tool
:
BaseTool
tool
Args
:
Record
<
string
,
any
>
tool
Context
:
ToolContext
Returns
Promise
<
Record
<
string
,
any
>
>
after
Tool
Callback
after
Tool
Callback
(
params
)
:
Promise
<
Record
<
string
,
any
>
>
Parameters
params
:
{
tool
:
BaseTool
;
toolArgs
:
Record
<
string
,
any
>
;
toolContext
:
ToolContext
;
result
:
Record
<
string
,
any
>
;
}
tool
:
BaseTool
tool
Args
:
Record
<
string
,
any
>
tool
Context
:
ToolContext
result
:
Record
<
string
,
any
>
Returns
Promise
<
Record
<
string
,
any
>
>
on
Tool
Error
Callback
on
Tool
Error
Callback
(
params
)
:
Promise
<
Record
<
string
,
any
>
>
Parameters
params
:
{
tool
:
BaseTool
;
toolArgs
:
Record
<
string
,
any
>
;
toolContext
:
ToolContext
;
error
:
unknown
;
}
tool
:
BaseTool
tool
Args
:
Record
<
string
,
any
>
tool
Context
:
ToolContext
error
:
unknown
Returns
Promise
<
Record
<
string
,
any
>
>
flush
flush
(
)
:
Promise
<
void
>
Returns
Promise
<
void
>
close
close
(
)
:
Promise
<
void
>
Returns
Promise
<
void
>
Settings
Member Visibility
Protected
Inherited
Theme
OS
Light
Dark
On This Page
Constructors
constructor
Properties
name
Methods
to
Plain
Text
on
User
Message
Callback
before
Run
Callback
on
Event
Callback
after
Run
Callback
before
Agent
Callback
after
Agent
Callback
before
Model
Callback
after
Model
Callback
on
Model
Error
Callback
before
Tool
Callback
after
Tool
Callback
on
Tool
Error
Callback
flush
close
@iqai/adk API Documentation
Loading...
Converts any data to plain text, handling various formats