feat(api): add endpoint to create group of dedicated agents (#79)

Signed-off-by: mudler <mudler@localai.io>
This commit is contained in:
Ettore Di Giacinto
2025-03-22 18:44:22 +01:00
committed by GitHub
parent d689bb4331
commit c1ac7b675a
7 changed files with 136 additions and 57 deletions

View File

@@ -6,6 +6,9 @@ type Config struct {
DefaultChunkSize int
Pool *state.AgentPool
ApiKeys []string
LLMAPIURL string
LLMAPIKey string
LLMModel string
}
type Option func(*Config)
@@ -16,6 +19,24 @@ func WithDefaultChunkSize(size int) Option {
}
}
func WithLLMModel(model string) Option {
return func(c *Config) {
c.LLMModel = model
}
}
func WithLLMAPIUrl(url string) Option {
return func(c *Config) {
c.LLMAPIURL = url
}
}
func WithLLMAPIKey(key string) Option {
return func(c *Config) {
c.LLMAPIKey = key
}
}
func WithPool(pool *state.AgentPool) Option {
return func(c *Config) {
c.Pool = pool