Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
47 commits
Select commit Hold shift + click to select a range
2611f78
Let a schedule track a goal across days, try failed runs again, and b…
claude Nov 17, 2026
969e7cd
Give every agent Harness Relay's own tools through one MCP gateway, a…
claude Nov 17, 2026
1bd7c89
Let agents use a browser of their own: open pages, read them, click a…
claude Nov 17, 2026
5cca923
Connect a mail account and a calendar: agents search and read mail, s…
claude Nov 17, 2026
bdc59b1
Close what the independent reviews found in tracked goals, the gatewa…
claude Nov 17, 2026
8baa8f4
Close the security gaps left in the browser, the gateway, mail and tr…
claude Nov 17, 2026
e7c31f0
Say how mail and calendar passwords are kept, not MCP servers' values
claude Nov 17, 2026
dfcc046
Add the pull request's screenshots, for its description only
claude Nov 17, 2026
a930940
Add Prettier for the code, the desktop app's included, and check the …
claude Nov 17, 2026
382d9a5
Format the code with Prettier
claude Nov 17, 2026
4a75e50
Remove the pull request's screenshots again
claude Nov 17, 2026
517e38f
Keep the browser out of the user's own browser folders, and fix what …
claude Nov 17, 2026
b6b2e95
Let the gateway decide by tier, track only the schedule's runs, and c…
claude Nov 17, 2026
0f83b3e
Tell visitors and the tour about tracked goals, the outbox and Harnes…
claude Nov 17, 2026
6fc3160
Keep tracking a goal through the runs that carry a schedule's run on,…
claude Nov 17, 2026
913b5ff
Keep a schedule's kinds on one row that scrolls sideways, with no set…
claude Nov 17, 2026
bce2ef5
Start a new schedule with no set times
claude Nov 17, 2026
895a5e6
Expect each system's answer from a gateway without Node.js in its test
claude Nov 17, 2026
4a6531c
Give the open agents Harness Relay's own tools in full access, as Gro…
claude Nov 17, 2026
3c54f67
Call schedules automations: a message that you, set times or a webhoo…
claude Nov 17, 2026
a5cd595
Update the pull request's screenshots, for its description only
claude Nov 17, 2026
74fae94
Remove the pull request's screenshots again
claude Nov 17, 2026
18e5cac
Give New chat and New automation half the sidebar's row each, with a …
claude Nov 17, 2026
a9bced7
Update the pull request's screenshots, for its description only
claude Nov 17, 2026
4abfec6
Remove the pull request's screenshots again
claude Nov 17, 2026
4b7b036
Say who asks and what waits in a notification about the outbox
claude Nov 17, 2026
995fc51
Expect PowerShell's example in the webhook's end-to-end test on Windows
claude Nov 17, 2026
0657c3d
Tell the user when an automation's goal is held up, as #83 asked
claude Nov 17, 2026
6ba0a5c
Let Settings choose the browser the browser tools start, as #85 asked
claude Nov 17, 2026
c44db8d
Read the whole page a click or Enter opens, however late its server a…
cyyeh Nov 17, 2026
e9d21c8
Give OpenCode and Codex Harness Relay's tools over loopback HTTP, the…
claude Nov 17, 2026
842230f
Merge branch 'claude/bold-archimedes-fc9x97' of https://github.com/Ag…
claude Nov 17, 2026
b5a360e
Answer OpenCode's own question about Harness Relay's tools, and keep …
claude Nov 17, 2026
879c305
Keep the mail accounts' note on one spacing in Chinese, and add the T…
claude Nov 17, 2026
e54a2b4
Remove the pull request's screenshots from the tree
claude Nov 17, 2026
0216bee
Merge main: the notification inbox (#89) beside automations, Harness …
cyyeh Nov 17, 2026
89ec0cf
Find iCloud's calendars, and only those that take events
cyyeh Nov 17, 2026
dda851f
Check on macOS too that a command in Harness Relay's sandbox cannot r…
cyyeh Nov 17, 2026
7e10b4d
Say that an account's password could not be kept, not an MCP server's…
cyyeh Nov 17, 2026
02e9eda
Let New automation create the automation's webhook too, its token sho…
cyyeh Nov 17, 2026
82e424b
Open the browser-path box in its test only when it is closed, so the …
cyyeh Nov 17, 2026
db56e2e
Give Copilot Harness Relay's tools over loopback HTTP, Muse Code in f…
cyyeh Nov 17, 2026
bff007a
Call Settings' entry for the agents' cards "Agents" in Chinese too
cyyeh Nov 17, 2026
979b87b
Fold the webhook away under "Let another program start it", so New au…
cyyeh Nov 17, 2026
e7d1238
Fix what the independent review of this round found: held-up goals in…
cyyeh Nov 17, 2026
57c1ee0
Record the header checks of Antigravity and Muse Code: Antigravity ke…
cyyeh Nov 17, 2026
e3f2097
Name Muse Code among the CLIs the tool library serves
cyyeh Nov 17, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 1 addition & 1 deletion .github/pull_request_template.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ Thanks for the pull request! CONTRIBUTING.md says what a change needs. Write in

## Checklist · 檢查清單

- [ ] `npm run typecheck`, `npm test` and `npm run build` pass · 都通過
- [ ] `npm run format:check`, `npm run typecheck`, `npm test` and `npm run build` pass · 都通過
- [ ] `npm run test:e2e` passes, if I changed the UI, the HTTP API, the orchestrator or an adapter · 修改了介面、HTTP API、協調器或轉接器時,端對端測試通過
- [ ] `npm run desktop:typecheck` passes and I tried `npm run desktop`, if I changed `desktop/` · 修改了 `desktop/` 時,型別檢查通過,也用 `npm run desktop` 試過
- [ ] User-facing text and docs come in both English and 繁體中文, or I said which one I need help with · 給使用者看的文字與文件都有中英文,或我已說明需要協助的語言
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,9 @@ jobs:
- name: Install
run: npm ci

- name: Check the formatting
run: npm run format:check

- name: Typecheck
run: npm run typecheck

Expand Down
17 changes: 17 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# What Prettier leaves alone (it also skips what .gitignore lists, and node_modules).
# The desktop app, a package of its own, has its own list: desktop/.prettierignore.

# Docs: written by hand, their tables and line breaks as they are.
*.md

# Written by npm, or by a program of ours: never by hand.
package-lock.json
src/web/public/manifest.webmanifest
src/web/public/icons/

# Recorded from the real CLIs: replayed byte for byte.
test/fixtures/

# The landing page's HTML: its whitespace and JSON-LD as written (site/DESIGN-GUIDELINES.md), and
# the search engines' verification files, which must stay byte for byte.
site/**/*.html
6 changes: 6 additions & 0 deletions .prettierrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"$schema": "https://json.schemastore.org/prettierrc",
"printWidth": 140,
"singleQuote": true,
"embeddedLanguageFormatting": "off"
}
11 changes: 9 additions & 2 deletions AGENTS.md

Large diffs are not rendered by default.

6 changes: 5 additions & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ Fork the repository (or create a branch if you have write access), branch off `m
### Code

- Strict TypeScript with ES modules. Shared types live only in `src/shared/types.ts`.
- [Prettier](https://prettier.io) formats the code: run `npm run format` before you commit (your editor's Prettier extension uses the same settings, `.prettierrc.json`). It leaves the docs alone (`.prettierignore`). Don't change its settings in a pull request about something else: that reformats the whole repository.
- Start child processes only through `src/server/process.ts`, so they are tracked and stopped on shutdown; a quick probe the server waits for (`lsof`, `ps`, `chflags`) goes through its `runSync()`, which kills it after its timeout. The relay sandbox's host (`relaySandboxHost.ts`) is a program of its own and starts the agent itself. Start programs directly, never through a shell; a shell script (`runShellScript()`, or `sh -c` given to `spawnDetached()`) is fixed text, and the values it needs (paths, names, settings) go in its environment, never in its text or its arguments. A program that gives what it runs an environment of its own (`sudo`, `pkexec`) runs `env NAME=value … /bin/sh -c <fixed text>`, the values Harness Relay's own (`sandboxSetup.ts`). On Windows a CLI found as a `.cmd` (npm's shims, Cursor's and Muse Code's launchers) is started as the program it runs (`src/server/winLaunch.ts`), never through `cmd.exe`.
- Keep CLI output parsers pure (lines in, `AgentEvent`s out) so they can be tested with recorded output.
- Tests run in Node without a DOM. Put client logic you want to test in plain modules (like `src/web/chat.ts`), not inside components.
Expand All @@ -67,6 +68,8 @@ Fork the repository (or create a branch if you have write access), branch off `m
- Never send secrets to the client. API keys belong in the OS credential store (`src/server/secrets.ts`), never in the database as they are: without a credential store they go to the database encrypted (`openSecretStore()`), through the same `SecretStore`.
- The server binds to `127.0.0.1`, and agent replies must not make the browser load remote content (images are shown as links; local media goes through the media endpoint's path checks).
- An open-source agent's process starts only through `startOpenProcess()` (`src/server/agents/open.ts`), which puts it in Harness Relay's own sandbox below full access and fails closed. Model keys reach the CLI in environment variables (only the run's own backend's), never in the config files its adapter writes, and everything a run writes goes in the conversation member's own state folder (`home(root, state)`). A sandbox opening is asked for by one adapter for its own CLI only, and documented in [docs/open-agents.md](docs/open-agents.md) and [docs/sandboxing.md](docs/sandboxing.md).
- Harness Relay's own tools (`src/server/gateway.ts`) reach the server only over the gateway's socket, with a token for one turn kept in a file under `data/tmp`, or over its loopback HTTP endpoint, with the token only in the CLI's memory (a CLI gets it so only once `scripts/mcp-headers-check.ts` shows it writes the token to no file), never through the HTTP API. Their credentials stay in the server, and a call that reaches other people never runs in the turn: it waits in the outbox until the user's Send. A schedule's webhook is the one route that takes its own token (kept hashed) instead of a browser's sign-in.
- The browser tools' Chromium connects only through its own proxy (`src/server/browser/proxy.ts`), which checks the address each connection goes to: never start it without that proxy, nor let anything it loads reach the network another way. Its page scripts run in an isolated world, and it gets only the environment `launchEnv()` gives, never the server's; it writes nothing in the user's own browsers' folders (on Linux its config and cache folders are in its profile).

### Database

Expand Down Expand Up @@ -109,6 +112,7 @@ Tests also have to pass on Windows, where CI runs them too: build paths with `jo
Run the same checks as CI:

```bash
npm run format:check # npm run format fixes what it finds
npm run typecheck
npm test
npm run build
Expand All @@ -120,7 +124,7 @@ If you changed the desktop app, also run `npm run desktop:typecheck`, and try it

Releases are made by maintainers with the Release workflow only (**Actions → Release**, from `main`, today's date as the version): never tag a version by hand. See [Releasing](docs/developer-guide.md#releasing) in the developer guide.

[CI](.github/workflows/ci.yml) runs the typecheck, the tests and the build on Node 22 and 24 for every pull request and every push to `main`, and on Windows with Node 24. It also typechecks and builds the desktop app, runs its bundled server as the app does, and packages it for Linux to check it as a release is checked. [Another workflow](.github/workflows/e2e.yml) runs the end-to-end tests on Linux, macOS and Windows. On a pull request, the tests on Windows, the packaged app and the end-to-end tests run only when it touches a file they depend on ([`scripts/ci-scope.ts`](scripts/ci-scope.ts)): the run's summary says which ran and why. A push to `main` runs them all. If you make one of them read, import or ship a file its `IGNORES` list names, take the file off the list. Each workflow's last check (**CI passed**, **End-to-end passed**) stands for all its jobs.
[CI](.github/workflows/ci.yml) checks the formatting, and runs the typecheck, the tests and the build on Node 22 and 24 for every pull request and every push to `main`, and on Windows with Node 24. It also typechecks and builds the desktop app, runs its bundled server as the app does, and packages it for Linux to check it as a release is checked. [Another workflow](.github/workflows/e2e.yml) runs the end-to-end tests on Linux, macOS and Windows. On a pull request, the tests on Windows, the packaged app and the end-to-end tests run only when it touches a file they depend on ([`scripts/ci-scope.ts`](scripts/ci-scope.ts)): the run's summary says which ran and why. A push to `main` runs them all. If you make one of them read, import or ship a file its `IGNORES` list names, take the file off the list. Each workflow's last check (**CI passed**, **End-to-end passed**) stands for all its jobs.

If your change affects what agents see or do, also try it in the app with at least one real CLI, and say which ones you used.

Expand Down
6 changes: 5 additions & 1 deletion CONTRIBUTING.zh-TW.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ npm run dev # API 在 :8789(檔案變更時重啟)+ 介面在 http://
### 程式碼

- 使用 strict TypeScript 與 ES modules。共用型別只放在 `src/shared/types.ts`。
- 程式碼由 [Prettier](https://prettier.io) 排版:commit 前執行 `npm run format`(編輯器的 Prettier 擴充套件也用同一份設定 `.prettierrc.json`)。它不動文件(`.prettierignore`)。不要在處理其他事情的 pull request 裡改它的設定:那會重新排版整個 repository。
- 子程序一律透過 `src/server/process.ts` 啟動,這樣才會被追蹤並在關閉時結束;伺服器等它結束的簡短檢查(`lsof`、`ps`、`chflags`)用它的 `runSync()`,逾時就結束它。Harness Relay 沙箱的 host(`relaySandboxHost.ts`)是獨立的程式,由它自己啟動 agent。程式要直接啟動,不經過 shell;shell 腳本(`runShellScript()`,或交給 `spawnDetached()` 的 `sh -c`)是固定的文字,它需要的值(路徑、名稱、設定)放在它的環境變數裡,絕不放進腳本文字或參數。會替要執行的程式另設環境的程式(`sudo`、`pkexec`)則執行 `env 名稱=值 … /bin/sh -c <固定文字>`,值都是 Harness Relay 自己的(`sandboxSetup.ts`)。在 Windows 上,找到的 CLI 若是 `.cmd`(npm 的包裝檔、Cursor 與 Muse Code 的啟動檔),會改為啟動它執行的程式(`src/server/winLaunch.ts`),絕不經過 `cmd.exe`。
- CLI 輸出的 parser 保持純函式(輸入一行行文字,輸出 `AgentEvent`),方便用錄下來的輸出測試。
- 測試在沒有 DOM 的 Node 環境執行。想測試的前端邏輯請放在一般模組(例如 `src/web/chat.ts`),不要寫在元件裡。
Expand All @@ -67,6 +68,8 @@ npm run dev # API 在 :8789(檔案變更時重啟)+ 介面在 http://
- 絕不把機密傳給前端。API key 放在作業系統的金鑰儲存區(`src/server/secrets.ts`),絕不以原文放進資料庫:沒有金鑰儲存區時,透過同一個 `SecretStore` 加密後存進資料庫(`openSecretStore()`)。
- 伺服器只綁定 `127.0.0.1`,而且 agent 的回覆不能讓瀏覽器載入遠端內容(圖片以連結顯示;本機媒體要經過媒體端點的路徑檢查)。
- 開源 agent 的程序只能透過 `startOpenProcess()`(`src/server/agents/open.ts`)啟動:完全存取以外,它會把程序放進 Harness Relay 自己的沙箱,沙箱無法啟動就不執行。模型的金鑰以環境變數交給 CLI(只有這次執行的模型來源那一把),絕不寫進轉接器寫的設定檔;一次執行寫入的一切都放在對話成員自己的狀態資料夾(`home(root, state)`)。沙箱的開口只由一個轉接器為它自己的 CLI 申請,並寫在 [docs/open-agents.zh-TW.md](docs/open-agents.zh-TW.md) 與 [docs/sandboxing.zh-TW.md](docs/sandboxing.zh-TW.md)。
- Harness Relay 自己的工具(`src/server/gateway.ts`)只能透過 gateway 的 socket 連到伺服器,用只給一回合、存在 `data/tmp` 底下檔案中的權杖;或透過它的本機 HTTP 端點,權杖只留在 CLI 的記憶體中(要等 `scripts/mcp-headers-check.ts` 確認某個 CLI 不會把權杖寫進任何檔案,它才能這樣拿到),絕不經過 HTTP API。它們的憑證留在伺服器中,會送到別人那裡的呼叫絕不在那一回合執行:它會在待送出匣等到使用者按送出。排程的 webhook 是唯一用自己的權杖(只存雜湊)代替瀏覽器登入的路由。
- 瀏覽器工具的 Chromium 只透過它自己的 proxy(`src/server/browser/proxy.ts`)連線,proxy 會檢查每個連線要去的位址:絕不能不帶那個 proxy 啟動它,也不能讓它載入的任何東西用別的方式連上網路。它在網頁中執行的腳本在 isolated world 中執行,它只拿到 `launchEnv()` 給的環境變數,絕不是伺服器的;它也不在使用者自己瀏覽器的資料夾裡寫任何東西(在 Linux 上,它的設定與快取資料夾都在它的設定檔裡)。

### 資料庫

Expand Down Expand Up @@ -109,6 +112,7 @@ Harness Relay 是雙語的:每一段給使用者看的文字都有繁體中文
請執行和 CI 一樣的檢查:

```bash
npm run format:check # npm run format 會修正它找到的地方
npm run typecheck
npm test
npm run build
Expand All @@ -120,7 +124,7 @@ npm run build

發佈只由維護者透過發佈 workflow 進行(**Actions → Release**,從 `main`,以今天的日期為版本):絕不要手動建立版本 tag。詳見開發者說明的[發佈](docs/developer-guide.zh-TW.md#發佈)。

[CI](.github/workflows/ci.yml) 會在每個 pull request 與每次推送到 `main` 時,以 Node 22 與 24 執行型別檢查、測試與建置,也在 Windows 上以 Node 24 執行。它也會型別檢查並建置桌面 app、像 app 一樣執行打包好的伺服器,並為 Linux 打包它,像檢查發佈一樣檢查。[另一個 workflow](.github/workflows/e2e.yml) 會在 Linux、macOS 與 Windows 上執行端對端測試。在 pull request 上,Windows 上的測試、打包好的 app 與端對端測試,只在它碰到它們依賴的檔案時才會跑([`scripts/ci-scope.ts`](scripts/ci-scope.ts)),執行摘要會說明哪些跑了、為什麼。推送到 `main` 時全部都會跑。如果你讓其中一個開始讀取、import 或打包它的 `IGNORES` 清單上的檔案,請把那個檔案從清單拿掉。每個 workflow 最後的檢查(**CI passed**、**End-to-end passed**)代表它所有的 job。
[CI](.github/workflows/ci.yml) 會在每個 pull request 與每次推送到 `main` 時檢查排版,並以 Node 22 與 24 執行型別檢查、測試與建置,也在 Windows 上以 Node 24 執行。它也會型別檢查並建置桌面 app、像 app 一樣執行打包好的伺服器,並為 Linux 打包它,像檢查發佈一樣檢查。[另一個 workflow](.github/workflows/e2e.yml) 會在 Linux、macOS 與 Windows 上執行端對端測試。在 pull request 上,Windows 上的測試、打包好的 app 與端對端測試,只在它碰到它們依賴的檔案時才會跑([`scripts/ci-scope.ts`](scripts/ci-scope.ts)),執行摘要會說明哪些跑了、為什麼。推送到 `main` 時全部都會跑。如果你讓其中一個開始讀取、import 或打包它的 `IGNORES` 清單上的檔案,請把那個檔案從清單拿掉。每個 workflow 最後的檢查(**CI passed**、**End-to-end passed**)代表它所有的 job。

如果你的修改會影響 agent 看到或做的事,也請在 app 中用至少一個真正的 CLI 試過,並說明用了哪些。

Expand Down
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,8 @@ For each question, a lead agent picks the team from your templates (or adapts on
- **Safe editing with git**: each working directory (up to eight per chat) becomes a git repository, each reply shows the files it changed with a diff, and in parallel mode every agent works in its own worktree. ([Reviewing and applying changes](docs/user-guide.md#reviewing-and-applying-changes))
- **You stay in charge**: a permission per chat (read-only, edit, full access), approvals in the chat for anything beyond it, agents that ask you rather than guess, and messages you can send while they reply. ([Approvals](docs/user-guide.md#approvals), [chatting](docs/user-guide.md#4-chat))
- **Everything live**: replies, reasoning, plans and tool activity stream in; Mermaid diagrams, images and the files agents make show in the chat; copy, edit, retry or branch from any reply. ([Copying, editing and retrying](docs/user-guide.md#copying-editing-and-retrying), [branching](docs/user-guide.md#branching-a-conversation))
- **Schedules**: send the team a message at set times, such as a review of yesterday's commits every weekday at 9:00. ([Schedules](docs/user-guide.md#schedules))
- **Harness Relay's own tools**: a browser of its own, mail and a calendar for the agents of every CLI (Grok's, Muse Code's, and the open-source agents' but OpenCode's, in full access only), through one MCP server; what reaches other people waits in an outbox until you send it. ([Harness Relay's tools](docs/user-guide.md#harness-relays-tools-browser-mail-and-calendar))
- **Automations**: send the team a message when you run one, at set times (a review of yesterday's commits every weekday at 9:00), or when a program on this computer calls its webhook; an automation can track a goal across days until an agent says it is reached, and tries a failed run again. ([Automations](docs/user-guide.md#automations))
- **Files, voice and sharing**: attach files and screenshots, browse the working directory, dictate with voice input that stays on your computer, and share a chat as Markdown or a link. ([Browsing files](docs/user-guide.md#browsing-files), [voice input](docs/user-guide.md#voice-input), [sharing](docs/user-guide.md#sharing-a-conversation))
- **Organised**: groups, pinned chats at the top, search, each chat's status in the sidebar, notifications and sound, as push notifications on a phone, and a bell that keeps every notification, the same in every browser. ([Groups](docs/user-guide.md#groups), [pinned chats](docs/user-guide.md#pinned-conversations), [search](docs/user-guide.md#search), [notifications](docs/user-guide.md#notifications-and-sound), [notification inbox](docs/user-guide.md#notification-inbox))
- **Set up once for every CLI**: a CLI not found installs from its card in one click (and removes again), a tool library of MCP servers, skills and memory, several accounts per CLI, each account's plan usage, what each CLI loads by itself, and the agents' sessions in [AgentsView](https://www.agentsview.io). ([Installing a CLI](docs/user-guide.md#installing-a-cli-from-settings), [tool library](docs/user-guide.md#tool-library-mcp-servers-skills-and-memory), [accounts](docs/user-guide.md#more-than-one-account), [plan usage](docs/user-guide.md#plan-usage), [AgentsView](docs/user-guide.md#agent-sessions-the-clis-own-folder-and-agentsview))
Expand Down Expand Up @@ -83,7 +84,7 @@ Agents can change your files and run commands, so Harness Relay keeps them withi
| `npm start` | Serve the built UI and the API from one process on http://127.0.0.1:8787 |
| `npm run login` | Print another one-time sign-in link, for when the one `npm start` printed is used or old |
| `npm run dev` | For development: the API server (port 8789, auto-restart) and Vite (port 5173) |
| `npm run typecheck`, `npm test`, `npm run build` | What CI runs for every pull request |
| `npm run format:check`, `npm run typecheck`, `npm test`, `npm run build` | What CI runs for every pull request (`npm run format` formats the code with Prettier) |

The other commands (end-to-end tests, the desktop app, the website, the demo) are in the [developer guide](docs/developer-guide.md#running), with what [CI](docs/developer-guide.md#continuous-integration) runs.

Expand Down
Loading
Loading