# @gbasin/agentboard 中文文档

规范地址：https://npmcn.com/package/%40gbasin/agentboard/

版本：0\.46\.8
npm 元数据更新时间：2026-11-14T19:36:03.684Z
中文译文更新时间：2026-11-16T00:32:54.203Z
软件包许可：MIT

本文由上游 README 翻译，可能存在偏差，请结合原文核对 API、命令与配置。版权与许可归原作者所有。

原始 npm 页面：https://www.npmjs.com/package/%40gbasin/agentboard
原文对照：https://npmcn.com/package/%40gbasin/agentboard/?lang=original
项目主页：https://github.com/gbasin/agentboard#readme
源码仓库：https://github.com/gbasin/agentboard

## 关键信息（来自 npm 元数据）

- 包体积（解压后）：20.7 kB，4 个文件
- 模块格式：ES Module
- TypeScript 类型：未声明
- 运行依赖：30 个
- 首次发布：2026-02-07T15:02:45.705Z
- 最新版本发布：2026-11-14T19:36:03.334Z
- 近 30 天下载量：7293（2026-10-16 至 2026-11-14，npm 官方下载统计）
- 已发布版本数：198（近 12 个月 198 个）

## 中文简介

Tmux 的 Web GUI 优化用于 AI 代理 TUI

## 安装

```sh
npm install @gbasin/agentboard
```

也可以使用：`pnpm add @gbasin/agentboard`、`yarn add @gbasin/agentboard`、`bun add @gbasin/agentboard`

## README

# 代理板

[![CI](https://img.shields.io/github/actions/workflow/status/gbasin/agentboard/ci.yml?branch=master&logo=github)](https://github.com/gbasin/agentboard/actions) [![npm](https://img.shields.io/npm/v/@gbasin/agentboard?logo=npm)](https://www.npmjs.com/package/@gbasin/agentboard) [![License: MIT](https://img.shields.io/github/license/gbasin/agentboard)](https://github.com/gbasin/agentboard/blob/master/LICENSE) [![TypeScript](https://img.shields.io/badge/TypeScript-5.x-3178c6?logo=typescript&logoColor=white)](https://www.typescriptlang.org/) [![Ask DeepWiki](https://deepwiki.com/badge.svg)](https://deepwiki.com/gbasin/agentboard)

Agentboard 是网络用户界面 `tmux`claude Code 和 Codex 等运行编码代理设备。 在桌面或服务器上启动您的代理, 然后从任何浏览器, 包括您的手机, 监视并引导他们 .

每个会话都生活在tmux中,所以关闭分页时你的代理继续运行,每个设备都有同样的会话可用.

![Agentboard in a desktop browser window, with a phone in front of it. The desktop sidebar lists agent sessions with their status, age, last prompt and pull request chips; one session waits for permission. The terminal shows a Claude Code session refactoring a router, with a Media 2 pill in its corner. The phone shows the same session's terminal with a quick-keys toolbar.](https://npmcn.com/package/%40gbasin/agentboard/assets/readme/hero.webp)

同样的tmux会话在笔记本电脑和手机上.

## 特征

<table><tbody><tr><td><h3 id="readme-status-and-last-prompt-for-every-session">每届会议的现状和最后一次提示</h3><p>每个会话都显示从其终端输出中推断的状态: <em>正在工作</em>, (中文(简体) ), <em>等待输入</em>,或 <em>需要许可</em>。与代理记录匹配的会话还显示您发送的最后一个提示。 可选声音告诉您何时需要会话许可或闲置 .</p></td><td><img alt="Animation: the sidebar lists sessions with their last prompts and ages. The selected session, orders-migration, shows a permission prompt to run a database migration; its status badge changes to a raised hand while the prompt is open, then back to now when the prompt is answered." src="https://npmcn.com/package/%40gbasin/agentboard/assets/readme/status-loop.gif" width="520" loading="lazy" decoding="async" referrerpolicy="no-referrer"></td></tr><tr><td><h3 id="readme-subagent-activity">分剂活性</h3><p>对于本地Claude Code和Codex会话,会话的计数器显示有多少子代理正在运行. 点击它可以看到主会话和每个子剂及其当前状态和最后一个活性信号的时间.</p></td><td><img alt="The agent activity panel for the router-refactor session, opened from its subagent counter showing 3. The main session has an active model turn. Of four subagents, Migrate billing routes and Run e2e suite are waiting on Edit and Bash tool calls, Migrate invoice routes has an active model turn, and Audit auth middleware has finished." src="https://npmcn.com/package/%40gbasin/agentboard/assets/readme/subagents.webp" width="520" loading="lazy" decoding="async" referrerpolicy="no-referrer"></td></tr><tr><td><h3 id="readme-pull-requests-with-ci-state">用 CI 状态拉请求</h3><p>拉动创建会话的请求 <code>gh pr create</code> 或通过 GitHub 连接器作为芯片出现在会话上,颜色按状态:开口,草稿,合并,或关闭. Claude Code会话还显示Claude Code与会话相关的拉动请求,比如它所推动的拉拉请求. 找一个芯片看看它的标题和CI检查.</p></td><td><img alt="Four sidebar sessions with pull request chips: a draft (489), two open (482 and 1193) and a merged one (1187). A hover card for pull request 1193 shows its title and four CI checks, one of them failing." src="https://npmcn.com/package/%40gbasin/agentboard/assets/readme/pull-requests.webp" width="520" loading="lazy" decoding="async" referrerpolicy="no-referrer"></td></tr><tr><td><h3 id="readme-media-from-the-transcript">记录的媒体</h3><p>一个媒体铁路收集图像、文件和会议记录的链接。 在取景器中打开任意图像,并步入其余部分.</p></td><td><img alt="The media rail open over a session's terminal: tabs for Media 5 and Links 1, then thumbnails for a PDF report, a search results screenshot, a CPU flame graph and two latency charts. Below it, the transcript lines where the agent read those files." src="https://npmcn.com/package/%40gbasin/agentboard/assets/readme/media-rail.webp" width="520" loading="lazy" decoding="async" referrerpolicy="no-referrer"></td></tr><tr><td><h3 id="readme-history-hibernate-and-wake">历史 休伯纳特 醒来</h3><p><strong>休眠状态</strong> 关闭代理会话的 tmux 窗口, 并将其对话保留在侧边栏中 。 它在 Agentboard 管理的 tmux 会话中为本地会话工作. <strong>历史</strong> 列出最近的对话:打开一个来预览其记录,然后 <strong>醒来</strong> 继续.</p></td><td><img alt="The transcript preview of a past Claude Code conversation, admin-react-19, about upgrading an app to React 19, with Cancel and Wake buttons." src="https://npmcn.com/package/%40gbasin/agentboard/assets/readme/history.webp" width="520" loading="lazy" decoding="async" referrerpolicy="no-referrer"></td></tr><tr><td colspan="2"><h3 id="readme-on-your-phone">在你的电话上</h3><p>在小屏幕上,棋盘切换为触摸布局:会话抽屉,快键工具栏(Esc, Tab, Ctrl,箭头键,数字)和粘贴对话框. 触摸滚动,自来相击,以及终端的长压选择工作. 在你的家用屏幕上加入板作为PWA.</p><img alt="Three phone screens. Left: the session drawer listing sessions with status, last prompt and pull request chips. Middle: a session waiting on a permission prompt, with a row of numbered session tiles at the top and the quick-keys toolbar at the bottom. Right: the paste dialog with three lines of text ready to submit." src="https://npmcn.com/package/%40gbasin/agentboard/assets/readme/phone.webp" width="880" loading="lazy" decoding="async" referrerpolicy="no-referrer"></td></tr><tr><td><h3 id="readme-sessions-from-other-machines">其他机器的会话</h3><p>来自其他机器的会话在SSH上方的同一块板上出现,每块上都有一个主机徽章. 通过主机或项目过滤板. 见 <a href="https://npmcn.com/package/%40gbasin/agentboard/docs/remote-hosts.md" rel="nofollow noopener noreferrer">远程主机</a>。 。 。 .</p></td><td><img alt="Five sidebar sessions from two machines: rows badged STUDIO run locally, rows badged BUILD-BOX run on a remote host. The remote Codex session nightly-e2e is selected." src="https://npmcn.com/package/%40gbasin/agentboard/assets/readme/hosts.webp" width="520" loading="lazy" decoding="async" referrerpolicy="no-referrer"></td></tr></tbody></table>

### 还有

-   浏览器中的完整终端. 鼠标滚动,选择,剪贴板与克洛德代码的全屏幕渲染器一起工作.
-   粘贴或将文本、图像和文件放入提示中.
-   键盘快捷键来切换,创建并关闭会话.
-   按年龄或需要注意的内容排序, 按项目或主机过滤, 或将会话拖入您的顺序 .
-   会话恢复列出崩溃或重启中断的会话, 这样您就可以重新打开 。 自动重开是选入 。 见 [会话恢复](https://npmcn.com/package/%40gbasin/agentboard/docs/session-recovery.md)。 。 。 .

## 支助代理人

| 探员 | 匹配, 最后一个提示, Wake | 调取请求 | 媒体铁路 | 分剂活性 |
| --- | --- | --- | :-: | :-: |
| 克劳德代码 | 对 | 对 | 对 | 对 |
| 代码 | 对 | 对 | 对 | 对 |
| Pi | 对 | 对 | 链接 |  |
| 哦,我的宝贝 | 对 | 对 | 链接 |  |
| 开发CLI | 对 | 对 | 链接 |  |
| 格罗克CLI | 对 | 对 | 链接 |  |

媒体铁路显示克劳德代码和Codex的图像,文件和链接. 对于其他特工来说,它显示了链接.

Agentboard在其默认位置找到每个代理的笔录,并自动与tmux窗口相匹配. 在tmux中运行的任何其他程序也作为平版终端会话工作,具有状态但无笔录功能.

## 所需资源

-   macOS(苹果硅或英特尔)或Linux(x64或arm64).
-   tmux 3.2 或以后的: `brew install tmux` 或者说 `apt install tmux`。 。 。 .
-   [撕裂](https://github.com/BurntSushi/ripgrep) (单位:千美元)`rg`: `brew install ripgrep` 或者说 `apt install ripgrep`. Agentboard 使用它来匹配代理文本到 tmux 窗口. Homebrew 和 npm 包不安装它 .
-   [分级](https://tailscale.com/download) (推荐)或您机器的另一条网络路径,用于从其他设备访问.

可选 :

-   这个 [GitHub 缩写](https://cli.github.com/) (单位:千美元)`gh`),以显示拉动请求状态和CI检查.
-   `ssh` 基于密钥的访问,以显示来自 [远程主机](https://npmcn.com/package/%40gbasin/agentboard/docs/remote-hosts.md)。 。 。 .

## 安装

### 土生土长

```bash
brew tap gbasin/tap
brew install agentboard
agentboard
```

### 无

需要节点.js 18或以后.

```bash
npm install -g @gbasin/agentboard
agentboard
```

或运行它而不安装:

```bash
npx @gbasin/agentboard
```

### 打开棋盘

打开 `http://localhost:4040` 在同一个机器上.

如果 Tailscale 正在运行, Agentboard 也会在您的 Tailscale 地址上监听 。 打开 `http://<your-machine>:4040` 从任何设备 在你的尾网。 要在手机的屏幕上安装板子,看 [PWA 安装](https://npmcn.com/package/%40gbasin/agentboard/docs/pwa-install.md)。 。 。 .

没有尾图, Agentboard 只能接受同一机器的连接. 要改变这一点,看 [网络和安全](https://npmcn.com/package/%40gbasin/agentboard/docs/configuration.md#network-and-security)。 。 。 .

### 运行它作为服务

登录时启动代理板并保持其运行 :

-   马可斯: [发射/README.md](https://npmcn.com/package/%40gbasin/agentboard/launchd/README.md)
-   林纳: [系统/README.md](https://npmcn.com/package/%40gbasin/agentboard/systemd/README.md)

两个安装器都需要对这个寄存器进行git检出. 他们不使用Homebrew或npm安装.

### 升级

运行 `brew upgrade agentboard` 或者说 `npm install -g @gbasin/agentboard@latest`,然后重新启动代理板。 您的 tmux 会话会一直贯穿重启, 您的数据会留在 `~/.agentboard`。 。 。 .

这些命令不升级安装在已启动或系统安装器上的服务. 按照服务指南的规定升级服务.

### 卸载

停止代理板,然后运行 `brew uninstall agentboard` 或者说 `npm uninstall -g @gbasin/agentboard`。 。 。 .

`brew uninstall` 如果没有其他公式需要,也删除 tmux。 要保持tmux,运行 `HOMEBREW_NO_AUTOREMOVE=1 brew uninstall agentboard`。 。 。 .

如果您安装了服务, 请先移除它 。 关于这一点,以及一个未安装的数据和设置,见 [卸载](https://npmcn.com/package/%40gbasin/agentboard/docs/uninstall.md)。 。 。 .

### 从源

见 [发展](https://npmcn.com/package/%40gbasin/agentboard/docs/development.md)。 。 。 .

## 配置

Agentboard 配置了环境变量 。 它没有指挥线的旗帜.

```bash
PORT=8080 TMUX_SESSION=work agentboard
```

| 变量 | 默认 | 效果 |
| --- | --- | --- |
| `PORT` | `4040` | 网络用户界面端口 . |
| `HOSTNAME` | `127.0.0.1` | 要装订地址 设定 `0.0.0.0` 以在所有界面上监听. |
| `TMUX_SESSION` | `agentboard` | Agentboard 管理的 tmux 会话名称 . |
| `DISCOVER_PREFIXES` | 未设定 | 限制您其他 tmux 会话中的哪个出现在棋盘上 。 默认情况下,它们全部出现. |
| `AGENTBOARD_REMOTE_HOSTS` | 未设定 | SSH主机在板上显示. |
| `AGENTBOARD_DATA_DIR` | `~/.agentboard` | 数据库和日志目录 . |

见 [配置](https://npmcn.com/package/%40gbasin/agentboard/docs/configuration.md) 每个环境.

外观、通知声音、命令预设、会话列表选项和终端选项都在 **设置** 用户界面中的对话 .

> **安全说明:** 代理板没有认证 。 任何能够到达服务器的人都可以作为您的用户运行命令. 默认它接受来自此机器的连接,如果Tailscale正在运行,则接受来自您的尾网的连接. 未设置 `HOSTNAME=0.0.0.0` 在您不信任的网络(公共Wi-Fi,共享局域网)上,没有另一个访问控制层。 见 [警卫](https://npmcn.com/package/%40gbasin/agentboard/SECURITY.md#threat-model) 完全威胁模型.

## 键盘快捷键

| 行动 | 麦克 | 视窗/ Linux |
| --- | --- | --- |
| 上届会议 | `Ctrl+Option+[` | `Ctrl+Shift+[` |
| 下届会议 | `Ctrl+Option+]` | `Ctrl+Shift+]` |
| 跳转到会话 1- 9 | `Ctrl+Option+1..9` | `Ctrl+Shift+1..9` |
| 新会话 | `Ctrl+Option+N` | `Ctrl+Shift+N` |
| 杀死会话 | `Ctrl+Option+X` | `Ctrl+Shift+X` |
| 设置 | `Ctrl+Option+,` | `Ctrl+Shift+,` |

要使用不同的修饰符, 打开 **设置** > 翻译: **终端**。 。 。 .

## 如何运作

```
┌─────────────┐    SSH     ┌─────────────┐
│ Remote Host ├───────────►│             │   WebSocket   ┌────────────┐
│ (tmux)      │            │  Agentboard ├──────────────►│  Browser   │
└─────────────┘    tmux    │  Server     │               │  (React +  │
┌─────────────┐    CLI     │             │               │  xterm.js) │
│ Local tmux  ├───────────►│  - discover │               └────────────┘
│ sessions    │            │    sessions │
└─────────────┘            │  - parse    │
┌─────────────┐    read    │    agent    │
│ Agent logs  ├───────────►│    logs     │
│             │            └─────────────┘
└─────────────┘
```

-   **会话发现:** 服务器对本地 tmux 窗口进行民调,如果配置的话,远程主机会覆盖 SSH .
-   **状态推断 :** 服务器读取窗格内容, 以显示每个代理商是否 _正在工作_, (中文(简体) ), _等待输入_,或 _请求许可_。 。 。 .
-   **日志匹配 :** 服务器读取代理记录稿,将每个会话与它的tmux窗口相匹配,并显示其最后的快取,拉取请求和媒体.
-   **现场终端 :** 服务器流终端 I/O 到浏览器, 这样您就可以使用任何设备的会话 .
-   **休眠和历史会议:** 侧边栏保持休眠 代理会话, 当你需要它时,你醒来一个。 启动不会唤醒休眠或历史会话.

## 文档

-   [会话预览](https://npmcn.com/package/%40gbasin/agentboard/docs/session-previews.md): HTML 在共享媒体面板中报告和活应用.
    
-   [配置](https://npmcn.com/package/%40gbasin/agentboard/docs/configuration.md):每个环境变量.
    
-   [远程主机](https://npmcn.com/package/%40gbasin/agentboard/docs/remote-hosts.md): 来自SSH上空其他机器的会话.
    
-   [会话恢复](https://npmcn.com/package/%40gbasin/agentboard/docs/session-recovery.md): 崩溃或重启后重开会话 .
    
-   [PWA 安装](https://npmcn.com/package/%40gbasin/agentboard/docs/pwa-install.md): 在手机的家用屏幕上添加板.
    
-   [卸载](https://npmcn.com/package/%40gbasin/agentboard/docs/uninstall.md):去掉代理板,什么留在后面.
    
-   [macOS 服务](https://npmcn.com/package/%40gbasin/agentboard/launchd/README.md) 财务报告和审定财务报表 [Linux 服务](https://npmcn.com/package/%40gbasin/agentboard/systemd/README.md)。 。 。 .
    
-   [发展](https://npmcn.com/package/%40gbasin/agentboard/docs/development.md):从源头运行并贡献.
    
-   [安全政策](https://npmcn.com/package/%40gbasin/agentboard/SECURITY.md)。 。 。 .

## 常见问题

### @gbasin/agentboard 是什么？

Tmux 的 Web GUI 优化用于 AI 代理 TUI

### 如何安装 @gbasin/agentboard？

在项目目录运行 npm install @gbasin/agentboard，或使用 pnpm add / yarn add / bun add。它还提供命令行工具 agentboard，可以用 npx agentboard 直接运行。

### @gbasin/agentboard 支持 TypeScript 吗？

该包的 package\.json 没有声明类型入口。需要类型提示时，可以在 npm 上查找社区维护的 @types/gbasin\_\_agentboard 是否存在。

### @gbasin/agentboard 支持 ESM 还是 CommonJS？

以 ES Module 形式发布，推荐使用 import 引入。在 CommonJS 项目中，Node\.js 20\.19\+ / 22\.12\+ 可以直接 require\(\) 不含顶层 await 的 ES Module，更早的版本需要改用动态 import\(\)。

### @gbasin/agentboard 可以商用吗？

@gbasin/agentboard 使用 MIT 许可。宽松许可：允许商业使用、修改和再分发，通常只需在分发时保留原版权与许可声明。以上为概括，不构成法律意见，请以许可原文为准。

### @gbasin/agentboard 的下载量有多少？

根据 npm 官方下载统计，@gbasin/agentboard 在 2026/10/16 – 2026/11/14 这 30 天内被下载 7,293 次，日均约 243 次。下载量会把 CI 构建、镜像同步和作为其他包依赖的安装一并计入，适合横向比较热度，不能直接等同于使用人数。

### @gbasin/agentboard 还在维护吗？

最新版本 0\.46\.8 发布于 2026/11/15（1 天前）；至今共发布 198 个版本，其中过去 12 个月发布了 198 个；首次发布于 2026/02/07。发布频率只是参考信号：功能稳定的工具可能很少需要更新，建议结合源码仓库的 issue 和提交记录判断。

