@devtune/agentpicks 0.4.5 → 0.4.6
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 +4 -4
- package/dist/cli.js +57 -19
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -253,7 +253,7 @@ agentpicks run add-feature-flags
|
|
|
253
253
|
|
|
254
254
|
`agentpicks pull` writes each of the project's DevTune setups to `agentpicks/<name>.yaml`, or into the file already linked to it, with its `id` and `synced`; `pull <setup>` writes one. It leaves a file in sync alone, and refuses to replace a file with changes not yet pushed, or an unlinked file of that name, unless you pass `--force`. A setup's name is its `from` category for an unedited copy of one, else its job line in lowercase with dashes, cut at a word to at most 30 characters.
|
|
255
255
|
|
|
256
|
-
`agentpicks push` saves every setup file to DevTune, and `push <setup>` one. A new file becomes a new DevTune setup, and push writes its `id` and `synced` into the file. A linked file in sync sends nothing. If the DevTune setup changed since the file last saw it, push refuses with `setup_changed` and saves nothing: pull it, apply your changes again, and push. A setup `from` a category saves as the project's setup of that category
|
|
256
|
+
`agentpicks push` saves every setup file to DevTune, and `push <setup>` one. A new file becomes a new DevTune setup, and push writes its `id` and `synced` into the file. A linked file in sync sends nothing. If the DevTune setup changed since the file last saw it, push refuses with `setup_changed` and saves nothing: pull it, apply your changes again, and push. A setup `from` a category saves as the project's setup of that category. Adding or editing a full entry (`key`, `name` and `signals`) for a tool outside DevTune's catalogue, or adding a catalogue tool by key outside the category, saves the category's copy with those tools. Use catalogue keys alone; a full entry with edited catalogue signals is refused. A tool from DevTune's catalogue goes by key alone: `pull` writes it that way, and DevTune fills in its signals when you push. A job or copy can name, by key, any tool of a category DevTune publishes. When adding or editing tools this way, keep `requests.add` and `requests.recommend` as text and `requests.improve` at its inherited or pulled value. Push the tools first, then push any supported request omissions or improve changes separately; `requests.hosted: null` can be saved with the tools. What a file can't say, such as agent models and a job's building blocks, push keeps as DevTune holds it. For a new file with `repo`, push detects the repository's stacks from its manifests and lockfiles and saves those to DevTune. The file keeps `repo`, so `run <setup>` still tests your repository. If no supported stack is detected, replace `repo` with `stacks` before pushing and pass `--repo` when running. A linked file with `repo` keeps the stacks DevTune already holds.
|
|
257
257
|
|
|
258
258
|
`agentpicks run <name>` also runs a DevTune setup that has no file here, by the name `list` shows, and its runs upload under that setup. A job, or a copy that asks an add request of its own, is refused before Docker starts: anyone who can edit the setup in DevTune could change that request, and the agent runs it with your keys. `agentpicks pull` it and run the file.
|
|
259
259
|
|
|
@@ -281,7 +281,7 @@ jobs:
|
|
|
281
281
|
steps:
|
|
282
282
|
- uses: actions/checkout@v5
|
|
283
283
|
- run: npm install -g @anthropic-ai/claude-code@2.1.323
|
|
284
|
-
- uses: devtunehq/agentpicks@v0.4.
|
|
284
|
+
- uses: devtunehq/agentpicks@v0.4.6
|
|
285
285
|
with:
|
|
286
286
|
setup: agentpicks/error-tracking.yaml
|
|
287
287
|
agent: claude-code
|
|
@@ -295,7 +295,7 @@ jobs:
|
|
|
295
295
|
|
|
296
296
|
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.
|
|
297
297
|
|
|
298
|
-
Pin a release tag, such as `v0.4.
|
|
298
|
+
Pin a release tag, such as `v0.4.6`. 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.
|
|
299
299
|
|
|
300
300
|
| Input | Passed as |
|
|
301
301
|
|---|---|
|
|
@@ -336,7 +336,7 @@ Install Docker, Node.js 20 or later and the agent, set `DEVTUNE_API_KEY`, `DEVTU
|
|
|
336
336
|
|
|
337
337
|
```sh
|
|
338
338
|
npm install -g @anthropic-ai/claude-code@2.1.323
|
|
339
|
-
npx --yes @devtune/agentpicks@0.4.
|
|
339
|
+
npx --yes @devtune/agentpicks@0.4.6 run error-tracking --agent claude-code
|
|
340
340
|
```
|
|
341
341
|
|
|
342
342
|
## The bundle
|
package/dist/cli.js
CHANGED
|
@@ -7375,7 +7375,7 @@ var import_promises5 = require("node:readline/promises");
|
|
|
7375
7375
|
// package.json
|
|
7376
7376
|
var package_default = {
|
|
7377
7377
|
name: "@devtune/agentpicks",
|
|
7378
|
-
version: "0.4.
|
|
7378
|
+
version: "0.4.6",
|
|
7379
7379
|
description: "The open Agent Picks runner: the agentpicks CLI, which tests the coding agents installed on your machine in fresh Docker containers, and the sandbox code DevTune runs its managed tests on",
|
|
7380
7380
|
license: "Apache-2.0",
|
|
7381
7381
|
engines: {
|
|
@@ -28676,11 +28676,10 @@ function resolveSetup(name, file2, held) {
|
|
|
28676
28676
|
}
|
|
28677
28677
|
const row = held?.find((each) => each.tool_key === ref);
|
|
28678
28678
|
if (file2.from) {
|
|
28679
|
-
|
|
28680
|
-
if (!catalogueKeys.includes(ref) && !row && !unchecked)
|
|
28679
|
+
if (!catalogueKeys.includes(ref) && !row && !CATALOGUE_TOOL_KEYS.has(ref))
|
|
28681
28680
|
problems.push({
|
|
28682
28681
|
field,
|
|
28683
|
-
message: `${file2.from} has no tool ${ref}.
|
|
28682
|
+
message: `${file2.from} has no tool ${ref}. Give the full entry: key, name and signals, and optionally domain; or, for a tool DevTune's catalogue has added since, update agentpicks.`
|
|
28684
28683
|
});
|
|
28685
28684
|
} else if (!CATALOGUE_TOOL_KEYS.has(ref) && row?.signals !== null)
|
|
28686
28685
|
problems.push({
|
|
@@ -80106,11 +80105,27 @@ function pushRequest(file2, current, list, shown3, repositoryStacks) {
|
|
|
80106
80105
|
...current ? { setup: current.id } : {}
|
|
80107
80106
|
};
|
|
80108
80107
|
if (from) {
|
|
80109
|
-
|
|
80110
|
-
|
|
80108
|
+
const named = [
|
|
80109
|
+
...file2.tools?.own !== void 0 ? [{ ref: file2.tools.own, field: "tools.own" }] : [],
|
|
80110
|
+
...(file2.tools?.competitors ?? []).map((ref, index) => ({
|
|
80111
|
+
ref,
|
|
80112
|
+
field: `tools.competitors[${index}]`
|
|
80113
|
+
}))
|
|
80114
|
+
];
|
|
80115
|
+
for (const { ref, field } of named)
|
|
80116
|
+
if (typeof ref !== "string" && CATALOGUE_TOOL_KEYS.has(ref.key) && !heldAsWritten(ref, current))
|
|
80111
80117
|
throw new UsageError(
|
|
80112
|
-
`${shown3}: ${key
|
|
80118
|
+
`${shown3}: ${field}: ${ref.key} is a catalogue tool. Use the key alone (${ref.key}), so pull and push keep the same tool.`
|
|
80113
80119
|
);
|
|
80120
|
+
}
|
|
80121
|
+
const writesCopy = from && tools.some(
|
|
80122
|
+
(ref) => typeof ref === "string" ? !CATEGORY_TOOLS[from.slug]?.includes(ref) && !current?.tools.some((row) => row.tool_key === ref) : !heldAsWritten(ref, current)
|
|
80123
|
+
);
|
|
80124
|
+
if (writesCopy && current?.kind === "category")
|
|
80125
|
+
throw new UsageError(
|
|
80126
|
+
`${shown3}: this file is linked to a public-category setup, which can't add tools through push. Create a category copy in the DevTune app, pull that copy, then add your tools to its file and push again.`
|
|
80127
|
+
);
|
|
80128
|
+
if (from && !writesCopy) {
|
|
80114
80129
|
return {
|
|
80115
80130
|
route: "setup",
|
|
80116
80131
|
body: {
|
|
@@ -80122,11 +80137,12 @@ function pushRequest(file2, current, list, shown3, repositoryStacks) {
|
|
|
80122
80137
|
}
|
|
80123
80138
|
};
|
|
80124
80139
|
}
|
|
80125
|
-
if (file2.requests?.improve != null)
|
|
80140
|
+
if (!from && file2.requests?.improve != null)
|
|
80126
80141
|
throw new UsageError(
|
|
80127
80142
|
`${shown3}: requests.improve can't be saved on a job. Remove it, and change it in DevTune instead.`
|
|
80128
80143
|
);
|
|
80129
|
-
const
|
|
80144
|
+
const copyRequests = from ? categoryJobRequests(file2, current, from, shown3) : null;
|
|
80145
|
+
const recommend = copyRequests?.recommend ?? file2.requests?.recommend;
|
|
80130
80146
|
if (!recommend)
|
|
80131
80147
|
throw new UsageError(
|
|
80132
80148
|
`${shown3}: give requests.recommend. DevTune saves a job with its add and recommend requests.`
|
|
@@ -80139,18 +80155,23 @@ function pushRequest(file2, current, list, shown3, repositoryStacks) {
|
|
|
80139
80155
|
return {
|
|
80140
80156
|
route: "job",
|
|
80141
80157
|
body: {
|
|
80142
|
-
job: file2.job,
|
|
80143
|
-
source_category_id: null,
|
|
80144
|
-
requests: {
|
|
80158
|
+
job: from ? current?.name ?? from.name : file2.job,
|
|
80159
|
+
source_category_id: from ? categoryId(list, from.slug, shown3) : null,
|
|
80160
|
+
requests: copyRequests ?? {
|
|
80145
80161
|
add: file2.requests?.add,
|
|
80146
80162
|
recommend,
|
|
80147
80163
|
hosted: file2.requests?.hosted ?? null
|
|
80148
80164
|
},
|
|
80149
|
-
building_blocks: current?.building_blocks ?? NO_BUILDING_BLOCKS,
|
|
80165
|
+
...!from ? { building_blocks: current?.building_blocks ?? NO_BUILDING_BLOCKS } : {},
|
|
80150
80166
|
tools: [
|
|
80151
80167
|
...tools.map((ref) => jobTool(ref, current)),
|
|
80152
|
-
// A
|
|
80153
|
-
...(current
|
|
80168
|
+
// A new copy inherits every category tool, including ones the file doesn't select.
|
|
80169
|
+
...(from && !current ? CATEGORY_TOOLS[from.slug] ?? [] : []).filter((tool) => !listed.has(tool)).map((tool_key) => ({ tool_key })),
|
|
80170
|
+
// A tool DevTune measures that is neither yours nor a competitor, which a file can't name. A copy keeps every
|
|
80171
|
+
// tool it holds, as the setup route does; only a job drops a tool its file stops selecting.
|
|
80172
|
+
...(current?.tools ?? []).filter(
|
|
80173
|
+
(row) => !listed.has(row.tool_key) && (from || !held.has(row.tool_key))
|
|
80174
|
+
).map(heldJobTool)
|
|
80154
80175
|
],
|
|
80155
80176
|
own_tool_key: file2.tools?.own === void 0 ? null : key(file2.tools.own),
|
|
80156
80177
|
competitor_tool_keys: (file2.tools?.competitors ?? []).map(key),
|
|
@@ -80158,6 +80179,27 @@ function pushRequest(file2, current, list, shown3, repositoryStacks) {
|
|
|
80158
80179
|
}
|
|
80159
80180
|
};
|
|
80160
80181
|
}
|
|
80182
|
+
function categoryJobRequests(file2, current, from, shown3) {
|
|
80183
|
+
const published = (intent) => from.prompts.find((prompt) => prompt.intent === intent)?.text ?? null;
|
|
80184
|
+
const effective = (intent) => file2.requests?.[intent] === void 0 ? published(intent) : file2.requests[intent];
|
|
80185
|
+
const improve = effective("improve");
|
|
80186
|
+
const heldImprove = current ? current.requests.improve ?? null : published("improve");
|
|
80187
|
+
if (improve !== heldImprove)
|
|
80188
|
+
throw new UsageError(
|
|
80189
|
+
`${shown3}: requests.improve can't be changed while push saves tools to a category copy. Keep the inherited or pulled requests.improve value, then push again.`
|
|
80190
|
+
);
|
|
80191
|
+
const add = effective("add");
|
|
80192
|
+
const recommend = effective("recommend");
|
|
80193
|
+
for (const [intent, text3] of [
|
|
80194
|
+
["add", add],
|
|
80195
|
+
["recommend", recommend]
|
|
80196
|
+
])
|
|
80197
|
+
if (!text3)
|
|
80198
|
+
throw new UsageError(
|
|
80199
|
+
`${shown3}: requests.${intent} can't be left out while push saves tools to a category copy. Give its text, push the tools, then push the omission separately.`
|
|
80200
|
+
);
|
|
80201
|
+
return { add, recommend, hosted: effective("hosted") };
|
|
80202
|
+
}
|
|
80161
80203
|
var OMITTED_REQUEST = "omitted";
|
|
80162
80204
|
function setupRequests(file2, current, from) {
|
|
80163
80205
|
const requests = {};
|
|
@@ -81116,10 +81158,6 @@ async function linkUploads(plan, setup, content, shown3, ctx) {
|
|
|
81116
81158
|
}
|
|
81117
81159
|
} : plan;
|
|
81118
81160
|
if (setup.id === null) {
|
|
81119
|
-
if (setup.customReason && content && hasOwnTools(content))
|
|
81120
|
-
throw new UsageError(
|
|
81121
|
-
`${shown3} is a custom setup (${setup.customReason}), so its runs have no DevTune setup to upload under, and push can't save tools ${setup.from} doesn't have. Add them to a category copy in the DevTune app, run agentpicks pull, and run the pulled setup, or pass --no-upload to keep the bundles on this machine.`
|
|
81122
|
-
);
|
|
81123
81161
|
if (setup.customReason)
|
|
81124
81162
|
throw new UsageError(
|
|
81125
81163
|
`${shown3} is a custom setup (${setup.customReason}), so its runs have no DevTune setup to upload under. Run agentpicks push ${setup.name} to save it to DevTune first, or pass --no-upload to keep the bundles on this machine.`
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@devtune/agentpicks",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.6",
|
|
4
4
|
"description": "The open Agent Picks runner: the agentpicks CLI, which tests the coding agents installed on your machine in fresh Docker containers, and the sandbox code DevTune runs its managed tests on",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"engines": {
|