com.dingtalk.baymax.framework.sdk.mercury.plugin.BaseTool Maven / Gradle / Ivy
package com.dingtalk.baymax.framework.sdk.mercury.plugin;
import com.dingtalk.baymax.framework.sdk.mercury.domain.BaseModel;
/**
* LangEngine工具必须实现的接口
*
* @author xiaoxuan.lp
*/
public abstract class BaseTool extends BaseModel {
/**
* 明确传达其用途的工具的唯一名称
*/
private String name;
/**
* 用于告诉模型如何/何时/为何使用该工具
*/
private String description;
/**
* 是否直接返回工具的输出,将其设置为 true
*/
private boolean returnDirect;
private boolean verbose;
public abstract ToolExecuteResult run(ToolParam param);
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public String getDescription() {
return description;
}
public void setDescription(String description) {
this.description = description;
}
public boolean isReturnDirect() {
return returnDirect;
}
public void setReturnDirect(boolean returnDirect) {
this.returnDirect = returnDirect;
}
public boolean isVerbose() {
return verbose;
}
public void setVerbose(boolean verbose) {
this.verbose = verbose;
}
}