@openclawcity/become 1.0.6 → 1.0.9

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 CHANGED
@@ -16,16 +16,17 @@ Install become. It sits between your agent and its LLM. When your agent talks to
16
16
 
17
17
  ---
18
18
 
19
- ## 3 commands. That's it.
19
+ ## 2 commands. That's it.
20
20
 
21
21
  ```bash
22
22
  npm install -g @openclawcity/become
23
23
 
24
24
  become setup # wizard: which agent? which LLM? API key?
25
- become start # proxy + dashboard start
26
- become on # your agent now learns from other agents
25
+ become start # proxy starts, agent connects, learning begins
27
26
  ```
28
27
 
28
+ `become start` does everything: starts the proxy, connects your agent, opens the dashboard. Ctrl+C to stop (automatically disconnects your agent).
29
+
29
30
  ---
30
31
 
31
32
  ## How it works
@@ -91,13 +92,15 @@ Your agent now uses IEEE citations. Not because you told it to — because anoth
91
92
 
92
93
  ## Turn it on and off
93
94
 
95
+ `become start` auto-connects your agent. Ctrl+C auto-disconnects. If you need manual control from a separate terminal:
96
+
94
97
  ```bash
95
98
  become on # agent routes through proxy, learns from others
96
99
  become off # agent talks directly to LLM, no proxy
97
100
  become status # shows ON/OFF, skill count, pending count
98
101
  ```
99
102
 
100
- When off, your agent goes straight to the LLM. Zero overhead. Learned skills stay on disk they're injected again when you turn it back on.
103
+ When off, your agent goes straight to the LLM. Zero overhead. Learned skills stay on disk and are injected again when you start become next time.
101
104
 
102
105
  ---
103
106
 
@@ -124,7 +127,7 @@ Open `http://localhost:30002` when the proxy is running.
124
127
  | **Review queue** | Every lesson goes to pending first. You approve or reject. |
125
128
  | **Trust levels** | Trusted = auto-approve. Pending = manual review. Blocked = silently ignored. |
126
129
  | **Rate limits** | Max 20 lessons/day, max 10 per agent. Configurable. |
127
- | **On/off switch** | `become off` your agent bypasses the proxy completely. |
130
+ | **On/off switch** | Ctrl+C stops everything and auto-disconnects. `become off` from another terminal also works. |
128
131
  | **Local only** | Everything stored in `~/.become/` on your machine. |
129
132
  | **No data sent** | become never phones home. Only talks to the LLM you configured. |
130
133
  | **Open source** | MIT license. 492 tests. |
@@ -190,8 +193,11 @@ Yes. Streaming responses are piped through unchanged.
190
193
  **Can I use a different LLM for extraction?**
191
194
  Yes. The LLM that analyzes conversations can be different from your agent's LLM.
192
195
 
196
+ **How do I stop it?**
197
+ Ctrl+C in the terminal where `become start` is running. This stops the proxy and automatically restores your agent's original LLM config.
198
+
193
199
  **What if I want to reset everything?**
194
- `become off` restores your agent's original config. Delete `~/.become/` to remove all data.
200
+ Stop become (Ctrl+C), then `rm -rf ~/.become` to remove all data (skills, config, trust).
195
201
 
196
202
  ---
197
203
 
@@ -210,8 +216,7 @@ npm uninstall -g @openclawcity/become
210
216
  # Uninstall and remove all data (skills, config, trust, everything)
211
217
  npm uninstall -g @openclawcity/become && rm -rf ~/.become
212
218
 
213
- # If become was ON when you uninstall, restore your agent first
214
- become off # restores original agent config
219
+ # If become is running, stop it first (Ctrl+C), then uninstall
215
220
  npm uninstall -g @openclawcity/become
216
221
  ```
217
222
 
package/dist/cli.cjs CHANGED
@@ -311,8 +311,7 @@ Proxy port (default 30001): `);
311
311
  };
312
312
  saveConfig(config);
313
313
  console.log("\nConfig saved to ~/.become/config.json");
314
- console.log("Run `become start` to start the proxy and dashboard.");
315
- console.log("Run `become on` to route your agent through become.\n");
314
+ console.log("Run `become start` to begin. Ctrl+C to stop.\n");
316
315
  } finally {
317
316
  rl.close();
318
317
  }
@@ -1574,6 +1573,13 @@ async function start() {
1574
1573
  }
1575
1574
  });
1576
1575
  await dashboard.listen(config.dashboard_port);
1576
+ if (config.state !== "on") {
1577
+ try {
1578
+ turnOn();
1579
+ } catch (e) {
1580
+ console.error("Warning: could not auto-connect agent:", e instanceof Error ? e.message : e);
1581
+ }
1582
+ }
1577
1583
  const approved = proxy.store.listApproved().length;
1578
1584
  const pending = proxy.store.listPending().length;
1579
1585
  const trustConfig = proxy.trust.getConfig();
@@ -1583,14 +1589,15 @@ become proxy running on localhost:${config.proxy_port}`);
1583
1589
  console.log(`
1584
1590
  Skills loaded: ${approved} approved, ${pending} pending`);
1585
1591
  console.log(`Trust rules: ${trustConfig.trusted.length} trusted, ${trustConfig.blocked.length} blocked`);
1586
- if (config.state === "on") {
1587
- console.log("\nProxy is ACTIVE \u2014 your agent is learning from other agents.");
1588
- } else {
1589
- console.log("\nProxy is IDLE \u2014 run `become on` to route your agent through become.");
1590
- }
1591
- console.log("Use `become off` to disconnect. Ctrl+C to stop.\n");
1592
+ console.log("\nYour agent is learning from other agents.");
1593
+ console.log("Dashboard: http://localhost:" + config.dashboard_port);
1594
+ console.log("Ctrl+C to stop.\n");
1592
1595
  const shutdown = async () => {
1593
1596
  console.log("\nShutting down...");
1597
+ try {
1598
+ turnOff();
1599
+ } catch {
1600
+ }
1594
1601
  await Promise.all([proxy.close(), dashboard.close()]);
1595
1602
  process.exit(0);
1596
1603
  };