Documentation
¶
Index ¶
Examples ¶
Constants ¶
View Source
const ( DaemonName = "violet" DefaultVersion = "dev" )
Variables ¶
This section is empty.
Functions ¶
func DefaultSocketPath ¶
Example ¶
core.Println("DefaultSocketPath")
Output: DefaultSocketPath
Types ¶
type Registry ¶
type Registry struct {
// contains filtered or unexported fields
}
Registry maps daemon actions to handlers. It preserves registration order so the info response is stable and human-readable.
func DefaultRegistryForDaemon ¶
func DefaultRegistryForDaemon() *Registry
Example ¶
core.Println("DefaultRegistryForDaemon")
Output: DefaultRegistryForDaemon
func NewRegistry ¶
Example ¶
Generated runnable examples for file-aware public API coverage.
core.Println("NewRegistry")
Output: NewRegistry
type Request ¶
type Request struct {
Action string `json:"action"`
Text string `json:"text,omitempty"`
Prompt string `json:"prompt,omitempty"`
Model string `json:"model,omitempty"`
}
Request is one JSON-line frame from a local Violet client.
type Response ¶
Response is encoded as one complete JSON-line frame. Streaming responses are intentionally deferred so the initial UDS contract stays simple.
type Server ¶
func NewServer ¶
func NewServer(cfg ServerConfig) *Server
Example ¶
Generated runnable examples for file-aware public API coverage.
core.Println("NewServer")
Output: NewServer
type ServerConfig ¶
type ServerConfig struct {
SocketPath string
Registry *Registry
// ModelPaths is populated from config/env by cmd/violet. Violet is one
// process for multiple configured models; actual model loading is a follow-up
// and should load once at startup, with restart as the swap mechanism.
ModelPaths map[string]string
}
Click to show internal directories.
Click to hide internal directories.