owlmem 0.9.25 → 0.9.26
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 +1 -2
- package/owlmem.mjs +18 -6
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -58,8 +58,7 @@ npx -y owlmem wake disable # also done by npx -y owlmem uninstall
|
|
|
58
58
|
Claude Code is only additionally allowed the two OwlMem tools it needs to report back (`kb_task_update`,
|
|
59
59
|
`kb_inbox`). Anything that needs a person — an approval, a sign-in, a code — it declines, saying what to do.
|
|
60
60
|
It is told never to put secrets in its result.
|
|
61
|
-
- **Turning it off.**
|
|
62
|
-
the computer. When the computer is removed, the AI is disconnected or the account is gone, the program gets a 401,
|
|
61
|
+
- **Turning it off.** Run `npx -y owlmem wake disable` on that computer, or remove the computer in the console (AI agents → Agents, Paired computers). When the computer is removed, the AI is disconnected or the account is gone, the program gets a 401,
|
|
63
62
|
removes its own autostart entry and exits. The command for each app is in `~/.config/owlmem/wake/wake.json`;
|
|
64
63
|
logs and worktrees stay in that folder after uninstalling.
|
|
65
64
|
- **Plan usage.** The waker also reports each app's plan usage to OwlMem. Cursor:自动报套餐用量。
|
package/owlmem.mjs
CHANGED
|
@@ -44,7 +44,7 @@ import { fileURLToPath } from "node:url";
|
|
|
44
44
|
import { spawn, spawnSync } from "node:child_process";
|
|
45
45
|
import { createConnection } from "node:net";
|
|
46
46
|
|
|
47
|
-
export const VERSION = "0.9.
|
|
47
|
+
export const VERSION = "0.9.26";
|
|
48
48
|
const BASE = (process.env.OWLMEM_URL || "https://owlmem.com").replace(/\/$/, "");
|
|
49
49
|
const DIR = process.env.OWLMEM_HOME || join(process.env.XDG_CONFIG_HOME || join(homedir(), ".config"), "owlmem");
|
|
50
50
|
const enc = new TextEncoder(), dec = new TextDecoder();
|
|
@@ -815,7 +815,7 @@ function nextSteps(items, out) {
|
|
|
815
815
|
// needs a person, it declines with what the person has to do. When a task the agent gave out is done or declined, it is
|
|
816
816
|
// woken too, to read the result (OwlMem sends those only to 0.7.7 and later).
|
|
817
817
|
// This computer is identified by its device key (device.json); the pairing is approved in the console, where each AI has an
|
|
818
|
-
// auto-wake
|
|
818
|
+
// auto-wake is on by default for computer AIs, and the computer can be removed. If OwlMem answers 401 (computer removed, AI disconnected, account gone)
|
|
819
819
|
// the program removes its own autostart entry and exits.
|
|
820
820
|
// The OwlMem tools an unattended wake run may call without asking: answer the task, read its inbox, and send (report the
|
|
821
821
|
// result to its person, hand work on). 0.7.8 added kb_send (站长 10-28).
|
|
@@ -2118,6 +2118,18 @@ export async function wakeNoClients(api, items = null) {
|
|
|
2118
2118
|
return r.status === 200;
|
|
2119
2119
|
}
|
|
2120
2120
|
|
|
2121
|
+
// #3936:已配对的电脑再配对,打出真实结果:绑上的列表 + 没对上的应用的补配链接(不再说去控制台拨开关,那个开关 0.82.0 就去掉了)。
|
|
2122
|
+
export function wakeActiveText(data) {
|
|
2123
|
+
const bound = (data.agents || []).map((x) => x.agent + " (" + x.client + ")").join(", ");
|
|
2124
|
+
let out = "Bound here: " + (bound || "nothing yet") + ". Auto-wake is on by default for these AIs; to turn it off, run: npx -y owlmem wake disable.";
|
|
2125
|
+
const un = data.unassigned || [];
|
|
2126
|
+
if (un.length && data.url) {
|
|
2127
|
+
out += "\nThese aren't assigned to an AI yet: " + un.join(", ") + ". Choose which AI each is:\n\n " + data.url +
|
|
2128
|
+
"\n\nCheck that the console shows this code: " + data.code;
|
|
2129
|
+
}
|
|
2130
|
+
return out;
|
|
2131
|
+
}
|
|
2132
|
+
|
|
2121
2133
|
async function wakeEnable(args = []) {
|
|
2122
2134
|
const boot = args.includes("--boot"), again = args.includes("--again");
|
|
2123
2135
|
const num = (name, lo, hi) => { const i = args.indexOf(name); if (i < 0) return undefined; const n = Number(args[i + 1]); if (!Number.isInteger(n) || n < lo || n > hi) throw new Fail(`${name} takes a whole number from ${lo} to ${hi}.`); return n; };
|
|
@@ -2165,7 +2177,7 @@ async function wakeEnable(args = []) {
|
|
|
2165
2177
|
say("\nApprove this computer in the OwlMem console and pick which AI each app is:\n\n " + r.data.url + "\n\nCheck that the console shows this code: " + r.data.code + "\nUntil then auto-wake waits and starts nothing." +
|
|
2166
2178
|
"\n(If you're an AI agent running this: send the link and the code to the person who turned auto-wake on, with kb_send.)");
|
|
2167
2179
|
openBrowser(r.data.url);
|
|
2168
|
-
} else say(
|
|
2180
|
+
} else say(wakeActiveText(r.data));
|
|
2169
2181
|
}
|
|
2170
2182
|
|
|
2171
2183
|
function wakeDisable(quiet = false) {
|
|
@@ -2196,10 +2208,10 @@ async function wakeStatus() {
|
|
|
2196
2208
|
if (r.status === 401) say("OwlMem: this computer isn't paired any more. Pair it again: npx -y owlmem wake enable --again");
|
|
2197
2209
|
else if (r.status !== 200) say("OwlMem: can't reach it (" + (r.data.detail || "HTTP " + r.status) + ")");
|
|
2198
2210
|
else if (r.data.status === "pending") say("OwlMem: waiting for approval in the console" + (cfg.pair_url ? ": " + cfg.pair_url : "") + " (code " + r.data.code + ")");
|
|
2199
|
-
else say("OwlMem: paired as " + r.data.code + ". " + r.data.agents.map((x) => x.agent + " (" + x.client +
|
|
2211
|
+
else say("OwlMem: paired as " + r.data.code + ". " + r.data.agents.map((x) => x.agent + " (" + x.client + ")").join(", "));
|
|
2200
2212
|
}
|
|
2201
2213
|
|
|
2202
|
-
const WAKE_HELP = `Usage: npx -y owlmem wake <enable|disable|status>
|
|
2214
|
+
export const WAKE_HELP = `Usage: npx -y owlmem wake <enable|disable|status>
|
|
2203
2215
|
|
|
2204
2216
|
Auto-wake starts the AI on this computer when it gets an OwlMem task (Claude Code with \`claude -p\`, Codex with
|
|
2205
2217
|
\`codex exec\`, Antigravity with \`agy -p\`, Hermes with \`hermes -z\`), without you opening it. It runs in the background from login, for this user only.
|
|
@@ -2211,7 +2223,7 @@ Auto-wake starts the AI on this computer when it gets an OwlMem task (Claude Cod
|
|
|
2211
2223
|
disable remove it from this computer (also done by npx -y owlmem uninstall)
|
|
2212
2224
|
status show what's set up and what OwlMem says
|
|
2213
2225
|
|
|
2214
|
-
|
|
2226
|
+
Settings, including the command for
|
|
2215
2227
|
each app ("claude-code", "codex", or your own under "gemini" / "custom"): ~/.config/owlmem/wake/wake.json`;
|
|
2216
2228
|
|
|
2217
2229
|
async function wakeCmd(sub, args) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "owlmem",
|
|
3
|
-
"version": "0.9.
|
|
3
|
+
"version": "0.9.26",
|
|
4
4
|
"description": "OwlMem command line: connect your AI apps to OwlMem in one command (npx -y owlmem install), an end-to-end encrypted vault for your AI agents, and a local MCP server.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": { "owlmem": "owlmem.mjs" },
|