A terminal companion that pins a persistent input bar at the bottom of your tmux pane, so you can scroll freely through long TUI agent output while composing your response.
Project description
tui-input
A terminal companion that pins a persistent input bar at the bottom of your tmux pane. Scroll freely through long TUI agent output while composing your response.
The Problem
When using TUI-based AI agents (Claude Code, Codex CLI, etc.), long outputs force you to scroll up to read, then scroll back down to type. You end up:
- Losing your place in the output
- Writing responses in a separate editor, then copy-pasting
- Fighting the terminal scroll position
The Solution
tui-input splits your terminal into two panes:
┌─────────────────────────────────────┐
│ Top pane (Claude Code / Codex etc) │
│ Scroll freely through long output │
├─────────────────────────────────────┤ ← 3-10 lines, auto-resizing
│ Type your response here... │
│ Enter to send · Shift+Enter: newline│
└─────────────────────────────────────┘
Features
- Pinned input bar — always visible at the bottom, regardless of scroll position
- Auto-resize — companion grows from 3 to 10 lines as you type multi-line input
- Bracketed paste — safe multi-line text transfer via tmux buffers
- Input history — press
↑/↓to recall previous inputs (persisted across sessions) - Agent-agnostic — works with any terminal program, not just AI agents
- Auto-cleanup — companion exits when the agent exits
Installation
Requirements
- Python 3.10+
- tmux
Install via Homebrew
brew install maked-dev/tap/tui-input
Install via pip/uv
# Using uv (recommended)
uv tool install tui-input
# Using pip
pip install tui-input
After Installation: Add Alias
Register a shell alias so you can launch your favorite AI agent with tui-input by just typing its name.
echo "alias claude='tui-input claude'" >> ~/.zshrc && source ~/.zshrc
echo "alias codex='tui-input codex'" >> ~/.zshrc && source ~/.zshrc
Now just type claude to launch Claude Code with the input bar attached.
Usage
# Basic usage
tui-input claude
# Any command works
tui-input "vim file.py"
tui-input htop
# With alias registered, just type the agent name
claude
codex
Key Bindings
| Key | Action |
|---|---|
Enter |
Send text to top pane + clear input |
Shift+Enter |
Insert newline (multi-line input) |
↑ (on empty) |
Previous history entry |
↓ (on empty) |
Next history entry |
Esc |
Clear all input |
How It Works
tui-inputcreates a tmux vertical split (or a new session if not in tmux)- Your command runs in the top pane
- A Textual-based companion widget runs in the bottom pane
- Press
Enterto send text to the top pane viatmux paste-buffer - When the top pane command exits, the companion auto-exits
Development
# Clone and install
git clone https://github.com/maked-dev/tui-input.git
cd tui-input
uv sync
# Run tests
uv run pytest
# Lint and format
uv run ruff check src/ tests/
uv run ruff format --check src/ tests/
# Type check
uv run mypy src/
License
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file tui_input-0.1.3.tar.gz.
File metadata
- Download URL: tui_input-0.1.3.tar.gz
- Upload date:
- Size: 56.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
47751be498a6efdb94bcf5c4a49eb9946f1e1950c1e13fcf98fb286a654335d9
|
|
| MD5 |
181f9bfd9b66371da4e5934f1f2701e2
|
|
| BLAKE2b-256 |
eb233da7244924159afb11b89c2f88f3b7ab45eafe91e59c58250f60776116a7
|
Provenance
The following attestation bundles were made for tui_input-0.1.3.tar.gz:
Publisher:
release.yml on maked-dev/tui-input
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
tui_input-0.1.3.tar.gz -
Subject digest:
47751be498a6efdb94bcf5c4a49eb9946f1e1950c1e13fcf98fb286a654335d9 - Sigstore transparency entry: 1107834462
- Sigstore integration time:
-
Permalink:
maked-dev/tui-input@818cd214c3b7462dd210c6089f8ee33003477fde -
Branch / Tag:
refs/tags/v0.1.3 - Owner: https://github.com/maked-dev
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@818cd214c3b7462dd210c6089f8ee33003477fde -
Trigger Event:
push
-
Statement type:
File details
Details for the file tui_input-0.1.3-py3-none-any.whl.
File metadata
- Download URL: tui_input-0.1.3-py3-none-any.whl
- Upload date:
- Size: 16.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ca98a752192a84166f9abdf26260a1aa3f3b914ec3d026fe7b4954bf56851a62
|
|
| MD5 |
b3d25e3a13205736e394e4e1a924532d
|
|
| BLAKE2b-256 |
c9b636e228c222b1390f0b423f0f42adfb20344b9f9f803500c1da2a1f933f9a
|
Provenance
The following attestation bundles were made for tui_input-0.1.3-py3-none-any.whl:
Publisher:
release.yml on maked-dev/tui-input
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
tui_input-0.1.3-py3-none-any.whl -
Subject digest:
ca98a752192a84166f9abdf26260a1aa3f3b914ec3d026fe7b4954bf56851a62 - Sigstore transparency entry: 1107834465
- Sigstore integration time:
-
Permalink:
maked-dev/tui-input@818cd214c3b7462dd210c6089f8ee33003477fde -
Branch / Tag:
refs/tags/v0.1.3 - Owner: https://github.com/maked-dev
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@818cd214c3b7462dd210c6089f8ee33003477fde -
Trigger Event:
push
-
Statement type: