File tree 1 file changed +12
-1
lines changed
1 file changed +12
-1
lines changed Original file line number Diff line number Diff line change @@ -18,6 +18,15 @@ class RunEventType(Enum):
18
18
prompt = "prompt"
19
19
20
20
21
+ class ToolCategory (Enum ):
22
+ provider = "provider" ,
23
+ credential = "credential" ,
24
+ context = "context" ,
25
+ input = "input" ,
26
+ output = "output" ,
27
+ none = ""
28
+
29
+
21
30
class RunState (Enum ):
22
31
Creating = "creating" ,
23
32
Running = "running" ,
@@ -118,7 +127,7 @@ def __init__(self,
118
127
currentAgent : ToolReference = None ,
119
128
displayText : str = "" ,
120
129
inputContext : list [InputContext ] = None ,
121
- toolCategory : str = "" ,
130
+ toolCategory : ToolCategory = ToolCategory . none ,
122
131
toolName : str = "" ,
123
132
parentID : str = "" ,
124
133
type : RunEventType = RunEventType .event ,
@@ -148,6 +157,8 @@ def __init__(self,
148
157
if isinstance (self .inputContext [i ], dict ):
149
158
self .inputContext [i ] = InputContext (** self .inputContext [i ])
150
159
self .toolCategory = toolCategory
160
+ if isinstance (self .toolCategory , str ):
161
+ self .toolCategory = ToolCategory .none if self .toolCategory == "" else ToolCategory [self .toolCategory ]
151
162
self .toolName = toolName
152
163
self .parentID = parentID
153
164
self .type = type
You can’t perform that action at this time.
0 commit comments