@amykit/plugin-claude 0.4.0 → 0.6.0
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 -11
- package/dist/config.d.ts.map +1 -1
- package/dist/config.js +0 -20
- package/dist/config.js.map +1 -1
- package/dist/plugin.d.ts.map +1 -1
- package/dist/plugin.js +0 -12
- package/dist/plugin.js.map +1 -1
- package/package.json +5 -5
package/README.md
CHANGED
|
@@ -2,14 +2,15 @@
|
|
|
2
2
|
|
|
3
3
|
# @amykit/plugin-claude
|
|
4
4
|
|
|
5
|
-
The claude CLI as the agent,
|
|
5
|
+
The claude CLI as the agent, over its JSON envelope.
|
|
6
6
|
|
|
7
|
-
A plugin for [amy](https://github.com/nicolasmelo1/amy). It provides `claude` in the `
|
|
7
|
+
A plugin for [amy](https://github.com/nicolasmelo1/amy). It provides `claude` in the `harness` collection.
|
|
8
8
|
|
|
9
9
|
## Install
|
|
10
10
|
|
|
11
11
|
```sh
|
|
12
|
-
|
|
12
|
+
# Add @amykit/plugin-claude to amy.yaml, then install configured plugins:
|
|
13
|
+
amy init --install
|
|
13
14
|
```
|
|
14
15
|
|
|
15
16
|
Then name it in `~/.amy/config.yaml`:
|
|
@@ -26,23 +27,15 @@ workflows:
|
|
|
26
27
|
```yaml
|
|
27
28
|
plugins:
|
|
28
29
|
"@amykit/plugin-claude":
|
|
29
|
-
baseBranch: {}
|
|
30
|
-
checkouts: {}
|
|
31
|
-
defaultBranch: "main"
|
|
32
30
|
model: ""
|
|
33
31
|
models: []
|
|
34
|
-
reviewerHints: {}
|
|
35
32
|
timeoutMs: 1800000
|
|
36
33
|
```
|
|
37
34
|
|
|
38
35
|
| Setting | Type | Required | Default | What it is |
|
|
39
36
|
| :-- | :-- | :-- | :-- | :-- |
|
|
40
|
-
| `baseBranch` | `record` | no | `{}` | where one repository's base branch is, instead of the fallback. A repository named here has its work cut from, and its pull requests opened against, that branch |
|
|
41
|
-
| `checkouts` | `record` | no | `{}` | where one repository's checkout is, instead of under the workspace root, which is where the agent is sent |
|
|
42
|
-
| `defaultBranch` | `string` | no | `main` | the branch new work is cut from, which is not always `main` |
|
|
43
37
|
| `model` | `string` | no | `""` | passed to the CLI as --model, which is the flag it accepts |
|
|
44
38
|
| `models` | `string[]` | no | `[]` | the model tiers to offer the relay, cheapest first. One agent is contributed per tier, named `claude:<model>`. Empty means a single agent using `model` |
|
|
45
|
-
| `reviewerHints` | `record` | no | `{}` | guidance appended when answering a particular reviewer, by host login |
|
|
46
39
|
| `timeoutMs` | `number` | no | `1800000` | how long one agent call may run before it is given up on |
|
|
47
40
|
|
|
48
41
|
Every field is checked at boot against the schema this package declares. A key that is
|
package/dist/config.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../src/config.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AAE5C,2DAA2D;AAC3D,eAAO,MAAM,YAAY,EAAE,
|
|
1
|
+
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../src/config.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AAE5C,2DAA2D;AAC3D,eAAO,MAAM,YAAY,EAAE,YAiB1B,CAAC"}
|
package/dist/config.js
CHANGED
|
@@ -1,20 +1,5 @@
|
|
|
1
1
|
/** What this plugin needs told to it, and nothing more. */
|
|
2
2
|
export const configSchema = {
|
|
3
|
-
defaultBranch: {
|
|
4
|
-
type: "string",
|
|
5
|
-
description: "the branch new work is cut from, which is not always `main`",
|
|
6
|
-
default: "main",
|
|
7
|
-
},
|
|
8
|
-
baseBranch: {
|
|
9
|
-
type: "record",
|
|
10
|
-
description: "where one repository's base branch is, instead of the fallback. A repository named here has its work cut from, and its pull requests opened against, that branch",
|
|
11
|
-
default: {},
|
|
12
|
-
},
|
|
13
|
-
checkouts: {
|
|
14
|
-
type: "record",
|
|
15
|
-
description: "where one repository's checkout is, instead of under the workspace root, which is where the agent is sent",
|
|
16
|
-
default: {},
|
|
17
|
-
},
|
|
18
3
|
model: {
|
|
19
4
|
type: "string",
|
|
20
5
|
description: "passed to the CLI as --model, which is the flag it accepts",
|
|
@@ -25,11 +10,6 @@ export const configSchema = {
|
|
|
25
10
|
description: "the model tiers to offer the relay, cheapest first. One agent is contributed per tier, named `claude:<model>`. Empty means a single agent using `model`",
|
|
26
11
|
default: [],
|
|
27
12
|
},
|
|
28
|
-
reviewerHints: {
|
|
29
|
-
type: "record",
|
|
30
|
-
description: "guidance appended when answering a particular reviewer, by host login",
|
|
31
|
-
default: {},
|
|
32
|
-
},
|
|
33
13
|
timeoutMs: {
|
|
34
14
|
type: "number",
|
|
35
15
|
description: "how long one agent call may run before it is given up on",
|
package/dist/config.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config.js","sourceRoot":"","sources":["../src/config.ts"],"names":[],"mappings":"AAEA,2DAA2D;AAC3D,MAAM,CAAC,MAAM,YAAY,GAAiB;IACxC,
|
|
1
|
+
{"version":3,"file":"config.js","sourceRoot":"","sources":["../src/config.ts"],"names":[],"mappings":"AAEA,2DAA2D;AAC3D,MAAM,CAAC,MAAM,YAAY,GAAiB;IACxC,KAAK,EAAE;QACL,IAAI,EAAE,QAAQ;QACd,WAAW,EAAE,4DAA4D;QACzE,OAAO,EAAE,EAAE;KACZ;IACD,MAAM,EAAE;QACN,IAAI,EAAE,UAAU;QAChB,WAAW,EACT,yJAAyJ;QAC3J,OAAO,EAAE,EAAE;KACZ;IACD,SAAS,EAAE;QACT,IAAI,EAAE,QAAQ;QACd,WAAW,EAAE,0DAA0D;QACvE,OAAO,EAAE,EAAE,GAAG,EAAE,GAAG,IAAI;KACxB;CACF,CAAC"}
|
package/dist/plugin.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../src/plugin.ts"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../src/plugin.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,cAAc,CAAC;AAKtC,eAAO,MAAM,MAAM,EAAE,MAwBpB,CAAC"}
|
package/dist/plugin.js
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { Git } from "@amykit/core";
|
|
2
1
|
import { contributeTiers } from "@amykit/agent-kit";
|
|
3
2
|
import { ClaudeHarness } from "./ClaudeHarness.js";
|
|
4
3
|
import { configSchema } from "./config.js";
|
|
@@ -7,15 +6,6 @@ export const plugin = {
|
|
|
7
6
|
version: "0.1.0",
|
|
8
7
|
configSchema,
|
|
9
8
|
register(registry, ctx) {
|
|
10
|
-
const git = new Git(ctx.runner, {
|
|
11
|
-
workspaceRoot: ctx.paths.workspace,
|
|
12
|
-
checkouts: ctx.paths.checkouts,
|
|
13
|
-
defaultBranch: ctx.config.defaultBranch,
|
|
14
|
-
baseBranch: ctx.config.baseBranch,
|
|
15
|
-
},
|
|
16
|
-
// The gate (and the agent it hands paths to) runs where the work runs:
|
|
17
|
-
// with a worktree port mounted, that is the item's own tree.
|
|
18
|
-
ctx.port("worktree"));
|
|
19
9
|
const tiers = ctx.config.models;
|
|
20
10
|
// Contributed rather than mounted as the `agent` port: only one plugin
|
|
21
11
|
// can own a port, and three harnesses that each wanted to be *the* agent
|
|
@@ -27,8 +17,6 @@ export const plugin = {
|
|
|
27
17
|
// never leaves a ceiling in money with nothing to spend against it.
|
|
28
18
|
pricesItsOwnRuns: true,
|
|
29
19
|
models: tiers.length > 0 ? tiers : [ctx.config.model || ""],
|
|
30
|
-
git,
|
|
31
|
-
agent: { reviewerHints: ctx.config.reviewerHints },
|
|
32
20
|
make: (model) => new ClaudeHarness(ctx.runner, {
|
|
33
21
|
model: model || undefined,
|
|
34
22
|
timeoutMs: ctx.config.timeoutMs,
|
package/dist/plugin.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"plugin.js","sourceRoot":"","sources":["../src/plugin.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"plugin.js","sourceRoot":"","sources":["../src/plugin.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;AACnD,OAAO,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;AAE3C,MAAM,CAAC,MAAM,MAAM,GAAW;IAC5B,IAAI,EAAE,uBAAuB;IAC7B,OAAO,EAAE,OAAO;IAChB,YAAY;IACZ,QAAQ,CAAC,QAAQ,EAAE,GAAG;QACpB,MAAM,KAAK,GAAG,GAAG,CAAC,MAAM,CAAC,MAAkB,CAAC;QAE5C,uEAAuE;QACvE,yEAAyE;QACzE,0EAA0E;QAC1E,eAAe,CAAC,QAAQ,EAAE;YACxB,OAAO,EAAE,QAAQ;YACjB,gEAAgE;YAChE,mEAAmE;YACnE,oEAAoE;YACpE,gBAAgB,EAAE,IAAI;YACtB,MAAM,EAAE,KAAK,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAE,GAAG,CAAC,MAAM,CAAC,KAAgB,IAAI,EAAE,CAAC;YACvE,IAAI,EAAE,CAAC,KAAK,EAAE,EAAE,CACd,IAAI,aAAa,CAAC,GAAG,CAAC,MAAM,EAAE;gBAC5B,KAAK,EAAE,KAAK,IAAI,SAAS;gBACzB,SAAS,EAAE,GAAG,CAAC,MAAM,CAAC,SAAmB;aAC1C,CAAC;SACL,CAAC,CAAC;IACL,CAAC;CACF,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@amykit/plugin-claude",
|
|
3
|
-
"version": "0.
|
|
4
|
-
"description": "The claude CLI as the agent,
|
|
3
|
+
"version": "0.6.0",
|
|
4
|
+
"description": "The claude CLI as the agent, over its JSON envelope.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"author": "Nicolas Melo",
|
|
@@ -28,9 +28,9 @@
|
|
|
28
28
|
"dist"
|
|
29
29
|
],
|
|
30
30
|
"dependencies": {
|
|
31
|
-
"@amykit/agent-kit": "^0.
|
|
32
|
-
"@amykit/core": "^0.
|
|
33
|
-
"@amykit/model-specs": "^0.
|
|
31
|
+
"@amykit/agent-kit": "^0.6.0",
|
|
32
|
+
"@amykit/core": "^0.6.0",
|
|
33
|
+
"@amykit/model-specs": "^0.6.0"
|
|
34
34
|
},
|
|
35
35
|
"devDependencies": {
|
|
36
36
|
"@amykit/test-fixtures": "^0.1.0"
|