Documentation
¶
Index ¶
- func DeepCopyJSON[T any](src T) (T, error)
- func OpenAIConfigFromServiceConfig(serviceConfig llm.ServiceConfig, botConfig llm.BotConfig) openai.Config
- func OpenAIConfigFromServiceConfigWithOptions(serviceConfig llm.ServiceConfig, botConfig llm.BotConfig, ...) openai.Config
- type Config
- type Container
- func (c *Container) AllowNativeWebSearchInChannels() bool
- func (c *Container) AllowUnsafeLinks() bool
- func (c *Container) Config() *Config
- func (c *Container) EmbeddingSearchConfig() embeddings.EmbeddingSearchConfig
- func (c *Container) EnableChannelMentionToolCalling() bool
- func (c *Container) EnableLLMLogging() bool
- func (c *Container) EnableTokenUsageLogging() bool
- func (c *Container) GetBots() []llm.BotConfig
- func (c *Container) GetDefaultBotName() string
- func (c *Container) GetEnableLLMTrace() bool
- func (c *Container) GetServiceByID(id string) (llm.ServiceConfig, bool)
- func (c *Container) GetTranscriptGenerator() string
- func (c *Container) MCP() mcp.Config
- func (c *Container) RegisterUpdateListener(listener UpdateListener)
- func (c *Container) Update(newConfig *Config)
- type UpdateListener
- type WebSearchBraveConfig
- type WebSearchConfig
- type WebSearchGoogleConfig
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DeepCopyJSON ¶
DeepCopyJSON creates a deep copy of JSON-serializable structs
func OpenAIConfigFromServiceConfigWithOptions ¶ added in v1.7.0
func OpenAIConfigFromServiceConfigWithOptions(serviceConfig llm.ServiceConfig, botConfig llm.BotConfig, disableStreamOptions bool, useMaxTokens bool) openai.Config
OpenAIConfigFromServiceConfigWithOptions creates an OpenAI config with additional options for OpenAI-compatible APIs
Types ¶
type Config ¶
type Config struct {
Services []llm.ServiceConfig `json:"services"`
Bots []llm.BotConfig `json:"bots"`
DefaultBotName string `json:"defaultBotName"`
TranscriptGenerator string `json:"transcriptBackend"`
EnableLLMTrace bool `json:"enableLLMTrace"`
EnableTokenUsageLogging bool `json:"enableTokenUsageLogging"`
AllowedUpstreamHostnames string `json:"allowedUpstreamHostnames"`
AllowUnsafeLinks bool `json:"allowUnsafeLinks"`
EnableChannelMentionToolCalling bool `json:"enableChannelMentionToolCalling"`
AllowNativeWebSearchInChannels bool `json:"allowNativeWebSearchInChannels"`
EmbeddingSearchConfig embeddings.EmbeddingSearchConfig `json:"embeddingSearchConfig"`
MCP mcp.Config `json:"mcp"`
WebSearch WebSearchConfig `json:"webSearch"`
}
func (*Config) GetServiceByID ¶ added in v1.5.0
func (c *Config) GetServiceByID(id string) (llm.ServiceConfig, bool)
GetServiceByID returns the service configuration for the given ID
type Container ¶
type Container struct {
// contains filtered or unexported fields
}
func (*Container) AllowNativeWebSearchInChannels ¶ added in v1.8.1
func (*Container) AllowUnsafeLinks ¶ added in v1.5.0
func (*Container) Config ¶
Config retruns the whole configuration readonly. Avoid using this method, prefer using config though interfaces.
func (*Container) EmbeddingSearchConfig ¶
func (c *Container) EmbeddingSearchConfig() embeddings.EmbeddingSearchConfig
func (*Container) EnableChannelMentionToolCalling ¶ added in v1.9.0
func (*Container) EnableLLMLogging ¶
func (*Container) EnableTokenUsageLogging ¶ added in v1.4.0
func (*Container) GetDefaultBotName ¶
func (*Container) GetEnableLLMTrace ¶
func (*Container) GetServiceByID ¶ added in v1.5.0
func (c *Container) GetServiceByID(id string) (llm.ServiceConfig, bool)
GetServiceByID returns the service configuration for the given ID
func (*Container) GetTranscriptGenerator ¶
func (*Container) RegisterUpdateListener ¶
func (c *Container) RegisterUpdateListener(listener UpdateListener)
type UpdateListener ¶
type UpdateListener func()
type WebSearchBraveConfig ¶ added in v1.8.0
type WebSearchConfig ¶ added in v1.8.0
type WebSearchConfig struct {
Enabled bool `json:"enabled"`
Provider string `json:"provider"`
Google WebSearchGoogleConfig `json:"google"`
Brave WebSearchBraveConfig `json:"brave"`
DomainDenylist []string `json:"domainDenylist"`
}
Click to show internal directories.
Click to hide internal directories.