-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathconfig.go
More file actions
40 lines (31 loc) · 1.07 KB
/
config.go
File metadata and controls
40 lines (31 loc) · 1.07 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
package cortex
import "time"
// Config holds configuration for the Cortex engine.
type Config struct {
// DefaultModel is the LLM model used when an agent does not specify one.
DefaultModel string
// DefaultMaxSteps is the maximum reasoning steps per run.
DefaultMaxSteps int
// DefaultMaxTokens is the maximum output tokens per LLM call.
DefaultMaxTokens int
// DefaultTemperature is the LLM sampling temperature.
DefaultTemperature float64
// DefaultReasoningLoop is the reasoning strategy when none is set.
DefaultReasoningLoop string
// ShutdownTimeout is the maximum time to wait for graceful shutdown.
ShutdownTimeout time.Duration
// RunConcurrency is the maximum number of agent runs processed concurrently.
RunConcurrency int
}
// DefaultConfig returns a Config with sensible defaults.
func DefaultConfig() Config {
return Config{
DefaultModel: "smart",
DefaultMaxSteps: 25,
DefaultMaxTokens: 4096,
DefaultTemperature: 0.7,
DefaultReasoningLoop: "react",
ShutdownTimeout: 30 * time.Second,
RunConcurrency: 4,
}
}