Documentation
¶
Index ¶
- Variables
- func Legend() string
- func RenderCompatJSON(results []models.CompatResult) []map[string]interface{}
- func RenderCompatTable(results []models.CompatResult) string
- func RenderHardwareInfo(info hardware.SystemInfo) string
- func RenderModelList(modelNames []string, descriptions []string) string
- func RunTUI(cfg config.Config) error
- type CompatTab
- func (t *CompatTab) CycleQuant()
- func (t *CompatTab) MoveDown()
- func (t *CompatTab) MoveUp()
- func (t *CompatTab) SetHardware(hw hardware.SystemInfo)
- func (t *CompatTab) SetRemoteModels(remote []ollama.RemoteModel)
- func (t *CompatTab) SetSearchQuery(q string)
- func (t *CompatTab) StartSearch()
- func (t *CompatTab) StopSearch()
- func (t CompatTab) View(width, height int) string
- type HardwareTab
- type ModelsTab
- func (t *ModelsTab) MoveDown()
- func (t *ModelsTab) MoveUp()
- func (t *ModelsTab) SelectedModelName() string
- func (t *ModelsTab) SetError(err error)
- func (t *ModelsTab) SetLocal(models []ollama.LocalModel)
- func (t *ModelsTab) SetRemote(models []ollama.RemoteModel)
- func (t *ModelsTab) SetSearchQuery(q string)
- func (t *ModelsTab) StartSearch()
- func (t *ModelsTab) StopSearch()
- func (t *ModelsTab) ToggleLocal()
- func (t ModelsTab) View(width, height int) string
- type PullDoneMsg
- type PullProgress
- type PullProgressMsg
- type PullTab
- func (t *PullTab) CheckCompat()
- func (t *PullTab) FinishPull(err error)
- func (t *PullTab) Reset()
- func (t *PullTab) SetHardware(hw hardware.SystemInfo)
- func (t *PullTab) SetInput(s string)
- func (t *PullTab) StartPull()
- func (t *PullTab) UpdateProgress(status string, total, completed int64)
- func (t PullTab) View(width, height int) string
- type TUIModel
Constants ¶
This section is empty.
Variables ¶
var ( // Title styles TitleStyle = lipgloss.NewStyle(). Bold(true). Foreground(lipgloss.Color("12")). MarginBottom(1) SubtitleStyle = lipgloss.NewStyle(). Foreground(lipgloss.Color("8")). Italic(true) // Verdict styles VerdictCanRun = lipgloss.NewStyle(). Bold(true). Foreground(lipgloss.Color("10")) // green VerdictDegraded = lipgloss.NewStyle(). Bold(true). Foreground(lipgloss.Color("11")) // yellow VerdictCannotRun = lipgloss.NewStyle(). Bold(true). Foreground(lipgloss.Color("9")) // red // Table styles HeaderStyle = lipgloss.NewStyle(). Bold(true). Foreground(lipgloss.Color("15")). Background(lipgloss.Color("8")). Padding(0, 1) CellStyle = lipgloss.NewStyle(). Padding(0, 1) // Info labels LabelStyle = lipgloss.NewStyle(). Bold(true). Foreground(lipgloss.Color("14")) // cyan ValueStyle = lipgloss.NewStyle(). Foreground(lipgloss.Color("15")) // white // Warning/Error WarningStyle = lipgloss.NewStyle(). Foreground(lipgloss.Color("11")) // yellow ErrorStyle = lipgloss.NewStyle(). Foreground(lipgloss.Color("9")) // red SuccessStyle = lipgloss.NewStyle(). Foreground(lipgloss.Color("10")) // green DimStyle = lipgloss.NewStyle(). Foreground(lipgloss.Color("8")) // dim gray // TUI tab styles TabActiveStyle = lipgloss.NewStyle(). Bold(true). Foreground(lipgloss.Color("15")). Background(lipgloss.Color("12")). Padding(0, 2) TabInactiveStyle = lipgloss.NewStyle(). Foreground(lipgloss.Color("7")). Background(lipgloss.Color("0")). Padding(0, 2) StatusBarStyle = lipgloss.NewStyle(). Foreground(lipgloss.Color("7")). Background(lipgloss.Color("0")). Padding(0, 1). Width(80) )
Functions ¶
func RenderCompatJSON ¶
func RenderCompatJSON(results []models.CompatResult) []map[string]interface{}
RenderCompatJSON renders results as JSON-friendly output.
func RenderCompatTable ¶
func RenderCompatTable(results []models.CompatResult) string
RenderCompatTable renders the compatibility results as a colored table.
func RenderHardwareInfo ¶
func RenderHardwareInfo(info hardware.SystemInfo) string
RenderHardwareInfo renders the hardware detection results.
func RenderModelList ¶
RenderModelList renders a list of models.
Types ¶
type CompatTab ¶
type CompatTab struct {
// contains filtered or unexported fields
}
CompatTab holds state for the compatibility check tab.
func NewCompatTab ¶
func (*CompatTab) CycleQuant ¶
func (t *CompatTab) CycleQuant()
func (*CompatTab) SetHardware ¶
func (t *CompatTab) SetHardware(hw hardware.SystemInfo)
func (*CompatTab) SetRemoteModels ¶
func (t *CompatTab) SetRemoteModels(remote []ollama.RemoteModel)
func (*CompatTab) SetSearchQuery ¶
func (*CompatTab) StartSearch ¶
func (t *CompatTab) StartSearch()
func (*CompatTab) StopSearch ¶
func (t *CompatTab) StopSearch()
type HardwareTab ¶
type HardwareTab struct {
// contains filtered or unexported fields
}
HardwareTab holds state for the hardware detection tab.
func NewHardwareTab ¶
func NewHardwareTab() HardwareTab
func (*HardwareTab) SetError ¶
func (t *HardwareTab) SetError(err error)
func (*HardwareTab) SetHardware ¶
func (t *HardwareTab) SetHardware(hw hardware.SystemInfo)
func (HardwareTab) View ¶
func (t HardwareTab) View(width, height int) string
type ModelsTab ¶
type ModelsTab struct {
// contains filtered or unexported fields
}
ModelsTab holds state for the models listing tab.
func NewModelsTab ¶
func (*ModelsTab) SelectedModelName ¶
SelectedModelName returns the name of the currently selected model.
func (*ModelsTab) SetLocal ¶
func (t *ModelsTab) SetLocal(models []ollama.LocalModel)
func (*ModelsTab) SetRemote ¶
func (t *ModelsTab) SetRemote(models []ollama.RemoteModel)
func (*ModelsTab) SetSearchQuery ¶
func (*ModelsTab) StartSearch ¶
func (t *ModelsTab) StartSearch()
func (*ModelsTab) StopSearch ¶
func (t *ModelsTab) StopSearch()
func (*ModelsTab) ToggleLocal ¶
func (t *ModelsTab) ToggleLocal()
type PullProgress ¶
type PullProgress struct {
// contains filtered or unexported fields
}
PullProgress tracks download progress for model pulling.
func NewPullProgress ¶
func NewPullProgress() PullProgress
func (PullProgress) Init ¶
func (m PullProgress) Init() tea.Cmd
func (PullProgress) View ¶
func (m PullProgress) View() string
type PullProgressMsg ¶
PullProgressMsg is sent to update the progress bar.
type PullTab ¶
type PullTab struct {
// contains filtered or unexported fields
}
PullTab holds state for the pull/download tab.
func NewPullTab ¶
func (*PullTab) CheckCompat ¶
func (t *PullTab) CheckCompat()
func (*PullTab) FinishPull ¶
func (*PullTab) SetHardware ¶
func (t *PullTab) SetHardware(hw hardware.SystemInfo)
func (*PullTab) UpdateProgress ¶
type TUIModel ¶
type TUIModel struct {
// contains filtered or unexported fields
}
TUIModel is the top-level bubbletea model for the interactive TUI.
func NewTUIModel ¶
NewTUIModel creates a new TUI model with the given config.