MCP.so
登录

Aiterm Mcp

@kitepon-rgb

关于 Aiterm Mcp

One persistent tmux-backed terminal for AI agents. ssh, docker exec, and REPLs nest inside a single authenticated session (no re-auth per command). Token-reduced reads, 4-layer completion detection, and a human can co-drive via the shared tmux socket. Install: npx -y aiterm-mcp

基本信息

分类

开发工具

传输方式

stdio

发布者

kitepon-rgb

提交者

kitepon-rgb

配置

使用下面的配置,将此服务器添加到你的 MCP 客户端。

{
  "mcpServers": {
    "aiterm": {
      "command": "npx",
      "args": [
        "-y",
        "aiterm-mcp"
      ]
    }
  }
}

工具

6

ローカル永続端末(tmux セッション)を1個開き、session_id を返す。tmux サーバ常駐ゆえ本サーバや クライアントが再起動してもセッションは生存する。リモート操作は専用ツールにせず、開いた端末の中で pty_send(session_id, "ssh host") と打って入る。

セッションへテキスト(コマンド)を送る。送信後の出力は pty_read で取得する。

セッションの出力をトークン削減して読む(既定は前回読取位置からの増分)。削減: 制御文字除去 / 反復圧縮 / head+tail 折りたたみ+復元ヒント+メタ併記。

制御キーを送る(C-c, C-d, Enter, Tab, Up, Down... の別名に対応)。

セッションを閉じ、ログ/読取位置を破棄する。

握っているセッション一覧(名前 / 現在の前面コマンド / attach 状態 / サイズ)。

概览

What is Aiterm Mcp?

Aiterm Mcp is a Model Context Protocol server that provides one persistent terminal session (backed by tmux) over stdio. It is designed for AI agents that need to run multiple commands in a single SSH, Docker, or REPL session without reconnecting for each command. The server reduces token usage by truncating output and includes completion detection.

How to use Aiterm Mcp?

Install via claude mcp add --scope user --transport stdio aiterm -- npx -y aiterm-mcp (for Claude Code) or run npx -y aiterm-mcp for any MCP client. Requires Node.js 18 or later and tmux. The server exposes six tools: pty_open, pty_send, pty_read, pty_key, pty_close, and pty_list.

Key features of Aiterm Mcp

  • One persistent tmux-backed terminal that survives restarts.
  • SSH, containers, and REPLs nest via a single pty_send call.
  • Token-reduced reads with per-command reducers for git, grep, pytest.
  • Four-layer completion detection (exit codes, until, quiescence, timeout).
  • Human co-driving possible via a shared tmux socket.
  • Supports Linux, WSL2, macOS, and native Windows.

Use cases of Aiterm Mcp

  • Running multi‑step SSH commands without re‑authenticating each step.
  • Executing commands inside Docker containers or REPLs in a single session.
  • Automating development workflows (e.g., git, pytest, grep) with reduced token consumption.
  • Allowing a human and an AI agent to share the same terminal session.

FAQ from Aiterm Mcp

What problem does Aiterm Mcp solve?

Over SSH, one-command-at-a-time leads to re‑authenticating every call, short‑lived sessions piling up, and fail2ban locking you out. Aiterm holds one authenticated session, preventing those issues.

What are the runtime dependencies?

Node.js 18 or later and tmux must be installed on the host.

Which platforms are supported?

Linux, WSL2, macOS, and native Windows.

Can a human interact with the same terminal?

Yes, the terminal is backed by a shared tmux socket, allowing a human to co‑drive the session.

What tools does Aiterm Mcp expose?

Six tools: pty_open, pty_send, pty_read, pty_key, pty_close, and pty_list.

评论

开发工具 分类下的更多 MCP 服务器