@bivy/bivy 0.0.0 → 0.1.0-staging.11
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/LICENSE +105 -0
- package/README.md +335 -5
- package/bin/acp-shim.mjs +298 -0
- package/bin/agent-manifest.json +277 -0
- package/bin/bivy.mjs +4215 -0
- package/bin/codex-app-server-shim.mjs +447 -0
- package/bin/patch-pi-dependencies.mjs +44 -0
- package/bin/port-picker.mjs +40 -0
- package/bin/prune-sessions.mjs +52 -0
- package/bin/sessions-list.mjs +27 -0
- package/bin/shim-path.mjs +126 -0
- package/bin/uninstall-paths.mjs +48 -0
- package/dist/approval.js +87 -0
- package/dist/attach.js +248 -0
- package/dist/auth.js +258 -0
- package/dist/bivy-login.js +180 -0
- package/dist/browser-open.js +50 -0
- package/dist/control-plane-tasks.js +236 -0
- package/dist/data-dir.js +25 -0
- package/dist/device-registry.js +201 -0
- package/dist/e2e.js +70 -0
- package/dist/ephemeral-exec.js +109 -0
- package/dist/exec.js +209 -0
- package/dist/git-auth.js +155 -0
- package/dist/github-app-auth.js +107 -0
- package/dist/github-app-connect.js +235 -0
- package/dist/github-app-manifest.js +82 -0
- package/dist/github-app-sync-cli.js +93 -0
- package/dist/github-app-vault.js +106 -0
- package/dist/github-apps.js +121 -0
- package/dist/github-connect-repo.js +74 -0
- package/dist/github-device-auth.js +109 -0
- package/dist/github-tasks.js +650 -0
- package/dist/guard.js +109 -0
- package/dist/harness/cache-evict.js +88 -0
- package/dist/harness/checkpoint.js +0 -0
- package/dist/harness/cow-clone.js +84 -0
- package/dist/harness/dep-cache.js +78 -0
- package/dist/harness/disk-admission.js +46 -0
- package/dist/harness/egress.js +30 -0
- package/dist/harness/manager.js +97 -0
- package/dist/harness/mcp-config-formats.js +164 -0
- package/dist/harness/mcp-config.js +111 -0
- package/dist/harness/mcp-inject.js +134 -0
- package/dist/harness/mcp-proxy-cli.js +88 -0
- package/dist/harness/mcp-proxy.js +150 -0
- package/dist/harness/net-proxy.js +120 -0
- package/dist/harness/sandbox.js +96 -0
- package/dist/history-sync.js +26 -0
- package/dist/hosted-endpoints.d.mts +14 -0
- package/dist/hosted-endpoints.mjs +35 -0
- package/dist/identity.js +153 -0
- package/dist/integrations/index.js +4 -0
- package/dist/integrations/manager.js +279 -0
- package/dist/integrations/oauth.js +78 -0
- package/dist/integrations/registry.js +239 -0
- package/dist/integrations/store.js +54 -0
- package/dist/integrations/types.js +1 -0
- package/dist/linear-tasks.js +49 -0
- package/dist/metadata.js +226 -0
- package/dist/multiplexer.js +79 -0
- package/dist/native-pi.js +38 -0
- package/dist/node-stats.js +237 -0
- package/dist/pairing-crypto.js +105 -0
- package/dist/policy/conditions.js +103 -0
- package/dist/policy/policy-engine.js +20 -0
- package/dist/policy/risk.js +18 -0
- package/dist/policy/ruleset.js +113 -0
- package/dist/policy/run-policy.js +108 -0
- package/dist/policy/session-reroute.js +96 -0
- package/dist/pty-runner.py +95 -0
- package/dist/question.js +146 -0
- package/dist/redact.js +97 -0
- package/dist/relay-attach.js +345 -0
- package/dist/relay-chunk.js +73 -0
- package/dist/relay-cli-crypto.js +70 -0
- package/dist/relay-client.js +372 -0
- package/dist/relay-setup.js +262 -0
- package/dist/repo-workspace.js +208 -0
- package/dist/runtime/adoption.js +45 -0
- package/dist/runtime/agent-service-bin.js +149 -0
- package/dist/runtime/agent-service.js +439 -0
- package/dist/runtime/ansi.js +27 -0
- package/dist/runtime/anthropic-preflight.js +80 -0
- package/dist/runtime/claude-code.js +1408 -0
- package/dist/runtime/cli-parsers.js +647 -0
- package/dist/runtime/codex-auth.js +168 -0
- package/dist/runtime/codex-preflight.js +60 -0
- package/dist/runtime/codex-sessions.js +279 -0
- package/dist/runtime/control-plane-location.js +74 -0
- package/dist/runtime/credential-ingest.js +122 -0
- package/dist/runtime/credential-provisioning.js +79 -0
- package/dist/runtime/credential-store.js +435 -0
- package/dist/runtime/credentials.js +153 -0
- package/dist/runtime/host.js +153 -0
- package/dist/runtime/index.js +1552 -0
- package/dist/runtime/local-model-store.js +194 -0
- package/dist/runtime/location-registry.js +28 -0
- package/dist/runtime/model-catalog.js +97 -0
- package/dist/runtime/model-namer.js +85 -0
- package/dist/runtime/native-process-scan.js +102 -0
- package/dist/runtime/native-session-discovery.js +103 -0
- package/dist/runtime/normalize.js +75 -0
- package/dist/runtime/oauth/model-oauth-providers.js +75 -0
- package/dist/runtime/oauth/model-oauth.js +324 -0
- package/dist/runtime/opencode-preflight.js +55 -0
- package/dist/runtime/pi-auth.js +82 -0
- package/dist/runtime/pi-oauth.js +52 -0
- package/dist/runtime/pi-session-discovery.js +42 -0
- package/dist/runtime/pi.js +539 -0
- package/dist/runtime/process.js +499 -0
- package/dist/runtime/protocol.js +646 -0
- package/dist/runtime/remote.js +541 -0
- package/dist/runtime/rpc-protocol.js +56 -0
- package/dist/runtime/ruleset-store.js +117 -0
- package/dist/runtime/session-location.js +50 -0
- package/dist/runtime/types.js +17 -0
- package/dist/secrets-cli.js +134 -0
- package/dist/secrets.js +264 -0
- package/dist/server.js +9435 -0
- package/dist/session/bivy-session.js +1 -0
- package/dist/session/checkpoint-pack.js +133 -0
- package/dist/session/event-log.js +340 -0
- package/dist/session/fork-dirty.js +73 -0
- package/dist/session/fork-prereqs.js +61 -0
- package/dist/session/fork.js +90 -0
- package/dist/session/native-import.js +56 -0
- package/dist/session/reconnect.js +168 -0
- package/dist/session/replication-service.js +236 -0
- package/dist/session/replication.js +106 -0
- package/dist/session/replicator.js +140 -0
- package/dist/session/session-new-dedupe.js +42 -0
- package/dist/session/sibling-client.js +201 -0
- package/dist/session/transcript-merge.js +131 -0
- package/dist/session/transcript-normal.js +195 -0
- package/dist/session/workspace-context.js +1 -0
- package/dist/session-event-coalescer.js +50 -0
- package/dist/session-identity.js +34 -0
- package/dist/session-ref.js +65 -0
- package/dist/stt-cli.js +131 -0
- package/dist/stt.js +168 -0
- package/dist/terminal.js +409 -0
- package/dist/wire-format.js +67 -0
- package/dist/worktree-provision.js +118 -0
- package/dist/worktree.js +117 -0
- package/package.json +40 -6
- package/public/qr.js +464 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
# Functional Source License, Version 1.1, ALv2 Future License
|
|
2
|
+
|
|
3
|
+
## Abbreviation
|
|
4
|
+
|
|
5
|
+
FSL-1.1-ALv2
|
|
6
|
+
|
|
7
|
+
## Notice
|
|
8
|
+
|
|
9
|
+
Copyright 2026 Petter André Sjulstad
|
|
10
|
+
|
|
11
|
+
## Terms and Conditions
|
|
12
|
+
|
|
13
|
+
### Licensor ("We")
|
|
14
|
+
|
|
15
|
+
The party offering the Software under these Terms and Conditions.
|
|
16
|
+
|
|
17
|
+
### The Software
|
|
18
|
+
|
|
19
|
+
The "Software" is each version of the software that we make available under
|
|
20
|
+
these Terms and Conditions, as indicated by our inclusion of these Terms and
|
|
21
|
+
Conditions with the Software.
|
|
22
|
+
|
|
23
|
+
### License Grant
|
|
24
|
+
|
|
25
|
+
Subject to your compliance with this License Grant and the Patents,
|
|
26
|
+
Redistribution and Trademark clauses below, we hereby grant you the right to
|
|
27
|
+
use, copy, modify, create derivative works, publicly perform, publicly display
|
|
28
|
+
and redistribute the Software for any Permitted Purpose identified below.
|
|
29
|
+
|
|
30
|
+
### Permitted Purpose
|
|
31
|
+
|
|
32
|
+
A Permitted Purpose is any purpose other than a Competing Use. A Competing Use
|
|
33
|
+
means making the Software available to others in a commercial product or
|
|
34
|
+
service that:
|
|
35
|
+
|
|
36
|
+
1. substitutes for the Software;
|
|
37
|
+
|
|
38
|
+
2. substitutes for any other product or service we offer using the Software
|
|
39
|
+
that exists as of the date we make the Software available; or
|
|
40
|
+
|
|
41
|
+
3. offers the same or substantially similar functionality as the Software.
|
|
42
|
+
|
|
43
|
+
Permitted Purposes specifically include using the Software:
|
|
44
|
+
|
|
45
|
+
1. for your internal use and access;
|
|
46
|
+
|
|
47
|
+
2. for non-commercial education;
|
|
48
|
+
|
|
49
|
+
3. for non-commercial research; and
|
|
50
|
+
|
|
51
|
+
4. in connection with professional services that you provide to a licensee
|
|
52
|
+
using the Software in accordance with these Terms and Conditions.
|
|
53
|
+
|
|
54
|
+
### Patents
|
|
55
|
+
|
|
56
|
+
To the extent your use for a Permitted Purpose would necessarily infringe our
|
|
57
|
+
patents, the license grant above includes a license under our patents. If you
|
|
58
|
+
make a claim against any party that the Software infringes or contributes to
|
|
59
|
+
the infringement of any patent, then your patent license to the Software ends
|
|
60
|
+
immediately.
|
|
61
|
+
|
|
62
|
+
### Redistribution
|
|
63
|
+
|
|
64
|
+
The Terms and Conditions apply to all copies, modifications and derivatives of
|
|
65
|
+
the Software.
|
|
66
|
+
|
|
67
|
+
If you redistribute any copies, modifications or derivatives of the Software,
|
|
68
|
+
you must include a copy of or a link to these Terms and Conditions and not
|
|
69
|
+
remove any copyright notices provided in or with the Software.
|
|
70
|
+
|
|
71
|
+
### Disclaimer
|
|
72
|
+
|
|
73
|
+
THE SOFTWARE IS PROVIDED "AS IS" AND WITHOUT WARRANTIES OF ANY KIND, EXPRESS OR
|
|
74
|
+
IMPLIED, INCLUDING WITHOUT LIMITATION WARRANTIES OF FITNESS FOR A PARTICULAR
|
|
75
|
+
PURPOSE, MERCHANTABILITY, TITLE OR NON-INFRINGEMENT.
|
|
76
|
+
|
|
77
|
+
IN NO EVENT WILL WE HAVE ANY LIABILITY TO YOU ARISING OUT OF OR RELATED TO THE
|
|
78
|
+
SOFTWARE, INCLUDING INDIRECT, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES,
|
|
79
|
+
EVEN IF WE HAVE BEEN INFORMED OF THEIR POSSIBILITY IN ADVANCE.
|
|
80
|
+
|
|
81
|
+
### Trademarks
|
|
82
|
+
|
|
83
|
+
Except for displaying the License Details and identifying us as the origin of
|
|
84
|
+
the Software, you have no right under these Terms and Conditions to use our
|
|
85
|
+
trademarks, trade names, service marks or product names.
|
|
86
|
+
|
|
87
|
+
## Grant of Future License
|
|
88
|
+
|
|
89
|
+
We hereby irrevocably grant you an additional license to use the Software under
|
|
90
|
+
the Apache License, Version 2.0 that is effective on the second anniversary of
|
|
91
|
+
the date we make the Software available. On or after that date, you may use the
|
|
92
|
+
Software under the Apache License, Version 2.0, in which case the following
|
|
93
|
+
will apply:
|
|
94
|
+
|
|
95
|
+
Licensed under the Apache License, Version 2.0 (the "License"); you may not use
|
|
96
|
+
this file except in compliance with the License.
|
|
97
|
+
|
|
98
|
+
You may obtain a copy of the License at
|
|
99
|
+
|
|
100
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
|
101
|
+
|
|
102
|
+
Unless required by applicable law or agreed to in writing, software distributed
|
|
103
|
+
under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
|
|
104
|
+
CONDITIONS OF ANY KIND, either express or implied. See the License for the
|
|
105
|
+
specific language governing permissions and limitations under the License.
|
package/README.md
CHANGED
|
@@ -1,8 +1,338 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Bivy
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Route coding-agent work to infrastructure you own.
|
|
4
4
|
|
|
5
|
-
|
|
6
|
-
|
|
5
|
+
Bivy turns GitHub issues, Slack requests, signed webhooks, schedules, and live
|
|
6
|
+
prompts into governed agent runs on your laptop, server, or cloud account. Choose
|
|
7
|
+
the node, agent, and model; burst onto a short-lived runner in your own cloud;
|
|
8
|
+
then watch, steer, and approve from a phone, browser, or terminal.
|
|
7
9
|
|
|
8
|
-
|
|
10
|
+
Agents run with your repository, keys, and toolchain. Bivy's relay and control
|
|
11
|
+
plane do not receive repository contents, prompts, transcripts, or model keys.
|
|
12
|
+
Bivy adds routing, durable sessions, approvals, fallback rules, and outcome
|
|
13
|
+
reports around agents you already use.
|
|
14
|
+
|
|
15
|
+
- **Website:** [bivy.sh](https://bivy.sh)
|
|
16
|
+
- **Documentation:** [`docs/`](docs/README.md) — start with the [quickstart](docs/quickstart.md)
|
|
17
|
+
- **License:** [FSL-1.1-ALv2](LICENSE) (source-available; converts to Apache-2.0 two years after each release)
|
|
18
|
+
|
|
19
|
+
> Bivy is 0.x software. The core loop is solid and used daily, but interfaces
|
|
20
|
+
> and behaviour can change between releases.
|
|
21
|
+
|
|
22
|
+
## Install
|
|
23
|
+
|
|
24
|
+
```bash
|
|
25
|
+
curl -fsSL https://bivy.sh/install.sh | bash
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
macOS and Linux. Requires Node.js 22.19 or newer; the installer installs it for
|
|
29
|
+
you on Debian/Ubuntu and otherwise points you at nodejs.org. It installs the
|
|
30
|
+
[`@bivy/bivy`](https://www.npmjs.com/package/@bivy/bivy) package from npm, puts
|
|
31
|
+
the `bivy` command on your `PATH`, then runs the guided `bivy setup` wizard —
|
|
32
|
+
workspace, relay/control-plane sign-in, and an auto-start background service
|
|
33
|
+
(launchd on macOS, systemd on Linux). Re-running it on a machine that already
|
|
34
|
+
has Bivy just applies the latest build and restarts the service.
|
|
35
|
+
|
|
36
|
+
Already have Node.js 22.19+? The installer is optional:
|
|
37
|
+
|
|
38
|
+
```bash
|
|
39
|
+
npm install -g @bivy/bivy
|
|
40
|
+
bivy setup
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
Or try it once without installing anything (`npx` always fetches the latest):
|
|
44
|
+
|
|
45
|
+
```bash
|
|
46
|
+
npx @bivy/bivy setup
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
Releases are published from CI with provenance attestations; verify a build's
|
|
50
|
+
origin with `npm audit signatures`. See [`docs/releasing.md`](docs/releasing.md).
|
|
51
|
+
|
|
52
|
+
### Install options
|
|
53
|
+
|
|
54
|
+
Environment variables passed to the one-line installer change what it does:
|
|
55
|
+
|
|
56
|
+
| Goal | Variable |
|
|
57
|
+
|---|---|
|
|
58
|
+
| Track the dev channel (new build on every merge to `main`) | `BIVY_CHANNEL=staging` |
|
|
59
|
+
| Pin an exact version | `BIVY_VERSION=0.1.0` |
|
|
60
|
+
| Install without sudo, into a user-owned prefix | `BIVY_NPM_PREFIX=~/.local` |
|
|
61
|
+
| Preinstall every bundled agent runtime | `BIVY_INSTALL_ALL_AGENTS=1` |
|
|
62
|
+
|
|
63
|
+
For example: `BIVY_CHANNEL=staging curl -fsSL https://bivy.sh/install.sh | bash`.
|
|
64
|
+
|
|
65
|
+
Working from a checkout of this repository instead:
|
|
66
|
+
|
|
67
|
+
```bash
|
|
68
|
+
npm install
|
|
69
|
+
npm run setup
|
|
70
|
+
```
|
|
71
|
+
|
|
72
|
+
See [`docs/install.md`](docs/install.md) for where data lives, service
|
|
73
|
+
management, and uninstall.
|
|
74
|
+
|
|
75
|
+
## Updating
|
|
76
|
+
|
|
77
|
+
```bash
|
|
78
|
+
bivy update
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
`bivy update` detects how Bivy was installed and does the right thing, then
|
|
82
|
+
waits for any active session to finish its current turn and restarts the
|
|
83
|
+
background service so the node reconnects on the new build:
|
|
84
|
+
|
|
85
|
+
| Install kind | What `bivy update` does |
|
|
86
|
+
|---|---|
|
|
87
|
+
| npm global (`npm i -g`) | `npm install -g @bivy/bivy@<channel>`, then restart the service |
|
|
88
|
+
| installer / packaged | re-runs `install.sh` (migrating to npm if needed), then restart |
|
|
89
|
+
| git checkout | `git pull --ff-only` + `npm ci`, then restart |
|
|
90
|
+
| `npx` run | nothing to update — each run already fetches the latest |
|
|
91
|
+
|
|
92
|
+
Updates follow the release **channel** recorded at install time — `latest`
|
|
93
|
+
(production) by default, or `staging` if you installed with
|
|
94
|
+
`BIVY_CHANNEL=staging`. Switch channels (the choice is remembered for next
|
|
95
|
+
time), or skip the wait for a busy session:
|
|
96
|
+
|
|
97
|
+
```bash
|
|
98
|
+
bivy update --staging # move to the dev channel
|
|
99
|
+
bivy update --stable # move back to production (latest)
|
|
100
|
+
bivy update --force # don't wait for an in-flight turn to finish
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
The daemon also checks the registry periodically and posts an in-session notice
|
|
104
|
+
when a newer build is available.
|
|
105
|
+
|
|
106
|
+
## Architecture
|
|
107
|
+
|
|
108
|
+
Bivy has three parts. Only the first one holds your data.
|
|
109
|
+
|
|
110
|
+
```text
|
|
111
|
+
your machine hosted or self-hosted
|
|
112
|
+
|
|
113
|
+
┌──────────────┐ ┌─────────┐ ┌───────────────┐
|
|
114
|
+
│ node daemon │ ──dials──▶ │ relay │ ◀────▶ │ control plane │
|
|
115
|
+
│ agents, keys │ outbound │ opaque │ │ accounts, web │
|
|
116
|
+
│ repo, tools │ │ frames │ │ app, metadata │
|
|
117
|
+
└──────────────┘ └─────────┘ └───────────────┘
|
|
118
|
+
▲ ▲
|
|
119
|
+
└────────── end-to-end encrypted session ───────────┘
|
|
120
|
+
phone · browser · another terminal
|
|
121
|
+
```
|
|
122
|
+
|
|
123
|
+
- **Node** — a daemon on your machine. Owns the workspace, credentials, and agent
|
|
124
|
+
processes. Serves an API and WebSocket on `http://localhost:4317` plus a
|
|
125
|
+
`/healthz` probe. **It hosts no web UI.**
|
|
126
|
+
- **Relay** — forwards encrypted frames between your node and your devices. Your
|
|
127
|
+
node dials out, so no inbound port is opened. The relay cannot read the frames.
|
|
128
|
+
- **Control plane** — holds your account, node registry, and session index, and
|
|
129
|
+
serves the web/PWA client. Use the hosted one or run your own.
|
|
130
|
+
|
|
131
|
+
Because the node serves no UI, a browser or phone needs a control plane — hosted
|
|
132
|
+
at `app.bivy.sh`, or one you deploy yourself. The terminal CLI needs neither.
|
|
133
|
+
|
|
134
|
+
See [`docs/remote-access.md`](docs/remote-access.md) and
|
|
135
|
+
[`docs/security-model.md`](docs/security-model.md).
|
|
136
|
+
|
|
137
|
+
## Supported agents
|
|
138
|
+
|
|
139
|
+
Nineteen agents are available in the picker, each driven through its native interface:
|
|
140
|
+
|
|
141
|
+
| Agent | Command | Notes |
|
|
142
|
+
|---|---|---|
|
|
143
|
+
| Pi | `bivy run pi` | Default; bundled |
|
|
144
|
+
| Claude Code | `bivy run claude` | Bundled SDK |
|
|
145
|
+
| Codex | `bivy run codex` | Installs `@openai/codex` |
|
|
146
|
+
| OpenCode | `bivy run opencode` | Installs `opencode-ai` |
|
|
147
|
+
| Gemini CLI | `bivy run gemini` | Installs `@google/gemini-cli` |
|
|
148
|
+
| Qwen Code | `bivy run qwen` | Installs `@qwen-code/qwen-code` |
|
|
149
|
+
| Goose | `bivy run goose` | Requires `goose` on PATH |
|
|
150
|
+
| Aider | `bivy run aider` | No session resume (upstream gap) |
|
|
151
|
+
| Cline | `bivy run cline` | Installs `cline` |
|
|
152
|
+
| Crush | `bivy run crush` | No session resume (upstream gap) |
|
|
153
|
+
| Cursor | `bivy run cursor` | ACP-capable |
|
|
154
|
+
| GitHub Copilot | `bivy run copilot` | ACP-capable |
|
|
155
|
+
| Grok | `bivy run grok` | Model selection |
|
|
156
|
+
| Amp | `bivy run amp` | Native thread resume |
|
|
157
|
+
| Auggie | `bivy run auggie` | Headless CLI |
|
|
158
|
+
| Droid | `bivy run droid` | Model selection |
|
|
159
|
+
| Continue | `bivy run continue` | Headless CLI |
|
|
160
|
+
| Kilo Code | `bivy run kilocode` | ACP-capable |
|
|
161
|
+
| Rovo Dev | `bivy run rovodev` | Installed out of band |
|
|
162
|
+
|
|
163
|
+
Any other command works via `bivy run -- ./your-agent --flags`. ACP-capable
|
|
164
|
+
agents can be promoted to Bivy's governed protocol path for per-tool approvals
|
|
165
|
+
and native resume.
|
|
166
|
+
|
|
167
|
+
[`docs/runtime-support-matrix.md`](docs/runtime-support-matrix.md) lists exactly
|
|
168
|
+
what each agent supports — resume, model selection, approvals, sandboxing.
|
|
169
|
+
|
|
170
|
+
## Common commands
|
|
171
|
+
|
|
172
|
+
```bash
|
|
173
|
+
bivy # launch the default agent as a durable session
|
|
174
|
+
bivy run claude # run a specific agent
|
|
175
|
+
bivy sessions # list live and saved sessions
|
|
176
|
+
bivy resume # resume the most recent session
|
|
177
|
+
bivy open # open the web app (requires relay setup)
|
|
178
|
+
bivy status # config summary and node reachability
|
|
179
|
+
bivy doctor # health check
|
|
180
|
+
bivy logs -f # tail node logs
|
|
181
|
+
bivy update # update Bivy and restart the service
|
|
182
|
+
```
|
|
183
|
+
|
|
184
|
+
Full command list, flags, and examples: [`docs/cli-reference.md`](docs/cli-reference.md).
|
|
185
|
+
|
|
186
|
+
## Configuration
|
|
187
|
+
|
|
188
|
+
The common knobs:
|
|
189
|
+
|
|
190
|
+
```bash
|
|
191
|
+
BIVY_WORKSPACE=/path/to/repo # default workspace
|
|
192
|
+
BIVY_SANDBOX=read-only # read-only | workspace-write (default) | danger-full-access
|
|
193
|
+
BIVY_APPROVAL_MODE=risky # never | risky | always | autonomous (default)
|
|
194
|
+
```
|
|
195
|
+
|
|
196
|
+
Every environment variable, config file, and precedence rule:
|
|
197
|
+
[`docs/configuration.md`](docs/configuration.md).
|
|
198
|
+
|
|
199
|
+
## Approvals and sandboxing
|
|
200
|
+
|
|
201
|
+
The default approval mode is **`autonomous`**: agents act without per-action
|
|
202
|
+
prompts. Safety comes from a floor that applies in *every* mode — catastrophic
|
|
203
|
+
commands and writes outside the workspace are refused outright, and a backstop
|
|
204
|
+
set (force-push, publish, deploy, sudo) always pauses for a human.
|
|
205
|
+
|
|
206
|
+
If you want to be asked about more, set the mode explicitly:
|
|
207
|
+
|
|
208
|
+
```bash
|
|
209
|
+
BIVY_APPROVAL_MODE=risky # prompt on risky shell commands and file edits
|
|
210
|
+
BIVY_APPROVAL_MODE=always # prompt on all shell commands and file edits
|
|
211
|
+
BIVY_APPROVAL_MODE=never # no prompts beyond the hard floor
|
|
212
|
+
```
|
|
213
|
+
|
|
214
|
+
Approve from the terminal, browser, or phone.
|
|
215
|
+
|
|
216
|
+
Sandbox tiers (`read-only`, `workspace-write`, `danger-full-access`) are enforced
|
|
217
|
+
natively by agents that support them — Codex, Claude Code, Gemini CLI, Qwen Code.
|
|
218
|
+
Agents without a native sandbox are governed at the filesystem, MCP, and network
|
|
219
|
+
layer. **Bivy does not ship its own OS-level jail in 0.1.**
|
|
220
|
+
|
|
221
|
+
## Credentials
|
|
222
|
+
|
|
223
|
+
Provider credentials stay on the node or in a vault you control. Bivy Cloud does
|
|
224
|
+
not receive model keys, GitHub repository tokens, OAuth refresh tokens, prompts,
|
|
225
|
+
transcripts, or workspace files.
|
|
226
|
+
|
|
227
|
+
```bash
|
|
228
|
+
bivy secrets list
|
|
229
|
+
bivy secrets set github.repo-token
|
|
230
|
+
bivy secrets ref github.repo-token op://Bivy/GitHub/repo-token
|
|
231
|
+
bivy secrets doctor
|
|
232
|
+
```
|
|
233
|
+
|
|
234
|
+
`secret://`, `env://`, and `op://` (1Password) references are resolved on demand
|
|
235
|
+
when the daemon provisions an agent run, so the raw values never sit in your
|
|
236
|
+
config. See [`docs/key-management.md`](docs/key-management.md).
|
|
237
|
+
|
|
238
|
+
## GitHub work queue
|
|
239
|
+
|
|
240
|
+
Label an issue `bivy` (or `bivy/<node>` to target a machine), or mention the Bivy
|
|
241
|
+
GitHub App in a comment. A node you own claims the work, runs the agent in an
|
|
242
|
+
isolated worktree, and the agent opens the pull request itself.
|
|
243
|
+
|
|
244
|
+
Available on every plan: interactive CLI/app sessions are unlimited. Free
|
|
245
|
+
accounts also get 10 unattended automations per rolling 7-day window across
|
|
246
|
+
GitHub, Slack, webhooks, and schedules; Pro removes the automation cap.
|
|
247
|
+
Self-hosted stacks are unlimited.
|
|
248
|
+
|
|
249
|
+
A private GitHub App only installs on the account that owns it, so connect one
|
|
250
|
+
app per GitHub account — one for your personal repos, one per organization
|
|
251
|
+
(`bivy github:app-create --org <org>`). A node can serve several at once, each
|
|
252
|
+
with its own key and `@`-mention handle.
|
|
253
|
+
|
|
254
|
+
See [`docs/github-work-queue.md`](docs/github-work-queue.md).
|
|
255
|
+
|
|
256
|
+
## Linear work queue
|
|
257
|
+
|
|
258
|
+
Apply `bivy` or `bivy/<node>` to a Linear issue to dispatch it to the same hosted queue. The node fetches issue content directly from Linear, works in an isolated GitHub worktree, and asks the agent to open a pull request. See [`docs/linear-work-queue.md`](docs/linear-work-queue.md).
|
|
259
|
+
|
|
260
|
+
## Development
|
|
261
|
+
|
|
262
|
+
```bash
|
|
263
|
+
npm install
|
|
264
|
+
npm run dev # node daemon on http://localhost:4317
|
|
265
|
+
npm run dev:web # web client dev server (proxies /api and /ws to the node)
|
|
266
|
+
```
|
|
267
|
+
|
|
268
|
+
Checks — all of these run in CI:
|
|
269
|
+
|
|
270
|
+
```bash
|
|
271
|
+
npm run typecheck
|
|
272
|
+
npm run typecheck:web
|
|
273
|
+
npm run lint
|
|
274
|
+
npm run test:unit
|
|
275
|
+
npm run test:core
|
|
276
|
+
npm run check:licenses
|
|
277
|
+
npm run check:secrets
|
|
278
|
+
```
|
|
279
|
+
|
|
280
|
+
Repository layout:
|
|
281
|
+
|
|
282
|
+
- `src/` — node daemon, runtime adapters, approvals, secrets, sessions
|
|
283
|
+
- `bin/` — the `bivy` CLI
|
|
284
|
+
- `packages/core` — shared protocol, pairing, wire format
|
|
285
|
+
- `packages/web` — the React/Vite PWA client (`@bivy/web`)
|
|
286
|
+
- `services/relay` — self-hostable relay
|
|
287
|
+
- `services/control-plane` — self-hostable control plane
|
|
288
|
+
- `deploy/` — self-host deployment examples
|
|
289
|
+
|
|
290
|
+
See [`CONTRIBUTING.md`](CONTRIBUTING.md).
|
|
291
|
+
|
|
292
|
+
## Self-hosting
|
|
293
|
+
|
|
294
|
+
Node, relay, and control plane are all in this repository. Point a node at your
|
|
295
|
+
own deployment by passing URLs to `bivy relay:setup` — re-running it switches an
|
|
296
|
+
existing node over to the new endpoints:
|
|
297
|
+
|
|
298
|
+
```bash
|
|
299
|
+
bivy relay:setup \
|
|
300
|
+
--control-plane https://bivy.example.com \
|
|
301
|
+
--relay wss://relay.example.com
|
|
302
|
+
```
|
|
303
|
+
|
|
304
|
+
Each URL has a flag and an environment-variable equivalent (the flag wins):
|
|
305
|
+
|
|
306
|
+
| Flag | Environment variable | Points at | Default |
|
|
307
|
+
|---|---|---|---|
|
|
308
|
+
| `--control-plane <url>` | `BIVY_CONTROL_PLANE_URL` | accounts, node registry, and the web-app API | hosted (`app.bivy.sh`) |
|
|
309
|
+
| `--relay <wss-url>` | `BIVY_RELAY_URL` | the encrypted-frame relay your node dials out to | hosted |
|
|
310
|
+
| `--client <url>` | `BIVY_CLIENT_BASE_URL` | base URL used when building app/PWA links | the `--control-plane` URL |
|
|
311
|
+
|
|
312
|
+
Sign-in defaults to GitHub device login (`--github`); pass
|
|
313
|
+
`--email you@example.com` for an email magic-link, or `--session-token <token>`
|
|
314
|
+
to skip interactive sign-in. `relay:setup` checks the control plane is reachable, enrolls
|
|
315
|
+
this node, and writes the endpoints to `.bivy/relay.json`, so `bivy open`,
|
|
316
|
+
`bivy link`, and `bivy update` all keep using your deployment afterwards.
|
|
317
|
+
|
|
318
|
+
**Self-hosting is unsupported** — no SLA, community best-effort via GitHub
|
|
319
|
+
issues. You own TLS, backups, upgrades, and hardening. See
|
|
320
|
+
[`docs/self-host.md`](docs/self-host.md).
|
|
321
|
+
|
|
322
|
+
## Security
|
|
323
|
+
|
|
324
|
+
Report vulnerabilities through [GitHub private vulnerability reporting](https://github.com/bivysh/bivy/security/advisories/new).
|
|
325
|
+
Please do not open a public issue. See [`SECURITY.md`](SECURITY.md) for scope,
|
|
326
|
+
response times, and safe harbour, and [`docs/security-model.md`](docs/security-model.md)
|
|
327
|
+
for the trust model and known limitations.
|
|
328
|
+
|
|
329
|
+
## License
|
|
330
|
+
|
|
331
|
+
Bivy Core is licensed under the Functional Source License (FSL-1.1-ALv2): you may
|
|
332
|
+
use, modify, and self-host it for any purpose **except a Competing Use** —
|
|
333
|
+
offering it to others as a product or service that substitutes for Bivy or Bivy
|
|
334
|
+
Cloud. Two years after each release, that version converts to Apache-2.0.
|
|
335
|
+
|
|
336
|
+
This is a source-available licence, not an OSI-approved open source licence.
|
|
337
|
+
|
|
338
|
+
See [`LICENSE`](LICENSE), [`CORE.md`](CORE.md), and [`CLOUD.md`](CLOUD.md).
|