Documentation
¶
Index ¶
- type AppConfig
- func (c *AppConfig) AddServer(name string, inst *ServerInstance)
- func (c *AppConfig) GetDefaultServer() *ServerInstance
- func (c *AppConfig) GetOutputFormat() string
- func (c *AppConfig) GetServer(name string) *ServerInstance
- func (c *AppConfig) ListServers() []string
- func (c *AppConfig) RemoveServer(name string)
- func (c *AppConfig) SetDefault(name string)
- type ServerInstance
- type Servers
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AppConfig ¶
type AppConfig struct {
Version string `yaml:"version"`
Servers *Servers `yaml:"servers"`
AI struct {
Provider string `yaml:"provider"`
BaseURL string `yaml:"base_url"`
ApiKey string `yaml:"api_key"`
Model string `yaml:"model"`
MaxTokens int `yaml:"max_tokens"`
Temperature float64 `yaml:"temperature"`
Timeout int `yaml:"timeout"`
} `yaml:"ai"`
Output struct {
Format string `yaml:"format"`
} `yaml:"output"`
Log struct {
Level string `yaml:"level"`
MaxSize int `yaml:"maxSize"`
MaxBackups int `yaml:"maxBackups"`
MaxAge int `yaml:"maxAge"`
Compress bool `yaml:"compress"`
} `yaml:"log"`
}
func (*AppConfig) AddServer ¶
func (c *AppConfig) AddServer(name string, inst *ServerInstance)
func (*AppConfig) GetDefaultServer ¶
func (c *AppConfig) GetDefaultServer() *ServerInstance
func (*AppConfig) GetOutputFormat ¶
func (*AppConfig) GetServer ¶
func (c *AppConfig) GetServer(name string) *ServerInstance
func (*AppConfig) ListServers ¶
func (*AppConfig) RemoveServer ¶
func (*AppConfig) SetDefault ¶
type ServerInstance ¶
type Servers ¶
type Servers struct {
Default string `yaml:"default"`
Instances map[string]*ServerInstance `yaml:"instances"`
}
Click to show internal directories.
Click to hide internal directories.