@khanglvm/relay 0.16.1 → 0.17.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -1,259 +1,71 @@
1
- # relay
1
+ # Relay
2
2
 
3
- **The relay between AI agents and humans — browser boards instead of terminal walls.**
3
+ Relay gives your AI coding agent a board for showing work and asking for
4
+ feedback. Review a design, compare a diff, or answer several questions in one
5
+ place, in your browser or inside a chat app that supports MCP Apps.
4
6
 
5
- `rly` is a CLI that lets your AI agent ask questions and present work in a
6
- local browser board — real forms, charts, diagrams, sortable tables, images,
7
- and live prototypes instead of terminal text and ASCII art. You click, comment
8
- on any element, and Submit; the agent gets your answers and comments back as
9
- JSON and keeps working.
7
+ Feedback stays attached to the thing you mean: a chart point, a line of text,
8
+ or a marked area of an image. When you submit, the agent gets your choices
9
+ and comments as structured JSON, including the target of each comment.
10
+ It works with agents such as Claude Code and Codex.
10
11
 
11
- ## See it
12
+ ![An agent opens a Relay board, the user reviews and submits, and the agent continues](https://raw.githubusercontent.com/khanglvm/relay/main/docs/assets/demo.gif)
12
13
 
13
- **The whole loop** — your agent asks in the terminal, a board opens in your
14
- browser; you pick a style, expand the chart, comment on a data point, leave a
15
- note, Submit — and the agent picks up your answers and keeps going:
14
+ ## Install and try it
16
15
 
17
- ![Full flow: Claude Code opens a relay board, the user answers, comments and submits, the agent continues](https://raw.githubusercontent.com/khanglvm/relay/main/docs/assets/demo.gif)
18
-
19
- ## Quick start
16
+ Requires Node.js 18.3 or newer.
20
17
 
21
18
  ```sh
22
- # the rly CLI
23
19
  npm i -g @khanglvm/relay
24
-
25
- # the agent skill → every detected agent (Claude Code, Codex, Cursor, …)
26
- npx skills add khanglvm/relay --skill relay --all
27
-
28
- # enforce it (recommended) — a skill alone is an ignorable hint; `rly install`
29
- # writes relay's usage rules into the file each agent reads (run `rly install`
30
- # with no args to see every supported target and where it lands):
31
- rly install --all # every agent detected on this machine
20
+ rly ask -q "Which layout?::single::Sidebar,Top navigation"
32
21
  ```
33
22
 
34
- That's it. Next time your agent needs a decision or wants to show you a plan,
35
- it opens a board like the ones above and waits for your Submit.
36
-
37
- Keep relay current with **`rly upgrade`** — it installs the latest CLI and
38
- refreshes the skill (via `npx skills`, falling back to the bundled copy) in one
39
- step, leaving any boards you have open untouched.
40
-
41
- ## Inside the Claude & Codex apps (MCP App)
23
+ A board opens in your browser. Choose an option and submit to see the result
24
+ in your terminal.
42
25
 
43
- relay also runs as an **MCP App** ([SEP-1865](https://modelcontextprotocol.io/seps/1865-mcp-apps-interactive-user-interfaces-for-mcp))
44
- — so the same board renders **inline, right in the conversation**, on Claude
45
- desktop **and mobile** and in Codex, no browser tab. `rly mcp` is a
46
- stdio MCP server with no npm runtime dependencies; register it once and the agent gets two tools,
47
- `relay_ask` (collect decisions/feedback with real form controls) and
48
- `relay_show` (present a plan, diagram, diff, table, or prototype):
26
+ You can also open local files or review changes from a Git repository:
49
27
 
50
28
  ```sh
51
- # Claude Code
52
- claude mcp add relay -- rly mcp
53
-
54
- # Claude Desktop / Codex — write the host config for you
55
- rly mcp install --target claude # claude_desktop_config.json
56
- rly mcp install --target codex # ~/.codex/config.toml
57
-
58
- # or print the snippet for any MCP host (incl. the raw JSON/TOML)
59
- rly mcp config
29
+ rly view README.md
30
+ rly diff --staged
60
31
  ```
61
32
 
62
- When the agent calls a relay tool, the host renders relay's `ui://relay/board`
63
- resource in a sandboxed iframe, hands it the board spec, and the user's answers
64
- flow back to the agent as a `ui/message` user turn, with
65
- `ui/update-model-context` used as a best-effort structured context sync —
66
- markdown, code, diffs, tables, charts, mermaid/graphviz diagrams, images, and
67
- forms, all in-chat. The classic browser board (`rly ask` / `rly show`) is
68
- unchanged; pick whichever surface fits.
69
-
70
- ## What it improves
33
+ ## What you can review
71
34
 
72
- | Without relay | With relay |
73
- |---|---|
74
- | Six questions asked one at a time in the terminal | One board, all questions, real form controls, optional "Other" + notes |
75
- | "Option B is the one with caching (see my last message)" | Each answer option carries its own image / chart / diagram — pick by looking |
76
- | ASCII architecture art | Mermaid, Graphviz, PlantUML — zoomable, full-screen, even user-editable |
77
- | Numbers buried in prose | Charts and sortable tables; screenshots and HTML prototypes in a sandbox |
78
- | "Here's the diff — paste it in your editor" | Side-by-side **diff** blocks, syntax-highlighted **code**, **video** walkthroughs, and **file paths you click to open** in the default app |
79
- | "Which commits should I pick? Resolve this conflict manually." | `rly git pick` / `rly git cherry-pick` boards and color-coded `git-conflict` resolvers with ours/theirs/custom hunk choices |
80
- | "Type *done* when finished reviewing" | A Submit button; answers, notes, and inline comments returned as JSON |
81
- | Feedback = another wall of text | Click any chart point, diagram node, table cell, or sentence; drag an image region to attach a local crop — the agent replies and the thread grows on the board |
35
+ - Plans, documents, charts, and diagrams.
36
+ - Images and HTML prototypes, with comments on individual elements or areas.
37
+ - Source files and diffs, including commit choices and merge conflicts.
38
+ - Questions with choices, notes, and other form controls.
82
39
 
83
- Everything autosaves in real time, detached board links keep serving after
84
- agent timeouts, multiple boards run at once, and the package has **zero npm
85
- runtime dependencies** — plain Node ≥ 18. Browser-side Chart.js, Mermaid, and
86
- Viz.js assets are vendored in the package and lazy-loaded offline when a board
87
- actually needs them.
40
+ Answers and comments autosave. To stop a board, run `rly list` to find its
41
+ ID, then `rly stop <board-id>`.
88
42
 
89
- ## Learn more
43
+ ## For AI agents
90
44
 
91
- | | |
92
- |---|---|
93
- | `rly help` | every command at a glance |
94
- | `rly git pick` / `rly git cherry-pick` | choose commit actions and rank the order directly on a board; add `--code` to cherry-pick with split code review and per-hunk Apply/Skip/Hold |
95
- | `rly git conflict [files…]` | auto-detect unmerged conflict files, or open specific local paths, and return resolved content in `result.blockEdits` |
96
- | `rly share <board-id>` | activate/list/revoke same-Wi-Fi collaborator, reference-only reviewer, or read-only links for a running browser board |
97
- | `rly view <file.md> …` | open a quick read-only board that renders local markdown file(s), data files, or PDFs — library-free; great for plans, READMEs, reports, quotes |
98
- | `rly show --file spec.json --display-only` | present a browser board and continue immediately — no comment/note or acknowledgement required; inline `relay_show` uses this mode by default |
99
- | `rly install --target <agent>` | write relay's rules into an agent's instruction file — `claude` `codex` `cursor` `copilot` `kiro` `windsurf` `cline` `gemini` `opencode` `droid` `agents`; `--all`, `--scope`, `--print`, `--list` |
100
- | `rly upgrade` | update the CLI **and** refresh the skill in one step (safe around open boards; `--dry-run`, `--cli-only`, `--skill-only`) |
101
- | `rly mcp` | run relay as an MCP App server so boards render **inline** in the chat — **stdio** for local desktop hosts (Claude Desktop, Codex), or `rly mcp --http` (Streamable HTTP) for web/mobile/remote; `rly mcp config` / `rly mcp install --target claude\|codex` to register it |
102
- | `rly agent` | the full agent guide — spec format, all block types, annotations, patterns ([docs/AGENT.md](docs/AGENT.md)) |
103
- | `rly schema` | board spec JSON Schema |
104
- | [skills/relay/SKILL.md](skills/relay/SKILL.md) | the bundled skill |
105
-
106
- ## Development
45
+ Install the skill so your agent knows how to create boards and read feedback:
107
46
 
108
47
  ```sh
109
- npm test # smoke tests with no external services (spawns real servers, fake-submits)
48
+ npx skills add khanglvm/relay --skill relay --all
110
49
  ```
111
50
 
112
- ## Changelog
113
-
114
- ### 0.16.1 — reliable area-comment zones
51
+ Give your agent this instruction:
115
52
 
116
- - Primary drag now draws a comment area directly on image and comparison views;
117
- **Area** remains as a visible one-shot lock. Image pan uses Space-drag or the
118
- middle button, while the comparison divider moves only from its handle.
119
- - The selected rectangle remains visible while its comment is composed. Saved
120
- zones carry a comment icon plus count, reopen for add/edit/delete, and disappear
121
- automatically when their final comment is removed.
122
-
123
- ### 0.16.0 — native viewer chrome, area comments, and durable agent waits
124
-
125
- - Viewer toolbars now use browser-native sticky positioning instead of a
126
- scroll-event counter-translation; open comment composers re-anchor on scroll
127
- and preserve unsaved per-target drafts.
128
- - Hold then drag on an image to comment on an exact rectangular area. Relay
129
- saves the crop beside the browser-board record and returns its path; comparison
130
- crops also identify and capture the selected Before/After source.
131
- - Browser boards support `responseRequired:false` / `--display-only`; inline
132
- `relay_show` is display-only by default. Board and waiter deadlines now default
133
- to one day (`--timeout 0` removes Relay's deadline), with client-specific
134
- background/polling guidance in the agent docs.
135
-
136
- ### 0.11.0 — render inline inside the Claude & Codex apps (MCP App)
137
- - **`rly mcp` — relay as an MCP App** ([SEP-1865](https://modelcontextprotocol.io/seps/1865-mcp-apps-interactive-user-interfaces-for-mcp),
138
- extension `io.modelcontextprotocol/ui`). A stdio MCP server with no npm runtime dependencies
139
- that declares a `ui://relay/board` resource (`text/html;profile=mcp-app`) and
140
- two tools, **`relay_ask`** and **`relay_show`**, linked to it via
141
- `_meta.ui.resourceUri` (plus `openai/outputTemplate` for ChatGPT/Codex). The
142
- host renders the board **inline in the conversation** — Claude desktop **and
143
- mobile**, Codex — instead of opening a browser tab.
144
- - **Same board, postMessage transport.** The inline board reuses relay's block
145
- renderer (markdown, code, diff, table, chart, mermaid, graphviz, image, html)
146
- over the MCP Apps JSON-RPC bridge: the spec arrives as the tool result, the
147
- user's submit goes back via `ui/message` so the agent resumes, the structured
148
- payload is also offered through `ui/update-model-context`, the iframe
149
- auto-sizes via `ui/notifications/size-changed`, and vendored Chart.js /
150
- Mermaid / Viz.js load on demand through the host's `resources/read` (no
151
- `/vendor` route, no server in the sandbox).
152
- - **One-command setup** — `rly mcp install --target claude|codex` writes the
153
- host config; `rly mcp config` prints the snippet for any MCP host. The classic
154
- browser board is untouched.
155
- - **Streamable HTTP transport for web/mobile/remote** — `rly mcp --http
156
- [--port N --host H --token SECRET --allow-origin ORIGIN]` serves the same tools
157
- over MCP's Streamable HTTP transport (single `/mcp` endpoint, JSON responses,
158
- CORS, Origin validation, bearer auth, `Mcp-Session-Id`, `$PORT`-aware). relay is
159
- **stateless**, so one instance serves everyone — deploy it once with the repo
160
- **`Dockerfile`** on any free MCP host (mcpdeploy.dev, mcphosting.io,
161
- Render/Railway/Fly, Glama) or publish to **Smithery**, then add the URL as a
162
- custom connector. Only the relay CLI is required — no tunnel/tailscale. stdio
163
- stays the zero-setup path for local desktop.
164
- - **Native look** — the inline board **color-blends** onto the host's SEP-1865
165
- style variables (surfaces, text, borders, primary button, fonts), pins
166
- `color-scheme` so `light-dark()` tokens resolve, and uses the host's **own
167
- full-screen** control (centering content to a readable column in fullscreen).
168
- After submit it collapses to a one-line confirmation so the iframe shrinks.
169
- - **Progressive rendering** — when the host streams the tool call
170
- (`ui/notifications/tool-input-partial`), the board renders valid blocks as they
171
- arrive (a "Composing…" preview) instead of waiting for the whole spec.
172
- - **`palette` block** — color palettes as swatch cards (hover reveals hex, click
173
- copies); mark one `featured` for a spotlight. **`color` question type** — native
174
- picker + hex field + optional `presets`, returns a hex string. Both work on the
175
- browser board and inline.
176
- - **Element annotations inline** — comment on chart points, diagram nodes, table
177
- cells, images and text selections in the MCP board too, returned in
178
- `annotations` exactly like the CLI board.
179
-
180
- ### 0.10.0 — open files, richer code, diffs & video
181
- - **Clickable local file-links.** Write a path in any markdown (`~/clip.mp4`,
182
- `./src/app.ts`, `/abs/report.pdf`, a `file://` URL, a backtick-wrapped path,
183
- or `[label](path)`) and it renders as a link that opens the file in the OS
184
- default app — guarded by a same-origin check + an allowlist of paths the
185
- board actually references. `RLY_OPEN_CMD` overrides the opener.
186
- - **`code` blocks leveled up** — syntax highlighting for ~20 languages (js, ts,
187
- py, go, rust, java, c, cpp, csharp, ruby, php, swift, kotlin, sql, yaml, json,
188
- sh, css, html…), a line-number gutter, a filename/lang header, and `codeFile`
189
- to load source straight from a local file.
190
- - **`diff` block** — render a unified git diff as a colored, line-numbered
191
- comparison with a live **Unified ⇄ Split (side-by-side)** toggle. No git
192
- required; the agent supplies the diff text (`diff`/`diffFile`, `view`).
193
- - **`video` block** — YouTube/Vimeo embeds, a direct media URL, or a local
194
- video file streamed from the server with HTTP Range (seekable), never
195
- embedded in the payload.
196
- - **`pdf` block** — render local `.pdf` files or PDF URLs inline. Local PDFs
197
- stream from the board server and are never embedded in the page payload.
198
- - **Durable boards / rescue** — detached boards keep serving after timeout
199
- until Submit or `rly stop`; every autosave mirrors to `localStorage`; a board
200
- whose connection drops blocks further input instead of losing it, and
201
- `rly rescue <id>` re-serves on the same port so an open tab reconnects. Active
202
- same-Wi-Fi share links stay tied to the board and survive a same-port re-serve
203
- until revoked. Reviewer submissions are isolated, reference-only side reviews
204
- that never finish the owner's board; read-only links cannot mutate feedback.
205
- - Still **zero npm runtime dependencies**, offline, and cross-platform. Vendored
206
- browser libraries are loaded only for boards that need them.
207
-
208
- ### 0.9.1
209
- - The board **intro renders as markdown** (bold/italic/code/links/lists).
210
-
211
- ### 0.9.0 — interactive visual annotations
212
- - Drag/zoom/full-screen viewer, per-element **and** whole-block comments, chart
213
- data-point comment badges, and inline-SVG PlantUML rendering.
214
-
215
- ### 0.8.1
216
- - `rly install` adds **OpenCode** (`~/.config/opencode/AGENTS.md`) and **Droid /
217
- Factory** (`~/.factory/AGENTS.md`) targets.
218
- - README documents `rly install` and `rly upgrade`.
219
-
220
- ### 0.8.0 — install into any agent
221
- - **`rly install --target <agent>`** writes relay's usage rules into the right
222
- file for Claude Code, Codex, Cursor, GitHub Copilot (VS Code / Visual Studio /
223
- JetBrains), Kiro, Windsurf, Cline, Gemini, or the generic `AGENTS.md` —
224
- cross-platform (macOS / Linux / Windows), idempotent, with `--all`, `--scope`,
225
- and `--print`.
226
- - Fixed `rly skill install` crashing when the target skill dir was a symlink.
227
-
228
- ### 0.7.0 — sturdier boards, self-update
229
- - **Markdown blocks render GFM tables**; element comments moved to an
230
- Outline-style right sidebar with inline highlights on commented text.
231
- - **Seamless timeouts** — a detached board that runs past its deadline keeps
232
- serving until Submit or explicit stop, so you can still submit (it lands as
233
- `submitted`); the page shows a calm note instead of disconnecting.
234
- - **`rly upgrade`** — install the latest CLI and refresh the skill in one step.
235
- - Per-question notes are multi-line textboxes.
236
-
237
- ### 0.6.0 — comment on anything
238
- - **Comment on any part of a custom-HTML mockup.** Hover any element — a heading,
239
- a button, a card, the price — and a pin appears to leave an inline note. No
240
- setup needed; the agent writes zero annotation code. Want to scope it? Mark
241
- specific elements with `data-relay-annotate="label"`.
242
- - **Radio questions can carry a note.** Pick an option *and* say why, in one
243
- optional field — now shown by default (set `"note": false` to hide it).
244
- - **Edge-to-edge fullscreen** for charts and HTML mockups, with the toolbar
245
- pinned to the top while you scroll.
246
- - The board **title and intro are commentable** too.
247
-
248
- ### 0.5.0
249
- - Visual answer options, image blocks, viewer redesign, adoption rules.
53
+ ```text
54
+ Use Relay to show work or collect visual feedback. Install the CLI with
55
+ `npm i -g @khanglvm/relay` if missing. Run `rly agent` for the board format.
56
+ Create with `rly ask --file spec.json --detach`, then use `rly wait <board-id>`
57
+ to collect answers. On timeout, check `rly result <board-id>` before continuing.
58
+ ```
250
59
 
251
- ## Migration from quest-board
60
+ To make this a standing preference, `rly install --target codex` adds Relay
61
+ rules to Codex's instruction file. Run `rly install` to see other targets.
252
62
 
253
- relay was formerly `@khanglvm/quest-board` (CLI: `qbd`) — that package is
254
- deprecated. Storage moved from `~/.quest-board` to `~/.relay` (override with
255
- `RLY_HOME`); legacy `"html"` / `"htmlFile"` spec fields keep working.
63
+ ## More help
256
64
 
257
- ## License
65
+ - [Setup and MCP Apps](docs/SETUP.md): agent configuration, in-chat boards, sharing, and updates.
66
+ - [Agent guide](docs/AGENT.md): board examples, block types, and JSON schemas; also available as `rly agent`.
67
+ - `rly help` lists commands. `rly upgrade` updates the CLI and skill.
68
+ - [Changelog](CHANGELOG.md) · [MIT license](LICENSE)
258
69
 
259
- [MIT](LICENSE) © Le Vu Minh Khang
70
+ For development, clone the repo and run `npm test`. The smoke tests use local
71
+ servers and do not require external services.
package/docs/AGENT.md CHANGED
@@ -1,26 +1,15 @@
1
1
  # relay (`rly`) — agent guide
2
2
 
3
- Purpose: ask the human structured questions in a browser tab and/or show them
4
- rich content blocks (markdown, charts, diagrams, tables, code, custom HTML),
5
- then **wait for them to click Submit** and read the answers as JSON from stdout.
6
- No "type 'done' in the terminal", no hand-rolled HTML+server.
7
-
8
- **Match the surface to the content.** You run inside a terminal, an IDE side-panel
9
- (VS Code / JetBrains / Cursor), or a plain-text chat — none of which can render a
10
- markdown file, an image, a chart, a table, a diagram, or a diff. They degrade to
11
- walls of monospace text, or can't show it at all (a terminal can't draw a PNG).
12
- relay renders it in a real browser board. So whenever your output would read better
13
- than monospace — or is a file/visual the user should look at — show it in relay
14
- instead of printing it. Fast paths: `rly view file.md` (or `data.csv`), `rly diff`,
15
- `rly git pick` / `rly git conflict`, or an `image`/`chart`/`table` block on a board.
16
-
17
- **Use relay even in plan mode** — for any clarifying or decision question (Claude
18
- Code / Codex), route it through a relay board, **not** the native
19
- `AskUserQuestion` / ask-user tool: that tool is **not** a substitute, even though
20
- plan-mode guidance suggests it. Do NOT ask in plain terminal text and do NOT
21
- reach for the native ask tool for anything beyond one trivial yes/no — open a
22
- board. Reserve the harness's `ExitPlanMode` strictly for the final plan-approval
23
- gate (it's a mode transition, not a question).
3
+ Use Relay to present files, visuals, substantial plans, diffs, and related user
4
+ questions. Choose purpose-built blocks so users can inspect the content and
5
+ leave precise feedback. Keep short answers and progress updates in chat.
6
+ Respect the user’s existing authorization; boards do not add approval gates.
7
+ For a concise workflow, read the bundled skill (`rly skill path`). This guide is
8
+ a reference for fields and less common operations.
9
+
10
+ Use `rly show --file spec.json --display-only` when no response is needed. Use
11
+ `rly ask --file spec.json --detach` and a waiter for answers or comments.
12
+ Fast paths include `rly view`, `rly diff`, and `rly git`.
24
13
 
25
14
  **Tell the user** at the start of your intro text that they can hover chart
26
15
  points, diagram nodes, table cells, and any element of a custom-HTML block to
@@ -495,15 +484,28 @@ Rules of thumb:
495
484
  // tagTone (optional pill color): warm | cool | neutral | nature | bold | digital
496
485
  ```
497
486
 
498
- ### Local file links — clickable, open in the default app
499
-
500
- Inside any **markdown** (the intro or a `markdown` block) just write a local
501
- file path — `~/clip.mp4`, `./src/app.ts`, `/abs/report.pdf`, a `file://` URL,
502
- or a backtick-wrapped path — and it renders as a click-to-open link. Clicking it
503
- asks relay to open that file in the user's OS default app (video player, editor,
504
- viewer, …); a `[label](~/path)` link works too. Only paths you actually wrote on
505
- the board can be opened (same-origin + allowlist guarded), so prefer surfacing a
506
- real path over telling the user to paste it into a terminal.
487
+ ### Local file links — preview in a board modal
488
+
489
+ Write `[source](/absolute/path/app.js:98)` in the intro or a markdown block.
490
+ Bare/backtick paths, `./`, `../`, `~/`, and `file://` URLs also work. Encode spaces
491
+ in file URLs (`file:///tmp/My%20Report.md`). The browser board previews supported
492
+ files in a modal and restores focus/scroll when closed. `:line`, `:line:column`,
493
+ and `#Lstart-Lend` select source lines; columns are accepted but not highlighted.
494
+
495
+ UTF-8 source/config/log files show numbered source. Markdown renders as a
496
+ document, CSV/TSV as a table, and HTML as a static sandboxed page; these have a
497
+ Source toggle. Images, PDFs, and browser-compatible audio/video render directly.
498
+ HTML scripts, forms, and external resources are disabled. Text previews are
499
+ limited to 1 MiB and 20,000 lines. Unsupported/binary/oversized files and
500
+ folders offer an explicit **Open in app** action; missing files show an error.
501
+
502
+ Preview/open access is restricted to paths explicitly referenced on the board,
503
+ for owner/collaborator browser sessions only. A preview’s nested links do not
504
+ extend the allowlist. These are live disk views without annotations; use content
505
+ blocks for snapshots or feedback. For inline MCP or reviewer/read-only shares,
506
+ embed the file content using `mdFile`, `codeFile`, or media blocks instead.
507
+ Running boards retain their old UI/server snapshot after upgrade; reconnect the
508
+ same board using the upgraded CLI to activate the viewer.
507
509
 
508
510
  ### When to use which block
509
511
 
package/docs/SETUP.md ADDED
@@ -0,0 +1,74 @@
1
+ # Relay setup
2
+
3
+ [Back to the README](../README.md)
4
+
5
+ ## Agent instructions
6
+
7
+ Install the CLI and bundled skill:
8
+
9
+ ```sh
10
+ npm i -g @khanglvm/relay
11
+ npx skills add khanglvm/relay --skill relay --all
12
+ ```
13
+
14
+ To add Relay usage rules to an agent's instruction file:
15
+
16
+ ```sh
17
+ rly install --target codex
18
+ ```
19
+
20
+ Run `rly install` to list supported targets and paths. Use `--all` for all
21
+ detected agents, `--scope project` for project instructions, or `--print`
22
+ to inspect the rules first.
23
+
24
+ `rly upgrade` updates the CLI and refreshes the skill, leaving open boards
25
+ running. It supports `--dry-run`, `--cli-only`, and `--skill-only`.
26
+
27
+ ## Boards inside a chat app
28
+
29
+ Relay can serve boards through MCP Apps. A host that supports MCP Apps can
30
+ render the board inside the conversation. Register the server for your client:
31
+
32
+ ```sh
33
+ claude mcp add relay -- rly mcp
34
+ rly mcp install --target claude
35
+ rly mcp install --target codex
36
+ ```
37
+
38
+ The first command configures Claude Code; the others write Claude Desktop
39
+ and Codex config respectively. Use `rly mcp config` to print config snippets.
40
+ The server exposes `relay_ask` for feedback and `relay_show` for display.
41
+
42
+ For remote clients, `rly mcp --http` serves Streamable HTTP. Run `rly help`
43
+ for host, port, token, and origin flags. The repo includes a `Dockerfile`.
44
+ See the [agent guide](AGENT.md) for board schemas, transport details,
45
+ and host requirements.
46
+
47
+ ## More commands
48
+
49
+ | Command | Use it to |
50
+ | --- | --- |
51
+ | `rly view <file.md>` | Read local Markdown, tables, or PDFs in a board |
52
+ | `rly diff --staged` | Review a staged Git diff |
53
+ | `rly git pick` / `rly git cherry-pick` | Choose commits and their order; add `--code` for per-hunk review |
54
+ | `rly git conflict [files…]` | Review conflict hunks and return resolved text |
55
+ | `rly share <board-id>` | Manage links for collaborators or reviewers on the same Wi-Fi |
56
+ | `rly show --file spec.json --display-only` | Display a board without requiring feedback |
57
+ | `rly rescue <board-id>` | Restore a disconnected board on its original port |
58
+ | `rly agent` | Read the full guide to blocks, annotations, and agent workflows |
59
+ | `rly schema` | Print the board JSON Schema |
60
+
61
+ Boards autosave answers and comments. Detached boards keep serving after
62
+ a wait times out, until submission or `rly stop <board-id>`. Multiple boards
63
+ can run at once.
64
+
65
+ Relay has no npm runtime dependencies. It bundles the browser libraries for
66
+ charts and diagrams and loads them only when a board needs them. Local
67
+ file links open referenced paths in the default app; `RLY_OPEN_CMD` overrides
68
+ the opener.
69
+
70
+ ## Migration from quest-board
71
+
72
+ relay was formerly `@khanglvm/quest-board` (CLI: `qbd`) — that package is
73
+ deprecated. Storage moved from `~/.quest-board` to `~/.relay` (override with
74
+ `RLY_HOME`); legacy `"html"` / `"htmlFile"` spec fields keep working.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@khanglvm/relay",
3
- "version": "0.16.1",
3
+ "version": "0.17.1",
4
4
  "description": "Question boards with rich blocks (markdown, charts, mermaid, tables, code, diffs, video, sandboxed HTML), clickable local file-links, and element-level annotations for AI coding agents (Claude Code, Codex, …): ask users structured questions, present interactive visuals, collect inline comments, read answers as JSON — in a local browser board OR rendered INLINE inside the Claude & Codex apps as an MCP App (SEP-1865).",
5
5
  "keywords": [
6
6
  "ai-agents",