Agents 0.0.2
Edge AI Agents SDK
Loading...
Searching...
No Matches
agents::tools::SummarizationTool Class Reference

Summarization tool that provides text summarization capabilities using LLM. More...

#include <summarization_tool.h>

Inheritance diagram for agents::tools::SummarizationTool:
agents::Tool

Public Member Functions

 SummarizationTool (std::shared_ptr< AgentContext > context)
 Construct a new Summarization Tool object.
 
ToolResult execute (const JsonObject &params) const override
 Execute the summarization tool.
 
const StringgetName () const
 Get the name of the tool.
 
const StringgetDescription () const
 Get the description of the tool.
 
const ParameterMapgetParameters () const
 Get the parameters of the tool.
 
const JsonObjectgetSchema () const
 Get the schema of the tool.
 
void addParameter (const Parameter &param)
 Add a parameter to the tool.
 
void setCallback (ToolCallback callback)
 Set the execution callback.
 
bool validateParameters (const JsonObject &params) const
 Validate parameters against schema.
 

Detailed Description

Summarization tool that provides text summarization capabilities using LLM.

Constructor & Destructor Documentation

◆ SummarizationTool()

agents::tools::SummarizationTool::SummarizationTool ( std::shared_ptr< AgentContext > context)
explicit

Construct a new Summarization Tool object.

Parameters
contextThe agent context containing the LLM

Member Function Documentation

◆ addParameter()

void agents::Tool::addParameter ( const Parameter & param)
inherited

Add a parameter to the tool.

Parameters
paramThe parameter to add

◆ execute()

ToolResult agents::tools::SummarizationTool::execute ( const JsonObject & params) const
overridevirtual

Execute the summarization tool.

Parameters
paramsThe parameters for the summarization tool
Returns
ToolResult The result of the summarization tool

Reimplemented from agents::Tool.

◆ getDescription()

const String & agents::Tool::getDescription ( ) const
inherited

Get the description of the tool.

Returns
The description of the tool

◆ getName()

const String & agents::Tool::getName ( ) const
inherited

Get the name of the tool.

Returns
The name of the tool

◆ getParameters()

const ParameterMap & agents::Tool::getParameters ( ) const
inherited

Get the parameters of the tool.

Returns
The parameters of the tool

◆ getSchema()

const JsonObject & agents::Tool::getSchema ( ) const
inherited

Get the schema of the tool.

Returns
The schema of the tool

◆ setCallback()

void agents::Tool::setCallback ( ToolCallback callback)
inherited

Set the execution callback.

Parameters
callbackThe callback to set

◆ validateParameters()

bool agents::Tool::validateParameters ( const JsonObject & params) const
inherited

Validate parameters against schema.

Parameters
paramsThe parameters to validate
Returns
true of valid, otherwise false