forked from SciSharp/BotSharp
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathBotSharpStatsDelta.cs
More file actions
40 lines (35 loc) · 1.02 KB
/
BotSharpStatsDelta.cs
File metadata and controls
40 lines (35 loc) · 1.02 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
using BotSharp.Abstraction.Statistics.Enums;
namespace BotSharp.Abstraction.Statistics.Models;
public class BotSharpStatsDelta
{
public string AgentId { get; set; } = null!;
public StatsCountDelta CountDelta { get; set; } = new();
public StatsLlmCostDelta LlmCostDelta { get; set; } = new();
public DateTime RecordTime { get; set; } = DateTime.UtcNow;
public StatsInterval IntervalType { get; set; } = StatsInterval.Day;
public string Interval
{
get
{
return IntervalType.ToString();
}
set
{
if (Enum.TryParse(value, out StatsInterval type))
{
IntervalType = type;
}
}
}
}
public class StatsCountDelta
{
public int AgentCallCountDelta { get; set; }
}
public class StatsLlmCostDelta
{
public int PromptTokensDelta { get; set; }
public int CompletionTokensDelta { get; set; }
public float PromptTotalCostDelta { get; set; }
public float CompletionTotalCostDelta { get; set; }
}