baychat 0.34.1 → 0.34.2
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/.claude-plugin/plugin.json +1 -1
- package/README.md +13 -2
- package/dist/bays-command.js +6 -0
- package/dist/channel/feed.js +48 -4
- package/dist/channel/log-file.js +37 -0
- package/dist/channel/server.js +34 -4
- package/dist/claude-context-flush.js +31 -8
- package/dist/claude-context.js +19 -5
- package/dist/claude-onboarding.js +21 -8
- package/dist/cli-help.js +3 -0
- package/dist/client-paths.js +6 -1
- package/dist/client-scope.js +34 -0
- package/dist/commands.js +16 -8
- package/dist/launch/command.js +6 -3
- package/dist/main.js +14 -1
- package/dist/mcp-files.js +2 -0
- package/dist/mcp-register.js +2 -0
- package/dist/protocol-content.js +1 -1
- package/dist/refresh-clients.js +7 -0
- package/dist/relay/acp/approval.js +99 -30
- package/dist/relay/acp/daemon-glue.js +2 -1
- package/dist/relay/adapters.js +5 -1
- package/dist/relay/bay-relays.js +18 -5
- package/dist/relay/codex-allowances.js +113 -0
- package/dist/relay/codex-app-server.js +637 -157
- package/dist/relay/codex-approvals.js +390 -0
- package/dist/relay/codex-commands.js +61 -0
- package/dist/relay/codex-log.js +260 -0
- package/dist/relay/codex-runner.js +505 -0
- package/dist/relay/codex-version.js +50 -0
- package/dist/relay/daemon.js +190 -6
- package/dist/relay/fresh-start.js +2 -1
- package/dist/relay/launcher/capabilities.js +24 -9
- package/dist/relay/launcher/codex-launch.js +9 -2
- package/dist/relay/launcher/codex-relay-launch.js +80 -0
- package/dist/relay/launcher/handle.js +101 -30
- package/dist/relay/launcher/loop.js +5 -1
- package/dist/relay/launcher/stop-registered.js +124 -9
- package/dist/relay/registry.js +30 -0
- package/dist/relay/runtime-limits.js +167 -0
- package/dist/relay/spawn-env.js +40 -3
- package/dist/relay/terminal-pane.js +1 -0
- package/dist/skill-bootstrap.js +2 -0
- package/dist/tool-defs.js +30 -0
- package/package.json +1 -1
package/dist/launch/command.js
CHANGED
|
@@ -48,9 +48,12 @@ exports.LAUNCH_USAGE = `Usage: baychat launch add <folder> [--label <label>] [--
|
|
|
48
48
|
baychat launch remove <id> Stop offering one of them`;
|
|
49
49
|
/** Printed by every `add`: the one thing a person must know before saying yes. */
|
|
50
50
|
exports.APPROVALS_NOTICE = "Claude Code sessions started here from BayChat ask for approvals in BayChat.";
|
|
51
|
-
/** Printed when Codex is offered: it
|
|
52
|
-
exports.CODEX_UNATTENDED_NOTICE = "Codex started here from BayChat
|
|
53
|
-
"
|
|
51
|
+
/** Printed when Codex is offered: what it may do without asking, and what it asks on the phone. */
|
|
52
|
+
exports.CODEX_UNATTENDED_NOTICE = "Codex started here from BayChat is run by the relay (Codex 0.160 or newer): it can change files in this folder without asking, with no network, " +
|
|
53
|
+
"and asks for approval in BayChat — on the session owner's phone — before anything more (a command outside its sandbox, network access, files elsewhere). " +
|
|
54
|
+
"A message from someone without command access to the session makes that turn read only. " +
|
|
55
|
+
"With BAYCHAT_CODEX_TRANSPORT=exec on the relay, Codex cannot answer in BayChat, so starting it from the phone is refused. " +
|
|
56
|
+
"MCP servers in its own config run as usual.";
|
|
54
57
|
const realDeps = () => {
|
|
55
58
|
const file = (0, claude_trust_1.claudeConfigPath)();
|
|
56
59
|
return {
|
package/dist/main.js
CHANGED
|
@@ -23,6 +23,7 @@ const server_1 = require("./channel/server");
|
|
|
23
23
|
const launch_1 = require("./channel/launch");
|
|
24
24
|
const mcp_config_1 = require("./mcp-config");
|
|
25
25
|
const commands_2 = require("./relay/commands");
|
|
26
|
+
const codex_log_1 = require("./relay/codex-log");
|
|
26
27
|
const bays_1 = require("./bays");
|
|
27
28
|
const config_1 = require("./config");
|
|
28
29
|
const help_topics_1 = require("./help-topics");
|
|
@@ -293,8 +294,20 @@ async function main() {
|
|
|
293
294
|
ownerPid: numberFlag(rest, "--owner-pid"),
|
|
294
295
|
});
|
|
295
296
|
}
|
|
297
|
+
case "log": {
|
|
298
|
+
// A relay-run Codex session's own log (relay/codex-log.ts): what it ran, changed and said.
|
|
299
|
+
(0, args_1.rejectUnknownFlags)(rest, ["--follow"], "baychat relay log <session> [-f]");
|
|
300
|
+
const session = rest.find((a) => !a.startsWith("-"));
|
|
301
|
+
if (!session)
|
|
302
|
+
throw new Error("Usage: baychat relay log <session> [-f]");
|
|
303
|
+
const follow = rest.includes("-f") || rest.includes("--follow");
|
|
304
|
+
const stop = new AbortController();
|
|
305
|
+
if (follow)
|
|
306
|
+
process.once("SIGINT", () => stop.abort());
|
|
307
|
+
return await (0, codex_log_1.showCodexLog)(session, { follow, signal: stop.signal });
|
|
308
|
+
}
|
|
296
309
|
default:
|
|
297
|
-
throw new Error("Usage: baychat relay <start|status|stop|attach> [options]");
|
|
310
|
+
throw new Error("Usage: baychat relay <start|status|stop|attach|log> [options]");
|
|
298
311
|
}
|
|
299
312
|
}
|
|
300
313
|
case "hermes": {
|
package/dist/mcp-files.js
CHANGED
|
@@ -403,6 +403,7 @@ exports.SEND_FILES_PARAM = {
|
|
|
403
403
|
exports.FILE_TOOL_DEFS = [
|
|
404
404
|
{
|
|
405
405
|
name: "upload_file",
|
|
406
|
+
access: "write",
|
|
406
407
|
title: "Upload a file to BayChat",
|
|
407
408
|
description: "Upload ONE file from this machine to BayChat and get back an attachment id to send with " +
|
|
408
409
|
"send_message (attachmentIds). Prefer send_message's files parameter when you just want to " +
|
|
@@ -419,6 +420,7 @@ exports.FILE_TOOL_DEFS = [
|
|
|
419
420
|
},
|
|
420
421
|
{
|
|
421
422
|
name: "download_attachment",
|
|
423
|
+
access: "read",
|
|
422
424
|
title: "Download an attachment",
|
|
423
425
|
description: "Download an attachment from a BayChat message onto this machine and get back the local " +
|
|
424
426
|
"path, so you can open it with your own file tools. Pass the signed attachmentUrl exactly " +
|
package/dist/mcp-register.js
CHANGED
|
@@ -17,6 +17,7 @@
|
|
|
17
17
|
// takes no arguments must omit the key entirely.
|
|
18
18
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
19
19
|
exports.registerToolDefs = registerToolDefs;
|
|
20
|
+
const tool_defs_1 = require("./tool-defs");
|
|
20
21
|
/**
|
|
21
22
|
* Register every def against its handler, failing loudly if one is missing.
|
|
22
23
|
*
|
|
@@ -33,6 +34,7 @@ function registerToolDefs(server, defs, handlers) {
|
|
|
33
34
|
description: def.description,
|
|
34
35
|
...(Object.keys(def.inputSchema).length ? { inputSchema: def.inputSchema } : {}),
|
|
35
36
|
...(def._meta ? { _meta: def._meta } : {}),
|
|
37
|
+
annotations: (0, tool_defs_1.toolAnnotations)(def.access),
|
|
36
38
|
}, async (args) => handler(args));
|
|
37
39
|
}
|
|
38
40
|
}
|