Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ButlerConfig ¶
type ButlerConfig struct {
Enabled *bool `json:"enabled"` // nil treated as true (kill switch)
Project ProjectMeta `json:"project"`
Capabilities Capabilities `json:"capabilities"`
DocPaths []string `json:"doc_paths"`
Upstream []UpstreamDep `json:"upstream"`
Synthesis SynthesisConfig `json:"synthesis"`
ShadowRepo string `json:"shadow_repo"`
Thresholds map[string]float64 `json:"thresholds"`
MaxDailyLLMCalls int `json:"max_daily_llm_calls"`
ResearchBrief ResearchBriefConfig `json:"research_brief"`
}
func DefaultConfig ¶
func DefaultConfig() ButlerConfig
func Parse ¶
func Parse(data []byte) (ButlerConfig, error)
func (ButlerConfig) IsEnabled ¶
func (c ButlerConfig) IsEnabled() bool
IsEnabled returns false only when Enabled is explicitly set to false.
func (ButlerConfig) Validate ¶ added in v0.1.1
func (c ButlerConfig) Validate() []string
Validate checks a ButlerConfig for common misconfigurations and returns a list of warnings. An empty list means the config is valid.
type Cache ¶
type Cache struct {
// contains filtered or unexported fields
}
Cache provides a TTL-based cache for butler config.
func (*Cache) Get ¶
func (c *Cache) Get() (ButlerConfig, error)
Get returns the cached config, fetching it if the cache is stale or empty.
func (*Cache) Invalidate ¶
func (c *Cache) Invalidate()
Invalidate forces the next Get() call to re-fetch.
type Capabilities ¶
type FetchFunc ¶
FetchFunc fetches the raw config file content. Returns nil, nil if the file doesn't exist.
type ProjectMeta ¶ added in v0.1.1
type ProjectMeta struct {
Name string `json:"name"` // human-readable project name (e.g. "Teams for Linux")
Description string `json:"description"` // architecture description for research prompts
DocsURL string `json:"docs_url"` // base URL for project documentation site
DebugCommand string `json:"debug_command"` // shell command users run to capture debug logs
}
ProjectMeta holds per-repo metadata used to parameterize LLM prompts and bot output. Defaults match the teams-for-linux deployment for backward compatibility; other repos override these in their butler.json.