@@ -27,7 +27,7 @@ private sealed class SemanticWorkbenchWebservice
27
27
28
28
public static WorkbenchConnector < TAgentConfig > UseAgentWebservice < TAgentConfig > (
29
29
this IEndpointRouteBuilder builder , string endpoint , bool enableCatchAll = false )
30
- where TAgentConfig : IAgentConfig , new ( )
30
+ where TAgentConfig : AgentConfigBase , new ( )
31
31
{
32
32
WorkbenchConnector < TAgentConfig > ? workbenchConnector = builder . ServiceProvider . GetService < WorkbenchConnector < TAgentConfig > > ( ) ;
33
33
if ( workbenchConnector == null )
@@ -60,7 +60,7 @@ public static WorkbenchConnector<TAgentConfig> UseAgentWebservice<TAgentConfig>(
60
60
// Return service details and default agent configuration
61
61
public static IEndpointRouteBuilder UseFetchServiceInfo < TAgentConfig > (
62
62
this IEndpointRouteBuilder builder , string prefix )
63
- where TAgentConfig : IAgentConfig , new ( )
63
+ where TAgentConfig : AgentConfigBase , new ( )
64
64
{
65
65
builder . MapGet ( prefix + "/" , (
66
66
[ FromServicesAttribute ] WorkbenchConnector < TAgentConfig > workbenchConnector ,
@@ -76,7 +76,7 @@ public static IEndpointRouteBuilder UseFetchServiceInfo<TAgentConfig>(
76
76
// Create new agent instance
77
77
public static IEndpointRouteBuilder UseCreateAgentEndpoint < TAgentConfig > (
78
78
this IEndpointRouteBuilder builder , string prefix )
79
- where TAgentConfig : IAgentConfig , new ( )
79
+ where TAgentConfig : AgentConfigBase , new ( )
80
80
{
81
81
builder . MapPut ( prefix + "/{agentId}" ,
82
82
async (
@@ -110,7 +110,7 @@ await workbenchConnector.CreateAgentAsync(agentId, name, null, cancellationToken
110
110
// Delete agent instance
111
111
public static IEndpointRouteBuilder UseDeleteAgentEndpoint < TAgentConfig > (
112
112
this IEndpointRouteBuilder builder , string prefix )
113
- where TAgentConfig : IAgentConfig , new ( )
113
+ where TAgentConfig : AgentConfigBase , new ( )
114
114
{
115
115
builder . MapDelete ( prefix + "/{agentId}" ,
116
116
async (
@@ -130,7 +130,7 @@ public static IEndpointRouteBuilder UseDeleteAgentEndpoint<TAgentConfig>(
130
130
// Fetch agent configuration
131
131
public static IEndpointRouteBuilder UseFetchAgentConfigEndpoint < TAgentConfig > (
132
132
this IEndpointRouteBuilder builder , string prefix )
133
- where TAgentConfig : IAgentConfig , new ( )
133
+ where TAgentConfig : AgentConfigBase , new ( )
134
134
{
135
135
builder . MapGet ( prefix + "/{agentId}/config" ,
136
136
(
@@ -155,7 +155,7 @@ public static IEndpointRouteBuilder UseFetchAgentConfigEndpoint<TAgentConfig>(
155
155
// Save agent configuration
156
156
public static IEndpointRouteBuilder UseSaveAgentConfigEndpoint < TAgentConfig > (
157
157
this IEndpointRouteBuilder builder , string prefix )
158
- where TAgentConfig : IAgentConfig , new ( )
158
+ where TAgentConfig : AgentConfigBase , new ( )
159
159
{
160
160
builder . MapPut ( prefix + "/{agentId}/config" ,
161
161
async (
@@ -171,7 +171,7 @@ public static IEndpointRouteBuilder UseSaveAgentConfigEndpoint<TAgentConfig>(
171
171
if ( agent == null ) { return Results . NotFound ( "Agent Not Found" ) ; }
172
172
173
173
var config = agent . ParseConfig ( data [ "config" ] ) ;
174
- IAgentConfig newConfig =
174
+ AgentConfigBase newConfig =
175
175
await agent . UpdateAgentConfigAsync ( config , cancellationToken ) . ConfigureAwait ( false ) ;
176
176
177
177
var tmp = workbenchConnector . GetAgent ( agentId ) ;
@@ -186,7 +186,7 @@ public static IEndpointRouteBuilder UseSaveAgentConfigEndpoint<TAgentConfig>(
186
186
// Create new conversation
187
187
private static IEndpointRouteBuilder UseCreateConversationEndpoint < TAgentConfig > (
188
188
this IEndpointRouteBuilder builder , string prefix )
189
- where TAgentConfig : IAgentConfig , new ( )
189
+ where TAgentConfig : AgentConfigBase , new ( )
190
190
{
191
191
builder . MapPut ( prefix + "/{agentId}/conversations/{conversationId}" ,
192
192
async (
@@ -214,7 +214,7 @@ private static IEndpointRouteBuilder UseCreateConversationEndpoint<TAgentConfig>
214
214
// Fetch conversation states
215
215
public static IEndpointRouteBuilder UseFetchConversationStatesEndpoint < TAgentConfig > (
216
216
this IEndpointRouteBuilder builder , string prefix )
217
- where TAgentConfig : IAgentConfig , new ( )
217
+ where TAgentConfig : AgentConfigBase , new ( )
218
218
{
219
219
builder . MapGet ( prefix + "/{agentId}/conversations/{conversationId}/states" ,
220
220
async (
@@ -285,7 +285,7 @@ end of content
285
285
// Fetch conversation states
286
286
public static IEndpointRouteBuilder UseFetchConversationInsightEndpoint < TAgentConfig > (
287
287
this IEndpointRouteBuilder builder , string prefix )
288
- where TAgentConfig : IAgentConfig , new ( )
288
+ where TAgentConfig : AgentConfigBase , new ( )
289
289
{
290
290
builder . MapGet ( prefix + "/{agentId}/conversations/{conversationId}/states/{insightId}" ,
291
291
async (
@@ -348,7 +348,7 @@ public static IEndpointRouteBuilder UseFetchConversationInsightEndpoint<TAgentCo
348
348
// New conversation event
349
349
private static IEndpointRouteBuilder UseCreateConversationEventEndpoint < TAgentConfig > (
350
350
this IEndpointRouteBuilder builder , string prefix )
351
- where TAgentConfig : IAgentConfig , new ( )
351
+ where TAgentConfig : AgentConfigBase , new ( )
352
352
{
353
353
builder . MapPost ( prefix + "/{agentId}/conversations/{conversationId}/events" ,
354
354
async (
@@ -539,7 +539,7 @@ private static IEndpointRouteBuilder UseCreateConversationEventEndpoint<TAgentCo
539
539
// Delete conversation
540
540
public static IEndpointRouteBuilder UseDeleteConversationEndpoint < TAgentConfig > (
541
541
this IEndpointRouteBuilder builder , string prefix )
542
- where TAgentConfig : IAgentConfig , new ( )
542
+ where TAgentConfig : AgentConfigBase , new ( )
543
543
{
544
544
builder . MapDelete ( prefix + "/{agentId}/conversations/{conversationId}" ,
545
545
async (
0 commit comments