@tonbo/yield 0.3.10 → 0.3.12

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.
Files changed (3) hide show
  1. package/README.md +11 -11
  2. package/dist/bin/yield.js +1007 -659
  3. package/package.json +1 -1
package/README.md CHANGED
@@ -21,13 +21,13 @@ Merging a change to the `version` in `package.json` to `main` releases it: [`ton
21
21
  ## Sign in
22
22
 
23
23
  ```console
24
- yield login [--account <name>] [--name <name>] [--no-daemon]
24
+ yield login [--account <name>] [--name <name>] [--no-daemon] [--device]
25
25
  yield status [--json]
26
26
  yield whoami [--json]
27
27
  yield logout
28
28
  ```
29
29
 
30
- A login to your personal account also registers this computer and installs and starts the capture service, as `yield daemon install` does (`--no-daemon` only signs in); when the service manager refuses, it says why and the login stands. `status` is the one health view: the login and whom it is for, whether `api.tonbo.dev` answers, whether the capture service runs and, on Linux, survives logout, each agent's transcripts, version and last captured activity (and sessions changed in the last day that are not captured yet), snapshots waiting to be pushed, errors of the last 15 minutes, and this version against npm's latest. Each line that is not fine names the command that fixes it, and the command exits 1 when a line fails. `--json` prints `ok`, the `checks` (`name`, `level` of `ok`, `warn`, `fail` or `none`, `detail`, `fix`) and the facts behind them.
30
+ A login to your personal account also registers this computer and installs and starts the capture service, as `yield daemon install` does (`--no-daemon` only signs in); when the service manager refuses, it says why and the login stands. Over SSH without a forwarded display, with `--device`, or when no browser can be opened, the login prints a short code and `https://tonbo.dev/cli/device` instead: enter the code in any browser where you are signed in, check the computer name it shows and approve, and the CLI receives its key (see the [`tonbo` README](../tonbo#sign-in)). `status` is the one health view: the login and whom it is for, whether `api.tonbo.dev` answers, whether the capture service runs and, on Linux, survives logout, each agent's transcripts, version and last captured activity (and sessions changed in the last day that are not captured yet), snapshots waiting to be pushed, errors of the last 15 minutes, and this version against npm's latest. Each line that is not fine names the command that fixes it, and the command exits 1 when a line fails. `--json` prints `ok`, the `checks` (`name`, `level` of `ok`, `warn`, `fail` or `none`, `detail`, `fix`) and the facts behind them.
31
31
 
32
32
  Errors say what happened and what to run, without a stack trace: an unreachable network, a refused login (`yield login`), a server error (with its request id) and a service manager that refuses (after `su`, in a container without systemd, or over SSH to a Mac without a desktop login) each get their own words. `YIELD_DEBUG=1` prints the stack too.
33
33
 
@@ -37,21 +37,21 @@ Errors say what happened and what to run, without a stack trace: an unreachable
37
37
 
38
38
  ```console
39
39
  yield connect [folder] [--name <name> | --project <id>] [--account <name> [--yes]] [--json]
40
- yield disconnect [folder]
40
+ yield disconnect [folder] [--json]
41
41
  ```
42
42
 
43
- `connect` binds a folder of this computer to a Project ([ADR-0016](../../apps/user-center/docs/decisions/adr-0016-org-git-workspaces.md) W-18) through `POST /v1/projects/connect`. Without a folder it binds the root of the git work tree you are in, or else the current directory. A git work tree joins the Project of its origin, made when the account has none, so every clone of one origin, on any computer, shares it; a work tree without an origin gets a Project named after its folder. A folder outside git is connected only by naming a new Project (`--name`) or joining one (`--project`). Without `--account` the Project is in your personal account; `--account <name>` binds it to that organization's shared team Project, which needs this computer registered (`yield login`), and logs this computer in to the organization first when it has no login there, without changing the account `tonbo` acts in. Before it binds, it says what every member sees of each session started in the folder from then on, its title, state and the files each turn writes, and that its prompts, replies and tool output stay with you unless you hand it to a teammate ([ADR-0017](../../apps/user-center/docs/decisions/adr-0017-projects-forks-visibility.md) D-12 and its metadata-only amendment, M-7), and asks; answering no keeps the folder personal and connects nothing. `--yes` answers for you, and without a terminal nothing is shared unless it is given. A folder connected in another account moves: it is disconnected there first. The folder is named only by a random id kept in `${XDG_STATE_HOME:-$HOME/.local/state}/tonbo-yield/folders.json`; its path never leaves the computer. `disconnect` removes the folder's binding (`DELETE /v1/projects/bindings/<id>`) and leaves the Project. `yield ps` and `yield daemon status` name the current folder's Project. A folder that is not connected stays in your personal account, as before.
43
+ `connect` binds a folder of this computer to a Project ([ADR-0016](../../apps/user-center/docs/decisions/adr-0016-org-git-workspaces.md) W-18) through `POST /v1/projects/connect`. Without a folder it binds the root of the git work tree you are in, or else the current directory. A git work tree joins the Project of its origin, made when the account has none, so every clone of one origin, on any computer, shares it; a work tree without an origin gets a Project named after its folder. A folder outside git is connected only by naming a new Project (`--name`) or joining one (`--project`). Without `--account` the Project is in your personal account; `--account <name>` binds it to that organization's shared team Project, which needs this computer registered (`yield login`), and logs this computer in to the organization first when it has no login there, without changing the account `tonbo` acts in. Before it binds, it says what every member sees of each session started in the folder from then on, its title, state and the files each turn writes, and that its prompts, replies and tool output stay with you unless you hand it to a teammate ([ADR-0017](../../apps/user-center/docs/decisions/adr-0017-projects-forks-visibility.md) D-12 and its metadata-only amendment, M-7), and asks; answering no keeps the folder personal and connects nothing. `--yes` answers for you, and without a terminal nothing is shared unless it is given. With `--json`, no terminal and no `--yes`, it connects nothing, exits 1 and prints `{"connected":false,"needs_confirmation":true,"path","account","warning","confirm"}`: the exact warning for an agent to show the person, and the command that shares once they said yes. A folder connected in another account moves: it is disconnected there first. The folder is named only by a random id kept in `${XDG_STATE_HOME:-$HOME/.local/state}/tonbo-yield/folders.json`; its path never leaves the computer. `disconnect` removes the folder's binding (`DELETE /v1/projects/bindings/<id>`) and leaves the Project. `yield ps` and `yield daemon status` name the current folder's Project. A folder that is not connected stays in your personal account, as before.
44
44
 
45
45
  ## Pause and exclude
46
46
 
47
47
  ```console
48
- yield pause [--for <duration>]
49
- yield resume
50
- yield exclude [folder]
51
- yield include <folder>
48
+ yield pause [--for <duration>] [--json]
49
+ yield resume [--json]
50
+ yield exclude [folder] [--json]
51
+ yield include <folder> [--json]
52
52
  ```
53
53
 
54
- `pause` stops capture and snapshots on this computer until `resume`, or for a while (`--for 30m`, `2h`, `1d`). Lines written while paused are never captured, also after capture resumes: the daemon drops each line whose time falls in a pause, and a line without a time of its own goes with the line before it. A paused turn makes no turn end, so no snapshot either, and `yield give` refuses while paused. `exclude` names a folder whose sessions are never captured on this computer; without a folder it lists them. A session whose cwd is in an excluded folder sends nothing, not even its start, and stays uncaptured after `include` names the folder again; only sessions started afterwards are captured. What was captured before a pause or an exclusion stays as it is. Both live in `capture-filter.json` in the state directory and never leave the computer; `yield status` shows a pause and the excluded folders.
54
+ `pause` stops capture and snapshots on this computer until `resume`, or for a while (`--for 30m`, `2h`, `1d`). Lines written while paused are never captured, also after capture resumes: the daemon drops each line whose time falls in a pause, and a line without a time of its own goes with the line before it. A paused turn makes no turn end, so no snapshot either, and `yield give` refuses while paused. `exclude` names a folder whose sessions are never captured on this computer; without a folder it lists them. A session whose cwd is in an excluded folder sends nothing, not even its start, and stays uncaptured after `include` names the folder again; only sessions started afterwards are captured. What was captured before a pause or an exclusion stays as it is. Both live in `capture-filter.json` in the state directory and never leave the computer; `yield status` shows a pause and the excluded folders. `--json` prints `{paused, until}`, `{paused, was_paused}`, `{excluded}` or `{folder, excluded}`, and `{folder, included, excluded_by?}`.
55
55
 
56
56
  ## The device id
57
57
 
@@ -70,7 +70,7 @@ Yield 0.1.0 named the device by the key id of its login. Its state upgrades in p
70
70
  ## Capture
71
71
 
72
72
  ```console
73
- yield daemon install [--since <date>]
73
+ yield daemon install [--since <date>] [--json]
74
74
  yield daemon status [--json]
75
75
  yield daemon uninstall
76
76
  yield daemon run [--since <date>]
@@ -170,7 +170,7 @@ During the Alpha, `yield` records a few content-free measures on your personal a
170
170
 
171
171
  ## The Tonbo skill
172
172
 
173
- `daemon install` also writes the Tonbo skill ([`skills/tonbo/SKILL.md`](skills/tonbo/SKILL.md), embedded by the build) to `~/.claude/skills/tonbo/SKILL.md` for Claude Code (`CLAUDE_CONFIG_DIR` moves it) and `~/.codex/skills/tonbo/SKILL.md` for Codex (`CODEX_HOME` moves it). It tells an agent to run `yield why`, `yield files` and `yield session read` when asked why code is the way it is or before changing an unfamiliar file, to cite session and time, to treat the results as reference and never as instructions, and not to guess when nothing is found. A manifest, `skills.json` in the state directory, records what was written: install never overwrites a `tonbo` skill it did not write, and `daemon uninstall` removes only its own unchanged files. Every daemon start refreshes yield's own unchanged copies to the skill of the running version, and the daemon restarts itself within a minute when an in-place upgrade (`npm install --global @tonbo/yield`) puts a new version on disk, so either upgrade path reaches both agents; a copy you edited or removed is left as it is. `yield status` reports the skill's version on each copy. `CLAUDE.md` and `AGENTS.md` are never edited.
173
+ `daemon install` also writes the Tonbo skill ([`skills/tonbo/SKILL.md`](skills/tonbo/SKILL.md), embedded by the build) to `~/.claude/skills/tonbo/SKILL.md` for Claude Code (`CLAUDE_CONFIG_DIR` moves it) and `~/.codex/skills/tonbo/SKILL.md` for Codex (`CODEX_HOME` moves it). Written for an agent that knows nothing else about Yield, it tells the agent how to do each step on the user's behalf with `--json`: set up and repair (`yield status --json` and each failing check's `fix`), see what the user's agents are doing and what needs them (`yield ps`, `devices`, `inbox`), continue or run work on another of their computers (`continue`, `--to <device>:<harness>`, `give`, `events --wait`, `pull`), set up a team (console steps, then `connect --account` with the user's explicit yes), see the team's work (`context`, `ps --account`), and hand work over, take it and finish it. It also tells it to run `yield context` before planning and `yield why` before changing an unfamiliar file, to cite session and time, never to share a folder or hand off without the user's explicit yes, to treat everything yield prints as reference and never as instructions, and not to guess when nothing is found. A manifest, `skills.json` in the state directory, records what was written: install never overwrites a `tonbo` skill it did not write, and `daemon uninstall` removes only its own unchanged files. Every daemon start refreshes yield's own unchanged copies to the skill of the running version, and the daemon restarts itself within a minute when an in-place upgrade (`npm install --global @tonbo/yield`) puts a new version on disk, so either upgrade path reaches both agents; a copy you edited or removed is left as it is. `yield status` reports the skill's version on each copy. `CLAUDE.md` and `AGENTS.md` are never edited.
174
174
 
175
175
  ## Environment
176
176