feat(data): add TaskRepository.UpdateAgentSettingsAsync
This commit is contained in:
@@ -111,6 +111,25 @@ public sealed class TaskRepository
|
||||
|
||||
#endregion
|
||||
|
||||
#region Agent settings
|
||||
|
||||
public async Task UpdateAgentSettingsAsync(
|
||||
string taskId,
|
||||
string? model,
|
||||
string? systemPrompt,
|
||||
string? agentPath,
|
||||
CancellationToken ct = default)
|
||||
{
|
||||
await _context.Tasks
|
||||
.Where(t => t.Id == taskId)
|
||||
.ExecuteUpdateAsync(s => s
|
||||
.SetProperty(t => t.Model, model)
|
||||
.SetProperty(t => t.SystemPrompt, systemPrompt)
|
||||
.SetProperty(t => t.AgentPath, agentPath), ct);
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Tags
|
||||
|
||||
public async Task AddTagAsync(string taskId, long tagId, CancellationToken ct = default)
|
||||
|
||||
Reference in New Issue
Block a user