@scotthuang/agent-knock-knock 0.5.0 → 0.5.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/CHANGELOG.md +19 -0
- package/README.md +61 -30
- package/dist/src/cli.js +3 -2
- package/dist/src/cli.js.map +1 -1
- package/dist/src/openclaw-doctor.js +3 -1
- package/dist/src/openclaw-doctor.js.map +1 -1
- package/dist/src/openclaw-plugin-helpers.d.ts +2 -0
- package/dist/src/openclaw-plugin-helpers.js +27 -6
- package/dist/src/openclaw-plugin-helpers.js.map +1 -1
- package/dist/src/openclaw-plugin.js +12 -15
- package/dist/src/openclaw-plugin.js.map +1 -1
- package/dist/src/terminal-process-source.js +3 -2
- package/dist/src/terminal-process-source.js.map +1 -1
- package/docs/quickstart-tmux.md +73 -18
- package/openclaw.plugin.json +2 -1
- package/package.json +1 -1
package/docs/quickstart-tmux.md
CHANGED
|
@@ -1,47 +1,102 @@
|
|
|
1
1
|
# Agent Knock Knock in 5 Minutes
|
|
2
2
|
|
|
3
|
-
This is the canonical
|
|
3
|
+
This is the canonical ClawHub setup: OpenClaw and a human share one live Codex or Claude Code terminal without changing the coding agent's permission mode.
|
|
4
4
|
|
|
5
|
-
##
|
|
5
|
+
## Before you start
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
You need:
|
|
8
8
|
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
9
|
+
- A Node.js version supported by OpenClaw; Node.js 24 LTS is recommended
|
|
10
|
+
- OpenClaw `2026.6.5` or newer
|
|
11
|
+
- tmux
|
|
12
|
+
- An installed and authenticated `codex` or `claude` CLI
|
|
13
|
+
- OpenClaw, tmux, and the coding agent running as the same OS user
|
|
12
14
|
|
|
13
|
-
|
|
15
|
+
AKK reuses a coding agent that you start in tmux. It never installs, authenticates, or launches Codex or Claude Code for you.
|
|
14
16
|
|
|
15
|
-
##
|
|
17
|
+
## 1. Install AKK for one project
|
|
18
|
+
|
|
19
|
+
Run these commands from the project AKK may edit:
|
|
16
20
|
|
|
17
21
|
```bash
|
|
18
|
-
|
|
22
|
+
cd /absolute/path/to/project
|
|
23
|
+
openclaw plugins install clawhub:@scotthuang/agent-knock-knock
|
|
24
|
+
openclaw config set plugins.entries.agent-knock-knock.config.workspace "$(pwd -P)"
|
|
25
|
+
openclaw gateway restart
|
|
19
26
|
```
|
|
20
27
|
|
|
21
|
-
|
|
28
|
+
The physical path from `pwd -P` gives AKK one canonical workspace boundary. The ClawHub package includes the OpenClaw plugin, bundled AKK skill, and its package-local relay CLI.
|
|
22
29
|
|
|
23
|
-
##
|
|
30
|
+
## 2. Start the shared terminal
|
|
24
31
|
|
|
25
32
|
```bash
|
|
26
|
-
tmux new-session -s akk-work -c "$
|
|
33
|
+
tmux new-session -s akk-work -c "$(pwd -P)" codex
|
|
27
34
|
```
|
|
28
35
|
|
|
29
|
-
Use `claude` instead of `codex` to share a Claude Code terminal. Detach with `Ctrl-b`,
|
|
36
|
+
Use `claude` instead of `codex` to share a Claude Code terminal. Wait until the coding agent is authenticated and showing its idle prompt. Detach from tmux with `Ctrl-b`, followed by `d`.
|
|
30
37
|
|
|
31
|
-
AKK
|
|
38
|
+
AKK sends work only to a matching Codex or Claude Code pane that is already running and idle inside the configured workspace.
|
|
32
39
|
|
|
33
|
-
##
|
|
40
|
+
## 3. Run doctor
|
|
34
41
|
|
|
35
42
|
From any configured OpenClaw channel:
|
|
36
43
|
|
|
44
|
+
```text
|
|
45
|
+
/akk doctor
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
Success starts with:
|
|
49
|
+
|
|
50
|
+
```text
|
|
51
|
+
AKK doctor: ready
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
Doctor verifies the installed plugin and skill, canonical workspace, Gateway health, tmux, and at least one supported coding-agent CLI. It does not make a credentialed model call or require a live pane.
|
|
55
|
+
|
|
56
|
+
## 4. Send the first task
|
|
57
|
+
|
|
37
58
|
```text
|
|
38
59
|
/akk inspect this repository and summarize it
|
|
39
60
|
```
|
|
40
61
|
|
|
41
|
-
|
|
62
|
+
The bare task works when exactly one eligible idle coding-agent pane exists in the configured workspace. If more than one pane is eligible, AKK stops instead of guessing: run `/akk list`, then use `/akk <selector>: <message>`, for example:
|
|
63
|
+
|
|
64
|
+
```text
|
|
65
|
+
/akk @a1b2c3d4: inspect this repository and summarize it
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
Success returns a managed conversation and, when the task finishes, its result. The same tmux pane remains available for direct human control; reattach with `tmux attach -t akk-work`.
|
|
69
|
+
|
|
70
|
+
## Optional: Enable natural-language delegation
|
|
71
|
+
|
|
72
|
+
Direct `/akk ...` commands work without changing the OpenClaw tool policy. To let OpenClaw decide to use AKK from a natural-language request, grant the optional `agent-knock-knock` tools in the applicable policy.
|
|
73
|
+
|
|
74
|
+
If you use the default `coding` profile and do not already have `tools.allow`:
|
|
75
|
+
|
|
76
|
+
```json5
|
|
77
|
+
{
|
|
78
|
+
tools: {
|
|
79
|
+
profile: "coding",
|
|
80
|
+
alsoAllow: ["agent-knock-knock"]
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
```
|
|
84
|
+
|
|
85
|
+
If a restrictive `tools.allow` list already exists at that scope, add `"agent-knock-knock"` to that list instead. Do not configure `allow` and `alsoAllow` at the same scope.
|
|
86
|
+
|
|
87
|
+
Restart the Gateway after changing the tool policy.
|
|
88
|
+
|
|
89
|
+
## Alternative: Install from npm
|
|
90
|
+
|
|
91
|
+
Use this route only when you also want the standalone `agent-knock-knock` shell command:
|
|
92
|
+
|
|
93
|
+
```bash
|
|
94
|
+
npm install -g @scotthuang/agent-knock-knock
|
|
95
|
+
agent-knock-knock install-openclaw --workspace "$(pwd -P)" --verify
|
|
96
|
+
```
|
|
42
97
|
|
|
43
|
-
|
|
98
|
+
Do not run `install-openclaw` after a ClawHub install. The two commands are alternative installation paths.
|
|
44
99
|
|
|
45
100
|
## Permissions and monitoring
|
|
46
101
|
|
|
47
|
-
AKK keeps the coding agent's own permission settings. Trusted, exact `autoApprove` rules may approve a supported prompt; everything else remains manual.
|
|
102
|
+
AKK keeps the coding agent's own permission settings. Trusted, exact `autoApprove` rules may approve a supported prompt; everything else remains manual. If monitoring stalls while the same task is still live, inspect `/akk status only` and use `/akk renew only <minutes>` to resume monitoring without sending terminal input.
|
package/openclaw.plugin.json
CHANGED
|
@@ -64,7 +64,8 @@
|
|
|
64
64
|
},
|
|
65
65
|
"workspace": {
|
|
66
66
|
"type": "string",
|
|
67
|
-
"
|
|
67
|
+
"minLength": 1,
|
|
68
|
+
"description": "Absolute project directory matched against eligible coding-agent tmux panes. Configure this before using AKK; runtime operations fail closed when it is missing."
|
|
68
69
|
},
|
|
69
70
|
"storeDir": {
|
|
70
71
|
"type": "string",
|
package/package.json
CHANGED