tui

package
v0.15.6 Latest Latest
Warning

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

Go to latest
Published: Nov 7, 2026 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Overview

Package tui holds the small set of messages shared across the strongo/aichat Bubble Tea chat kit's sub-packages (tui/stream, tui/chatshell) so a leaf component can ask the shell to do something (e.g. pin an entity to the sidebar) without importing the shell itself. The rendering components (transcript, sidebar, grid block) live in github.com/tuigoff/tuigoff; tui/chatshell composes them.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AddToSidebarMsg

type AddToSidebarMsg struct {
	Ref session.EntityRef
}

AddToSidebarMsg requests that ref be pinned to the working-context sidebar. A product control may emit it directly (tui/chatshell also pins on a grid's own PinRowMsg). tui/chatshell handles it by adding ref to the sidebar and, when the product's Handler implements OnSidebarChange, notifying it.

Directories

Path Synopsis
Package chatshell composes tuigoff's pkg/transcript, pkg/sidebar, pkg/focus and pkg/gridblock with aichat's tui/stream into the reusable chat screen every aichat product runs: history + composer + sidebar + top/status bars, with a split pane when the terminal is wide enough (>= 104 columns, matching DataTug's splitEnabled).
Package chatshell composes tuigoff's pkg/transcript, pkg/sidebar, pkg/focus and pkg/gridblock with aichat's tui/stream into the reusable chat screen every aichat product runs: history + composer + sidebar + top/status bars, with a split pane when the terminal is wide enough (>= 104 columns, matching DataTug's splitEnabled).
Package stream pumps an ai.LLMProvider's iter.Seq2[ai.Event, error] into Bubble Tea messages without buffering the response: each event arrives as an EventMsg carrying the tea.Cmd that re-arms the pump for the next event (the "channel re-arm" pattern DataTug chat used for HTTP/LLM streaming).
Package stream pumps an ai.LLMProvider's iter.Seq2[ai.Event, error] into Bubble Tea messages without buffering the response: each event arrives as an EventMsg carrying the tea.Cmd that re-arms the pump for the next event (the "channel re-arm" pattern DataTug chat used for HTTP/LLM streaming).

Jump to

Keyboard shortcuts

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