Merge branch 'worktree-agent-abc9e7b0a4e0a0f54'
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -77,12 +77,15 @@ only when asked). Stage use: `references/format.md`.
|
||||
## In a Pipelines chat
|
||||
|
||||
A chat's agent has a `pipelines` MCP server: `show_file`, `show_image`,
|
||||
`show_html`, `show_diff` (show the operator changes, e.g. before a pull request)
|
||||
and `notify` (every Pipelines app the operator is signed in to plus their phone;
|
||||
cleared everywhere once they read it or open the chat). Pipelines already
|
||||
notifies when a reply ends or the agent asks something, so `notify` is only for
|
||||
news mid-turn or after work the turn does not wait for. Show instead of
|
||||
telling the operator a path. Details, limits, chat RPCs: `references/chat.md`.
|
||||
`show_html` (follows the light/dark theme when it styles for dark), `show_diff` (show the
|
||||
operator changes, e.g. before a pull request; `head`, `paths`), `show_run` (a
|
||||
live run card), `schedule_followup` (come back to this chat later) and `notify`
|
||||
(every Pipelines app the operator is signed in to plus their phone; cleared
|
||||
everywhere once they read it or open the chat). Pipelines already notifies when
|
||||
a reply ends or the agent asks something, so `notify` is only for news mid-turn
|
||||
or after work the turn does not wait for. Show instead of telling the operator a
|
||||
path; pass a result's item id as `replace` to update a card in place. Unknown
|
||||
arguments are refused. Details, limits, chat RPCs: `references/chat.md`.
|
||||
|
||||
## References
|
||||
|
||||
|
||||
@@ -5,21 +5,32 @@ the Pipelines app (desktop, web or phone), often not at this machine's terminal.
|
||||
|
||||
## Pipelines tools (`pipelines` MCP server)
|
||||
|
||||
Each call adds a persisted item to the transcript and returns one short line; a
|
||||
refusal comes back as an error with the reason. Paths must resolve inside the
|
||||
operator's home (absolute, `~/...`, or relative to the chat's directory).
|
||||
Each `show_*` call adds a persisted item to the transcript and returns one short
|
||||
line ending with the item's id; a refusal comes back as an error with the
|
||||
reason. Arguments are checked against the tool's schema: an unknown or
|
||||
misnamed field is refused with the list of expected fields. Paths must resolve
|
||||
inside the operator's home (absolute, `~/...`, or relative to the chat's
|
||||
directory).
|
||||
|
||||
Every `show_*` tool takes `replace?`: the id of an item this chat showed
|
||||
earlier, of the same kind (file and image count as one). The card is updated
|
||||
where it is instead of a new one being added; use it for a chart or diff you
|
||||
regenerate, or a file you rewrote.
|
||||
|
||||
| Tool | Arguments | Use for |
|
||||
| --- | --- | --- |
|
||||
| `show_file` | `path`, `title?` | Any file the operator should see: images inline, other files as a preview card. Use instead of naming a path. |
|
||||
| `show_image` | `url_or_path`, `title?`, `alt?` | A home `image/*` file or an `https://` URL (no credentials, at most 2048 chars). |
|
||||
| `show_html` | `html`, `title?`, `height_hint?` (120-600) | Self-contained HTML/SVG: diagrams, charts, tables. Sandboxed: no JavaScript, no network; inline CSS/SVG, `<details>`, `:hover`. Refused above 512 KiB. |
|
||||
| `show_diff` | `path?`, `base?`, `committed_only?`, `title?` | A Git diff card when the operator asks to see the changes, or before submitting a pull request. No `base`: uncommitted work (staged, unstaged, untracked) against HEAD. `base` (e.g. `main`): everything since the merge base, which is what a PR contains, plus uncommitted work unless `committed_only`. Pipelines runs Git; do not paste the diff. |
|
||||
| `show_file` | `path`, `title?`, `replace?` | Any file the operator should see: images inline, other files as a preview card. Use instead of naming a path. A file up to 5 MiB is copied when shown, so the card keeps that version; a larger one stays linked and its card says "changed since shown" or "no longer exists". |
|
||||
| `show_image` | `url_or_path`, `title?`, `alt?`, `replace?` | A home `image/*` file, or an `https://` URL that Pipelines downloads and keeps (public hosts only, PNG/JPEG/GIF/WebP/AVIF/BMP, at most 10 MiB, no credentials, no redirect to plain http). A failed download is an error and nothing is shown. |
|
||||
| `show_html` | `html`, `title?`, `height_hint?` (120-600), `replace?` | Self-contained HTML/SVG: diagrams, charts, tables. Sandboxed: no JavaScript, no network; inline CSS/SVG, `<details>`, `:hover`. Follows the operator's light/dark theme only when it declares dark support: `@media (prefers-color-scheme: dark)`, `color-scheme` or `light-dark()`; anything else is always shown light, on white. Refused above 512 KiB. |
|
||||
| `show_diff` | `path?`, `base?`, `head?`, `paths?`, `committed_only?`, `title?`, `replace?` | A Git diff card when the operator asks to see the changes, or before submitting a pull request. No `base`: uncommitted work (staged, unstaged, untracked) against HEAD. `base` (e.g. `main`): everything since the merge base, which is what a PR contains, plus uncommitted work unless `committed_only`. `head` (e.g. `pipelines/run-123`): that revision instead of the work tree, against `base` or HEAD. `paths`: repository-relative files, directories or globs (`*.go`), at most 50. Pipelines runs Git; do not paste the diff. |
|
||||
| `show_run` | `run_id`, `title?`, `replace?` | A live card for a run: pipeline, title, status, current stage, duration; it updates as the run progresses and opens the run when tapped. |
|
||||
| `schedule_followup` | `message`, `at?` or `after_minutes?` | Queue a prompt to yourself in this chat, 1 minute to 7 days ahead (`at` is RFC 3339). It is a scheduled message from "Agent follow-up" the operator can remove; it does not hold the operator's own messages back, and is delivered when the chat is free at that time. At most 3 pending per chat. Do not wait for it in the current turn. |
|
||||
| `notify` | `title`, `message`, `priority?` | A notification on every Pipelines app the operator is signed in to (web tabs, desktop, Android) and their phone (ntfy); a tap opens this chat. Opening the chat, or tapping or dismissing it on any device, clears it on all of them. Pipelines already notifies when the reply ends and for questions and approvals, so use it only for news mid-turn or after background work the turn does not wait for; a turn that notified sends no separate "replied" notification. 5 per minute per chat; the result says where it went, and undelivered sends report why. |
|
||||
|
||||
`show_diff` lists at most 300 files; a file patch over 256 KiB or a total over
|
||||
1 MiB is shown partially and says so; binaries have no patch; renames show as
|
||||
delete plus add. `base` is a plain revision name. Tools are absent when the
|
||||
delete plus add. `base` and `head` are plain revision names, and `paths` stay
|
||||
inside the repository (no `..`, absolute paths or pathspec magic). Tools are absent when the
|
||||
harness could not register them (logged); then name paths instead.
|
||||
|
||||
## References sent into the chat
|
||||
|
||||
Reference in New Issue
Block a user