plugins

package
v0.1.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 27, 2026 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Registry = make(map[string]PluginFactory)

Registry holds all available plugin factories

Functions

func ListPlugins

func ListPlugins() []string

ListPlugins returns a list of available plugin names

func NewPlugin

func NewPlugin(name string) (dispatcher.BackendPlugin, error)

NewPlugin creates a new plugin instance by name

Types

type FilePlugin

type FilePlugin struct {
	// contains filtered or unexported fields
}

FilePlugin implements file-based event logging

func NewFilePlugin

func NewFilePlugin() *FilePlugin

NewFilePlugin creates a new file plugin

func (*FilePlugin) Close

func (p *FilePlugin) Close() error

Close closes the file

func (*FilePlugin) Init

func (p *FilePlugin) Init(cfg map[string]string) error

Init initializes the file plugin with configuration

func (*FilePlugin) SendEvents

func (p *FilePlugin) SendEvents(ctx context.Context, events []dispatcher.EventPayload) error

SendEvents writes events to the file as JSONL (JSON Lines)

type HeliconePlugin

type HeliconePlugin struct {
	// contains filtered or unexported fields
}

HeliconePlugin implements Helicone backend integration

func NewHeliconePlugin

func NewHeliconePlugin() *HeliconePlugin

NewHeliconePlugin creates a new Helicone plugin

func (*HeliconePlugin) Close

func (p *HeliconePlugin) Close() error

Close cleans up the plugin resources

func (*HeliconePlugin) Init

func (p *HeliconePlugin) Init(cfg map[string]string) error

Init initializes the Helicone plugin with configuration

func (*HeliconePlugin) SendEvents

func (p *HeliconePlugin) SendEvents(ctx context.Context, events []dispatcher.EventPayload) error

SendEvents sends events to Helicone

type LunaryPlugin

type LunaryPlugin struct {
	// contains filtered or unexported fields
}

LunaryPlugin implements Lunary.ai backend integration

func NewLunaryPlugin

func NewLunaryPlugin() *LunaryPlugin

NewLunaryPlugin creates a new Lunary plugin

func (*LunaryPlugin) Close

func (p *LunaryPlugin) Close() error

Close cleans up the plugin resources

func (*LunaryPlugin) Init

func (p *LunaryPlugin) Init(cfg map[string]string) error

Init initializes the Lunary plugin with configuration

func (*LunaryPlugin) SendEvents

func (p *LunaryPlugin) SendEvents(ctx context.Context, events []dispatcher.EventPayload) error

SendEvents sends events to Lunary.ai

type PluginFactory

type PluginFactory func() dispatcher.BackendPlugin

PluginFactory is a function that creates a new plugin instance

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL