Skip to content
go-steerPublic

About

Reusable Bubble Tea TUI for agentic assistants

Topics

Resources

Code of conduct

Contributing

Stars

2 stars

Watchers

0 watching

Forks

Repository files navigation

core-tui

CI Go Reference License

A reusable Bubble Tea TUI for agentic assistants. core-tui owns the operator-facing surface — chat loop, slash commands, command palette, @file expansion, permissions modal, MCP elicitation, transcript persistence — and integrates with any agent via a small Go interface.

It is intentionally agent-framework agnostic: nothing in package tui imports an LLM SDK, an MCP SDK, or an agent runtime. Hosts adapt their own agent types to the interface in docs/design.md §3 and call tui.Run(ctx, opts).

Status

Latest release: v0.9.1. Pre-1.0 — public API is largely stable but minor breaking changes can ship in 0.X minor bumps; see the release notes for what's in each version.

The reference host is go-steer/core-agent, which tracks the latest release and exercises the full capability surface: theme picker, Notifier side channel, SSE push-mode subscriber, and the v2 transcript schema.

Documentation

Install

go get github.com/go-steer/core-tui

Requires Go ≥ 1.23.

Quick start

A host implements the tui.Agent interface and calls tui.Run:

package main

import (
    "context"

    "github.com/go-steer/core-tui/tui"
)

func main() {
    ctx := context.Background()
    if err := tui.Run(ctx, tui.Options{
        Agent: myAgent{},          // implements tui.Agent
        // Optional: any capability interfaces the host wants to light up
        // — ModelSwapper, Reloader, PermissionController, SlashProvider, …
    }); err != nil {
        panic(err)
    }
}

See docs/design.md §3 for the full interface set and §6 for the host-adapter recipe. Worked examples live under examples/:

  • examples/local — visual-preview binary running against a scripted test agent; exercises every renderer path (chat, tool calls, slash palette, modal forms, theme picker, status surfaces).
  • examples/notifier-smoke — standalone harness for the Notifier capability: a producer goroutine pushes realistic notices on a rotation (plus a periodic burst to demonstrate the drop-with-coalescence backpressure marker).
  • examples/core-agent — the reference-host adapter sketch, in the two flavors a real host ships: an in-process agent, and an attachclient talking to a remote agent over HTTP + SSE. Written against a local stand-in for core-agent's types (no dependency on that module), so it doubles as the compile-time canary on the plug-in surface. Start here if you are wiring your own host: go run ./examples/core-agent and go run ./examples/core-agent -flavor attach.

Contributing

See CONTRIBUTING.md for the development workflow, DCO sign-off requirement, and the no-Co-Authored-By policy. Local CI is one command:

dev/tools/ci

License

Apache License 2.0.

About

Reusable Bubble Tea TUI for agentic assistants

Topics

Resources

Code of conduct

Contributing

Stars

2 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages