cookbook-bridge 0.1.13 → 0.1.17
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 +9 -0
- package/approve-mcp.mjs +2 -1
- package/bridge.mjs +605 -93
- package/cloud-entry.mjs +127 -0
- package/codex-runner.mjs +28 -7
- package/config.example.json +4 -0
- package/connectors.mjs +46 -3
- package/cookbook.mjs +33 -5
- package/device.mjs +95 -13
- package/failures.mjs +179 -0
- package/hands.mjs +2 -1
- package/harden.mjs +68 -1
- package/openclaw-runner.mjs +1 -1
- package/package.json +8 -5
- package/plan.mjs +41 -0
- package/prompt.mjs +81 -0
- package/realtime.mjs +147 -0
- package/service.mjs +386 -0
- package/synthesis.mjs +70 -17
- package/thread-runner.mjs +44 -10
- package/trace.mjs +269 -0
- package/update.mjs +26 -8
package/README.md
CHANGED
|
@@ -2,6 +2,13 @@
|
|
|
2
2
|
|
|
3
3
|
## Changelog
|
|
4
4
|
|
|
5
|
+
**0.1.17** (2026-09-14)
|
|
6
|
+
- The instant lane. A chat turn with your own Claude used to take 38 s at the median in production (four model turns, a cold `claude` process per message, 187 tool schemas per call, whole messages only). Now: the persistent per-thread runner is on by default and stays warm for three hours (`runnerIdleMinutes`, pool capped by `maxRunners`); it streams token deltas (`--include-partial-messages`, verified to resume cleanly on claude 2.1.272); chat turns get an answer-first prompt instead of the autonomous task prompt; a claude agent with no token of its own is pinned to the CLI's Cookbook connection (`pinMcp`, from `~/.claude.json`) so one server loads instead of every server on the machine; and the agent's words go straight to the thread over a per-task Realtime topic the server hands out with the work (the database path still runs as the record). Measured on the real stack: pre-warmed root chat 2.9 s to first words after claim, warm reply 1.1 s, one model turn instead of four, 14K cached tokens per call instead of 250K.
|
|
7
|
+
- Every run logs its timing: `runner booted|warm|reused Ns after claim`, `first words Ns after claim`, and the total on the completion line.
|
|
8
|
+
|
|
9
|
+
**0.1.14** (2026-09-03)
|
|
10
|
+
- The AI-visibility probe rides the synthesis lane: a `probe` job asks one buyer prompt on your subscription, either with no tools (variant `model`) or with WebSearch only (variant `search`, passed as `--tools WebSearch --allowedTools WebSearch` because print mode refuses a tool nobody granted). Capped at 120s per prompt, logged as `probe: <group> #<n> (<variant>)`, never with the prompt text.
|
|
11
|
+
|
|
5
12
|
**0.1.13** (2026-09-02)
|
|
6
13
|
- Pre-flight: the moment a grant this Bridge hosts becomes active, it runs `env`, the doctor, `cli_versions` and the shape of its own config (tokens stripped) once, locally and read-only, and posts the result as a host-initiated `preflight` call, so the visiting agent starts with what the machine already knows. Remembered per grant in `bridge.state.json`; a failed post is retried once per process.
|
|
7
14
|
- One-click plans: a `plan` call carries `why` and an ordered list of steps. The Bridge recomputes the plan hash before running (a step added after the click is refused as `plan hash mismatch`), runs each step through the same authorization wall as a single call, with the plan's approval standing in for each write-class step's click, stops at the first failure, and reports every step with its duration. Plans cannot nest, cannot contain `preflight`, and run one at a time like every other call.
|
|
@@ -148,6 +155,8 @@ local files are behind.
|
|
|
148
155
|
|
|
149
156
|
## Agents (config.json)
|
|
150
157
|
|
|
158
|
+
Chat replies run on a persistent process per conversation (on by default). `runnerIdleMinutes` (180) is how long an idle one stays warm, `maxRunners` (8) how many live at once, and `pinMcp` (true) keeps Bridge runs to the Cookbook MCP server only. Set `"persistentThreads": false` to go back to one `claude -p` per message.
|
|
159
|
+
|
|
151
160
|
```json
|
|
152
161
|
"agents": [
|
|
153
162
|
{ "name": "Claude", "match": ["claude"], "enabled": true,
|
package/approve-mcp.mjs
CHANGED
|
@@ -86,7 +86,8 @@ const TOOL = {
|
|
|
86
86
|
// pure exports without a live stdin listener holding their process open.
|
|
87
87
|
// `import.meta.main` is undefined before Node 22.18 / 24.2; without the argv[1]
|
|
88
88
|
// fallback the relay never started on older Nodes and every ask-mode call was denied.
|
|
89
|
-
const IS_MAIN =
|
|
89
|
+
const IS_MAIN = (globalThis.__cookbookLauncher && !!process.argv[1] && path.resolve(process.argv[1]) === fileURLToPath(import.meta.url))
|
|
90
|
+
|| import.meta.main === true
|
|
90
91
|
|| (import.meta.main !== false && !!process.argv[1] && path.resolve(process.argv[1]) === fileURLToPath(import.meta.url));
|
|
91
92
|
let buf = "";
|
|
92
93
|
if (IS_MAIN) {
|