Skip to content

Comments

Migrate REPL to React/Ink TUI with streaming support#8

Merged
evantahler merged 3 commits intomainfrom
evantahler/chat-history-arrows
Feb 18, 2026
Merged

Migrate REPL to React/Ink TUI with streaming support#8
evantahler merged 3 commits intomainfrom
evantahler/chat-history-arrows

Conversation

@evantahler
Copy link
Contributor

Summary

Replace readline-based REPL with a full React/Ink TUI that keeps the input box persistent and interactive while the agent streams responses. Users can now type while the agent is working, with messages queued for processing. Features include scrollable terminal history, input history navigation (up/down arrows), and Emacs-style line editing (Ctrl+A/E, Ctrl+U/K/W).

Changes

  • New component architecture: App, MessageArea, InputBox, Message, and custom TextInput
  • Logger refactor: EventEmitter-based instead of ora spinners and LoggerStream
  • Agent simplification: Removed interactiveChat() and stream piping logic
  • Message queueing: Process user input sequentially during agent responses
  • Input features: History navigation, terminal scrollback, and Emacs keybindings

Test Plan

  • Run ./agent.ts chat and type a message
  • Verify agent streams response while input stays active
  • Type multiple messages while agent streams (check queue count)
  • Use up/down arrows in input to navigate history
  • Check Ctrl+A/Ctrl+E moves cursor
  • Scroll terminal up/down to see full chat history
  • Exit with quit or Ctrl+C

🤖 Generated with Claude Code

evantahler and others added 3 commits February 17, 2026 17:04
Replace readline-based REPL with a full React/Ink TUI that keeps the input
box persistent and interactive while the agent streams responses. Add message
queueing so users can type multiple messages during streaming. Includes
scrollable terminal history, input history with up/down arrows, and Emacs-style
line editing (Ctrl+A/E, Ctrl+U/K/W).

Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Ink has an optional import of react-devtools-core that Bun's bundler
can't resolve. Mark it as external. Also remove unused ora dependency.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@evantahler evantahler merged commit 9428121 into main Feb 18, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant