Skip to content

block/thread-manager-for-amp

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

154 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Thread Manager for Amp

A local web UI for managing Amp AI coding agent threads β€” monitor, interact with, and organize multiple concurrent agent sessions from your browser.

Screenshots

Thread List

Sortable, filterable table view with bulk operations, labels, and status tracking.

Thread list view

Thread Detail

Conversation view with rich message rendering, syntax highlighting, and a minimap for navigation.

Thread detail view

Kanban Board

Organize threads across status columns β€” Active, Blocked, Paused, and Done.

Kanban board view

Quick Start

Prerequisites

  • Node.js 24+ (needed to compile native modules like better-sqlite3 and node-pty)
  • pnpm 10+ β€” install with npm install -g pnpm
  • Amp CLI installed and authenticated (amp command available)

Install & Run

pnpm install
pnpm dev

Open http://localhost:5173

Why?

When working with multiple Amp threads simultaneously β€” across repos, features, and tasks β€” it's hard to keep track of what's running, what's blocked, and what each thread has done. This tool gives you a single dashboard to manage it all.

Features

πŸ–₯️ Multi-Terminal Management

  • Run multiple Amp threads side-by-side with tabs, split views, and grid layouts
  • Real-time streaming of agent output via WebSocket
  • Rich message rendering with syntax highlighting for code and tool outputs
  • Conversation minimap for navigating long threads
  • Auto-reconnect on connection drops with output resumption

πŸ“‹ Thread Organization

  • Table view β€” sortable, filterable thread listing with bulk operations
  • Card view β€” detailed cards grouped by date
  • Kanban view β€” organize threads across status columns (Active, Blocked, Paused, Done)
  • Thread status tracking with blocker relationships between threads
  • Labels and linked issue URLs for organization
  • Handoff support to create continuation threads

πŸ” Discovery & Context

  • Thread chains β€” visualize parent/child handoff relationships
  • Related threads β€” find threads that touched the same files
  • Git activity β€” see commits, branches, and PRs correlated to each thread
  • Source control β€” view uncommitted changes per workspace with inline diffs
  • Content search β€” full-text search across all thread messages

πŸ› οΈ Built-in Tools

  • Shell terminal β€” integrated xterm.js terminal sessions
  • Command palette (⌘O) β€” quick access to all actions
  • Skills management β€” list, add, and remove Amp skills
  • MCP status β€” view connected MCP servers
  • Image viewer β€” view images attached to or generated by threads

🎨 Customization

  • 30+ theme presets β€” Cyberpunk 2077, Dracula, Tokyo Night, Nord, Catppuccin, Gruvbox, and more
  • Adaptive theme system that derives a full UI from just 3 colors (bg, fg, accent)
  • Light and dark themes supported
  • Configurable layouts and view preferences
  • Notification sounds for completed tasks

Architecture

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚                    Frontend (React 19)                   β”‚
β”‚  src/                                                    β”‚
β”‚  β”œβ”€β”€ components/     # UI components                     β”‚
β”‚  β”‚   β”œβ”€β”€ terminal/   # WebSocket terminal + messages     β”‚
β”‚  β”‚   β”œβ”€β”€ ThreadList/ # Table view with bulk selection    β”‚
β”‚  β”‚   β”œβ”€β”€ sidebar/    # Workspace tree navigation         β”‚
β”‚  β”‚   └── Toolbar/    # Search, filters, view switching   β”‚
β”‚  β”œβ”€β”€ hooks/          # Data fetching + state hooks       β”‚
β”‚  β”œβ”€β”€ commands/       # Command palette registry          β”‚
β”‚  └── lib/            # Theme system, utilities           β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                           β”‚
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚               Shared (shared/)                           β”‚
β”‚  types.ts, websocket.ts, validation.ts, cost.ts,         β”‚
β”‚  utils.ts, constants.ts                                  β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                           β”‚
                    HTTP + WebSocket
                           β”‚
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚                 Backend (Node.js)                        β”‚
β”‚  server/                                                 β”‚
β”‚  β”œβ”€β”€ websocket.ts    # Per-thread session management     β”‚
β”‚  β”œβ”€β”€ shell-websocket.ts  # Shell terminal PTY sessions   β”‚
β”‚  β”œβ”€β”€ routes/         # REST API handlers                 β”‚
β”‚  β”‚   β”œβ”€β”€ threads.ts  # Thread CRUD + search + discovery  β”‚
β”‚  β”‚   β”œβ”€β”€ metadata.ts # Status, labels, blockers          β”‚
β”‚  β”‚   β”œβ”€β”€ git.ts      # Git status + diffs                β”‚
β”‚  β”‚   β”œβ”€β”€ skills.ts   # Amp skills + MCP management       β”‚
β”‚  β”‚   └── artifacts.ts # Notes + image storage            β”‚
β”‚  └── lib/            # Core logic                        β”‚
β”‚      β”œβ”€β”€ threadCrud.ts    # Thread CRUD operations        β”‚
β”‚      β”œβ”€β”€ threadSearch.ts  # Search + related threads      β”‚
β”‚      β”œβ”€β”€ threadExport.ts  # Markdown + image export       β”‚
β”‚      β”œβ”€β”€ threadChain.ts   # Handoff chains                β”‚
β”‚      β”œβ”€β”€ database.ts # SQLite for local metadata         β”‚
β”‚      β”œβ”€β”€ amp-api.ts  # Amp internal API client           β”‚
β”‚      β”œβ”€β”€ git.ts      # Git operations                    β”‚
β”‚      └── git-activity.ts  # Commit/branch correlation    β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                           β”‚
              β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
              β”‚                         β”‚
     ~/.local/share/amp/        ~/.amp-thread-manager/
     └── threads/*.json         β”œβ”€β”€ threads.db (SQLite)
         (Amp thread data)      └── artifacts/

Data Storage

Location Purpose
~/.local/share/amp/threads/ Amp's thread JSON files (read by the server)
~/.amp-thread-manager/threads.db Local SQLite for status, blockers, linked issues
~/.amp-thread-manager/artifacts/ Saved images and notes per thread

Keyboard Shortcuts

Shortcut Action
Ctrl/⌘+O Command palette
Alt+N New thread
Ctrl/⌘+R Refresh threads / prompt history
Ctrl/⌘+W Close current thread
Ctrl/⌘+B Toggle sidebar
Ctrl/⌘+H Handoff current thread
Ctrl+T Open shell terminal
Ctrl+M Thread map
Alt+D Toggle deep mode
Alt+L Toggle layout
Alt+[ / Alt+] Switch tabs
j/k or ↓/↑ Navigate thread list
Enter Open focused thread
x Toggle selection
Esc Close modal / clear focus

Scripts

Command Description
pnpm dev Start dev server (Vite frontend + Node backend)
pnpm build Build for production
pnpm start Build and serve production
pnpm check Format check + lint + typecheck + build
pnpm lint ESLint
pnpm typecheck TypeScript type check
pnpm test Run tests (Vitest)
pnpm test:watch Run tests in watch mode

Configuration

Environment Variable Default Description
PORT 3001 Backend server port
AMP_HOME $HOME Base directory for Amp data
AMP_BIN auto-detected Path to the amp CLI binary

Security

This is a local development tool. The server binds to localhost only and is not accessible from other devices. See SECURITY.md for details.

Troubleshooting

Native module build errors (better-sqlite3, node-pty)

These packages require compilation. Make sure you have:

  • macOS: Xcode Command Line Tools (xcode-select --install)
  • Linux: build-essential, python3
  • Node.js 24+ (check with node -v)

If builds fail, try: pnpm rebuild

"Amp CLI not found"

Make sure amp is in your PATH, or set AMP_BIN to the full path of the binary.

Port already in use

Set a different port: PORT=3002 pnpm dev

Tech Stack

  • Frontend: React 19, TypeScript, Vite
  • Backend: Node.js with raw http module (no Express)
  • Database: SQLite via better-sqlite3
  • WebSocket: ws for real-time agent streaming
  • Terminal: xterm.js + node-pty for shell sessions
  • Testing: Vitest, Testing Library
  • Styling: CSS custom properties (no UI framework)

License

Apache License 2.0

About

A local web UI for managing Amp AI coding agent threads.

Resources

License

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages