2024-01-15 19:15:18 +00:00
|
|
|
using BotSharp.Abstraction.Evaluations.Settings;
|
|
|
|
|
using BotSharp.Abstraction.Evaluations;
|
|
|
|
|
using BotSharp.Abstraction.Settings;
|
|
|
|
|
using Microsoft.Extensions.Configuration;
|
2024-11-07 23:42:13 +00:00
|
|
|
using BotSharp.Core.Evaluations.Services;
|
2024-01-15 19:15:18 +00:00
|
|
|
|
|
|
|
|
namespace BotSharp.Core.Evaluations;
|
|
|
|
|
|
|
|
|
|
public class EvaluationPlugin : IBotSharpPlugin
|
|
|
|
|
{
|
|
|
|
|
public string Id => "0ae251a6-7e34-403e-a333-b365d8986068";
|
2024-01-16 19:23:45 +00:00
|
|
|
public string Name => "Agent Evaluation";
|
|
|
|
|
public string Description => "Evaluate the created Agent and review whether the user dialogue meets design expectations.";
|
2024-01-15 19:15:18 +00:00
|
|
|
|
|
|
|
|
public void RegisterDI(IServiceCollection services, IConfiguration config)
|
|
|
|
|
{
|
|
|
|
|
// Evaluation
|
|
|
|
|
services.AddScoped(provider =>
|
|
|
|
|
{
|
|
|
|
|
var settingService = provider.GetRequiredService<ISettingService>();
|
|
|
|
|
return settingService.Bind<EvaluatorSetting>("Evaluator");
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
services.AddScoped<IEvaluatingService, EvaluatingService>();
|
|
|
|
|
services.AddScoped<IExecutionLogger, ExecutionLogger>();
|
|
|
|
|
}
|
|
|
|
|
}
|