model

package
v0.93.0 Latest Latest
Warning

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

Go to latest
Published: Jun 17, 2026 License: GPL-3.0 Imports: 2 Imported by: 0

Documentation

Overview

Package model provides shared data types for UI views and transport.

Package model provides shared data types for UI views and transport.

Package model provides shared data types for UI views and transport.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AgentSession added in v0.93.0

type AgentSession struct {
	Flag      string    `json:"flag"`
	UID       string    `json:"uid"`
	LeafID    string    `json:"leaf_id"`
	State     string    `json:"state"`
	CreatedAt time.Time `json:"created_at"`
	UpdatedAt time.Time `json:"updated_at"`
}

AgentSession represents a chat agent session for UI display and transport.

type AgentSessionEntry added in v0.93.0

type AgentSessionEntry struct {
	Flag        string    `json:"flag"`
	SessionID   string    `json:"session_id"`
	ParentID    string    `json:"parent_id"`
	EntryType   string    `json:"entry_type"`
	PayloadJSON string    `json:"payload_json"`
	CreatedAt   time.Time `json:"created_at"`
}

AgentSessionEntry represents one append-only node in a chat session tree for UI display.

type AgentSkill added in v0.93.0

type AgentSkill struct {
	Flag                   string    `json:"flag"`
	Name                   string    `json:"name"`
	Description            string    `json:"description"`
	Content                string    `json:"content"`
	BaseDir                string    `json:"base_dir"`
	Source                 string    `json:"source"`
	Enabled                bool      `json:"enabled"`
	DisableModelInvocation bool      `json:"disable_model_invocation"`
	CreatedAt              time.Time `json:"created_at"`
	UpdatedAt              time.Time `json:"updated_at"`
}

AgentSkill represents an agent skill definition for UI display and transport.

type AgentSubagent added in v0.93.0

type AgentSubagent struct {
	Flag         string    `json:"flag"`
	Name         string    `json:"name"`
	Description  string    `json:"description"`
	SystemPrompt string    `json:"system_prompt"`
	Tools        []string  `json:"tools"`
	Model        string    `json:"model"`
	Source       string    `json:"source"`
	Enabled      bool      `json:"enabled"`
	CreatedAt    time.Time `json:"created_at"`
	UpdatedAt    time.Time `json:"updated_at"`
}

AgentSubagent represents a chat assistant subagent definition for UI display and transport.

type ConfigItem

type ConfigItem struct {
	ID        int64     `json:"id"`
	UID       string    `json:"uid"`
	Topic     string    `json:"topic"`
	Key       string    `json:"key"`
	Value     types.KV  `json:"value"`
	CreatedAt time.Time `json:"created_at"`
	UpdatedAt time.Time `json:"updated_at"`
}

ConfigItem represents a row from the configs database table.

type NotifyChannel

type NotifyChannel struct {
	ID        int64     `json:"id"`
	Name      string    `json:"name"`
	Protocol  string    `json:"protocol"`
	URI       string    `json:"uri"` // masked for display
	Enabled   bool      `json:"enabled"`
	CreatedAt time.Time `json:"created_at"`
	UpdatedAt time.Time `json:"updated_at"`
}

NotifyChannel represents a configured notification channel for UI display. The URI is masked for display; raw URI is never exposed to the client.

type NotifyRule

type NotifyRule struct {
	ID             int64     `json:"id"`
	RuleID         string    `json:"rule_id"`
	Name           string    `json:"name"`
	Action         string    `json:"action"`
	EventPattern   string    `json:"event_pattern"`
	ChannelPattern string    `json:"channel_pattern"`
	Condition      string    `json:"condition"`
	Priority       int       `json:"priority"`
	ParamsJSON     string    `json:"params_json"` // JSON string for form display
	Enabled        bool      `json:"enabled"`
	CreatedAt      time.Time `json:"created_at"`
	UpdatedAt      time.Time `json:"updated_at"`
}

NotifyRule represents a notification routing rule for UI display and editing.

type TokenItem

type TokenItem struct {
	Token      string     `json:"token"`
	UID        types.Uid  `json:"uid"`
	Scopes     []string   `json:"scopes"`
	CreatedAt  time.Time  `json:"created_at"`
	LastUsedAt *time.Time `json:"last_used_at,omitempty"`
	ExpiredAt  time.Time  `json:"expired_at"`
}

TokenItem represents a token row displayed in the token management UI.

Jump to

Keyboard shortcuts

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