Documentation
¶
Index ¶
Constants ¶
View Source
const ( // DefaultViewportWidth is the default width for the chat viewport before window sizing. DefaultViewportWidth = 80 // DefaultViewportHeight is the default height for the chat viewport before window sizing. DefaultViewportHeight = 20 )
Variables ¶
This section is empty.
Functions ¶
func RunChat ¶
func RunChat(opts ChatOptions) error
RunChat starts the chat TUI with the provided options.
Types ¶
type ChatMessage ¶
type ChatMessage struct {
Role string // "user" or "assistant"
Content string
Time time.Time
Provider string // The AI provider that generated this message (for assistant messages)
}
ChatMessage represents a single message in the chat.
type ChatModel ¶
type ChatModel struct {
// contains filtered or unexported fields
}
ChatModel represents the state of the chat TUI.
func NewChatModel ¶
func NewChatModel(p ChatModelParams) (*ChatModel, error)
NewChatModel creates a new chat model with the provided parameters.
type ChatModelParams ¶
type ChatModelParams struct {
Client ai.Client
AtmosConfig *schema.AtmosConfiguration
Manager *session.Manager
Session *session.Session
Executor *tools.Executor
MemoryMgr *instructions.Manager
}
ChatModelParams holds the parameters for creating a new ChatModel.
type ChatOptions ¶
type ChatOptions struct {
Client ai.Client
AtmosConfig *schema.AtmosConfiguration
Manager *session.Manager
Session *session.Session
Executor *tools.Executor
MemoryMgr *instructions.Manager
}
ChatOptions holds all parameters needed to start a chat session.
type ProviderWithModel ¶
ProviderWithModel represents a provider with its configured model.
Click to show internal directories.
Click to hide internal directories.