patchwork-os 1.2.0-beta.1.canary.565 → 1.2.0-beta.1.canary.568
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 +85 -22
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -7,7 +7,9 @@
|
|
|
7
7
|
|
|
8
8
|
> **You don't have an automation problem. You have a decision problem.**
|
|
9
9
|
|
|
10
|
-
Every AI-agent horror story ends the same way: an action nobody stopped to question. Patchwork OS is the layer between the agent's impulse and the action — a local-first runtime where your AI can automate real work across your editor, GitHub, Slack, Gmail, and 45+ services, while **anything consequential
|
|
10
|
+
Every AI-agent horror story ends the same way: an action nobody stopped to question. Patchwork OS is the layer between the agent's impulse and the action — a local-first runtime where your AI can automate real work across your editor, GitHub, Slack, Gmail, and 45+ services, while **anything consequential can be made to stop and ask you first**.
|
|
11
|
+
|
|
12
|
+
**Who it's for:** developers and technical operators who already run agents against real systems — a repo that ships, an inbox that matters, a production service — and who want a record of what was allowed and why. It expects a terminal, a Node install, and comfort editing YAML.
|
|
11
13
|
|
|
12
14
|
Three ideas, one runtime:
|
|
13
15
|
|
|
@@ -17,50 +19,97 @@ Three ideas, one runtime:
|
|
|
17
19
|
|
|
18
20
|
- **Every decision leaves a receipt.** What was done, why it was allowed, and how it turned out — durable, replayable, explainable via `patchwork judgments`, the dashboard's traces page, and `patchwork gate explain`. When you approve something, you find out later whether you were right.
|
|
19
21
|
|
|
20
|
-
All of it runs on your machine: your model (Claude, GPT, Gemini, Grok, or local Ollama), your credentials, your logs. Nothing phones home unless you opt in to [anonymous analytics](#telemetry).
|
|
21
|
-
|
|
22
22
|

|
|
23
23
|
|
|
24
|
-
|
|
24
|
+
## Status: beta
|
|
25
|
+
|
|
26
|
+
Version `1.2.0-beta.x`. The decision layer, recipes, connectors and IDE bridge all work and are dogfooded daily, but interfaces still move between betas and some surfaces are rougher than others. Pin an exact version if you are building on it.
|
|
27
|
+
|
|
28
|
+
**The safety features are opt-in, not the default.** This matters more than any other line in this README:
|
|
29
|
+
|
|
30
|
+
| Feature | Default | Turn it on with |
|
|
31
|
+
|---|---|---|
|
|
32
|
+
| Approval queue | **off** (`approvalGate: "off"`) | `--approval-gate high` or `all` |
|
|
33
|
+
| Worker autonomy gate | **off** | `PATCHWORK_FLAG_WORKER_AUTONOMY=1` (needs `--driver subprocess`) |
|
|
34
|
+
| Kill switch | available always | `patchwork panic` |
|
|
35
|
+
| Telemetry | **off** | opt in explicitly ([details](#telemetry)) |
|
|
36
|
+
|
|
37
|
+
Install Patchwork and nothing is gated until you say so. A fresh install is an automation runtime, and it becomes a decision layer when you switch the gate on. Everything above about "stops and asks you first" describes what the gate does once enabled — not what happens out of the box.
|
|
38
|
+
|
|
39
|
+
## The loop
|
|
40
|
+
|
|
41
|
+
```
|
|
42
|
+
trigger → recipe/worker → reversible? → runs
|
|
43
|
+
→ risky, gate on → approval queue → your yes → receipt
|
|
44
|
+
→ risky, gate off → runs
|
|
45
|
+
→ forbidden by policy → refused (no approval unlocks it)
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
`patchwork panic` blocks every write-tier tool call across all running bridges, immediately. Reads keep working, and in-flight reasoning is not killed — it is a write block, not a full stop.
|
|
49
|
+
|
|
50
|
+
## Install
|
|
51
|
+
|
|
52
|
+
```bash
|
|
53
|
+
npm install -g patchwork-os@beta
|
|
54
|
+
patchwork-os init
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
`init` scaffolds `~/.patchwork`, seeds local-only recipes, and registers Patchwork's PreToolUse hook in `~/.claude/settings.json`. Restart Claude Code afterwards — it reads hooks at session start.
|
|
58
|
+
|
|
59
|
+
**Prereqs:** Node 22+. macOS, Linux, and native Windows (no WSL).
|
|
25
60
|
|
|
26
|
-
|
|
61
|
+
Two things worth knowing before you start:
|
|
62
|
+
|
|
63
|
+
- **Use a global install, not `npx`.** `npx` does not persist the binary, so the very next command in any guide will not be found.
|
|
64
|
+
- **The web dashboard is not in the npm package.** It's a Next.js app that needs its own build, so it ships with the repo:
|
|
65
|
+
```bash
|
|
66
|
+
git clone https://github.com/Oolab-labs/patchwork-os && cd patchwork-os/dashboard
|
|
67
|
+
npm install && npm run build && npm start # http://localhost:3200
|
|
68
|
+
```
|
|
69
|
+
Everything below works from the CLI without it. The dashboard is where approvals, traces and connector setup are pleasant rather than possible.
|
|
70
|
+
|
|
71
|
+
## First run: zero connectors
|
|
72
|
+
|
|
73
|
+
Prove the runtime works before wiring any service to it. `daily-status` touches only git and local files — no accounts, no network:
|
|
27
74
|
|
|
28
75
|
```bash
|
|
29
|
-
|
|
30
|
-
patchwork start # bridge + dashboard
|
|
76
|
+
patchwork recipe run daily-status
|
|
31
77
|
```
|
|
32
78
|
|
|
33
|
-
|
|
79
|
+
It reads your commits since yesterday plus `~/.patchwork/planned.md`, and writes a Markdown digest to `~/.patchwork/inbox/daily-status-<date>.md`. If that file exists, your install is sound.
|
|
34
80
|
|
|
35
|
-
|
|
81
|
+
Useful neighbours: `patchwork recipe list`, `patchwork status`, `patchwork recipe doctor <name>` when something misbehaves.
|
|
36
82
|
|
|
37
|
-
|
|
83
|
+
## Morning Brief: the connected workflow
|
|
38
84
|
|
|
39
85
|
```bash
|
|
40
|
-
patchwork init --with-connectors # seeds the connector-backed recipes
|
|
86
|
+
patchwork-os init --with-connectors # seeds the connector-backed recipes
|
|
41
87
|
patchwork connect gmail
|
|
42
88
|
patchwork connect google-calendar
|
|
89
|
+
patchwork connect github
|
|
90
|
+
patchwork connect linear
|
|
43
91
|
patchwork recipe run morning-brief
|
|
44
92
|
```
|
|
45
93
|
|
|
46
|
-
|
|
94
|
+
The recipe pulls unread mail, today's calendar, your open GitHub issues and PRs, Linear issues, and local git activity, then has a model summarise them into one Markdown brief in `~/.patchwork/inbox/`. Its email step is **triage** — it lists what needs an answer; it does not compose or send replies. Nothing leaves your machine except the API calls to the services you connected.
|
|
47
95
|
|
|
48
|
-
|
|
96
|
+
All four connectors are required as written — no step is guarded, so a missing one halts the run. Drop the steps you don't want, or start from `daily-status` and add sources one at a time.
|
|
49
97
|
|
|
50
|
-
|
|
98
|
+
Requires a working model driver (`--driver subprocess` with the Claude CLI on PATH, or an API key). `patchwork recipe preflight templates/recipes/morning-brief.yaml` lists exactly what a recipe needs before you run it.
|
|
51
99
|
|
|
52
|
-
|
|
100
|
+
## Two ways to run this
|
|
53
101
|
|
|
54
|
-
|
|
102
|
+
**As an automation runtime** — recipes, workers, connectors, the decision layer. Needs `~/.patchwork` and a model driver; an editor is optional.
|
|
55
103
|
|
|
56
|
-
```
|
|
57
|
-
|
|
58
|
-
[risky? → approval queue → your yes → receipt]
|
|
104
|
+
```bash
|
|
105
|
+
patchwork start # bridge + Claude + dashboard
|
|
59
106
|
```
|
|
60
107
|
|
|
61
|
-
|
|
108
|
+
`patchwork start` launches `claude --ide` alongside the bridge, so it expects the **Claude CLI on your PATH**. Use `patchwork start --no-dashboard`, or run the bridge alone with `patchwork --workspace .`, if you don't want that.
|
|
62
109
|
|
|
63
|
-
|
|
110
|
+
On a global npm install there is no `dashboard/` to start, so it logs a dashboard warning and carries on with bridge + Claude; pass `--no-dashboard` to silence it. From a repo clone it starts all three.
|
|
111
|
+
|
|
112
|
+
**As a standalone IDE bridge** — 180 MCP tools giving Claude Code eyes and hands in your editor: diagnostics, LSP navigation, refactoring with risk analysis, debugger, terminal, git/GitHub, file ops. No `~/.patchwork`, no recipes, no gate.
|
|
64
113
|
|
|
65
114
|
```bash
|
|
66
115
|
npm install -g patchwork-os
|
|
@@ -71,7 +120,17 @@ claude --ide # in another terminal
|
|
|
71
120
|
|
|
72
121
|
JetBrains via a companion plugin. Claude Desktop, Gemini CLI, Codex CLI, Grok Build, and claude.ai connect over stdio or HTTP. Use the bridge alone forever if that's all you need; the runtime is an optional layer on top.
|
|
73
122
|
|
|
74
|
-
`claude --ide` can't find an IDE? Set `CLAUDE_CODE_IDE_SKIP_VALID_CHECK=true` (`
|
|
123
|
+
`claude --ide` can't find an IDE? Set `CLAUDE_CODE_IDE_SKIP_VALID_CHECK=true` (`init` does this for you).
|
|
124
|
+
|
|
125
|
+
## What "local-first" does and doesn't mean
|
|
126
|
+
|
|
127
|
+
**On your machine:** the runtime, every recipe and worker, all credentials and connector tokens, the approval queue, and every log and decision receipt under `~/.patchwork/`. Nothing is uploaded, and no Patchwork-operated server sits in any path.
|
|
128
|
+
|
|
129
|
+
**Over the network, necessarily:** calls to whatever model you point it at (Anthropic, OpenAI, Google, xAI) and to every connector you authorise (Gmail, GitHub, Slack…). Prompts, and whatever context a step feeds them, go to that model provider. Choosing a local Ollama endpoint keeps inference on your machine too; connector calls still leave it, because that is what a connector is.
|
|
130
|
+
|
|
131
|
+
**Only if you opt in:** [anonymous analytics](#telemetry).
|
|
132
|
+
|
|
133
|
+
Other boundaries worth knowing: `runCommand` executes only allowlisted commands, `sendHttpRequest` blocks private and loopback ranges, and file tools refuse symlink escapes out of the workspace. Remote deployments must sit behind TLS with OAuth 2.0 — see [docs/remote-access.md](docs/remote-access.md).
|
|
75
134
|
|
|
76
135
|
## What's here
|
|
77
136
|
|
|
@@ -87,6 +146,10 @@ JetBrains via a companion plugin. Claude Desktop, Gemini CLI, Codex CLI, Grok Bu
|
|
|
87
146
|
|
|
88
147
|
- **Deployment** — your laptop · headless VPS with OAuth 2.0 ([guide](docs/remote-access.md)) · native Windows
|
|
89
148
|
|
|
149
|
+
Recipes are plain YAML: a trigger (cron, file save, git commit, test run, or any webhook — iPhone Shortcut, Stream Deck, Home Assistant) plus steps. Share them like dotfiles, install them from the marketplace, or let the dashboard generate one from a sentence.
|
|
150
|
+
|
|
151
|
+
Workers are recipes with an identity and a track record. A worker that triages failing CI starts by only proposing ("this looks like a real break — file an issue?"). Confirm its filings were real and it earns a longer leash — for that job only. It can be demoted in one bad day. You can cap any worker permanently with one line of YAML.
|
|
152
|
+
|
|
90
153
|
Why not Zapier / an MCP server / a hosted assistant? Honest tradeoffs: [documents/comparison.md](documents/comparison.md).
|
|
91
154
|
|
|
92
155
|
## Docs
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "patchwork-os",
|
|
3
|
-
"version": "1.2.0-beta.1.canary.
|
|
3
|
+
"version": "1.2.0-beta.1.canary.568",
|
|
4
4
|
"description": "Your personal AI runtime, local-first. Patchwork OS gives any AI model a consistent set of tools, YAML recipes, a delegation policy with approval queue, and a durable trace memory — all on your machine, all under your policy.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|