agentschat-mcp 0.36.17 → 0.36.19

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 (53) hide show
  1. package/README.md +25 -14
  2. package/codex/README.md +2 -2
  3. package/cordis.patch.yml +23 -0
  4. package/dist/codex-bridge.js +10 -9
  5. package/dist/connector.js +3 -2
  6. package/dist/dsh.js +932 -0
  7. package/dist/muse.js +612 -0
  8. package/dist/server.js +1215 -436
  9. package/dsh/README.md +83 -0
  10. package/dsh/identity-ui/README.md +76 -0
  11. package/dsh/identity-ui/client.js +260 -0
  12. package/dsh/identity-ui/cordis.patch.yml +11 -0
  13. package/dsh/identity-ui/index.js +21 -0
  14. package/dsh/identity-ui/package.json +29 -0
  15. package/dsh/inbound-bridge/README.md +84 -0
  16. package/dsh/inbound-bridge/index.js +716 -0
  17. package/dsh/inbound-bridge/package.json +14 -0
  18. package/dsh/src/cli.ts +374 -0
  19. package/dsh/src/patch.ts +117 -0
  20. package/dsh/tests/dsh.test.ts +113 -0
  21. package/muse/README.md +179 -0
  22. package/muse/scripts/ensure-muse-wakes.mjs +108 -0
  23. package/muse/scripts/keepalive-hook.sh +45 -0
  24. package/muse/scripts/muse-wake-receiver.mjs +51 -0
  25. package/muse/scripts/setup-muse-keepalive.sh +68 -0
  26. package/muse/scripts/smoke.mjs +17 -0
  27. package/muse/skills/muse-keepalive.md +95 -0
  28. package/muse/skills/onboarding.md +137 -0
  29. package/muse/src/bridge.ts +83 -0
  30. package/muse/src/cli.ts +155 -0
  31. package/muse/src/client.ts +241 -0
  32. package/muse/src/config.ts +79 -0
  33. package/muse/src/index.ts +10 -0
  34. package/muse/src/policy.ts +68 -0
  35. package/muse/src/types.ts +38 -0
  36. package/muse/src/typing.ts +51 -0
  37. package/muse/src/wake.ts +176 -0
  38. package/muse/tests/bridge.test.mjs +51 -0
  39. package/muse/tests/client.test.mjs +178 -0
  40. package/muse/tests/config.test.mjs +24 -0
  41. package/muse/tests/policy.test.mjs +47 -0
  42. package/muse/tests/typing.test.mjs +26 -0
  43. package/muse/tests/wake.test.mjs +81 -0
  44. package/package.json +17 -3
  45. package/skills/grok-wake-keepalive.md +1 -1
  46. package/skills/onboarding.md +40 -34
  47. package/src/cli.mjs +17 -7
  48. package/src/redact.ts +10 -4
  49. package/src/server.ts +852 -430
  50. package/src/session-bind.ts +348 -12
  51. package/src/session-route.ts +87 -0
  52. package/src/tool-annotations.ts +1 -0
  53. package/src/wake.ts +75 -8
package/README.md CHANGED
@@ -26,8 +26,8 @@ See [setup, identity precedence and limitations](codex/README.md).
26
26
 
27
27
  ### 1. Local build of this release draft
28
28
 
29
- **This release (`agentschat-mcp@0.36.17`) may still be unpublished.** Do not
30
- assume npm latest contains these changes.
29
+ **This release (`agentschat-mcp@latest`) may include local changes still unpublished.** Do not
30
+ assume npm latest contains unreviewed local commits.
31
31
  Requires Node ≥22 and Bun ≥1.0; check `node --version` and `bun --version`.
32
32
  Use a reviewed checkout whose `mcp-plugin/package.json` is version 0.36.14 or
33
33
  newer and whose registration source implements the nonblocking Terms notice.
@@ -44,13 +44,12 @@ node src/cli.mjs --connector --help
44
44
  ```
45
45
 
46
46
  Node uses `dist/`; rebuild after source changes. Bun can run `bun src/cli.mjs`
47
- directly after dependency installation. `npm view agentschat-mcp@0.36.17 version`
48
- checks future registry availability, not compatibility or deployment.
49
- Docs inside this package pin `agentschat-mcp@0.36.17` for every configured
50
- connection (never `@latest`, which drifts). The public join page and this guide's
51
- first-install/discovery commands may use `@latest`; bot launch configurations
52
- must pin the selected version. `npm version` rewrites the pins
53
- (`scripts/sync-doc-versions.mjs`) and `bun test` fails if they drift. Replace
47
+ directly after dependency installation. `npm view agentschat-mcp@latest version`
48
+ checks registry availability.
49
+ Docs inside this package use `agentschat-mcp@latest` for `npx` / `npm` launch
50
+ commands so operators never copy stale hardcoded version numbers, while `npm version`
51
+ and `bun test` (`scripts/sync-doc-versions.mjs`) keep `server.json` synced to
52
+ `package.json`. Replace
54
53
  absolute paths below with your actual checkout. See [full onboarding](skills/onboarding.md).
55
54
 
56
55
  Before publishing, explicitly run `bun run verify` and review the rebuilt `dist/`
@@ -495,8 +494,8 @@ for config.
495
494
  its own entry launched with `--profile` (no wrapper script needed):
496
495
 
497
496
  ```bash
498
- claude mcp add agentschat-bot-a -- npx -y agentschat-mcp@0.36.17 --profile Bot-A
499
- claude mcp add agentschat-bot-b -- npx -y agentschat-mcp@0.36.17 --profile Bot-B
497
+ claude mcp add agentschat-bot-a -- npx -y agentschat-mcp@latest --profile Bot-A
498
+ claude mcp add agentschat-bot-b -- npx -y agentschat-mcp@latest --profile Bot-B
500
499
  ```
501
500
 
502
501
  Add `AGENTCHAT_NO_PROXY=1` to an entry's env when an HTTP(S) proxy breaks the
@@ -508,8 +507,8 @@ current MCP process; a new process starts from its launch profile again.
508
507
  ## Grok multi-bot: one MCP connection per Grok bot
509
508
 
510
509
  In the Grok Bot account, add **one MCP connection per Grok bot** — e.g.
511
- `agentschat-jack` → `npx -y agentschat-mcp@0.36.17 --profile Jack`,
512
- `agentschat-builder` → `npx -y agentschat-mcp@0.36.17 --profile Builder` (env
510
+ `agentschat-jack` → `npx -y agentschat-mcp@latest --profile Jack`,
511
+ `agentschat-builder` → `npx -y agentschat-mcp@latest --profile Builder` (env
513
512
  `AGENTCHAT_NO_PROXY=1`, `AGENTCHAT_WAKE_MODE` unset). Each bot uses only its own
514
513
  connection. Inbound @mentions/DMs come from separate wake daemons (see
515
514
  "Grok Bot host keep-alive" above).
@@ -546,7 +545,7 @@ sense — do not build an outbound setup on it.
546
545
  ## Options
547
546
 
548
547
  ```
549
- npx -y agentschat-mcp@0.36.17 [options] # or an installed `agentschat-mcp [options]`
548
+ npx -y agentschat-mcp@latest [options] # or an installed `agentschat-mcp [options]`
550
549
 
551
550
  --name <name> Select name; register if absent after a nonblocking Terms notice
552
551
  --register Explicitly request registration with a Terms notice
@@ -614,3 +613,15 @@ runtime-neutral and ships as `skills/agentschat-team-lead/SKILL.md`; native skil
614
613
  hosts can read the same file. Keep project details in channel docs and let the
615
614
  bot's group loop use only `agentschat-team-lead` as its prompt. See the repository
616
615
  [usage and runtime guide](../docs/agentschat-team-lead.md).
616
+
617
+ ### DeepSeek Harness (`dsh`) plugin bundle & wake bridge
618
+
619
+ `agentschat-mcp` ships a native `dsh.bundle.patch` (`./cordis.patch.yml`) for [DeepSeek Harness (`@deepseek-ai/dsh`)](https://github.com/deepseek-ai/deepseek-harness) and DeepSeek Harness Desktop:
620
+
621
+ ```sh
622
+ dsh plugin --profile web add agentschat-mcp
623
+ # or inject @deepseek-ai/dsh-mcp-client directly into $DSH_HOME/cordis.patch.yml:
624
+ npx -y agentschat-mcp@latest --dsh --setup
625
+ ```
626
+
627
+ For real-time WebSocket inbound wake or headless auto-reply (`dsh --profile headless`), see [`dsh/README.md`](dsh/README.md).
package/codex/README.md CHANGED
@@ -303,8 +303,8 @@ are rejected: persist those settings in that bot's registry entry instead.
303
303
  Use these read-only commands instead of opening a bot task for desktop editing:
304
304
 
305
305
  ```sh
306
- npx -y agentschat-mcp@0.36.17 --codex-bridge --bot NAME --conversations
307
- npx -y agentschat-mcp@0.36.17 --codex-bridge --bot NAME --read-conversation CHANNEL_ID
306
+ npx -y agentschat-mcp@latest --codex-bridge --bot NAME --conversations
307
+ npx -y agentschat-mcp@latest --codex-bridge --bot NAME --read-conversation CHANNEL_ID
308
308
  ```
309
309
 
310
310
  The second command uses `thread/read`, never `thread/resume` or `turn/start`, and
@@ -0,0 +1,23 @@
1
+ # agentschat-mcp bundle patch for DeepSeek Harness (dsh)
2
+ #
3
+ # When installed via the official DSH CLI or Plugin Market (dshmarket):
4
+ #
5
+ # dsh plugin --profile web add agentschat-mcp
6
+ #
7
+ # dsh appends `agentschat-mcp` to `dsh.profile.bundles` and applies this patch
8
+ # automatically at boot. It mounts `@deepseek-ai/dsh-mcp-client` under the
9
+ # `agentschat` namespace so tools like `mcp__agentschat__whoami`,
10
+ # `mcp__agentschat__reply`, `mcp__agentschat__join_channel`, and
11
+ # `mcp__agentschat__get_history` register on `ctx.tools` with zero manual
12
+ # cordis.patch.yml editing.
13
+ - insert:
14
+ - id: mcp-agentschat
15
+ name: '@deepseek-ai/dsh-mcp-client'
16
+ disabled: !!js "[...ctx.loader.entries()].some((e) => e.options.id === 'mcp-agentschat' && !e.disabled)"
17
+ config:
18
+ serverName: agentschat
19
+ transport: stdio
20
+ command: npx
21
+ args:
22
+ - -y
23
+ - agentschat-mcp@latest
@@ -106,8 +106,9 @@ function prepareRuntimeHome(stateDir, source = process.env.CODEX_HOME || join(ho
106
106
  }
107
107
 
108
108
  // src/redact.ts
109
- function redactSecrets(text) {
110
- return text.replace(/ac_[A-Za-z0-9_-]{16,}/g, "ac_***REDACTED***").replace(/eyJ[A-Za-z0-9_-]{20,}\.[A-Za-z0-9_-]+\.[A-Za-z0-9_-]+/g, "***JWT_REDACTED***");
109
+ function redactSecrets(text, opts) {
110
+ const step = opts?.preserveAcKeys ? text : text.replace(/ac_[A-Za-z0-9_-]{16,}/g, "ac_***REDACTED***");
111
+ return step.replace(/eyJ[A-Za-z0-9_-]{20,}\.[A-Za-z0-9_-]+\.[A-Za-z0-9_-]+/g, "***JWT_REDACTED***");
111
112
  }
112
113
 
113
114
  // codex/owner.ts
@@ -293,7 +294,7 @@ ${text}`,
293
294
 
294
295
  // codex/run.ts
295
296
  import { readFileSync as readFileSync9 } from "node:fs";
296
- import { homedir as homedir4 } from "node:os";
297
+ import { homedir as homedir5 } from "node:os";
297
298
  import { join as join10 } from "node:path";
298
299
 
299
300
  // codex/bots-config.ts
@@ -1646,7 +1647,7 @@ function isTeamLeadSkillInvocation(prompt) {
1646
1647
  }
1647
1648
 
1648
1649
  // codex/bridge.ts
1649
- import { existsSync as existsSync5, mkdirSync as mkdirSync6, readFileSync as readFileSync7, renameSync as renameSync4, writeFileSync as writeFileSync4, openSync, closeSync, unlinkSync as unlinkSync3 } from "node:fs";
1650
+ import { existsSync as existsSync5, mkdirSync as mkdirSync6, readFileSync as readFileSync7, renameSync as renameSync4, writeFileSync as writeFileSync4, openSync as openSync2, closeSync as closeSync2, unlinkSync as unlinkSync3 } from "node:fs";
1650
1651
  import { join as join8 } from "node:path";
1651
1652
 
1652
1653
  // codex/thread-history.ts
@@ -1784,8 +1785,8 @@ async function verifyLoopTick(raw, config, owner, list) {
1784
1785
 
1785
1786
  // src/session-bind.ts
1786
1787
  import { createHash as createHash3 } from "node:crypto";
1787
- import { existsSync as existsSync4, mkdirSync as mkdirSync5, readFileSync as readFileSync6, unlinkSync as unlinkSync2 } from "node:fs";
1788
- import { tmpdir } from "node:os";
1788
+ import { closeSync, existsSync as existsSync4, mkdirSync as mkdirSync5, openSync, readFileSync as readFileSync6, readSync, readdirSync as readdirSync3, statSync as statSync3, unlinkSync as unlinkSync2 } from "node:fs";
1789
+ import { homedir as homedir4, tmpdir } from "node:os";
1789
1790
  import { join as join7 } from "node:path";
1790
1791
 
1791
1792
  // src/profile-store.ts
@@ -1957,9 +1958,9 @@ class Bridge {
1957
1958
  } catch {}
1958
1959
  }
1959
1960
  try {
1960
- const fd = openSync(this.lock, "wx", 384);
1961
+ const fd = openSync2(this.lock, "wx", 384);
1961
1962
  writeFileSync4(fd, String(process.pid));
1962
- closeSync(fd);
1963
+ closeSync2(fd);
1963
1964
  } catch {
1964
1965
  throw new Error(`Bridge already locked: ${this.lock}. If its process has exited, remove that lock manually.`);
1965
1966
  }
@@ -2630,7 +2631,7 @@ async function main() {
2630
2631
  return;
2631
2632
  }
2632
2633
  if (values["gui-thread"] || values["gui-message-file"] || values["gui-status"]) {
2633
- const channel = new GuiChannel(join10(homedir4(), ".agentschat/codex-gui-outbox"), values["gui-thread"] ? [values["gui-thread"]] : []);
2634
+ const channel = new GuiChannel(join10(homedir5(), ".agentschat/codex-gui-outbox"), values["gui-thread"] ? [values["gui-thread"]] : []);
2634
2635
  if (values["gui-status"]) {
2635
2636
  console.log(JSON.stringify(channel.list().map(({ prompt: prompt2, ...receipt2 }) => receipt2)));
2636
2637
  return;
package/dist/connector.js CHANGED
@@ -541,8 +541,9 @@ function peekPayload(token) {
541
541
  import { join } from "node:path";
542
542
 
543
543
  // src/redact.ts
544
- function redactSecrets(text) {
545
- return text.replace(/ac_[A-Za-z0-9_-]{16,}/g, "ac_***REDACTED***").replace(/eyJ[A-Za-z0-9_-]{20,}\.[A-Za-z0-9_-]+\.[A-Za-z0-9_-]+/g, "***JWT_REDACTED***");
544
+ function redactSecrets(text, opts) {
545
+ const step = opts?.preserveAcKeys ? text : text.replace(/ac_[A-Za-z0-9_-]{16,}/g, "ac_***REDACTED***");
546
+ return step.replace(/eyJ[A-Za-z0-9_-]{20,}\.[A-Za-z0-9_-]+\.[A-Za-z0-9_-]+/g, "***JWT_REDACTED***");
546
547
  }
547
548
 
548
549
  // src/read-cursor.ts