@devtune/agentpicks 0.4.11 → 0.5.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 +39 -7
- package/dist/cli.js +6652 -424
- package/package.json +2 -2
- package/schema/setup.v1.json +84 -2
package/README.md
CHANGED
|
@@ -49,6 +49,8 @@ agentpicks run --category error-tracking --repo .
|
|
|
49
49
|
| `--model` | The model to ask for. OpenCode and Pi take `anthropic/<model>` or `openai/<model>`. |
|
|
50
50
|
| `--out` | Where bundles go. Default `./agentpicks-runs`. |
|
|
51
51
|
| `--no-upload` | Keep bundles on this machine only. Send them later with `agentpicks upload`; a custom setup's once `agentpicks push` saves it (see [Setups](#setups)). `AGENTPICKS_NO_UPLOAD`, set to anything, does the same for every run. |
|
|
52
|
+
| `--only use` | With a setup file, ask its use request instead of its add request, and run its success check. See [Use your tool](#use-your-tool). |
|
|
53
|
+
| `--no-check` | With `--only use`, skip the success check. |
|
|
52
54
|
|
|
53
55
|
`agentpicks --help`, or `--help` after any command, prints the usage and exits successfully.
|
|
54
56
|
|
|
@@ -130,7 +132,7 @@ agentpicks results
|
|
|
130
132
|
agentpicks results ./agentpicks-runs ./ci-runs --json
|
|
131
133
|
```
|
|
132
134
|
|
|
133
|
-
`agentpicks results` prints a row for each run in `./agentpicks-runs`, or the directories named: its run id, setup or category, agent, model and pick, then how many runs in each setup picked each tool. The pick is read from the bundle with the early-stop patterns the run recorded, in the order the early stop checks them: the packages the agent added that the patterns name, else the first added line of code they match, else a config file the agent created that they match. The pick shows the package names, the code or the file, not a tool name. A run with no pick shows `none`. A run shows `Unmeasured`, with the reason printed under the counts, when:
|
|
135
|
+
`agentpicks results` prints a row for each run in `./agentpicks-runs`, or the directories named: its run id, setup or category, agent, model and pick, then how many runs in each setup picked each tool. With a `use` run among them, a CHECK column shows each use run's success check, and why one didn't pass follows. The pick is read from the bundle with the early-stop patterns the run recorded, in the order the early stop checks them: the packages the agent added that the patterns name, else the first added line of code they match, else a config file the agent created that they match. The pick shows the package names, the code or the file, not a tool name. A run with no pick shows `none`. A run shows `Unmeasured`, with the reason printed under the counts, when:
|
|
134
136
|
|
|
135
137
|
- its bundle fails its checks, or was written before `agentpicks` recorded a run's early-stop patterns;
|
|
136
138
|
- a check is unread, because its package files or diff weren't captured or the diff was cut at its size limit, and no check before it found a pick;
|
|
@@ -168,10 +170,11 @@ agentpicks init --category authentication --tool clerk --competitors authjs,okta
|
|
|
168
170
|
- **Where to test**: this repository (`repo`, written `repo: .`), every stack the job runs in (`all`), or stacks by number or range. The default is `repo` in a git repository with at least one commit, else the stacks your `package.json` and lockfiles name (`next`, `@tanstack/react-start`, `@sveltejs/kit` and `express`, a pnpm monorepo's apps included, plus FastAPI and Rails).
|
|
169
171
|
- **Agents**: those installed here that `run` could start now, with their sign-in or key.
|
|
170
172
|
- **Runs** and the setup's **name**.
|
|
173
|
+
- **Use your tool**, when the setup has a tool of yours: the use request `run --only use` asks, drafted as the add request with your tool named, or `none`; then a check command, or `none`. See [Use your tool](#use-your-tool).
|
|
171
174
|
|
|
172
175
|
For a custom setup, run `agentpicks push <setup>` before running it with uploads.
|
|
173
176
|
|
|
174
|
-
Each question also has a flag, which takes keys, never list numbers: `--category <category>` or `--job <line>`, `--tool <tool>` or `none`, `--competitors <tool>,<tool>` or `all`, `--repo .` or `--stack <stack>` or `all`, `--agent <agent>` or `any`, `--runs <n>` and `--name <name>`. `--stack` and `--agent` repeat, or take a comma list. `init` asks only what the flags leave, and refuses a flag value that doesn't read, naming the flag. A job line's requests and tools have no flags: answer them on a terminal or, signed in, take DevTune's drafts with `--yes`. Without a sign-in, type them on a terminal, or have your coding agent write the file against `agentpicks schema` and check it with `agentpicks validate`.
|
|
177
|
+
Each question also has a flag, which takes keys, never list numbers: `--category <category>` or `--job <line>`, `--tool <tool>` or `none`, `--competitors <tool>,<tool>` or `all`, `--repo .` or `--stack <stack>` or `all`, `--agent <agent>` or `any`, `--runs <n>`, `--use <request>` or `none`, `--check <command>` or `none`, and `--name <name>`. `--stack` and `--agent` repeat, or take a comma list. `init` asks only what the flags leave, and refuses a flag value that doesn't read, naming the flag. A job line's requests and tools have no flags: answer them on a terminal or, signed in, take DevTune's drafts with `--yes`. Without a sign-in, type them on a terminal, or have your coding agent write the file against `agentpicks schema` and check it with `agentpicks validate`.
|
|
175
178
|
|
|
176
179
|
`agentpicks catalogue` lists the category, tool and stack keys the flags take: every category and the stacks a job line can run in. `agentpicks catalogue <category>` lists the category's tool keys and the stacks it runs in. `--json` prints either as one JSON object.
|
|
177
180
|
|
|
@@ -221,7 +224,8 @@ runs: 3
|
|
|
221
224
|
|---|---|
|
|
222
225
|
| `job` | The job line, one line of up to 300 characters, which labels the setup; a run asks `requests.add`. A new job line is at least 8 characters; a file linked to a DevTune job may keep the shorter line that job is saved with. Required without `from`. |
|
|
223
226
|
| `from` | A built-in category, as `--category` takes it. The setup inherits its job, requests and tools. |
|
|
224
|
-
| `requests` | One request per intent: `add`, `recommend`, `hosted` and `improve`, each one line of 8 to 300 characters that names none of the setup's own tools. A run asks `add`, which a setup without `from` must give. With `from`, `null` leaves out the category's request of that intent, except `add`. |
|
|
227
|
+
| `requests` | One request per intent: `add`, `recommend`, `hosted` and `improve`, each one line of 8 to 300 characters that names none of the setup's own tools. A run asks `add`, which a setup without `from` must give. With `from`, `null` leaves out the category's request of that intent, except `add`. `use`, which `run --only use` asks, names your tool (`tools.own`) and no competitor. |
|
|
228
|
+
| `check` | The success check a `use` run runs: `default` (the test app's own check, default `true`), `command` (one line of up to 1000 characters, run from the test app after it) and `timeout` (seconds the command may take, from 10 to 300, default 300; only with a command). Each runs under its own time limit. |
|
|
225
229
|
| `tools` | `own`, your tool, and `competitors`. Each is the key of a tool in DevTune's catalogue (`sentry`), or a full entry: `key`, `name` and `signals`, and optionally `domain`. A full entry's key can't be one of the `from` category's. Your setup lists up to six `competitors`; a file pulled from one of DevTune's public boards may list every tool the board ranks. A setup without `from` needs at least one tool and holds at most seven; a setup `from` a category holds its category's tools plus seven. A setup from a category that names a catalogue tool its category doesn't measure is custom. |
|
|
226
230
|
| `signals` | How a tool is recognised: `packages` by `npm`, `pypi` or `gem` (a name ending in `*` matches every package that starts with the text before the `*`, and one ending in `/` every package under that scope or path, so `@acme/` matches `@acme/flags`), `configNames` (environment variable names or API hosts, not starting with `-`), and `importPatterns`, `configFiles`, `configPatterns`, `commandPatterns`, `selfHosted` (patterns of up to 200 characters that RE2 compiles), `aliases`, `brandDomains`, `frameworkBuiltIn`, `yieldsTo` and `receivesFrom`. A tool can give only `aliases` and `brandDomains`: DevTune recognizes it when an agent names it as its pick, and the early stop doesn't watch for it. Tools can't yield to each other in a loop. |
|
|
227
231
|
| `stacks` | Starter apps to test in, as `--stack` takes them, each once. A setup without `from` can't use `nextjs-github-actions`, `fastapi-aws` or `rails-own-servers-eu`, which run in some categories only or carry a deploy context. |
|
|
@@ -241,6 +245,33 @@ agentpicks run
|
|
|
241
245
|
|
|
242
246
|
`agentpicks run <setup>` takes the setup's name or the path of its file. Each run asks the setup's `add` request, once per agent and stack. Claude Code's early stop watches for the `from` category's tools and for the package and config names of the setup's own tools; a tool that yields to another tool in the setup (`yieldsTo`) doesn't stop it, and nor does a tool named by key alone or a full entry with no package or config name, so a setup whose tools are all like these isn't stopped early. Flags override the file: `--stack` or `--repo` replaces its stacks or repo, `--ref` its commit, `--agent` its agents, and `--runs` its runs. `--model` sets one agent's model, so a setup with several agents needs `--agent` with it. On a terminal, `agentpicks run` with no setup and no `--category` lists the setups and asks which to run.
|
|
243
247
|
|
|
248
|
+
### Use your tool
|
|
249
|
+
|
|
250
|
+
`agentpicks/sentry-use.yaml` asks agents to add error tracking with your tool, Sentry, and checks the result:
|
|
251
|
+
|
|
252
|
+
```yaml
|
|
253
|
+
from: error-tracking
|
|
254
|
+
requests:
|
|
255
|
+
use: Add error tracking to this app with Sentry.
|
|
256
|
+
check:
|
|
257
|
+
command: node -e "require('@sentry/node')"
|
|
258
|
+
timeout: 120
|
|
259
|
+
tools:
|
|
260
|
+
own: sentry
|
|
261
|
+
stacks: [express]
|
|
262
|
+
```
|
|
263
|
+
|
|
264
|
+
```sh
|
|
265
|
+
agentpicks run sentry-use --only use --no-upload
|
|
266
|
+
agentpicks run sentry-use --only use --no-check
|
|
267
|
+
```
|
|
268
|
+
|
|
269
|
+
`agentpicks run <setup> --only use` asks the setup's `use` request, and measures whether the agent's integration works. The early stop is off, so the agent finishes. Before the agent starts, the success check runs on the untouched test app; after the agent exits, it runs again on what the agent left. The check is the test app's default check, unless `check.default` is `false`, then `check.command`. `results` and DevTune read the check after the agent: passed, failed, timed out, or Unmeasured with the reason, such as a test app that fails its own check before the agent starts, a file the check depends on that the agent changed, or a check that needs a key: it failed on an environment variable the agent's change reads and nothing set, or your tool's brand domains refused it with a 401 or 403. `--no-check` skips both checks, and the run's check reads Unmeasured.
|
|
270
|
+
|
|
271
|
+
`--only use` runs only a setup file in your repository, never a DevTune setup with no file: anyone who can edit the setup in DevTune could change its use request and check command, which run on your machine. Its runs upload under the file's linked DevTune setup, which holds the use request: `agentpicks push` it first, or pass `--no-upload`. A plain `run` asks the add request only.
|
|
272
|
+
|
|
273
|
+
`requests.use` and `check` need `agentpicks` 0.5.0 or later; `validate` and `pull` say so, and an older version refuses the file.
|
|
274
|
+
|
|
244
275
|
A setup file linked to a DevTune setup (it has an `id`) uploads under that setup. An unlinked setup `from` a category, with no requests or tool signals of its own, uploads as that category. Naming the category's tools under `tools` doesn't change that. Any other setup is custom, and can't share its name with a built-in category: until `agentpicks push` saves it to DevTune, `run` refuses to start it without `--no-upload`. A run of a linked file whose DevTune setup is gone is refused before it starts, and so is a run of a linked file with changes not pushed (push it first) or whose DevTune setup changed since the file last saw it (pull it first). DevTune refuses an upload whose prompt isn't its setup's current request, as `prompt_mismatch`. A `--no-upload` bundle of a custom setup, or of a linked file's changes not pushed, uploads once `agentpicks push` has saved the file with the same `from`, add request and tools the run tested: run `upload` from the repository that holds the file. Adding what `push` needs and a run doesn't, such as a `recommend` request, is fine. A bundle of an add request or tools the file or DevTune no longer holds can't file under the setup; run the setup again.
|
|
245
276
|
|
|
246
277
|
```sh
|
|
@@ -290,7 +321,7 @@ jobs:
|
|
|
290
321
|
steps:
|
|
291
322
|
- uses: actions/checkout@v5
|
|
292
323
|
- run: npm install -g @anthropic-ai/claude-code@2.1.323
|
|
293
|
-
- uses: devtunehq/agentpicks@v0.
|
|
324
|
+
- uses: devtunehq/agentpicks@v0.5.1
|
|
294
325
|
with:
|
|
295
326
|
setup: agentpicks/error-tracking.yaml
|
|
296
327
|
agent: claude-code
|
|
@@ -304,7 +335,7 @@ jobs:
|
|
|
304
335
|
|
|
305
336
|
Use a Linux runner: `ubuntu-latest` has Docker and Node.js 20 or later. Without Docker, `run` refuses; without Node.js 20 or later, the action does. The action uses the runner's Node.js and doesn't change it for later steps.
|
|
306
337
|
|
|
307
|
-
Pin a release tag, such as `v0.
|
|
338
|
+
Pin a release tag, such as `v0.5.1`. The action runs the `@devtune/agentpicks` version in the `package.json` of its ref, so a tag runs the same CLI every time. A branch moves to each new version when the mirror syncs, and fails while that version isn't on npm.
|
|
308
339
|
|
|
309
340
|
| Input | Passed as |
|
|
310
341
|
|---|---|
|
|
@@ -315,6 +346,7 @@ Pin a release tag, such as `v0.4.11`. The action runs the `@devtune/agentpicks`
|
|
|
315
346
|
| `runs` | `--runs` |
|
|
316
347
|
| `agent` | `--agent`, in place of the setup's agents. |
|
|
317
348
|
| `model` | `--model` |
|
|
349
|
+
| `only` | `--only`. `use` asks a setup file's use request, with its success check. |
|
|
318
350
|
| `out` | `--out`. Default `./agentpicks-runs`. |
|
|
319
351
|
| `no-upload` | `--no-upload` when `true`. Default `false`. |
|
|
320
352
|
| `devtune-api-key` | `DEVTUNE_API_KEY` |
|
|
@@ -345,7 +377,7 @@ Install Docker, Node.js 20 or later and the agent, set `DEVTUNE_API_KEY`, `DEVTU
|
|
|
345
377
|
|
|
346
378
|
```sh
|
|
347
379
|
npm install -g @anthropic-ai/claude-code@2.1.323
|
|
348
|
-
npx --yes @devtune/agentpicks@0.
|
|
380
|
+
npx --yes @devtune/agentpicks@0.5.1 run error-tracking --agent claude-code
|
|
349
381
|
```
|
|
350
382
|
|
|
351
383
|
## The bundle
|
|
@@ -358,7 +390,7 @@ redactions.json what redaction removed, per artifact
|
|
|
358
390
|
artifacts/ what the run captured, already redacted
|
|
359
391
|
```
|
|
360
392
|
|
|
361
|
-
`manifest.json` holds `bundleVersion` (1), the generated `runId`, the runner's version, the agent's kind, version and model, the host's OS and architecture, the image digest, the container's egress IP, the stack with its starter and lock digest or the repository with its remote address (`origin`, or the first remote) as host and path alone, without user, password, query, fragment or `transport::` prefix, or `null` with no remote, a local path, or an address it can't read with confidence, and its full commit id, the category (`setup:<name>` for a custom setup), request intent (`add`) and exact prompt, start and end times, and each artifact's size and SHA-256. An artifact that analysis doesn't read and that is over DevTune's upload limit (50 MiB) is trimmed to whole lines within it, and the manifest records its size before and after under `truncation`: `mitm.log` and `agent.err` keep their end, and the rest keep their start. The artifacts analysis reads (the transcript, `requests.jsonl`, the diff and the source files, and the package and manifest files before and after) are never trimmed, so a result is never drawn from part of a run; over the limit, `agentpicks upload` refuses the bundle and names the limit. The egress IP is read inside the container before setup from DevTune's `/api/public/egress-ip`, at the origin of `DEVTUNE_API_BASE_URL` (`https://devtune.ai` by default), which answers with the caller's address as plain text; when it can't be read it is `null`.
|
|
393
|
+
`manifest.json` holds `bundleVersion` (1), the generated `runId`, the runner's version, the agent's kind, version and model, the host's OS and architecture, the image digest, the container's egress IP, the stack with its starter and lock digest or the repository with its remote address (`origin`, or the first remote) as host and path alone, without user, password, query, fragment or `transport::` prefix, or `null` with no remote, a local path, or an address it can't read with confidence, and its full commit id, the category (`setup:<name>` for a custom setup), request intent (`add`, or `use` for `--only use`) and exact prompt, a `use` run's success check (`check`: its source, step digest, runner version, time limit, the default check's and your command's status before the agent, the status after it, and the last step's exit code and duration), start and end times, and each artifact's size and SHA-256. An artifact that analysis doesn't read and that is over DevTune's upload limit (50 MiB) is trimmed to whole lines within it, and the manifest records its size before and after under `truncation`: `mitm.log` and `agent.err` keep their end, and the rest keep their start. The artifacts analysis reads (the transcript, `requests.jsonl`, the diff and the source files, and the package and manifest files before and after) are never trimmed, so a result is never drawn from part of a run; over the limit, `agentpicks upload` refuses the bundle and names the limit. The egress IP is read inside the container before setup from DevTune's `/api/public/egress-ip`, at the origin of `DEVTUNE_API_BASE_URL` (`https://devtune.ai` by default), which answers with the caller's address as plain text; when it can't be read it is `null`.
|
|
362
394
|
|
|
363
395
|
The artifacts are those a DevTune managed run captures: `transcript.jsonl`, `diff.patch`, `requests.jsonl` (every request the agent's traffic made through the logging proxy), `llm-usage.jsonl`, `deps.txt`, the manifests and lockfiles before and after, `meta.json` (the agent's exit code) and `earlystop.json`, among others.
|
|
364
396
|
|