Documentation
¶
Index ¶
- Constants
- func CreateDefaultConfigFileInCurrentDir() (string, error)
- func CreateDefaultConfigFileInHomeDir() (string, error)
- func DiscoverConfigFiles() ([]string, error)
- func DiscoverConfigFilesInPath(path string) ([]string, error)
- func DiscoverFirstConfigFile() (string, error)
- func LoadFromSources(config *Config, sources []Source, paths []string) error
- func LoadGlobalConfig() error
- func ReloadGlobalConfig() error
- func SetGlobalManager(manager *Manager)
- func ValidateConfiguration(config *Config) error
- func ValidateDefaults() error
- type AgentConfig
- type AgentInterceptorsConfig
- type AgentMemoryConfig
- type AgentsConfig
- type AuditInterceptorConfig
- type AuthorizationInterceptorConfig
- type BootstrapFewShotConfig
- type COPROConfig
- type CachingConfig
- type CachingInterceptorConfig
- type ChainOfThoughtConfig
- type CircuitBreakerInterceptorConfig
- type CommandLineSource
- type Config
- type ConfigWatcher
- type ContextConfig
- type Discovery
- func (d *Discovery) AddFilename(filename string)
- func (d *Discovery) AddFilenames(filenames []string)
- func (d *Discovery) AddSearchPath(path string)
- func (d *Discovery) AddSearchPaths(paths []string)
- func (d *Discovery) CreateDefaultConfigFile() (string, error)
- func (d *Discovery) CreateDefaultConfigFileInPath(path string) (string, error)
- func (d *Discovery) Discover() ([]string, error)
- func (d *Discovery) DiscoverFirst() (string, error)
- func (d *Discovery) DiscoverInPath(path string) ([]string, error)
- func (d *Discovery) DiscoverRecursive() ([]string, error)
- func (d *Discovery) DiscoverWithPattern(pattern string) ([]string, error)
- func (d *Discovery) GetEnvironmentOverrides() map[string]string
- func (d *Discovery) GetFilenames() []string
- func (d *Discovery) GetSearchPaths() []string
- func (d *Discovery) SetFilenames(filenames []string)
- func (d *Discovery) SetSearchPaths(paths []string)
- func (d *Discovery) Validate() error
- type EmbeddingConfig
- type EndpointConfig
- type EnvironmentSource
- type ExecutionConfig
- type FileSource
- type FunctionToolsConfig
- type GenerationConfig
- type GlobalInterceptorConfig
- type InterceptorBuilder
- func (b *InterceptorBuilder) BuildAgentInterceptors() ([]core.AgentInterceptor, error)
- func (b *InterceptorBuilder) BuildAll() (*InterceptorSet, error)
- func (b *InterceptorBuilder) BuildModuleInterceptors() ([]core.ModuleInterceptor, error)
- func (b *InterceptorBuilder) BuildToolInterceptors() ([]core.ToolInterceptor, error)
- type InterceptorSet
- type InterceptorToggle
- type InterceptorsConfig
- type LLMConfig
- type LLMGlobalSettings
- type LLMProviderConfig
- type LogOutputConfig
- type LogRotationConfig
- type LoggingConfig
- type MCPConfig
- type MCPConnectionPoolConfig
- type MCPServerConfig
- type MIPROConfig
- type Manager
- func (m *Manager) Clone() (*Config, error)
- func (m *Manager) Export() (map[string]interface{}, error)
- func (m *Manager) Get() *Config
- func (m *Manager) GetAgentsConfig() *AgentsConfig
- func (m *Manager) GetConfigPath() string
- func (m *Manager) GetExecutionConfig() *ExecutionConfig
- func (m *Manager) GetLLMConfig() *LLMConfig
- func (m *Manager) GetLoggingConfig() *LoggingConfig
- func (m *Manager) GetModulesConfig() *ModulesConfig
- func (m *Manager) GetOptimizersConfig() *OptimizersConfig
- func (m *Manager) GetToolsConfig() *ToolsConfig
- func (m *Manager) Import(data map[string]interface{}) error
- func (m *Manager) IsLoaded() bool
- func (m *Manager) Load() error
- func (m *Manager) Merge(other *Config) error
- func (m *Manager) Reload() error
- func (m *Manager) Reset() error
- func (m *Manager) Save() error
- func (m *Manager) SaveToFile(path string) error
- func (m *Manager) StopWatching()
- func (m *Manager) Update(updater func(*Config) error) error
- func (m *Manager) Watch() error
- type ManagerOption
- type MemoryCacheConfig
- type MemoryPersistenceConfig
- type ModuleInterceptorsConfig
- type ModulesConfig
- type MultiChainComparisonConfig
- type MultiSource
- type OptimizersConfig
- type PredictConfig
- type PredictSettings
- type RateLimitInterceptorConfig
- type ReActConfig
- type RefineConfig
- type RemoteSource
- type RetryConfig
- type RetryInterceptorConfig
- type SIMBAConfig
- type SQLiteCacheConfig
- type SanitizationInterceptorConfig
- type Source
- type TPEConfig
- type TimeoutInterceptorConfig
- type ToolInterceptorsConfig
- type ToolRegistryConfig
- type ToolUseConfig
- type ToolsConfig
- type TracingConfig
- type TracingExporterConfig
- type ValidationError
- type ValidationErrors
- type ValidationInterceptorConfig
- type Validator
- type WorkflowPersistenceConfig
- type WorkflowsConfig
Constants ¶
const ( // Default timeouts. DefaultModuleTimeout = 30 * time.Second DefaultAgentTimeout = 60 * time.Second DefaultToolTimeout = 30 * time.Second // Default cache TTL. DefaultCacheTTL = 5 * time.Minute // Default circuit breaker settings. DefaultFailureThreshold = 5 DefaultRecoveryTimeout = 30 * time.Second DefaultHalfOpenRequests = 3 // Default retry settings. DefaultMaxRetries = 3 DefaultInitialBackoff = 100 * time.Millisecond DefaultMaxBackoff = 10 * time.Second DefaultBackoffFactor = 2.0 // Default rate limiting. DefaultRequestsPerMinute = 60 DefaultBurstSize = 10 DefaultRateWindow = 1 * time.Minute // Default validation settings. DefaultMaxStringLength = 1000 DefaultMaxInputSize = 1024 * 1024 // 1MB // Default sanitization settings. DefaultSanitizationMaxLength = 10240 // 10KB // Default audit settings. DefaultAuditLogLevel = "INFO" )
Default values for interceptor configurations.
Variables ¶
This section is empty.
Functions ¶
func CreateDefaultConfigFileInCurrentDir ¶
CreateDefaultConfigFileInCurrentDir creates a default configuration file in the current directory.
func CreateDefaultConfigFileInHomeDir ¶
CreateDefaultConfigFileInHomeDir creates a default configuration file in the user's home directory.
func DiscoverConfigFiles ¶
DiscoverConfigFiles discovers configuration files using default settings.
func DiscoverConfigFilesInPath ¶
DiscoverConfigFilesInPath discovers configuration files in a specific path.
func DiscoverFirstConfigFile ¶
DiscoverFirstConfigFile discovers the first configuration file found.
func LoadFromSources ¶
LoadFromSources loads configuration from multiple sources.
func LoadGlobalConfig ¶
func LoadGlobalConfig() error
LoadGlobalConfig loads the global configuration.
func ReloadGlobalConfig ¶
func ReloadGlobalConfig() error
ReloadGlobalConfig reloads the global configuration.
func SetGlobalManager ¶
func SetGlobalManager(manager *Manager)
SetGlobalManager sets the global configuration manager.
func ValidateConfiguration ¶
ValidateConfiguration validates a configuration using the global validator.
func ValidateDefaults ¶
func ValidateDefaults() error
ValidateDefaults validates that the default configuration is valid.
Types ¶
type AgentConfig ¶
type AgentConfig struct {
// Maximum conversation history
MaxHistory int `yaml:"max_history" validate:"min=1"`
// Agent timeout
Timeout time.Duration `yaml:"timeout" validate:"min=1s"`
// Tool use configuration
ToolUse ToolUseConfig `yaml:"tool_use"`
}
AgentConfig holds individual agent configuration.
type AgentInterceptorsConfig ¶
type AgentInterceptorsConfig struct {
// Standard interceptors
Logging InterceptorToggle `yaml:"logging,omitempty"`
Metrics InterceptorToggle `yaml:"metrics,omitempty"`
Tracing InterceptorToggle `yaml:"tracing,omitempty"`
// Performance interceptors
RateLimit RateLimitInterceptorConfig `yaml:"rate_limit,omitempty"`
Timeout TimeoutInterceptorConfig `yaml:"timeout,omitempty"`
// Security interceptors
Authorization AuthorizationInterceptorConfig `yaml:"authorization,omitempty"`
Audit AuditInterceptorConfig `yaml:"audit,omitempty"`
}
AgentInterceptorsConfig holds agent-specific interceptor configuration.
type AgentMemoryConfig ¶
type AgentMemoryConfig struct {
// Memory type (buffered, sqlite, redis)
Type string `yaml:"type" validate:"oneof=buffered sqlite redis"`
// Memory capacity
Capacity int `yaml:"capacity" validate:"min=1"`
// Memory persistence settings
Persistence MemoryPersistenceConfig `yaml:"persistence"`
}
AgentMemoryConfig holds agent memory configuration.
type AgentsConfig ¶
type AgentsConfig struct {
// Default agent configuration
Default AgentConfig `yaml:"default"`
// Memory configuration
Memory AgentMemoryConfig `yaml:"memory"`
// Workflow configuration
Workflows WorkflowsConfig `yaml:"workflows"`
}
AgentsConfig holds agent-specific configuration.
type AuditInterceptorConfig ¶
type AuditInterceptorConfig struct {
Enabled bool `yaml:"enabled"`
LogLevel string `yaml:"log_level,omitempty" validate:"omitempty,oneof=DEBUG INFO WARN ERROR"`
IncludeInput bool `yaml:"include_input,omitempty"`
IncludeOutput bool `yaml:"include_output,omitempty"`
AuditPath string `yaml:"audit_path,omitempty"`
}
AuditInterceptorConfig holds audit interceptor configuration.
type AuthorizationInterceptorConfig ¶
type AuthorizationInterceptorConfig struct {
Enabled bool `yaml:"enabled"`
RequireAuth bool `yaml:"require_auth,omitempty"`
AllowedRoles []string `yaml:"allowed_roles,omitempty"`
RequiredScopes []string `yaml:"required_scopes,omitempty"`
CustomRules map[string]string `yaml:"custom_rules,omitempty"`
}
AuthorizationInterceptorConfig holds authorization interceptor configuration.
type BootstrapFewShotConfig ¶
type BootstrapFewShotConfig struct {
// Maximum examples to use
MaxExamples int `yaml:"max_examples" validate:"min=1"`
// Teacher model configuration
TeacherModel string `yaml:"teacher_model"`
// Student model configuration
StudentModel string `yaml:"student_model"`
// Bootstrap iterations
BootstrapIterations int `yaml:"bootstrap_iterations" validate:"min=1"`
}
BootstrapFewShotConfig holds Bootstrap Few-Shot optimizer configuration.
type COPROConfig ¶
type COPROConfig struct {
// Maximum iterations
MaxIterations int `yaml:"max_iterations" validate:"min=1"`
// Convergence threshold
ConvergenceThreshold float64 `yaml:"convergence_threshold" validate:"min=0,max=1"`
// Learning rate
LearningRate float64 `yaml:"learning_rate" validate:"min=0,max=1"`
}
COPROConfig holds COPRO optimizer configuration.
type CachingConfig ¶
type CachingConfig struct {
// Enable caching
Enabled bool `yaml:"enabled"`
// Cache TTL
TTL time.Duration `yaml:"ttl" validate:"min=1s"`
// Maximum cache size (in bytes)
MaxSize int64 `yaml:"max_size" validate:"min=1"`
// Cache type (memory, sqlite)
Type string `yaml:"type" validate:"oneof=memory sqlite"`
// SQLite specific configuration
SQLiteConfig SQLiteCacheConfig `yaml:"sqlite_config,omitempty"`
// Memory cache specific configuration
MemoryConfig MemoryCacheConfig `yaml:"memory_config,omitempty"`
}
CachingConfig holds caching configuration.
type CachingInterceptorConfig ¶
type CachingInterceptorConfig struct {
Enabled bool `yaml:"enabled"`
TTL time.Duration `yaml:"ttl,omitempty" validate:"omitempty,min=1s"`
MaxSize int64 `yaml:"max_size,omitempty" validate:"omitempty,min=1"`
Type string `yaml:"type,omitempty" validate:"omitempty,oneof=memory sqlite"`
}
CachingInterceptorConfig holds caching interceptor configuration.
type ChainOfThoughtConfig ¶
type ChainOfThoughtConfig struct {
// Maximum reasoning steps
MaxSteps int `yaml:"max_steps" validate:"min=1"`
// Whether to include reasoning in output
IncludeReasoning bool `yaml:"include_reasoning"`
// Step delimiter
StepDelimiter string `yaml:"step_delimiter"`
}
ChainOfThoughtConfig holds Chain of Thought module configuration.
type CircuitBreakerInterceptorConfig ¶
type CircuitBreakerInterceptorConfig struct {
Enabled bool `yaml:"enabled"`
FailureThreshold int `yaml:"failure_threshold,omitempty" validate:"omitempty,min=1"`
RecoveryTimeout time.Duration `yaml:"recovery_timeout,omitempty" validate:"omitempty,min=1s"`
HalfOpenRequests int `yaml:"half_open_requests,omitempty" validate:"omitempty,min=1"`
}
CircuitBreakerInterceptorConfig holds circuit breaker interceptor configuration.
type CommandLineSource ¶
type CommandLineSource struct {
// contains filtered or unexported fields
}
CommandLineSource loads configuration from command line arguments.
func NewCommandLineSource ¶
func NewCommandLineSource(args []string) *CommandLineSource
NewCommandLineSource creates a new command line source.
func NewCommandLineSourceWithPriority ¶
func NewCommandLineSourceWithPriority(priority int, args []string) *CommandLineSource
NewCommandLineSourceWithPriority creates a new command line source with custom priority.
func (*CommandLineSource) Load ¶
func (cls *CommandLineSource) Load(config *Config, paths []string) error
Load loads configuration from command line arguments.
func (*CommandLineSource) Name ¶
func (cls *CommandLineSource) Name() string
Name returns the name of the command line source.
func (*CommandLineSource) Priority ¶
func (cls *CommandLineSource) Priority() int
Priority returns the priority of the command line source.
type Config ¶
type Config struct {
// LLM configuration
LLM LLMConfig `yaml:"llm" validate:"required"`
// Logging configuration
Logging LoggingConfig `yaml:"logging,omitempty" validate:"omitempty"`
// Execution configuration
Execution ExecutionConfig `yaml:"execution,omitempty" validate:"omitempty"`
// Module configuration
Modules ModulesConfig `yaml:"modules,omitempty" validate:"omitempty"`
// Agents configuration
Agents AgentsConfig `yaml:"agents,omitempty" validate:"omitempty"`
// Tools configuration
Tools ToolsConfig `yaml:"tools,omitempty" validate:"omitempty"`
// Optimizer configuration
Optimizers OptimizersConfig `yaml:"optimizers,omitempty" validate:"omitempty"`
// Interceptors configuration
Interceptors InterceptorsConfig `yaml:"interceptors,omitempty" validate:"omitempty"`
}
Config represents the complete configuration for the dspy-go system.
func GetDefaultConfig ¶
func GetDefaultConfig() *Config
GetDefaultConfig returns the default configuration for dspy-go.
func GetGlobalConfig ¶
func GetGlobalConfig() *Config
GetGlobalConfig returns the global configuration.
func MergeWithDefaults ¶
MergeWithDefaults performs a deep merge of a partial configuration with defaults.
type ConfigWatcher ¶
ConfigWatcher is called when configuration changes.
type ContextConfig ¶
type ContextConfig struct {
// Default context timeout
DefaultTimeout time.Duration `yaml:"default_timeout" validate:"min=1s"`
// Context buffer size
BufferSize int `yaml:"buffer_size" validate:"min=1"`
}
ContextConfig holds context-related configuration.
type Discovery ¶
type Discovery struct {
// contains filtered or unexported fields
}
Discovery handles configuration file discovery.
func NewDiscovery ¶
func NewDiscovery() *Discovery
NewDiscovery creates a new configuration discovery instance.
func NewDiscoveryWithFilenames ¶
NewDiscoveryWithFilenames creates a discovery instance with custom filenames.
func NewDiscoveryWithOptions ¶
NewDiscoveryWithOptions creates a discovery instance with custom options.
func NewDiscoveryWithPaths ¶
NewDiscoveryWithPaths creates a discovery instance with custom search paths.
func (*Discovery) AddFilename ¶
AddFilename adds a filename to search for.
func (*Discovery) AddFilenames ¶
AddFilenames adds multiple filenames to search for.
func (*Discovery) AddSearchPath ¶
AddSearchPath adds a search path to the discovery.
func (*Discovery) AddSearchPaths ¶
AddSearchPaths adds multiple search paths to the discovery.
func (*Discovery) CreateDefaultConfigFile ¶
CreateDefaultConfigFile creates a default configuration file in the first search path.
func (*Discovery) CreateDefaultConfigFileInPath ¶
CreateDefaultConfigFileInPath creates a default configuration file in a specific path.
func (*Discovery) DiscoverFirst ¶
DiscoverFirst returns the first configuration file found.
func (*Discovery) DiscoverInPath ¶
DiscoverInPath searches for configuration files in a specific path.
func (*Discovery) DiscoverRecursive ¶
DiscoverRecursive searches for configuration files recursively in the search paths.
func (*Discovery) DiscoverWithPattern ¶
DiscoverWithPattern searches for configuration files matching a pattern.
func (*Discovery) GetEnvironmentOverrides ¶
GetEnvironmentOverrides returns configuration overrides from environment variables.
func (*Discovery) GetFilenames ¶
GetFilenames returns the current filenames being searched for.
func (*Discovery) GetSearchPaths ¶
GetSearchPaths returns the current search paths.
func (*Discovery) SetFilenames ¶
SetFilenames sets the filenames to search for.
func (*Discovery) SetSearchPaths ¶
SetSearchPaths sets the search paths for discovery.
type EmbeddingConfig ¶
type EmbeddingConfig struct {
// Model to use for embeddings
Model string `yaml:"model,omitempty"`
// Batch size for bulk operations
BatchSize int `yaml:"batch_size" validate:"min=1"`
// Additional parameters
Params map[string]interface{} `yaml:"params"`
}
EmbeddingConfig holds embedding generation parameters.
func GetDefaultEmbeddingConfig ¶
func GetDefaultEmbeddingConfig() *EmbeddingConfig
GetDefaultEmbeddingConfig returns default embedding configuration.
type EndpointConfig ¶
type EndpointConfig struct {
// Base URL for the API
BaseURL string `yaml:"base_url"`
// API path (if different from default)
Path string `yaml:"path"`
// HTTP headers to include
Headers map[string]string `yaml:"headers"`
// Request timeout
Timeout time.Duration `yaml:"timeout"`
// Retry configuration
Retry RetryConfig `yaml:"retry"`
}
EndpointConfig holds endpoint-specific configuration.
func GetDefaultEndpointConfig ¶
func GetDefaultEndpointConfig() *EndpointConfig
GetDefaultEndpointConfig returns default endpoint configuration.
type EnvironmentSource ¶
type EnvironmentSource struct {
// contains filtered or unexported fields
}
EnvironmentSource loads configuration from environment variables.
func NewEnvironmentSource ¶
func NewEnvironmentSource() *EnvironmentSource
NewEnvironmentSource creates a new environment source.
func NewEnvironmentSourceWithOptions ¶
func NewEnvironmentSourceWithOptions(priority int, prefix string) *EnvironmentSource
NewEnvironmentSourceWithOptions creates a new environment source with custom options.
func NewEnvironmentSourceWithPrefix ¶
func NewEnvironmentSourceWithPrefix(prefix string) *EnvironmentSource
NewEnvironmentSourceWithPrefix creates a new environment source with custom prefix.
func (*EnvironmentSource) Load ¶
func (es *EnvironmentSource) Load(config *Config, paths []string) error
Load loads configuration from environment variables.
func (*EnvironmentSource) Name ¶
func (es *EnvironmentSource) Name() string
Name returns the name of the environment source.
func (*EnvironmentSource) Priority ¶
func (es *EnvironmentSource) Priority() int
Priority returns the priority of the environment source.
type ExecutionConfig ¶
type ExecutionConfig struct {
// Default timeout for operations
DefaultTimeout time.Duration `yaml:"default_timeout" validate:"min=1s"`
// Maximum number of concurrent operations
MaxConcurrency int `yaml:"max_concurrency" validate:"min=1"`
// Context configuration
Context ContextConfig `yaml:"context"`
// Tracing configuration
Tracing TracingConfig `yaml:"tracing"`
}
ExecutionConfig holds execution-related configuration.
type FileSource ¶
type FileSource struct {
// contains filtered or unexported fields
}
FileSource loads configuration from YAML files.
func NewFileSourceWithPriority ¶
func NewFileSourceWithPriority(priority int) *FileSource
NewFileSourceWithPriority creates a new file source with custom priority.
func (*FileSource) Load ¶
func (fs *FileSource) Load(config *Config, paths []string) error
Load loads configuration from YAML files.
func (*FileSource) Name ¶
func (fs *FileSource) Name() string
Name returns the name of the file source.
func (*FileSource) Priority ¶
func (fs *FileSource) Priority() int
Priority returns the priority of the file source.
type FunctionToolsConfig ¶
type FunctionToolsConfig struct {
// Maximum execution time
MaxExecutionTime time.Duration `yaml:"max_execution_time,omitempty" validate:"omitempty,min=1s"`
}
FunctionToolsConfig holds function tools configuration.
type GenerationConfig ¶
type GenerationConfig struct {
// Maximum tokens to generate
MaxTokens int `yaml:"max_tokens" validate:"min=1"`
// Sampling temperature
Temperature float64 `yaml:"temperature" validate:"min=0,max=2"`
// Top-p sampling
TopP float64 `yaml:"top_p" validate:"min=0,max=1"`
// Presence penalty
PresencePenalty float64 `yaml:"presence_penalty" validate:"min=-2,max=2"`
// Frequency penalty
FrequencyPenalty float64 `yaml:"frequency_penalty" validate:"min=-2,max=2"`
// Stop sequences
StopSequences []string `yaml:"stop_sequences"`
}
GenerationConfig holds text generation parameters.
func GetDefaultGenerationConfig ¶
func GetDefaultGenerationConfig() *GenerationConfig
GetDefaultGenerationConfig returns default generation configuration.
type GlobalInterceptorConfig ¶
type GlobalInterceptorConfig struct {
// Enable interceptors globally
Enabled bool `yaml:"enabled"`
// Default timeout for all interceptors
DefaultTimeout time.Duration `yaml:"default_timeout,omitempty" validate:"omitempty,min=1s"`
// Maximum interceptor chain length
MaxChainLength int `yaml:"max_chain_length,omitempty" validate:"omitempty,min=1"`
// Enable performance monitoring for interceptors
MonitorPerformance bool `yaml:"monitor_performance,omitempty"`
}
GlobalInterceptorConfig holds global interceptor settings.
type InterceptorBuilder ¶
type InterceptorBuilder struct {
// contains filtered or unexported fields
}
InterceptorBuilder provides a fluent interface for building interceptor chains from configuration.
func NewInterceptorBuilder ¶
func NewInterceptorBuilder(config *InterceptorsConfig) *InterceptorBuilder
NewInterceptorBuilder creates a new InterceptorBuilder from configuration.
func (*InterceptorBuilder) BuildAgentInterceptors ¶
func (b *InterceptorBuilder) BuildAgentInterceptors() ([]core.AgentInterceptor, error)
BuildAgentInterceptors builds a chain of agent interceptors from configuration.
func (*InterceptorBuilder) BuildAll ¶
func (b *InterceptorBuilder) BuildAll() (*InterceptorSet, error)
BuildAll builds all interceptor chains from configuration.
func (*InterceptorBuilder) BuildModuleInterceptors ¶
func (b *InterceptorBuilder) BuildModuleInterceptors() ([]core.ModuleInterceptor, error)
BuildModuleInterceptors builds a chain of module interceptors from configuration.
func (*InterceptorBuilder) BuildToolInterceptors ¶
func (b *InterceptorBuilder) BuildToolInterceptors() ([]core.ToolInterceptor, error)
BuildToolInterceptors builds a chain of tool interceptors from configuration.
type InterceptorSet ¶
type InterceptorSet struct {
ModuleInterceptors []core.ModuleInterceptor
AgentInterceptors []core.AgentInterceptor
ToolInterceptors []core.ToolInterceptor
}
InterceptorSet holds all configured interceptor chains.
func SetupInterceptorsFromConfig ¶
func SetupInterceptorsFromConfig(config *Config) (*InterceptorSet, error)
SetupInterceptorsFromConfig creates interceptor chains from a loaded configuration.
type InterceptorToggle ¶
type InterceptorToggle struct {
Enabled bool `yaml:"enabled"`
}
InterceptorToggle represents a simple on/off toggle for interceptors.
type InterceptorsConfig ¶
type InterceptorsConfig struct {
// Module interceptors configuration
Module ModuleInterceptorsConfig `yaml:"module,omitempty" validate:"omitempty"`
// Agent interceptors configuration
Agent AgentInterceptorsConfig `yaml:"agent,omitempty" validate:"omitempty"`
// Tool interceptors configuration
Tool ToolInterceptorsConfig `yaml:"tool,omitempty" validate:"omitempty"`
// Global interceptor settings
Global GlobalInterceptorConfig `yaml:"global,omitempty" validate:"omitempty"`
}
InterceptorsConfig holds interceptor configuration.
func SetupPerformanceInterceptors ¶
func SetupPerformanceInterceptors() *InterceptorsConfig
SetupPerformanceInterceptors creates an interceptor configuration focused on performance.
func SetupSecurityInterceptors ¶
func SetupSecurityInterceptors() *InterceptorsConfig
SetupSecurityInterceptors creates an interceptor configuration focused on security.
func SetupStandardInterceptors ¶
func SetupStandardInterceptors() *InterceptorsConfig
SetupStandardInterceptors creates a standard interceptor configuration with common settings.
type LLMConfig ¶
type LLMConfig struct {
// Default LLM configuration
Default LLMProviderConfig `yaml:"default" validate:"required"`
// Teacher LLM configuration (for optimization)
Teacher LLMProviderConfig `yaml:"teacher,omitempty" validate:"omitempty"`
// Available providers and their configurations
Providers map[string]LLMProviderConfig `yaml:"providers,omitempty" validate:"omitempty"`
// Global LLM settings
GlobalSettings LLMGlobalSettings `yaml:"global_settings,omitempty" validate:"omitempty"`
}
LLMConfig holds configuration for Language Learning Models.
type LLMGlobalSettings ¶
type LLMGlobalSettings struct {
// Default concurrency level
ConcurrencyLevel int `yaml:"concurrency_level" validate:"min=1"`
// Enable request/response logging
LogRequests bool `yaml:"log_requests"`
// Enable token usage tracking
TrackTokenUsage bool `yaml:"track_token_usage"`
// Enable metrics collection
EnableMetrics bool `yaml:"enable_metrics"`
}
LLMGlobalSettings holds global LLM configuration.
type LLMProviderConfig ¶
type LLMProviderConfig struct {
// Provider name (anthropic, google, ollama, llamacpp)
Provider string `yaml:"provider" validate:"required,oneof=anthropic google ollama llamacpp"`
// Model ID (e.g., claude-3-sonnet-20240229)
ModelID string `yaml:"model_id" validate:"required"`
// API key for the provider
APIKey string `yaml:"api_key,omitempty"`
// Endpoint configuration
Endpoint EndpointConfig `yaml:"endpoint,omitempty"`
// Generation parameters
Generation GenerationConfig `yaml:"generation,omitempty"`
// Embedding configuration
Embedding EmbeddingConfig `yaml:"embedding,omitempty"`
// Capabilities this provider supports
Capabilities []string `yaml:"capabilities,omitempty"`
}
LLMProviderConfig represents configuration for a specific LLM provider.
func GetDefaultLLMProviderConfig ¶
func GetDefaultLLMProviderConfig(provider string) *LLMProviderConfig
GetDefaultLLMProviderConfig returns a default LLM provider configuration.
type LogOutputConfig ¶
type LogOutputConfig struct {
// Type of output (console, file, syslog)
Type string `yaml:"type" validate:"required,oneof=console file syslog"`
// Output format (json, text)
Format string `yaml:"format" validate:"oneof=json text"`
// File path (for file outputs)
FilePath string `yaml:"file_path"`
// Whether to use colors (for console outputs)
Colors bool `yaml:"colors"`
// Log rotation configuration
Rotation LogRotationConfig `yaml:"rotation"`
}
LogOutputConfig represents a logging output destination.
type LogRotationConfig ¶
type LogRotationConfig struct {
// Maximum file size before rotation
MaxSize int `yaml:"max_size" validate:"min=1"`
// Maximum number of old files to retain
MaxFiles int `yaml:"max_files" validate:"min=1"`
// Maximum age of files in days
MaxAge int `yaml:"max_age" validate:"min=1"`
// Whether to compress old files
Compress bool `yaml:"compress"`
}
LogRotationConfig holds log rotation settings.
type LoggingConfig ¶
type LoggingConfig struct {
// Log level (DEBUG, INFO, WARN, ERROR, FATAL)
Level string `yaml:"level" validate:"oneof=DEBUG INFO WARN ERROR FATAL"`
// Output configurations
Outputs []LogOutputConfig `yaml:"outputs"`
// Sampling rate for high-frequency events
SampleRate uint32 `yaml:"sample_rate"`
// Default fields to include in all logs
DefaultFields map[string]interface{} `yaml:"default_fields"`
}
LoggingConfig holds logging configuration.
type MCPConfig ¶
type MCPConfig struct {
// MCP servers configuration
Servers []MCPServerConfig `yaml:"servers,omitempty"`
// Default timeout for MCP operations
DefaultTimeout time.Duration `yaml:"default_timeout,omitempty" validate:"omitempty,min=1s"`
// Connection pool settings
ConnectionPool MCPConnectionPoolConfig `yaml:"connection_pool,omitempty"`
}
MCPConfig holds MCP (Model Context Protocol) configuration.
type MCPConnectionPoolConfig ¶
type MCPConnectionPoolConfig struct {
// Maximum connections per server
MaxConnections int `yaml:"max_connections,omitempty" validate:"omitempty,min=1"`
// Connection timeout
ConnectionTimeout time.Duration `yaml:"connection_timeout,omitempty" validate:"omitempty,min=1s"`
// Idle timeout
IdleTimeout time.Duration `yaml:"idle_timeout,omitempty" validate:"omitempty,min=1s"`
}
MCPConnectionPoolConfig holds MCP connection pool configuration.
type MCPServerConfig ¶
type MCPServerConfig struct {
// Server name
Name string `yaml:"name" validate:"required"`
// Server command
Command string `yaml:"command" validate:"required"`
// Server arguments
Args []string `yaml:"args"`
// Environment variables
Env map[string]string `yaml:"env"`
// Working directory
WorkingDir string `yaml:"working_dir"`
// Server timeout
Timeout time.Duration `yaml:"timeout" validate:"min=1s"`
}
MCPServerConfig holds individual MCP server configuration.
type MIPROConfig ¶
type MIPROConfig struct {
// Population size
PopulationSize int `yaml:"population_size" validate:"min=1"`
// Number of generations
NumGenerations int `yaml:"num_generations" validate:"min=1"`
// Mutation rate
MutationRate float64 `yaml:"mutation_rate" validate:"min=0,max=1"`
// Crossover rate
CrossoverRate float64 `yaml:"crossover_rate" validate:"min=0,max=1"`
}
MIPROConfig holds MIPRO optimizer configuration.
type Manager ¶
type Manager struct {
// contains filtered or unexported fields
}
Manager handles configuration loading, validation, and management.
func GetGlobalManager ¶
func GetGlobalManager() *Manager
GetGlobalManager returns the global configuration manager.
func NewManager ¶
func NewManager(options ...ManagerOption) (*Manager, error)
NewManager creates a new configuration manager.
func (*Manager) GetAgentsConfig ¶
func (m *Manager) GetAgentsConfig() *AgentsConfig
GetAgentsConfig returns the agents configuration.
func (*Manager) GetConfigPath ¶
GetConfigPath returns the current configuration file path.
func (*Manager) GetExecutionConfig ¶
func (m *Manager) GetExecutionConfig() *ExecutionConfig
GetExecutionConfig returns the execution configuration.
func (*Manager) GetLLMConfig ¶
GetLLMConfig returns the LLM configuration.
func (*Manager) GetLoggingConfig ¶
func (m *Manager) GetLoggingConfig() *LoggingConfig
GetLoggingConfig returns the logging configuration.
func (*Manager) GetModulesConfig ¶
func (m *Manager) GetModulesConfig() *ModulesConfig
GetModulesConfig returns the modules configuration.
func (*Manager) GetOptimizersConfig ¶
func (m *Manager) GetOptimizersConfig() *OptimizersConfig
GetOptimizersConfig returns the optimizers configuration.
func (*Manager) GetToolsConfig ¶
func (m *Manager) GetToolsConfig() *ToolsConfig
GetToolsConfig returns the tools configuration.
func (*Manager) SaveToFile ¶
SaveToFile saves the configuration to a specific file.
func (*Manager) StopWatching ¶
func (m *Manager) StopWatching()
StopWatching stops watching for configuration changes.
type ManagerOption ¶
ManagerOption represents an option for configuring the Manager.
func WithConfigPath ¶
func WithConfigPath(path string) ManagerOption
WithConfigPath sets the configuration file path.
func WithDiscovery ¶
func WithDiscovery(discovery *Discovery) ManagerOption
WithDiscovery sets the discovery mechanism.
func WithSources ¶
func WithSources(sources ...Source) ManagerOption
WithSources sets the configuration sources.
func WithWatcher ¶
func WithWatcher(watcher ConfigWatcher) ManagerOption
WithWatcher adds a configuration watcher.
type MemoryCacheConfig ¶
type MemoryCacheConfig struct {
// Cleanup interval for expired entries
CleanupInterval time.Duration `yaml:"cleanup_interval"`
// Number of shards for concurrent access
ShardCount int `yaml:"shard_count"`
}
MemoryCacheConfig holds memory cache specific configuration.
type MemoryPersistenceConfig ¶
type MemoryPersistenceConfig struct {
// Enable persistence
Enabled bool `yaml:"enabled"`
// Storage path
Path string `yaml:"path"`
// Sync interval
SyncInterval time.Duration `yaml:"sync_interval" validate:"min=1s"`
}
MemoryPersistenceConfig holds memory persistence configuration.
type ModuleInterceptorsConfig ¶
type ModuleInterceptorsConfig struct {
// Standard interceptors
Logging InterceptorToggle `yaml:"logging,omitempty"`
Metrics InterceptorToggle `yaml:"metrics,omitempty"`
Tracing InterceptorToggle `yaml:"tracing,omitempty"`
// Performance interceptors
Caching CachingInterceptorConfig `yaml:"caching,omitempty"`
Timeout TimeoutInterceptorConfig `yaml:"timeout,omitempty"`
CircuitBreaker CircuitBreakerInterceptorConfig `yaml:"circuit_breaker,omitempty"`
Retry RetryInterceptorConfig `yaml:"retry,omitempty"`
// Security interceptors
Validation ValidationInterceptorConfig `yaml:"validation,omitempty"`
Authorization AuthorizationInterceptorConfig `yaml:"authorization,omitempty"`
Sanitization SanitizationInterceptorConfig `yaml:"sanitization,omitempty"`
}
ModuleInterceptorsConfig holds module-specific interceptor configuration.
type ModulesConfig ¶
type ModulesConfig struct {
// Chain of Thought configuration
ChainOfThought ChainOfThoughtConfig `yaml:"chain_of_thought"`
// Multi-Chain Comparison configuration
MultiChainComparison MultiChainComparisonConfig `yaml:"multi_chain_comparison"`
// ReAct configuration
ReAct ReActConfig `yaml:"react"`
// Refine configuration
Refine RefineConfig `yaml:"refine"`
// Predict configuration
Predict PredictConfig `yaml:"predict"`
}
ModulesConfig holds module-specific configuration.
type MultiChainComparisonConfig ¶
type MultiChainComparisonConfig struct {
// Number of chains to run
NumChains int `yaml:"num_chains" validate:"min=2"`
// Comparison strategy
ComparisonStrategy string `yaml:"comparison_strategy" validate:"oneof=majority_vote highest_confidence best_score"`
// Enable parallel execution
ParallelExecution bool `yaml:"parallel_execution"`
}
MultiChainComparisonConfig holds Multi-Chain Comparison configuration.
type MultiSource ¶
type MultiSource struct {
// contains filtered or unexported fields
}
MultiSource combines multiple configuration sources.
func NewMultiSource ¶
func NewMultiSource(sources ...Source) *MultiSource
NewMultiSource creates a new multi-source configuration loader.
func (*MultiSource) AddSource ¶
func (ms *MultiSource) AddSource(source Source)
AddSource adds a source to the multi-source.
func (*MultiSource) GetSources ¶
func (ms *MultiSource) GetSources() []Source
GetSources returns all sources.
func (*MultiSource) Load ¶
func (ms *MultiSource) Load(config *Config, paths []string) error
Load loads configuration from all sources in priority order.
func (*MultiSource) Name ¶
func (ms *MultiSource) Name() string
Name returns the name of the multi-source.
func (*MultiSource) Priority ¶
func (ms *MultiSource) Priority() int
Priority returns the highest priority among all sources.
func (*MultiSource) RemoveSource ¶
func (ms *MultiSource) RemoveSource(sourceName string)
RemoveSource removes a source from the multi-source.
type OptimizersConfig ¶
type OptimizersConfig struct {
// Bootstrap Few-Shot optimizer
BootstrapFewShot BootstrapFewShotConfig `yaml:"bootstrap_few_shot"`
// MIPRO optimizer
MIPRO MIPROConfig `yaml:"mipro"`
// COPRO optimizer
COPRO COPROConfig `yaml:"copro"`
// SIMBA optimizer
SIMBA SIMBAConfig `yaml:"simba"`
// TPE optimizer
TPE TPEConfig `yaml:"tpe"`
}
OptimizersConfig holds optimizer configuration.
type PredictConfig ¶
type PredictConfig struct {
// Default prediction settings
DefaultSettings PredictSettings `yaml:"default_settings"`
// Caching configuration
Caching CachingConfig `yaml:"caching"`
}
PredictConfig holds Predict module configuration.
type PredictSettings ¶
type PredictSettings struct {
// Include confidence scores
IncludeConfidence bool `yaml:"include_confidence"`
// Temperature for prediction
Temperature float64 `yaml:"temperature" validate:"min=0,max=2"`
// Top-k for prediction
TopK int `yaml:"top_k" validate:"min=1"`
}
PredictSettings holds prediction settings.
type RateLimitInterceptorConfig ¶
type RateLimitInterceptorConfig struct {
Enabled bool `yaml:"enabled"`
RequestsPerMinute int `yaml:"requests_per_minute,omitempty" validate:"omitempty,min=1"`
BurstSize int `yaml:"burst_size,omitempty" validate:"omitempty,min=1"`
WindowSize time.Duration `yaml:"window_size,omitempty" validate:"omitempty,min=1s"`
}
RateLimitInterceptorConfig holds rate limiting interceptor configuration.
type ReActConfig ¶
type ReActConfig struct {
// Maximum number of action/observation cycles
MaxCycles int `yaml:"max_cycles" validate:"min=1"`
// Action timeout
ActionTimeout time.Duration `yaml:"action_timeout" validate:"min=1s"`
// Whether to include intermediate steps
IncludeIntermediateSteps bool `yaml:"include_intermediate_steps"`
}
ReActConfig holds ReAct module configuration.
type RefineConfig ¶
type RefineConfig struct {
// Maximum refinement iterations
MaxIterations int `yaml:"max_iterations" validate:"min=1"`
// Convergence threshold
ConvergenceThreshold float64 `yaml:"convergence_threshold" validate:"min=0,max=1"`
// Refinement strategy
RefinementStrategy string `yaml:"refinement_strategy" validate:"oneof=iterative_improvement feedback_based"`
}
RefineConfig holds Refine module configuration.
type RemoteSource ¶
type RemoteSource struct {
// contains filtered or unexported fields
}
RemoteSource loads configuration from a remote URL (placeholder for future implementation).
func NewRemoteSource ¶
func NewRemoteSource(url string) *RemoteSource
NewRemoteSource creates a new remote source (placeholder).
func (*RemoteSource) Load ¶
func (rs *RemoteSource) Load(config *Config, paths []string) error
Load loads configuration from a remote URL (placeholder implementation).
func (*RemoteSource) Name ¶
func (rs *RemoteSource) Name() string
Name returns the name of the remote source.
func (*RemoteSource) Priority ¶
func (rs *RemoteSource) Priority() int
Priority returns the priority of the remote source.
type RetryConfig ¶
type RetryConfig struct {
// Maximum number of retries
MaxRetries int `yaml:"max_retries" validate:"min=0"`
// Initial backoff duration
InitialBackoff time.Duration `yaml:"initial_backoff" validate:"min=0"`
// Maximum backoff duration
MaxBackoff time.Duration `yaml:"max_backoff" validate:"min=0"`
// Backoff multiplier
BackoffMultiplier float64 `yaml:"backoff_multiplier" validate:"min=1.0"`
}
RetryConfig holds retry-specific configuration.
func GetDefaultRetryConfig ¶
func GetDefaultRetryConfig() *RetryConfig
GetDefaultRetryConfig returns default retry configuration.
type RetryInterceptorConfig ¶
type RetryInterceptorConfig struct {
Enabled bool `yaml:"enabled"`
MaxRetries int `yaml:"max_retries,omitempty" validate:"omitempty,min=1"`
InitialBackoff time.Duration `yaml:"initial_backoff,omitempty" validate:"omitempty,min=1ms"`
MaxBackoff time.Duration `yaml:"max_backoff,omitempty" validate:"omitempty,min=1ms"`
BackoffFactor float64 `yaml:"backoff_factor,omitempty" validate:"omitempty,min=1.0"`
}
RetryInterceptorConfig holds retry interceptor configuration.
type SIMBAConfig ¶
type SIMBAConfig struct {
// Number of candidates
NumCandidates int `yaml:"num_candidates" validate:"min=1"`
// Selection strategy
SelectionStrategy string `yaml:"selection_strategy" validate:"oneof=random tournament roulette"`
// Evaluation metric
EvaluationMetric string `yaml:"evaluation_metric"`
}
SIMBAConfig holds SIMBA optimizer configuration.
type SQLiteCacheConfig ¶
type SQLiteCacheConfig struct {
// Path to SQLite database file
Path string `yaml:"path"`
// Enable WAL mode for better concurrent performance
EnableWAL bool `yaml:"enable_wal"`
// Vacuum interval for database maintenance
VacuumInterval time.Duration `yaml:"vacuum_interval"`
// Maximum number of connections
MaxConnections int `yaml:"max_connections"`
}
SQLiteCacheConfig holds SQLite-specific cache configuration.
type SanitizationInterceptorConfig ¶
type SanitizationInterceptorConfig struct {
Enabled bool `yaml:"enabled"`
RemoveHTML bool `yaml:"remove_html,omitempty"`
RemoveSQL bool `yaml:"remove_sql,omitempty"`
RemoveScript bool `yaml:"remove_script,omitempty"`
CustomPatterns []string `yaml:"custom_patterns,omitempty"`
MaxStringLength int `yaml:"max_string_length,omitempty" validate:"omitempty,min=1"`
}
SanitizationInterceptorConfig holds sanitization interceptor configuration.
type Source ¶
type Source interface {
// Load loads configuration from the source into the provided config
Load(config *Config, paths []string) error
// Name returns the name of the source
Name() string
// Priority returns the priority of the source (higher priority overrides lower)
Priority() int
}
Source represents a configuration source.
func CreateAllSources ¶
CreateAllSources creates all available configuration sources.
func CreateDefaultSources ¶
func CreateDefaultSources() []Source
CreateDefaultSources creates the default set of configuration sources.
type TPEConfig ¶
type TPEConfig struct {
// Number of trials
NumTrials int `yaml:"num_trials" validate:"min=1"`
// Number of startup trials
NumStartupTrials int `yaml:"num_startup_trials" validate:"min=1"`
// Percentile for good/bad split
Percentile float64 `yaml:"percentile" validate:"min=0,max=1"`
// Random seed
RandomSeed int64 `yaml:"random_seed"`
}
TPEConfig holds TPE optimizer configuration.
type TimeoutInterceptorConfig ¶
type TimeoutInterceptorConfig struct {
Enabled bool `yaml:"enabled"`
Timeout time.Duration `yaml:"timeout,omitempty" validate:"omitempty,min=1s"`
}
TimeoutInterceptorConfig holds timeout interceptor configuration.
type ToolInterceptorsConfig ¶
type ToolInterceptorsConfig struct {
// Standard interceptors
Logging InterceptorToggle `yaml:"logging,omitempty"`
Metrics InterceptorToggle `yaml:"metrics,omitempty"`
Tracing InterceptorToggle `yaml:"tracing,omitempty"`
// Performance interceptors
Caching CachingInterceptorConfig `yaml:"caching,omitempty"`
Timeout TimeoutInterceptorConfig `yaml:"timeout,omitempty"`
// Security interceptors
Validation ValidationInterceptorConfig `yaml:"validation,omitempty"`
Authorization AuthorizationInterceptorConfig `yaml:"authorization,omitempty"`
Sanitization SanitizationInterceptorConfig `yaml:"sanitization,omitempty"`
}
ToolInterceptorsConfig holds tool-specific interceptor configuration.
type ToolRegistryConfig ¶
type ToolRegistryConfig struct {
// Maximum registered tools
MaxTools int `yaml:"max_tools,omitempty" validate:"omitempty,min=1"`
// Tool discovery paths
DiscoveryPaths []string `yaml:"discovery_paths,omitempty"`
// Auto-discovery enabled
AutoDiscovery bool `yaml:"auto_discovery,omitempty"`
}
ToolRegistryConfig holds tool registry configuration.
type ToolUseConfig ¶
type ToolUseConfig struct {
// Maximum tools per request
MaxTools int `yaml:"max_tools" validate:"min=1"`
// Tool timeout
Timeout time.Duration `yaml:"timeout" validate:"min=1s"`
// Enable parallel tool execution
ParallelExecution bool `yaml:"parallel_execution"`
}
ToolUseConfig holds tool usage configuration.
type ToolsConfig ¶
type ToolsConfig struct {
// Registry configuration
Registry ToolRegistryConfig `yaml:"registry"`
// MCP configuration
MCP MCPConfig `yaml:"mcp"`
// Function tools configuration
Functions FunctionToolsConfig `yaml:"functions"`
}
ToolsConfig holds tool configuration.
type TracingConfig ¶
type TracingConfig struct {
// Enable tracing
Enabled bool `yaml:"enabled"`
// Sampling rate for traces
SamplingRate float64 `yaml:"sampling_rate" validate:"min=0,max=1"`
// Trace export configuration
Exporter TracingExporterConfig `yaml:"exporter"`
}
TracingConfig holds tracing configuration.
type TracingExporterConfig ¶
type TracingExporterConfig struct {
// Exporter type (jaeger, zipkin, otlp)
Type string `yaml:"type" validate:"oneof=jaeger zipkin otlp"`
// Endpoint for the exporter
Endpoint string `yaml:"endpoint"`
// Additional headers
Headers map[string]string `yaml:"headers"`
}
TracingExporterConfig holds trace export configuration.
type ValidationError ¶
ValidationError represents a configuration validation error.
func (*ValidationError) Error ¶
func (e *ValidationError) Error() string
type ValidationErrors ¶
type ValidationErrors []ValidationError
ValidationErrors represents multiple validation errors.
func (ValidationErrors) Error ¶
func (e ValidationErrors) Error() string
type ValidationInterceptorConfig ¶
type ValidationInterceptorConfig struct {
Enabled bool `yaml:"enabled"`
StrictMode bool `yaml:"strict_mode,omitempty"`
RequiredFields []string `yaml:"required_fields,omitempty"`
MaxInputSize int64 `yaml:"max_input_size,omitempty" validate:"omitempty,min=1"`
MaxStringLength int `yaml:"max_string_length,omitempty" validate:"omitempty,min=1"`
AllowedContentTypes []string `yaml:"allowed_content_types,omitempty"`
}
ValidationInterceptorConfig holds validation interceptor configuration.
type Validator ¶
type Validator struct {
// contains filtered or unexported fields
}
Validator provides configuration validation.
func GetValidator ¶
func GetValidator() *Validator
GetValidator returns the global validator instance.
func NewValidator ¶
NewValidator creates a new configuration validator.
func (*Validator) ValidateConfig ¶
ValidateConfig validates a configuration struct.
type WorkflowPersistenceConfig ¶
type WorkflowPersistenceConfig struct {
// Enable persistence
Enabled bool `yaml:"enabled"`
// Storage backend
Backend string `yaml:"backend" validate:"oneof=file sqlite redis"`
// Storage configuration
Config map[string]interface{} `yaml:"config"`
}
WorkflowPersistenceConfig holds workflow persistence configuration.
type WorkflowsConfig ¶
type WorkflowsConfig struct {
// Default workflow timeout
DefaultTimeout time.Duration `yaml:"default_timeout" validate:"min=1s"`
// Maximum parallel workflows
MaxParallel int `yaml:"max_parallel" validate:"min=1"`
// Workflow persistence
Persistence WorkflowPersistenceConfig `yaml:"persistence"`
}
WorkflowsConfig holds workflow configuration.