@staff0rd/assist 0.318.0 → 0.318.2
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 +7 -4
- package/dist/index.js +22 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -5,6 +5,7 @@ A CLI tool for enforcing determinism in LLM development workflow automation.
|
|
|
5
5
|
See [devlog](https://staffordwilliams.com/devlog/assist/) for latest features.
|
|
6
6
|
|
|
7
7
|
## Installation
|
|
8
|
+
|
|
8
9
|
You can install `assist` globally using npm:
|
|
9
10
|
|
|
10
11
|
```bash
|
|
@@ -13,6 +14,7 @@ assist sync
|
|
|
13
14
|
```
|
|
14
15
|
|
|
15
16
|
## Updating
|
|
17
|
+
|
|
16
18
|
```bash
|
|
17
19
|
assist update
|
|
18
20
|
```
|
|
@@ -68,7 +70,7 @@ After installation, the `assist` command will be available globally. You can als
|
|
|
68
70
|
- `/seq` - Query Seq logs from a URL or filter expression
|
|
69
71
|
- `/sql` - Query a MSSQL database via assist sql
|
|
70
72
|
- `/verify` - Run all verification commands in parallel
|
|
71
|
-
- `/verify-new` - Add a new verify
|
|
73
|
+
- `/verify-new` - Add a new verify:\* run command to assist.yml
|
|
72
74
|
- `/transcript-format` - Format meeting transcripts from VTT files
|
|
73
75
|
- `/transcript-summarise` - Summarise transcripts missing summaries
|
|
74
76
|
- `/voice-setup` - Download required voice models (VAD, STT)
|
|
@@ -113,7 +115,7 @@ After installation, the `assist` command will be available globally. You can als
|
|
|
113
115
|
- `--top <n>` - Only report the top `n` repos by commit count; committers and the author breakdown then cover those repos only (also caps the per-repo author queries, which speeds up large orgs)
|
|
114
116
|
- `--json` - Output all three views as structured JSON instead of tables
|
|
115
117
|
- `assist news add [url]` - Add an RSS feed URL (rendered in the sessions web News tab)
|
|
116
|
-
Backlog data is stored in a global Postgres database (shared across all repos, scoped per repository by git origin), so a connection string is required. Set it via the `ASSIST_DATABASE_URL` environment variable or the `database.url` key in `assist.yml`; the environment variable takes precedence. Without one, every `assist backlog` command exits with a setup message. (There is no SQLite/JSONL fallback.) Commands default to the current repository's items; pass `--all-repos` to span every repository.
|
|
118
|
+
Backlog data is stored in a global Postgres database (shared across all repos, scoped per repository by git origin), so a connection string is required. Set it via the `ASSIST_DATABASE_URL` environment variable or the `database.url` key in `assist.yml`; the environment variable takes precedence. Without one, every `assist backlog` command exits with a setup message. (There is no SQLite/JSONL fallback.) Commands default to the current repository's items; pass `--all-repos` to span every repository.
|
|
117
119
|
|
|
118
120
|
The first backlog command in a repository that still has a local `.assist/backlog.jsonl` automatically migrates it into Postgres — but only as a one-time bootstrap into an empty origin. If Postgres has **no** items for the repo's origin yet, it runs `git pull` (best-effort) to fetch the latest committed copy, imports every item under the origin with fresh global IDs (rewriting links to other items), and verifies the result. If Postgres **already** has items for that origin (a prior run, another clone, or a pre-seeded database), the import is skipped to avoid creating duplicates. Either way the local `.assist/backlog.jsonl` and `.assist/backlog.db` are renamed to `*.bak`, so the migration never re-runs and a local copy is retained.
|
|
119
121
|
|
|
@@ -159,7 +161,7 @@ The first backlog command in a repository that still has a local `.assist/backlo
|
|
|
159
161
|
- `assist config get <key>` - Get a config value
|
|
160
162
|
- `assist config list` - List all config values
|
|
161
163
|
- `prs.slack` - The Slack channel (e.g. `#example`) that `/prs-slack` posts pull requests to via the Slack MCP connector
|
|
162
|
-
- `assist verify` - Run all verify
|
|
164
|
+
- `assist verify` - Run all verify:\* commands in parallel (from run configs in assist.yml and scripts in package.json)
|
|
163
165
|
- `assist verify all` - Run all checks, ignoring diff-based filters
|
|
164
166
|
- `assist verify --measure` - After the run, print a summary table of each command's status and duration (slowest first) plus a wall-clock total
|
|
165
167
|
- `assist verify init` - Add verify scripts to a project (writes to `assist.yml` by default; pass `--package-json` to write to `package.json` scripts instead)
|
|
@@ -268,10 +270,12 @@ The first backlog command in a repository that still has a local `.assist/backlo
|
|
|
268
270
|
Web sessions are owned by a long-lived daemon process, not the web server: the server is a thin client that relays WebSocket traffic to the daemon over a local IPC socket (unix domain socket at `~/.assist/daemon/daemon.sock`; named pipe `\\.\pipe\assist-sessions-daemon` on Windows). Restarting the web server leaves sessions running with scrollback intact. The daemon logs to `~/.assist/daemon/daemon.log` (timestamped lines tagged with the daemon's pid, including why it spawned and which sessions it restored) and auto-exits once no sessions remain and no client has been connected for 60 seconds (it is respawned on demand by the web server). Daemon spawning is arbitrated by an `O_EXCL` lockfile so racing clients start at most one daemon; sessions are only restored after the daemon owns the IPC socket, and a daemon that loses ownership of `daemon.pid` shuts down its sessions and exits rather than running orphaned.
|
|
269
271
|
|
|
270
272
|
From WSL, the selector can also surface and drive Windows-host repos (requires `assist` installed on the Windows host). Config keys:
|
|
273
|
+
|
|
271
274
|
- `sessions.windowsProjectsRoot` — the Windows `.claude/projects` directory as seen from WSL (e.g. `/mnt/c/Users/<user>/.claude/projects`); enables discovery of Windows-host repos, tagged with a `Windows` badge. Selecting one launches a native assist daemon on Windows and runs an interactive session there.
|
|
272
275
|
- `sessions.windowsDaemonHost` / `sessions.windowsDaemonPort` — where the WSL daemon reaches the native Windows daemon (defaults `127.0.0.1` / `51764`; set the host to the Windows IP on WSL2 NAT-mode networking).
|
|
273
276
|
|
|
274
277
|
When iterating on assist itself: web server changes only need the `assist sessions` process restarted — sessions survive. Daemon/session-core changes need `assist daemon restart` to load the new code; this kills the PTYs, then claude sessions — including assist sessions that wrap claude, like `assist draft` — are auto-respawned via `claude --resume` with scrollback starting fresh, while run sessions (and assist sessions whose claude sessionId was never discovered) reappear as not-restored tiles that can be retried.
|
|
278
|
+
|
|
275
279
|
- `assist next [id] [--once]` - Alias for `backlog next [id]`; `--once` exits after the first completed item run instead of prompting for another
|
|
276
280
|
- `assist draft [description] [--once]` (alias: `feat`) - Launch Claude in `/draft` mode, chain into next on `/next` signal; an optional `description` is forwarded as `/draft <description>`; `--once` exits when the done signal arrives after the initial draft completes
|
|
277
281
|
- `assist bug [description] [--once]` - Launch Claude in `/bug` mode, chain into next on `/next` signal; an optional `description` is forwarded as `/bug <description>`; `--once` exits when the done signal arrives after the initial bug report completes
|
|
@@ -284,7 +288,6 @@ When `commit.pull` is enabled in config, `assist draft`, `assist bug`, `assist r
|
|
|
284
288
|
|
|
285
289
|
When `commit.expectedBranch` is set (e.g. `main`), `assist commit` prints a prominent warning if HEAD is on any other branch before committing — so work committed (and pushed) on a stray branch in a repo that lands directly on the expected branch isn't silently orphaned. The warning is non-blocking: the commit still proceeds. With the key unset, behaviour is unchanged and no branch check runs.
|
|
286
290
|
|
|
287
|
-
|
|
288
291
|
## netcap browser extension
|
|
289
292
|
|
|
290
293
|
`assist netcap` only runs the receiver; the browser side is a raw Manifest V3 extension (no build step) under `netcap-extension/`. A MAIN-world content script patches `fetch`/`XMLHttpRequest` to capture `{url, method, status, requestBody, responseBody, timestamp}`, relays each entry to the background service worker (`window.postMessage` → `chrome.runtime.sendMessage`), and the background worker POSTs it to the receiver. The XHR patch reads the response across every `responseType` (`json`, `blob`, `arraybuffer`, `document`, not just `text`) — LinkedIn's voyager GraphQL calls use `responseType: "json"`, which exposes no `responseText`, so reading `responseText` alone captured those bodies empty. Forwarding happens in the background context, so the page's CSP (`connect-src`) never blocks it — the limitation that killed the earlier console-paste approach.
|
package/dist/index.js
CHANGED
|
@@ -6,7 +6,7 @@ import { Command } from "commander";
|
|
|
6
6
|
// package.json
|
|
7
7
|
var package_default = {
|
|
8
8
|
name: "@staff0rd/assist",
|
|
9
|
-
version: "0.318.
|
|
9
|
+
version: "0.318.2",
|
|
10
10
|
type: "module",
|
|
11
11
|
main: "dist/index.js",
|
|
12
12
|
bin: {
|
|
@@ -20536,6 +20536,26 @@ function refreshActivity(session) {
|
|
|
20536
20536
|
session.claudeSessionId = activity2.claudeSessionId;
|
|
20537
20537
|
}
|
|
20538
20538
|
|
|
20539
|
+
// src/commands/sessions/daemon/watchThinking.ts
|
|
20540
|
+
var ACTIVATE_MS = 500;
|
|
20541
|
+
var GAP_MS = 1e3;
|
|
20542
|
+
function noteOutputForThinking(session, onStatusChange) {
|
|
20543
|
+
if (session.status !== "waiting") {
|
|
20544
|
+
session.thinkingStreakStart = void 0;
|
|
20545
|
+
session.thinkingLastOutput = void 0;
|
|
20546
|
+
return;
|
|
20547
|
+
}
|
|
20548
|
+
const now = Date.now();
|
|
20549
|
+
const stale = session.thinkingStreakStart == null || session.thinkingLastOutput == null || now - session.thinkingLastOutput > GAP_MS;
|
|
20550
|
+
if (stale) session.thinkingStreakStart = now;
|
|
20551
|
+
session.thinkingLastOutput = now;
|
|
20552
|
+
if (now - (session.thinkingStreakStart ?? now) < ACTIVATE_MS) return;
|
|
20553
|
+
session.thinkingStreakStart = void 0;
|
|
20554
|
+
session.thinkingLastOutput = void 0;
|
|
20555
|
+
daemonLog(`session ${session.id} sustained output while waiting -> running`);
|
|
20556
|
+
onStatusChange(session, "running");
|
|
20557
|
+
}
|
|
20558
|
+
|
|
20539
20559
|
// src/commands/sessions/daemon/wirePtyEvents.ts
|
|
20540
20560
|
var MAX_SCROLLBACK = 256 * 1024;
|
|
20541
20561
|
function appendScrollback(session, data) {
|
|
@@ -20549,6 +20569,7 @@ function wirePtyEvents(session, clients, onStatusChange) {
|
|
|
20549
20569
|
session.pty.onData((data) => {
|
|
20550
20570
|
appendScrollback(session, data);
|
|
20551
20571
|
noteOutputForEscInterrupt(session, onStatusChange);
|
|
20572
|
+
noteOutputForThinking(session, onStatusChange);
|
|
20552
20573
|
broadcast(clients, { type: "output", sessionId: session.id, data });
|
|
20553
20574
|
});
|
|
20554
20575
|
session.pty.onExit(({ exitCode }) => {
|