Documentation
¶
Overview ¶
Package config provides configuration structures for AX server.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type A2AConfig ¶
type A2AConfig struct {
Stateless bool `yaml:"stateless,omitempty"` // Send full history each turn (default: stateful)
}
A2AConfig holds A2A-protocol-specific options. Honored only when RemoteAgentConfig.Protocol is "a2a".
type ATEConfig ¶
type ATEConfig struct {
Endpoint string `yaml:"endpoint"`
}
ATEConfig configures the ATE integration.
type ColabAgentConfig ¶
type ColabAgentConfig struct {
ID string `yaml:"id"` // Unique agent identifier
Name string `yaml:"name"` // Human-readable name
Description string `yaml:"description"` // Description of agent capabilities
LocalFile string `yaml:"local_file,omitempty"` // Path to local .py or .ipynb file (uploaded to VM)
DriveFile string `yaml:"drive_file,omitempty"` // Path to .ipynb file in Google Drive (e.g. MyDrive/notebooks/nb.ipynb)
Accelerator string `yaml:"accelerator,omitempty"` // Accelerator type (optional), e.g. "tpu-v5e1", "gpu-A100"
DriveMountPath string `yaml:"drive_mount_path,omitempty"` // Path to mount Google Drive (optional), default: "/content/drive"
Requirements string `yaml:"requirements,omitempty"` // Path to requirements.txt (optional)
InputFlag string `yaml:"input_flag,omitempty"` // Input parameter name (optional). For .py, passed as --<name>. For .ipynb, set as a variable before %run
OutputImage string `yaml:"output_image,omitempty"` // Local path to download the output image to
OutputDrivePath string `yaml:"output_drive_path,omitempty"` // Google Drive path to save converted .ipynb (e.g. MyDrive/notebooks/out.ipynb)
Metadata map[string]string `yaml:"metadata,omitempty"` // Optional metadata
}
ColabAgentConfig configures a Colab agent to register on startup.
type Config ¶
type Config struct {
Server ServerConfig `yaml:"server"`
EventLog EventLogConfig `yaml:"eventlog"`
Planner PlannerConfig `yaml:"planner,omitempty"`
Registry RegistryConfig `yaml:"registry,omitempty"`
ATE ATEConfig `yaml:"ate,omitempty"`
}
Config represents the main configuration for AX server.
func DefaultConfig ¶
func DefaultConfig() *Config
DefaultConfig returns a configuration with default values set.
func LoadFromFile ¶
LoadFromFile loads configuration from a YAML file.
type EventLogConfig ¶
type EventLogConfig struct {
SQLiteConfig SQLiteConfig `yaml:"sqlite"`
}
EventLogConfig configures the event log storage.
type GeminiConfig ¶
type GeminiConfig struct {
Model string `json:"model,omitempty" yaml:"model,omitempty"`
SystemPrompt string `json:"system_prompt,omitempty" yaml:"system_prompt,omitempty"`
MaxTokens int32 `json:"max_tokens,omitempty" yaml:"max_tokens,omitempty"`
Temperature float32 `json:"temperature,omitempty" yaml:"temperature,omitempty"` // 0 means use model default
Timeout time.Duration `json:"timeout,omitempty" yaml:"timeout,omitempty"`
Tools []string `json:"tools,omitempty" yaml:"tools,omitempty"`
}
GeminiConfig is the configuration for a Gemini agent execution.
type GeminiPlannerConfig ¶
type GeminiPlannerConfig struct {
Model string `yaml:"model,omitempty"` // Model name
Temperature float32 `yaml:"temperature,omitempty"`
MaxTokens int32 `yaml:"max_tokens,omitempty"`
Timeout string `yaml:"timeout,omitempty"`
SystemPrompt string `yaml:"system_prompt,omitempty"`
SkillsDir string `yaml:"skills_dir,omitempty"` // Directory to discover skills from. If omitted, falls back to SKILLS_DIR env var or ~/.agents/skills.
}
GeminiPlannerConfig configures the Gemini-based planner. Note: API key is not configurable here for security reasons. Set GEMINI_API_KEY environment variable instead.
type LocalAgentConfig ¶
type LocalAgentConfig struct {
ID string `yaml:"id"` // Unique agent identifier
Name string `yaml:"name"` // Human-readable name
Description string `yaml:"description"` // Description of agent capabilities
Metadata map[string]string `yaml:"metadata,omitempty"` // Optional metadata
Agent agent.Agent // In-process agent instance (not in YAML)
}
type PlannerConfig ¶
type PlannerConfig struct {
Type string `yaml:"type"` // "gemini"
Gemini GeminiPlannerConfig `yaml:"gemini,omitempty"`
}
PlannerConfig configures the planner.
type RegistryConfig ¶
type RegistryConfig struct {
RemoteAgents []RemoteAgentConfig `yaml:"remote_agents,omitempty"`
ColabAgents []ColabAgentConfig `yaml:"colab_agents,omitempty"`
SubstrateAgents []SubstrateAgentConfig `yaml:"substrate_agents,omitempty"`
}
RegistryConfig allows registring agents.
type RemoteAgentConfig ¶
type RemoteAgentConfig struct {
ID string `yaml:"id"` // Unique agent identifier
Name string `yaml:"name"` // Human-readable name
Description string `yaml:"description"` // Description
Address string `yaml:"address"` // Remote agent address
Protocol string `yaml:"protocol,omitempty"` // "axp" (default) or "a2a"
Auth auth.Auth `yaml:"auth,omitempty"` // Optional auth (cross-protocol; today honored only for a2a)
Headers auth.Headers `yaml:"headers,omitempty"` // Optional headers (cross-protocol; today honored only for a2a)
A2A A2AConfig `yaml:"a2a,omitempty"` // A2A-protocol-specific options
Metadata map[string]string `yaml:"metadata,omitempty"` // Optional metadata
}
RemoteAgentConfig configures a remote agent to register on startup.
type SQLiteConfig ¶
type SQLiteConfig struct {
Filename string `yaml:"filename"` // SQLite file for event log storage
}
type ServerConfig ¶
type ServerConfig struct {
Address string `yaml:"address"` // Server address to listen on (e.g., ":8494")
}
ServerConfig configures the gRPC server.
type SubstrateAgentConfig ¶
type SubstrateAgentConfig struct {
ID string `yaml:"id"` // Unique agent identifier
Name string `yaml:"name"` // Human-readable name
Description string `yaml:"description"` // Description of agent capabilities
Port int `yaml:"port"` // Port the agent is listening on
Namespace string `yaml:"namespace"` // Namespace for actor
Template string `yaml:"template"` // Template for actor
Protocol string `yaml:"protocol,omitempty"` // "axp" (default) or "a2a"
Auth auth.Auth `yaml:"auth,omitempty"` // Optional auth
Headers auth.Headers `yaml:"headers,omitempty"` // Optional headers
Metadata map[string]string `yaml:"metadata,omitempty"` // Optional metadata
}
SubstrateAgentConfig allows registering a new agent with an ATE actor template.