refactor: Remove validation for 'enabled' field in agent configuration

- Eliminated the check for the 'enabled' field in the ValidateConfig method of agentService.
- Updated comments in session service to reflect the removal of the 'enabled' field from AgentConfig.
- Streamlined agent configuration handling for improved clarity and maintainability.
This commit is contained in:
wizardchen
2025-11-21 14:32:28 +08:00
parent 6687e81b96
commit 301d400cce
2 changed files with 1 additions and 6 deletions
@@ -244,10 +244,6 @@ func (s *agentService) ValidateConfig(config *types.AgentConfig) error {
return fmt.Errorf("config cannot be nil")
}
if !config.Enabled {
return fmt.Errorf("agent is not enabled")
}
if config.MaxIterations <= 0 {
config.MaxIterations = 5 // Default
}