File tree Expand file tree Collapse file tree 3 files changed +4
-4
lines changed
BotSharp.Abstraction/Agents Expand file tree Collapse file tree 3 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -7,7 +7,7 @@ public interface IAgentService
7
7
{
8
8
Task < Agent > CreateAgent ( Agent agent ) ;
9
9
Task RefreshAgents ( ) ;
10
- Task < List < Agent > > GetAgents ( ) ;
10
+ Task < List < Agent > > GetAgents ( bool ? allowRouting = null ) ;
11
11
12
12
/// <summary>
13
13
/// Load agent configurations and trigger hooks
Original file line number Diff line number Diff line change @@ -7,9 +7,9 @@ public partial class AgentService
7
7
#if ! DEBUG
8
8
[ MemoryCache ( 10 * 60 ) ]
9
9
#endif
10
- public async Task < List < Agent > > GetAgents ( )
10
+ public async Task < List < Agent > > GetAgents ( bool ? allowRouting = null )
11
11
{
12
- var agents = _db . GetAgentsByUser ( _user . Id ) ;
12
+ var agents = _db . GetAgents ( allowRouting : allowRouting ) ;
13
13
return await Task . FromResult ( agents ) ;
14
14
}
15
15
Original file line number Diff line number Diff line change @@ -137,7 +137,7 @@ private string GetNextStepPrompt()
137
137
private void FixMalformedResponse ( FunctionCallFromLlm args )
138
138
{
139
139
var agentService = _services . GetRequiredService < IAgentService > ( ) ;
140
- var agents = agentService . GetAgents ( ) . Result ;
140
+ var agents = agentService . GetAgents ( allowRouting : true ) . Result ;
141
141
var malformed = false ;
142
142
143
143
// Sometimes it populate malformed Function in Agent name
You can’t perform that action at this time.
0 commit comments