Documentation
¶
Index ¶
- Variables
- func CreatePluginTemplate(pluginDir, name string) error
- type AgentCommand
- type Bridge
- type Info
- type LoadedPlugin
- type Manager
- func (m *Manager) ExecutePlugin(pluginName, command string, args []string) (*Result, error)
- func (m *Manager) GetPlugin(name string) (*Info, error)
- func (m *Manager) ListPlugins() map[string]*Info
- func (m *Manager) LoadPlugins() error
- func (m *Manager) UnloadAllPlugins()
- func (m *Manager) UnloadPlugin(name string) error
- type Manifest
- type PluginInterface
- type PluginRPC
- type PluginRPCPlugin
- type PluginRPCServer
- type Result
Constants ¶
This section is empty.
Variables ¶
var Handshake = plugin.HandshakeConfig{
ProtocolVersion: 1,
MagicCookieKey: "LUCIEN_PLUGIN",
MagicCookieValue: "lucien_neural_interface",
}
Handshake configuration for plugins
Functions ¶
func CreatePluginTemplate ¶
CreatePluginTemplate creates a basic plugin template
Types ¶
type AgentCommand ¶
AgentCommand represents an agent command configuration
type Bridge ¶
type Bridge struct {
// contains filtered or unexported fields
}
Bridge handles Python agent command execution
func (*Bridge) ExecuteWithTimeout ¶
func (b *Bridge) ExecuteWithTimeout(command string, args []string, timeout time.Duration) (string, error)
ExecuteWithTimeout runs an agent command with a timeout
func (*Bridge) GetAvailableAgents ¶
func (b *Bridge) GetAvailableAgents() []AgentCommand
GetAvailableAgents returns a list of available agent commands
func (*Bridge) IsAgentCommand ¶
IsAgentCommand checks if a command is an agent command
type Info ¶
type Info struct {
Name string `json:"name"`
Version string `json:"version"`
Description string `json:"description"`
Author string `json:"author"`
Capabilities []string `json:"capabilities"`
Config map[string]string `json:"config"`
}
Info contains plugin metadata
type LoadedPlugin ¶
type LoadedPlugin struct {
// contains filtered or unexported fields
}
LoadedPlugin represents a loaded plugin instance
type Manager ¶
type Manager struct {
// contains filtered or unexported fields
}
Manager handles plugin lifecycle and execution
func (*Manager) ExecutePlugin ¶
ExecutePlugin executes a command in the specified plugin with security validation
func (*Manager) ListPlugins ¶
ListPlugins returns information about all loaded plugins
func (*Manager) LoadPlugins ¶
LoadPlugins discovers and loads all plugins from the plugin directory
func (*Manager) UnloadAllPlugins ¶
func (m *Manager) UnloadAllPlugins()
UnloadAllPlugins unloads all plugins
func (*Manager) UnloadPlugin ¶
UnloadPlugin unloads a specific plugin
type Manifest ¶
type Manifest struct {
Name string `json:"name"`
Version string `json:"version"`
Description string `json:"description"`
Author string `json:"author"`
Executable string `json:"executable"`
Capabilities []string `json:"capabilities"`
Config map[string]string `json:"config"`
Dependencies []string `json:"dependencies"`
}
Manifest describes a plugin's configuration
type PluginInterface ¶
type PluginInterface interface {
Execute(ctx context.Context, command string, args []string) (*Result, error)
GetInfo() (*Info, error)
Initialize(config map[string]interface{}) error
}
PluginInterface defines the interface that all Lucien plugins must implement
type PluginRPC ¶
type PluginRPC struct {
// contains filtered or unexported fields
}
Plugin RPC implementation
func (*PluginRPC) Initialize ¶
type PluginRPCPlugin ¶
type PluginRPCPlugin struct{}
RPC Plugin implementation
type PluginRPCServer ¶
type PluginRPCServer struct {
}
func (*PluginRPCServer) Execute ¶
func (s *PluginRPCServer) Execute(req map[string]interface{}, resp *Result) error
Server RPC methods - simplified for demo
func (*PluginRPCServer) GetInfo ¶
func (s *PluginRPCServer) GetInfo(req interface{}, resp *Info) error
func (*PluginRPCServer) Initialize ¶
func (s *PluginRPCServer) Initialize(config map[string]interface{}, resp *interface{}) error