@vibest/cli 0.0.1-beta.11 → 0.0.1-beta.13
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/harnesses/claude/.claude-plugin/plugin.json +1 -1
- package/harnesses/claude/skills/delegate/SKILL.md +5 -5
- package/harnesses/claude/skills/pipeline/SKILL.md +7 -8
- package/harnesses/cursor/.cursor-plugin/plugin.json +1 -1
- package/harnesses/cursor/hooks/vibest.sh +1 -1
- package/harnesses/cursor/skills/delegate/SKILL.md +5 -5
- package/harnesses/cursor/skills/pipeline/SKILL.md +7 -8
- package/harnesses/pi/extension.mjs +7 -78
- package/harnesses/pi/skills/delegate/SKILL.md +5 -5
- package/harnesses/pi/skills/pipeline/SKILL.md +7 -8
- package/package.json +11 -11
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: delegate
|
|
3
|
-
description: Hand work to subagents with `vibest run` and keep talking with the user while they work. Only vibest's main
|
|
3
|
+
description: Hand work to subagents with `vibest run` and keep talking with the user while they work. Only vibest's main agent (the coordinator) starts agents; a subagent must not use this skill. Use for any request to change, fix, build, investigate, research, test or verify code ("fix this bug", "add X", "look into why Y", "do these three things", "have an agent check it"), and whenever a task splits into independent parts that can run at the same time.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Delegate
|
|
@@ -12,19 +12,19 @@ You direct subagents. You stay with the user. Each result arrives in your inbox
|
|
|
12
12
|
Split independent pieces. Research and review run in parallel. One writing subagent per set of files. A few shell reads (`git diff`, `rg`) you do yourself.
|
|
13
13
|
|
|
14
14
|
```
|
|
15
|
-
vibest run <harness> --
|
|
15
|
+
vibest run <harness> -- '<self-contained task>'
|
|
16
16
|
```
|
|
17
17
|
|
|
18
18
|
Its id is <id>.
|
|
19
19
|
|
|
20
20
|
```
|
|
21
|
-
vibest run <harness> --
|
|
21
|
+
vibest run <harness> --archive-on-completion -- '<task>'
|
|
22
22
|
```
|
|
23
23
|
|
|
24
24
|
`--archive-on-completion` is only for a session you will not message again after it completes. It archives once the session reports completed and that result has reached you. The branch is kept. Do not `vibest send` it after that. A `needs_input` or `failed` result has not archived it: send the answer to the id it printed; the flag still archives the completed result that follows. A reviewer that gets later rounds is the pipeline skill and must stay open, without this flag.
|
|
25
25
|
|
|
26
26
|
- `<harness>` is `pi`, `claude` or `cursor` (`auto` only when a spawn plugin chooses).
|
|
27
|
-
-
|
|
27
|
+
- Each session gets its own new worktree.
|
|
28
28
|
- Several `vibest run` commands in one message start in parallel.
|
|
29
29
|
- A subagent cannot see this conversation. Say what to achieve, where (paths, lines), what done means, and how to verify it. For code: run the tests and typecheck, commit, and report the branch and hash.
|
|
30
30
|
- Long material: `vibest project write scratch <name>.md --if-version new -- '<text>'`. The absolute path is `scratchPath` from `vibest project info`, plus the file name. If write says the file already exists, `vibest project read scratch <name>.md`, then write again with the version it prints, or pick a new file name.
|
|
@@ -36,7 +36,7 @@ Tell the user in one or two lines what is running, then end your turn. Never gue
|
|
|
36
36
|
|
|
37
37
|
## Check the result
|
|
38
38
|
|
|
39
|
-
An `<agent-result>` is a claim. For a session
|
|
39
|
+
An `<agent-result>` is a claim. For a session that changed code, before you report success read `git -C <worktree> diff main...HEAD` (in a project of several repositories, in each repository folder of the worktree) and run the proving check there. For research, judge the report text.
|
|
40
40
|
|
|
41
41
|
- `status: needs_input` → `vibest send <id> -- '<the answer>'`, or ask the user. If it is waiting for the user's approval of an action, do not send the approval back: start a fresh agent with the approved action, quoting the user's words.
|
|
42
42
|
- `status: failed`, or your check fails → `vibest send <id> -- '<the failure and what to fix>'`. It keeps its context. If a second correction fails, start a new `vibest run` or tell the user.
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: pipeline
|
|
3
|
-
description: Plan, implement, review, then open a pull request, with the user approving the plan first. Only vibest's main
|
|
3
|
+
description: Plan, implement, review, then open a pull request, with the user approving the plan first. Only vibest's main agent (the coordinator) starts agents; a subagent must not use this skill. Use when the user wants a plan or design before code, a review before merging, or a pull request at the end ("plan it first, then build it", "write a design, then implement", "implement it and have someone review it", "先出方案再写,写完找人 review 后提 PR", "do it as a pipeline", "/pipeline").
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Pipeline
|
|
7
7
|
|
|
8
|
-
Plan
|
|
8
|
+
Plan → the user agrees → implement → review until the reviewer approves → pull request. Follow delegate: do not poll; each result arrives by itself; check it yourself. The user stays in the loop and may step into any pane. What they say overrides the next step.
|
|
9
9
|
|
|
10
10
|
## 1. Plan
|
|
11
11
|
|
|
12
12
|
```
|
|
13
|
-
vibest run <harness> --
|
|
13
|
+
vibest run <harness> -- 'Write an implementation plan for: <goal, paths, constraints>. Read the code. Report the approach, the files to change, the steps, how to verify, and open questions. Do not modify files.'
|
|
14
14
|
```
|
|
15
15
|
|
|
16
|
-
Its id is <planner id>. Tell the user the plan is being written and end your turn.
|
|
16
|
+
Its id is <planner id>. Tell the user the plan is being written and end your turn. Do not pass `--archive-on-completion`: the user has not agreed yet, and a completed result would archive the session before they can answer.
|
|
17
17
|
|
|
18
18
|
## 2. Agree
|
|
19
19
|
|
|
@@ -23,16 +23,15 @@ Show the plan in full, including open questions. Do not implement until the user
|
|
|
23
23
|
|
|
24
24
|
```
|
|
25
25
|
vibest project write scratch pipeline-<topic>-plan.md --if-version new -- '<the agreed plan, verbatim>'
|
|
26
|
-
vibest run <harness> --
|
|
26
|
+
vibest run <harness> -- 'Implement the plan at <absolute scratch path> exactly. Run the tests and typecheck, commit on a branch, push, and report the branch and hash. Do not open a pull request.'
|
|
27
27
|
```
|
|
28
28
|
|
|
29
|
-
Its id is <implementer id>. The absolute path is `scratchPath` from `vibest project info`, plus the file name. If write says the file already exists, `vibest project read scratch pipeline-<topic>-plan.md`, then write again with the version it prints, or pick a new file name. Do not pass `--archive-on-completion`: this session stays for review and the pull request. When it reports, check the diff and the tests yourself before review.
|
|
29
|
+
Its id is <implementer id>. The absolute path is `scratchPath` from `vibest project info`, plus the file name. If write says the file already exists, `vibest project read scratch pipeline-<topic>-plan.md`, then write again with the version it prints, or pick a new file name. Do not pass `--archive-on-completion`: this session stays for review and the pull request. When it reports, check the diff and the tests yourself before review.
|
|
30
30
|
|
|
31
31
|
## 4. Review
|
|
32
32
|
|
|
33
33
|
`--peer` shares the implementer's worktree: a pane split off the implementer's pane. Archiving the reviewer never removes that worktree.
|
|
34
|
-
|
|
35
|
-
Read-only here is the prompt you pass, plus the peer git rule the session already has: no commit, and nothing that moves HEAD, a branch, or the index. The session is not started with `VIBEST_ACCESS=read`, so the harness is not in its read-only tool mode.
|
|
34
|
+
Read-only here is the prompt you pass, plus the peer git rule the session already has: no commit, and nothing that moves HEAD, a branch, or the index.
|
|
36
35
|
|
|
37
36
|
```
|
|
38
37
|
vibest run <harness> --peer <implementer id> -- 'Review the change on this branch against the plan at <absolute scratch path>. Run git diff main...HEAD. Do not modify files, commit, or move HEAD. Look for bugs, missing tests, and departures from the plan; run the tests. Start with "verdict: approve" or "verdict: changes requested", then each comment with file and line.'
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/bin/sh
|
|
2
|
-
# @vibest/cursor 0.0.1-beta.
|
|
2
|
+
# @vibest/cursor 0.0.1-beta.13: `vibest integration guard` before a tool call, `vibest integration prompt` when the user submits, `vibest integration stop` at a turn end.
|
|
3
3
|
case "${1:-}" in
|
|
4
4
|
guard)
|
|
5
5
|
# preToolUse runs fail-closed, where no answer refuses: outside vibest, allow (it grants no approval).
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: delegate
|
|
3
|
-
description: Hand work to subagents with `vibest run` and keep talking with the user while they work. Only vibest's main
|
|
3
|
+
description: Hand work to subagents with `vibest run` and keep talking with the user while they work. Only vibest's main agent (the coordinator) starts agents; a subagent must not use this skill. Use for any request to change, fix, build, investigate, research, test or verify code ("fix this bug", "add X", "look into why Y", "do these three things", "have an agent check it"), and whenever a task splits into independent parts that can run at the same time.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Delegate
|
|
@@ -12,19 +12,19 @@ You direct subagents. You stay with the user. Each result arrives in your inbox
|
|
|
12
12
|
Split independent pieces. Research and review run in parallel. One writing subagent per set of files. A few shell reads (`git diff`, `rg`) you do yourself.
|
|
13
13
|
|
|
14
14
|
```
|
|
15
|
-
vibest run <harness> --
|
|
15
|
+
vibest run <harness> -- '<self-contained task>'
|
|
16
16
|
```
|
|
17
17
|
|
|
18
18
|
Its id is <id>.
|
|
19
19
|
|
|
20
20
|
```
|
|
21
|
-
vibest run <harness> --
|
|
21
|
+
vibest run <harness> --archive-on-completion -- '<task>'
|
|
22
22
|
```
|
|
23
23
|
|
|
24
24
|
`--archive-on-completion` is only for a session you will not message again after it completes. It archives once the session reports completed and that result has reached you. The branch is kept. Do not `vibest send` it after that. A `needs_input` or `failed` result has not archived it: send the answer to the id it printed; the flag still archives the completed result that follows. A reviewer that gets later rounds is the pipeline skill and must stay open, without this flag.
|
|
25
25
|
|
|
26
26
|
- `<harness>` is `pi`, `claude` or `cursor` (`auto` only when a spawn plugin chooses).
|
|
27
|
-
-
|
|
27
|
+
- Each session gets its own new worktree.
|
|
28
28
|
- Several `vibest run` commands in one message start in parallel.
|
|
29
29
|
- A subagent cannot see this conversation. Say what to achieve, where (paths, lines), what done means, and how to verify it. For code: run the tests and typecheck, commit, and report the branch and hash.
|
|
30
30
|
- Long material: `vibest project write scratch <name>.md --if-version new -- '<text>'`. The absolute path is `scratchPath` from `vibest project info`, plus the file name. If write says the file already exists, `vibest project read scratch <name>.md`, then write again with the version it prints, or pick a new file name.
|
|
@@ -36,7 +36,7 @@ Tell the user in one or two lines what is running, then end your turn. Never gue
|
|
|
36
36
|
|
|
37
37
|
## Check the result
|
|
38
38
|
|
|
39
|
-
An `<agent-result>` is a claim. For a session
|
|
39
|
+
An `<agent-result>` is a claim. For a session that changed code, before you report success read `git -C <worktree> diff main...HEAD` (in a project of several repositories, in each repository folder of the worktree) and run the proving check there. For research, judge the report text.
|
|
40
40
|
|
|
41
41
|
- `status: needs_input` → `vibest send <id> -- '<the answer>'`, or ask the user. If it is waiting for the user's approval of an action, do not send the approval back: start a fresh agent with the approved action, quoting the user's words.
|
|
42
42
|
- `status: failed`, or your check fails → `vibest send <id> -- '<the failure and what to fix>'`. It keeps its context. If a second correction fails, start a new `vibest run` or tell the user.
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: pipeline
|
|
3
|
-
description: Plan, implement, review, then open a pull request, with the user approving the plan first. Only vibest's main
|
|
3
|
+
description: Plan, implement, review, then open a pull request, with the user approving the plan first. Only vibest's main agent (the coordinator) starts agents; a subagent must not use this skill. Use when the user wants a plan or design before code, a review before merging, or a pull request at the end ("plan it first, then build it", "write a design, then implement", "implement it and have someone review it", "先出方案再写,写完找人 review 后提 PR", "do it as a pipeline", "/pipeline").
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Pipeline
|
|
7
7
|
|
|
8
|
-
Plan
|
|
8
|
+
Plan → the user agrees → implement → review until the reviewer approves → pull request. Follow delegate: do not poll; each result arrives by itself; check it yourself. The user stays in the loop and may step into any pane. What they say overrides the next step.
|
|
9
9
|
|
|
10
10
|
## 1. Plan
|
|
11
11
|
|
|
12
12
|
```
|
|
13
|
-
vibest run <harness> --
|
|
13
|
+
vibest run <harness> -- 'Write an implementation plan for: <goal, paths, constraints>. Read the code. Report the approach, the files to change, the steps, how to verify, and open questions. Do not modify files.'
|
|
14
14
|
```
|
|
15
15
|
|
|
16
|
-
Its id is <planner id>. Tell the user the plan is being written and end your turn.
|
|
16
|
+
Its id is <planner id>. Tell the user the plan is being written and end your turn. Do not pass `--archive-on-completion`: the user has not agreed yet, and a completed result would archive the session before they can answer.
|
|
17
17
|
|
|
18
18
|
## 2. Agree
|
|
19
19
|
|
|
@@ -23,16 +23,15 @@ Show the plan in full, including open questions. Do not implement until the user
|
|
|
23
23
|
|
|
24
24
|
```
|
|
25
25
|
vibest project write scratch pipeline-<topic>-plan.md --if-version new -- '<the agreed plan, verbatim>'
|
|
26
|
-
vibest run <harness> --
|
|
26
|
+
vibest run <harness> -- 'Implement the plan at <absolute scratch path> exactly. Run the tests and typecheck, commit on a branch, push, and report the branch and hash. Do not open a pull request.'
|
|
27
27
|
```
|
|
28
28
|
|
|
29
|
-
Its id is <implementer id>. The absolute path is `scratchPath` from `vibest project info`, plus the file name. If write says the file already exists, `vibest project read scratch pipeline-<topic>-plan.md`, then write again with the version it prints, or pick a new file name. Do not pass `--archive-on-completion`: this session stays for review and the pull request. When it reports, check the diff and the tests yourself before review.
|
|
29
|
+
Its id is <implementer id>. The absolute path is `scratchPath` from `vibest project info`, plus the file name. If write says the file already exists, `vibest project read scratch pipeline-<topic>-plan.md`, then write again with the version it prints, or pick a new file name. Do not pass `--archive-on-completion`: this session stays for review and the pull request. When it reports, check the diff and the tests yourself before review.
|
|
30
30
|
|
|
31
31
|
## 4. Review
|
|
32
32
|
|
|
33
33
|
`--peer` shares the implementer's worktree: a pane split off the implementer's pane. Archiving the reviewer never removes that worktree.
|
|
34
|
-
|
|
35
|
-
Read-only here is the prompt you pass, plus the peer git rule the session already has: no commit, and nothing that moves HEAD, a branch, or the index. The session is not started with `VIBEST_ACCESS=read`, so the harness is not in its read-only tool mode.
|
|
34
|
+
Read-only here is the prompt you pass, plus the peer git rule the session already has: no commit, and nothing that moves HEAD, a branch, or the index.
|
|
36
35
|
|
|
37
36
|
```
|
|
38
37
|
vibest run <harness> --peer <implementer id> -- 'Review the change on this branch against the plan at <absolute scratch path>. Run git diff main...HEAD. Do not modify files, commit, or move HEAD. Look for bugs, missing tests, and departures from the plan; run the tests. Start with "verdict: approve" or "verdict: changes requested", then each comment with file and line.'
|
|
@@ -15903,7 +15903,6 @@ var init_layout = __esm(() => {
|
|
|
15903
15903
|
database: path.join(home, "vibest.db"),
|
|
15904
15904
|
socket: path.join(home, "vibest.sock"),
|
|
15905
15905
|
daemonInfo: path.join(home, "vibestd.pid"),
|
|
15906
|
-
daemonLock: path.join(home, "vibestd.lock"),
|
|
15907
15906
|
results: path.join(home, "results"),
|
|
15908
15907
|
reports: path.join(home, "reports"),
|
|
15909
15908
|
worktrees: path.join(home, "worktrees"),
|
|
@@ -16085,7 +16084,8 @@ var init_harness = __esm(() => {
|
|
|
16085
16084
|
const spawner = yield* ChildProcessSpawner;
|
|
16086
16085
|
const harnesses = yield* Harnesses;
|
|
16087
16086
|
const self = yield* VibestCommand;
|
|
16088
|
-
const
|
|
16087
|
+
const pkg = self.length === 1 && path.isAbsolute(self[0]) ? path.dirname(path.dirname(self[0])) : undefined;
|
|
16088
|
+
const beside = pkg === undefined ? undefined : yield* findFirst2([path.join(pkg, "harnesses"), path.join(pkg, "..", "cli", "harnesses"), path.join(pkg, "..", "..", "..", "harnesses")], (dir) => fs.exists(dir).pipe(orElseSucceed2(() => false))).pipe(map7((found) => getOrElse(found, () => path.join(pkg, "harnesses"))));
|
|
16089
16089
|
const plugins = getOrUndefined(yield* option3(String7("VIBEST_HARNESSES"))) || beside;
|
|
16090
16090
|
const searchPath = (yield* String7("PATH").pipe(withDefault3(""))).split(":").filter(Boolean);
|
|
16091
16091
|
const { listModels } = yield* promise2(() => Promise.resolve().then(() => (init_models(), exports_models)));
|
|
@@ -19358,7 +19358,7 @@ init_session();
|
|
|
19358
19358
|
// ../../protocol/package.json
|
|
19359
19359
|
var package_default = {
|
|
19360
19360
|
name: "@vibest/protocol",
|
|
19361
|
-
version: "0.0.1-beta.
|
|
19361
|
+
version: "0.0.1-beta.13",
|
|
19362
19362
|
private: true,
|
|
19363
19363
|
type: "module",
|
|
19364
19364
|
license: "MIT",
|
|
@@ -19511,8 +19511,7 @@ class VibestRpcs extends make31(make29("Ping", { success: PingResult }), scoped4
|
|
|
19511
19511
|
agent: optional2(String6),
|
|
19512
19512
|
machine: optional2(RuntimeMachine),
|
|
19513
19513
|
peer: optional2(String6),
|
|
19514
|
-
archive: optional2(Boolean3)
|
|
19515
|
-
access: optional2(Literals(["read", "write"]))
|
|
19514
|
+
archive: optional2(Boolean3)
|
|
19516
19515
|
},
|
|
19517
19516
|
success: Struct({
|
|
19518
19517
|
id: String6,
|
|
@@ -19954,63 +19953,6 @@ var HERDR_CONTROL = new Set(["agent", "pane", "tab", "workspace", "worktree", "s
|
|
|
19954
19953
|
var HARNESS_CLIS = new Set(["pi", "claude", "cursor-agent"]);
|
|
19955
19954
|
var GH_UNSAFE = new Set(["alias", "extension", "ext", "config", "auth"]);
|
|
19956
19955
|
var firstWord = (words) => words.find((w) => !w.startsWith("-")) ?? "";
|
|
19957
|
-
var WRITE_BIN = new Set(["rm", "rmdir", "mv", "cp", "tee", "touch", "mkdir", "truncate", "dd", "ln", "unlink", "install"]);
|
|
19958
|
-
var GIT_WRITE = new Set(["add", "commit", "push", "merge", "rebase", "reset", "checkout", "switch", "restore", "clean", "worktree", "pull", "cherry-pick", "revert", "am", "apply", "stash", "init", "mv", "rm"]);
|
|
19959
|
-
var gitSubcommand = (argv) => {
|
|
19960
|
-
for (let i = 1;i < argv.length; i++) {
|
|
19961
|
-
const word = argv[i];
|
|
19962
|
-
if (word === "-c" || word === "-C") {
|
|
19963
|
-
i++;
|
|
19964
|
-
continue;
|
|
19965
|
-
}
|
|
19966
|
-
if (!word.startsWith("-"))
|
|
19967
|
-
return word;
|
|
19968
|
-
}
|
|
19969
|
-
return "";
|
|
19970
|
-
};
|
|
19971
|
-
var writesByRedirect = (command) => {
|
|
19972
|
-
let quote;
|
|
19973
|
-
for (let i = 0;i < command.length; i++) {
|
|
19974
|
-
const c = command[i];
|
|
19975
|
-
if (quote === "'") {
|
|
19976
|
-
if (c === "'")
|
|
19977
|
-
quote = undefined;
|
|
19978
|
-
continue;
|
|
19979
|
-
}
|
|
19980
|
-
if (quote === '"') {
|
|
19981
|
-
if (c === '"')
|
|
19982
|
-
quote = undefined;
|
|
19983
|
-
else if (c === "\\")
|
|
19984
|
-
i++;
|
|
19985
|
-
continue;
|
|
19986
|
-
}
|
|
19987
|
-
if (c === "'" || c === '"') {
|
|
19988
|
-
quote = c;
|
|
19989
|
-
continue;
|
|
19990
|
-
}
|
|
19991
|
-
if (c === "\\") {
|
|
19992
|
-
i++;
|
|
19993
|
-
continue;
|
|
19994
|
-
}
|
|
19995
|
-
if (c === ">" && command[i + 1] !== "&")
|
|
19996
|
-
return true;
|
|
19997
|
-
}
|
|
19998
|
-
return false;
|
|
19999
|
-
};
|
|
20000
|
-
var writeLike = (command) => {
|
|
20001
|
-
if (writesByRedirect(command))
|
|
20002
|
-
return true;
|
|
20003
|
-
for (const p of programsOf(command)) {
|
|
20004
|
-
const name = base(p.argv[0] ?? "");
|
|
20005
|
-
if (WRITE_BIN.has(name))
|
|
20006
|
-
return true;
|
|
20007
|
-
if (name === "git" && GIT_WRITE.has(gitSubcommand(p.argv)))
|
|
20008
|
-
return true;
|
|
20009
|
-
if ((name === "sed" || name === "perl") && p.argv.slice(1).some((a) => a === "-i" || a.startsWith("-i") || a === "--in-place" || a.startsWith("--in-place=")))
|
|
20010
|
-
return true;
|
|
20011
|
-
}
|
|
20012
|
-
return false;
|
|
20013
|
-
};
|
|
20014
19956
|
var shellBlock = (command, vibest, coordinator) => {
|
|
20015
19957
|
for (const p of programsOf(command)) {
|
|
20016
19958
|
const [program = "", ...rest] = p.argv;
|
|
@@ -20074,8 +20016,7 @@ var coordinator = (call) => gen2(function* () {
|
|
|
20074
20016
|
return "The coordinator does not edit files; hand the change to a session.";
|
|
20075
20017
|
return;
|
|
20076
20018
|
});
|
|
20077
|
-
var OFF_LIMITS = "The
|
|
20078
|
-
var READ_ONLY = "This session is read-only; it does not edit files or run commands that write.";
|
|
20019
|
+
var OFF_LIMITS = "The project directory is off limits to sessions, except your scratchpad.";
|
|
20079
20020
|
var SHELL_WORDS = /[^\s'"`;|&()<>=,]+/g;
|
|
20080
20021
|
var SHELL_SEARCH = /(?:^|[\s;&|(])(?:rg|ag|ack|grep|egrep|find|fd|tree|du)\s/;
|
|
20081
20022
|
var session = fn2("Guard.session")(function* (call) {
|
|
@@ -20144,18 +20085,7 @@ var decodePreToolUse = decodeUnknownEffect2(fromJsonString2(Struct({
|
|
|
20144
20085
|
workspace_roots: optional2(ArraySchema(String6))
|
|
20145
20086
|
})));
|
|
20146
20087
|
var COORDINATOR = "coordinator";
|
|
20147
|
-
var
|
|
20148
|
-
const denied = yield* session(call);
|
|
20149
|
-
if (denied)
|
|
20150
|
-
return denied;
|
|
20151
|
-
if (fileWritingTool(call.tool))
|
|
20152
|
-
return READ_ONLY;
|
|
20153
|
-
const command = SHELL_TOOLS.has(call.tool.toLowerCase()) ? shellCommand(call.input) : undefined;
|
|
20154
|
-
if (command !== undefined && writeLike(command))
|
|
20155
|
-
return READ_ONLY;
|
|
20156
|
-
return;
|
|
20157
|
-
});
|
|
20158
|
-
var rulesOf = (agent, access = "write") => agent === COORDINATOR ? coordinator : access === "read" ? readSession : session;
|
|
20088
|
+
var rulesOf = (agent) => agent === COORDINATOR ? coordinator : session;
|
|
20159
20089
|
|
|
20160
20090
|
// ../../core/src/results.ts
|
|
20161
20091
|
init_dist();
|
|
@@ -21089,8 +21019,7 @@ var extension2 = unwrap(gen2(function* () {
|
|
|
21089
21019
|
const agent = getOrUndefined(yield* option3(String7("VIBEST_AGENT")));
|
|
21090
21020
|
if (!agent)
|
|
21091
21021
|
return empty4;
|
|
21092
|
-
const
|
|
21093
|
-
const guard = effectDiscard(guarded(rulesOf(agent, access === "read" ? "read" : "write")));
|
|
21022
|
+
const guard = effectDiscard(guarded(rulesOf(agent)));
|
|
21094
21023
|
if (agent === COORDINATOR)
|
|
21095
21024
|
return coordinator2.pipe(provideMerge(guard));
|
|
21096
21025
|
const sessionId = getOrUndefined(yield* option3(String7("VIBEST_SESSION_ID")));
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: delegate
|
|
3
|
-
description: Hand work to subagents with `vibest run` and keep talking with the user while they work. Only vibest's main
|
|
3
|
+
description: Hand work to subagents with `vibest run` and keep talking with the user while they work. Only vibest's main agent (the coordinator) starts agents; a subagent must not use this skill. Use for any request to change, fix, build, investigate, research, test or verify code ("fix this bug", "add X", "look into why Y", "do these three things", "have an agent check it"), and whenever a task splits into independent parts that can run at the same time.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Delegate
|
|
@@ -12,19 +12,19 @@ You direct subagents. You stay with the user. Each result arrives in your inbox
|
|
|
12
12
|
Split independent pieces. Research and review run in parallel. One writing subagent per set of files. A few shell reads (`git diff`, `rg`) you do yourself.
|
|
13
13
|
|
|
14
14
|
```
|
|
15
|
-
vibest run <harness> --
|
|
15
|
+
vibest run <harness> -- '<self-contained task>'
|
|
16
16
|
```
|
|
17
17
|
|
|
18
18
|
Its id is <id>.
|
|
19
19
|
|
|
20
20
|
```
|
|
21
|
-
vibest run <harness> --
|
|
21
|
+
vibest run <harness> --archive-on-completion -- '<task>'
|
|
22
22
|
```
|
|
23
23
|
|
|
24
24
|
`--archive-on-completion` is only for a session you will not message again after it completes. It archives once the session reports completed and that result has reached you. The branch is kept. Do not `vibest send` it after that. A `needs_input` or `failed` result has not archived it: send the answer to the id it printed; the flag still archives the completed result that follows. A reviewer that gets later rounds is the pipeline skill and must stay open, without this flag.
|
|
25
25
|
|
|
26
26
|
- `<harness>` is `pi`, `claude` or `cursor` (`auto` only when a spawn plugin chooses).
|
|
27
|
-
-
|
|
27
|
+
- Each session gets its own new worktree.
|
|
28
28
|
- Several `vibest run` commands in one message start in parallel.
|
|
29
29
|
- A subagent cannot see this conversation. Say what to achieve, where (paths, lines), what done means, and how to verify it. For code: run the tests and typecheck, commit, and report the branch and hash.
|
|
30
30
|
- Long material: `vibest project write scratch <name>.md --if-version new -- '<text>'`. The absolute path is `scratchPath` from `vibest project info`, plus the file name. If write says the file already exists, `vibest project read scratch <name>.md`, then write again with the version it prints, or pick a new file name.
|
|
@@ -36,7 +36,7 @@ Tell the user in one or two lines what is running, then end your turn. Never gue
|
|
|
36
36
|
|
|
37
37
|
## Check the result
|
|
38
38
|
|
|
39
|
-
An `<agent-result>` is a claim. For a session
|
|
39
|
+
An `<agent-result>` is a claim. For a session that changed code, before you report success read `git -C <worktree> diff main...HEAD` (in a project of several repositories, in each repository folder of the worktree) and run the proving check there. For research, judge the report text.
|
|
40
40
|
|
|
41
41
|
- `status: needs_input` → `vibest send <id> -- '<the answer>'`, or ask the user. If it is waiting for the user's approval of an action, do not send the approval back: start a fresh agent with the approved action, quoting the user's words.
|
|
42
42
|
- `status: failed`, or your check fails → `vibest send <id> -- '<the failure and what to fix>'`. It keeps its context. If a second correction fails, start a new `vibest run` or tell the user.
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: pipeline
|
|
3
|
-
description: Plan, implement, review, then open a pull request, with the user approving the plan first. Only vibest's main
|
|
3
|
+
description: Plan, implement, review, then open a pull request, with the user approving the plan first. Only vibest's main agent (the coordinator) starts agents; a subagent must not use this skill. Use when the user wants a plan or design before code, a review before merging, or a pull request at the end ("plan it first, then build it", "write a design, then implement", "implement it and have someone review it", "先出方案再写,写完找人 review 后提 PR", "do it as a pipeline", "/pipeline").
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Pipeline
|
|
7
7
|
|
|
8
|
-
Plan
|
|
8
|
+
Plan → the user agrees → implement → review until the reviewer approves → pull request. Follow delegate: do not poll; each result arrives by itself; check it yourself. The user stays in the loop and may step into any pane. What they say overrides the next step.
|
|
9
9
|
|
|
10
10
|
## 1. Plan
|
|
11
11
|
|
|
12
12
|
```
|
|
13
|
-
vibest run <harness> --
|
|
13
|
+
vibest run <harness> -- 'Write an implementation plan for: <goal, paths, constraints>. Read the code. Report the approach, the files to change, the steps, how to verify, and open questions. Do not modify files.'
|
|
14
14
|
```
|
|
15
15
|
|
|
16
|
-
Its id is <planner id>. Tell the user the plan is being written and end your turn.
|
|
16
|
+
Its id is <planner id>. Tell the user the plan is being written and end your turn. Do not pass `--archive-on-completion`: the user has not agreed yet, and a completed result would archive the session before they can answer.
|
|
17
17
|
|
|
18
18
|
## 2. Agree
|
|
19
19
|
|
|
@@ -23,16 +23,15 @@ Show the plan in full, including open questions. Do not implement until the user
|
|
|
23
23
|
|
|
24
24
|
```
|
|
25
25
|
vibest project write scratch pipeline-<topic>-plan.md --if-version new -- '<the agreed plan, verbatim>'
|
|
26
|
-
vibest run <harness> --
|
|
26
|
+
vibest run <harness> -- 'Implement the plan at <absolute scratch path> exactly. Run the tests and typecheck, commit on a branch, push, and report the branch and hash. Do not open a pull request.'
|
|
27
27
|
```
|
|
28
28
|
|
|
29
|
-
Its id is <implementer id>. The absolute path is `scratchPath` from `vibest project info`, plus the file name. If write says the file already exists, `vibest project read scratch pipeline-<topic>-plan.md`, then write again with the version it prints, or pick a new file name. Do not pass `--archive-on-completion`: this session stays for review and the pull request. When it reports, check the diff and the tests yourself before review.
|
|
29
|
+
Its id is <implementer id>. The absolute path is `scratchPath` from `vibest project info`, plus the file name. If write says the file already exists, `vibest project read scratch pipeline-<topic>-plan.md`, then write again with the version it prints, or pick a new file name. Do not pass `--archive-on-completion`: this session stays for review and the pull request. When it reports, check the diff and the tests yourself before review.
|
|
30
30
|
|
|
31
31
|
## 4. Review
|
|
32
32
|
|
|
33
33
|
`--peer` shares the implementer's worktree: a pane split off the implementer's pane. Archiving the reviewer never removes that worktree.
|
|
34
|
-
|
|
35
|
-
Read-only here is the prompt you pass, plus the peer git rule the session already has: no commit, and nothing that moves HEAD, a branch, or the index. The session is not started with `VIBEST_ACCESS=read`, so the harness is not in its read-only tool mode.
|
|
34
|
+
Read-only here is the prompt you pass, plus the peer git rule the session already has: no commit, and nothing that moves HEAD, a branch, or the index.
|
|
36
35
|
|
|
37
36
|
```
|
|
38
37
|
vibest run <harness> --peer <implementer id> -- 'Review the change on this branch against the plan at <absolute scratch path>. Run git diff main...HEAD. Do not modify files, commit, or move HEAD. Look for bugs, missing tests, and departures from the plan; run the tests. Start with "verdict: approve" or "verdict: changes requested", then each comment with file and line.'
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vibest/cli",
|
|
3
|
-
"version": "0.0.1-beta.
|
|
3
|
+
"version": "0.0.1-beta.13",
|
|
4
4
|
"description": "vibest: vibestd daemon and the vibest CLI. A coordinator directing sessions in herdr panes.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -24,19 +24,19 @@
|
|
|
24
24
|
"devDependencies": {
|
|
25
25
|
"@effect/platform-bun": "4.0.2",
|
|
26
26
|
"@effect/sql-sqlite-bun": "4.0.2",
|
|
27
|
-
"@vibest/client": "0.0.1-beta.
|
|
28
|
-
"@vibest/core": "0.0.1-beta.
|
|
29
|
-
"@vibest/plugin": "0.0.1-beta.
|
|
30
|
-
"@vibest/protocol": "0.0.1-beta.
|
|
31
|
-
"@vibest/runtime-herdr": "0.0.1-beta.
|
|
32
|
-
"@vibest/schema": "0.0.1-beta.
|
|
33
|
-
"@vibest/server": "0.0.1-beta.
|
|
27
|
+
"@vibest/client": "0.0.1-beta.13",
|
|
28
|
+
"@vibest/core": "0.0.1-beta.13",
|
|
29
|
+
"@vibest/plugin": "0.0.1-beta.13",
|
|
30
|
+
"@vibest/protocol": "0.0.1-beta.13",
|
|
31
|
+
"@vibest/runtime-herdr": "0.0.1-beta.13",
|
|
32
|
+
"@vibest/schema": "0.0.1-beta.13",
|
|
33
|
+
"@vibest/server": "0.0.1-beta.13",
|
|
34
34
|
"effect": "4.0.2",
|
|
35
|
-
"effect-herdr-sdk": "0.0.1-beta.
|
|
35
|
+
"effect-herdr-sdk": "0.0.1-beta.13"
|
|
36
36
|
},
|
|
37
37
|
"optionalDependencies": {
|
|
38
|
-
"@vibest/cli-darwin-arm64": "0.0.1-beta.
|
|
39
|
-
"@vibest/cli-linux-x64": "0.0.1-beta.
|
|
38
|
+
"@vibest/cli-darwin-arm64": "0.0.1-beta.13",
|
|
39
|
+
"@vibest/cli-linux-x64": "0.0.1-beta.13"
|
|
40
40
|
},
|
|
41
41
|
"imports": {
|
|
42
42
|
"#platform": {
|