@cotal-ai/connector-claude-code 0.6.0 → 0.8.0
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/dist/extension.d.ts.map +1 -1
- package/dist/extension.js +8 -3
- package/dist/extension.js.map +1 -1
- package/dist/hook.cjs +18 -13
- package/dist/mcp.cjs +180 -44
- package/dist/mcp.js +2 -2
- package/dist/mcp.js.map +1 -1
- package/package.json +3 -3
package/dist/extension.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"extension.d.ts","sourceRoot":"","sources":["../src/extension.ts"],"names":[],"mappings":"AAIA,OAAO,EAA2B,KAAK,SAAS,EAAoC,MAAM,gBAAgB,CAAC;AAoB3G;;;;;GAKG;AACH,eAAO,MAAM,eAAe,EAAE,
|
|
1
|
+
{"version":3,"file":"extension.d.ts","sourceRoot":"","sources":["../src/extension.ts"],"names":[],"mappings":"AAIA,OAAO,EAA2B,KAAK,SAAS,EAAoC,MAAM,gBAAgB,CAAC;AAoB3G;;;;;GAKG;AACH,eAAO,MAAM,eAAe,EAAE,SAgG7B,CAAC"}
|
package/dist/extension.js
CHANGED
|
@@ -3,7 +3,7 @@ import { tmpdir } from "node:os";
|
|
|
3
3
|
import { join, resolve } from "node:path";
|
|
4
4
|
import { fileURLToPath } from "node:url";
|
|
5
5
|
import { loadAgentFile, registry } from "@cotal-ai/core";
|
|
6
|
-
import { launchEnv, mcpServerEnvKeys } from "@cotal-ai/connector-core";
|
|
6
|
+
import { aclEnv, launchEnv, mcpServerEnvKeys } from "@cotal-ai/connector-core";
|
|
7
7
|
/** Name the cotal MCP server is registered under via --mcp-config (see buildLaunch). */
|
|
8
8
|
const MCP_SERVER_NAME = "cotal";
|
|
9
9
|
/** Channel ref for `--dangerously-load-development-channels`, which turns on the cotal MCP server's
|
|
@@ -29,6 +29,7 @@ export const claudeConnector = {
|
|
|
29
29
|
kind: "connector",
|
|
30
30
|
name: "claude",
|
|
31
31
|
pluginRoot: PLUGIN_ROOT,
|
|
32
|
+
requires: ["claude"],
|
|
32
33
|
buildLaunch(opts) {
|
|
33
34
|
// Operator MCP servers shared with this agent (default none — see the --mcp-config block).
|
|
34
35
|
const shared = opts.mcpServers ?? {};
|
|
@@ -38,6 +39,7 @@ export const claudeConnector = {
|
|
|
38
39
|
// by name). The operator's unrelated secrets don't reach the child (P3).
|
|
39
40
|
const env = {
|
|
40
41
|
...launchEnv({ mcpKeys: mcpServerEnvKeys(shared) }),
|
|
42
|
+
...aclEnv(opts),
|
|
41
43
|
COTAL_SPACE: opts.space,
|
|
42
44
|
COTAL_NAME: opts.name,
|
|
43
45
|
// Force the connector to emit channel wake-nudges: Claude doesn't advertise the
|
|
@@ -101,15 +103,18 @@ export const claudeConnector = {
|
|
|
101
103
|
args.push("--strict-mcp-config", "--mcp-config", mcpConfig);
|
|
102
104
|
// An agent file carries identity (read in-session via COTAL_AGENT_FILE) plus
|
|
103
105
|
// persona + model, which can only be applied to a `claude` session at launch.
|
|
106
|
+
let model = opts.model;
|
|
104
107
|
if (opts.configPath) {
|
|
105
108
|
const path = resolve(opts.configPath);
|
|
106
109
|
env.COTAL_AGENT_FILE = path;
|
|
107
110
|
const def = loadAgentFile(path);
|
|
108
111
|
if (def.persona)
|
|
109
112
|
args.push("--append-system-prompt", def.persona);
|
|
110
|
-
|
|
111
|
-
args.push("--model", def.model);
|
|
113
|
+
model ??= def.model;
|
|
112
114
|
}
|
|
115
|
+
// The `--model` flag wins over the agent file, and applies even with no agent file.
|
|
116
|
+
if (model)
|
|
117
|
+
args.push("--model", model);
|
|
113
118
|
return {
|
|
114
119
|
command: "claude",
|
|
115
120
|
args,
|
package/dist/extension.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"extension.js","sourceRoot":"","sources":["../src/extension.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AACrD,OAAO,E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,CAAC,CAAC;YACtC,GAAG,CAAC,gBAAgB,GAAG,IAAI,CAAC;YAC5B,MAAM,GAAG,GAAG,aAAa,CAAC,IAAI,CAAC,CAAC;YAChC,IAAI,GAAG,CAAC,OAAO;gBAAE,IAAI,CAAC,IAAI,CAAC,wBAAwB,EAAE,GAAG,CAAC,OAAO,CAAC,CAAC;YAClE,KAAK,KAAK,GAAG,CAAC,KAAK,CAAC;QACtB,CAAC;QACD,oFAAoF;QACpF,IAAI,KAAK;YAAE,IAAI,CAAC,IAAI,CAAC,SAAS,EAAE,KAAK,CAAC,CAAC;QAEvC,OAAO;YACL,OAAO,EAAE,QAAQ;YACjB,IAAI;YACJ,GAAG;YACH,wEAAwE;YACxE,yEAAyE;YACzE,OAAO,EAAE,kBAAkB;SAC5B,CAAC;IACJ,CAAC;CACF,CAAC;AAEF,QAAQ,CAAC,QAAQ,CAAC,eAAe,CAAC,CAAC"}
|
package/dist/hook.cjs
CHANGED
|
@@ -6421,7 +6421,7 @@ var require_authenticator = __commonJS({
|
|
|
6421
6421
|
exports2.tokenAuthenticator = tokenAuthenticator;
|
|
6422
6422
|
exports2.nkeyAuthenticator = nkeyAuthenticator;
|
|
6423
6423
|
exports2.jwtAuthenticator = jwtAuthenticator;
|
|
6424
|
-
exports2.credsAuthenticator =
|
|
6424
|
+
exports2.credsAuthenticator = credsAuthenticator7;
|
|
6425
6425
|
var nkeys_1 = require_nkeys2();
|
|
6426
6426
|
var encoders_1 = require_encoders();
|
|
6427
6427
|
function multiAuthenticator(authenticators) {
|
|
@@ -6471,7 +6471,7 @@ var require_authenticator = __commonJS({
|
|
|
6471
6471
|
return { jwt, nkey, sig };
|
|
6472
6472
|
};
|
|
6473
6473
|
}
|
|
6474
|
-
function
|
|
6474
|
+
function credsAuthenticator7(creds) {
|
|
6475
6475
|
const fn = typeof creds !== "function" ? () => creds : creds;
|
|
6476
6476
|
const parse = () => {
|
|
6477
6477
|
const CREDS = /\s*(?:(?:[-]{3,}[^\n]*[-]{3,}\n)(.+)(?:\n\s*[-]{3,}[^\n]*[-]{3,}\n))/ig;
|
|
@@ -13601,11 +13601,11 @@ var require_connect = __commonJS({
|
|
|
13601
13601
|
"../../node_modules/.pnpm/@nats-io+transport-node@3.4.0/node_modules/@nats-io/transport-node/lib/connect.js"(exports2) {
|
|
13602
13602
|
"use strict";
|
|
13603
13603
|
Object.defineProperty(exports2, "__esModule", { value: true });
|
|
13604
|
-
exports2.connect =
|
|
13604
|
+
exports2.connect = connect8;
|
|
13605
13605
|
var node_transport_1 = require_node_transport();
|
|
13606
13606
|
var nats_base_client_1 = require_nats_base_client();
|
|
13607
13607
|
var nats_base_client_2 = require_nats_base_client();
|
|
13608
|
-
function
|
|
13608
|
+
function connect8(opts = {}) {
|
|
13609
13609
|
if ((0, nats_base_client_2.hasWsProtocol)(opts)) {
|
|
13610
13610
|
return Promise.reject(nats_base_client_2.errors.InvalidArgumentError.format(`servers`, `node client doesn't support websockets, use the 'wsconnect' function instead`));
|
|
13611
13611
|
}
|
|
@@ -13797,7 +13797,7 @@ var require_kv = __commonJS({
|
|
|
13797
13797
|
throw new Error(`invalid bucket name: ${name}`);
|
|
13798
13798
|
}
|
|
13799
13799
|
}
|
|
13800
|
-
var
|
|
13800
|
+
var Kvm9 = class {
|
|
13801
13801
|
js;
|
|
13802
13802
|
/**
|
|
13803
13803
|
* Creates an instance of the Kv that allows you to create and access KV stores.
|
|
@@ -13863,7 +13863,7 @@ var require_kv = __commonJS({
|
|
|
13863
13863
|
return new internal_2.ListerImpl(subj, filter, this.js);
|
|
13864
13864
|
}
|
|
13865
13865
|
};
|
|
13866
|
-
exports2.Kvm =
|
|
13866
|
+
exports2.Kvm = Kvm9;
|
|
13867
13867
|
var Bucket = class _Bucket {
|
|
13868
13868
|
js;
|
|
13869
13869
|
jsm;
|
|
@@ -16415,6 +16415,7 @@ var import_jetstream = __toESM(require_mod4(), 1);
|
|
|
16415
16415
|
var import_transport_node = __toESM(require_transport_node(), 1);
|
|
16416
16416
|
var import_kv = __toESM(require_mod6(), 1);
|
|
16417
16417
|
var PLANE3_DEDUP_WINDOW_MS = 2 * 60 * 60 * 1e3;
|
|
16418
|
+
var MEMBERSHIP_MAX_BYTES = 64 * 1024 * 1024;
|
|
16418
16419
|
|
|
16419
16420
|
// ../../packages/core/dist/channels.js
|
|
16420
16421
|
var import_kv2 = __toESM(require_mod6(), 1);
|
|
@@ -16426,9 +16427,13 @@ var import_kv3 = __toESM(require_mod6(), 1);
|
|
|
16426
16427
|
// ../../packages/core/dist/acls.js
|
|
16427
16428
|
var import_kv4 = __toESM(require_mod6(), 1);
|
|
16428
16429
|
|
|
16429
|
-
// ../../packages/core/dist/
|
|
16430
|
-
var import_kv5 = __toESM(require_mod6(), 1);
|
|
16430
|
+
// ../../packages/core/dist/membership-feed.js
|
|
16431
16431
|
var import_transport_node3 = __toESM(require_transport_node(), 1);
|
|
16432
|
+
var import_kv5 = __toESM(require_mod6(), 1);
|
|
16433
|
+
|
|
16434
|
+
// ../../packages/core/dist/lease.js
|
|
16435
|
+
var import_kv6 = __toESM(require_mod6(), 1);
|
|
16436
|
+
var import_transport_node4 = __toESM(require_transport_node(), 1);
|
|
16432
16437
|
|
|
16433
16438
|
// ../../packages/core/dist/agent-file.js
|
|
16434
16439
|
var import_node_fs = require("node:fs");
|
|
@@ -16543,15 +16548,15 @@ function loadAgentFile(path) {
|
|
|
16543
16548
|
}
|
|
16544
16549
|
|
|
16545
16550
|
// ../../packages/core/dist/endpoint.js
|
|
16546
|
-
var
|
|
16551
|
+
var import_transport_node5 = __toESM(require_transport_node(), 1);
|
|
16547
16552
|
var import_jetstream2 = __toESM(require_mod4(), 1);
|
|
16548
|
-
var
|
|
16553
|
+
var import_kv7 = __toESM(require_mod6(), 1);
|
|
16549
16554
|
var DEFAULT_SERVER = "nats://127.0.0.1:4222";
|
|
16550
16555
|
|
|
16551
16556
|
// ../../packages/core/dist/spaces.js
|
|
16552
|
-
var
|
|
16557
|
+
var import_transport_node6 = __toESM(require_transport_node(), 1);
|
|
16553
16558
|
var import_jetstream3 = __toESM(require_mod4(), 1);
|
|
16554
|
-
var
|
|
16559
|
+
var import_kv8 = __toESM(require_mod6(), 1);
|
|
16555
16560
|
|
|
16556
16561
|
// ../../packages/core/dist/registry.js
|
|
16557
16562
|
var Registry = class {
|
|
@@ -16635,7 +16640,7 @@ function configFromEnv(env = process.env) {
|
|
|
16635
16640
|
subscribe: resolvedSubscribe,
|
|
16636
16641
|
allowSubscribe: resolvedAllowSub,
|
|
16637
16642
|
// Post ACL is default-DENY: only what's explicitly declared (env > agent-file). The broker
|
|
16638
|
-
// enforces it under auth; in open mode posting is unrestricted regardless
|
|
16643
|
+
// enforces it under auth; in open mode posting is unrestricted regardless.
|
|
16639
16644
|
allowPublish: resolvedAllowPub,
|
|
16640
16645
|
quiet: resolvedQuiet,
|
|
16641
16646
|
muted: resolvedMuted,
|
package/dist/mcp.cjs
CHANGED
|
@@ -13281,7 +13281,7 @@ var require_authenticator = __commonJS({
|
|
|
13281
13281
|
exports2.tokenAuthenticator = tokenAuthenticator;
|
|
13282
13282
|
exports2.nkeyAuthenticator = nkeyAuthenticator;
|
|
13283
13283
|
exports2.jwtAuthenticator = jwtAuthenticator;
|
|
13284
|
-
exports2.credsAuthenticator =
|
|
13284
|
+
exports2.credsAuthenticator = credsAuthenticator7;
|
|
13285
13285
|
var nkeys_1 = require_nkeys2();
|
|
13286
13286
|
var encoders_1 = require_encoders();
|
|
13287
13287
|
function multiAuthenticator(authenticators) {
|
|
@@ -13331,7 +13331,7 @@ var require_authenticator = __commonJS({
|
|
|
13331
13331
|
return { jwt: jwt2, nkey, sig };
|
|
13332
13332
|
};
|
|
13333
13333
|
}
|
|
13334
|
-
function
|
|
13334
|
+
function credsAuthenticator7(creds) {
|
|
13335
13335
|
const fn = typeof creds !== "function" ? () => creds : creds;
|
|
13336
13336
|
const parse3 = () => {
|
|
13337
13337
|
const CREDS = /\s*(?:(?:[-]{3,}[^\n]*[-]{3,}\n)(.+)(?:\n\s*[-]{3,}[^\n]*[-]{3,}\n))/ig;
|
|
@@ -20461,11 +20461,11 @@ var require_connect = __commonJS({
|
|
|
20461
20461
|
"../../node_modules/.pnpm/@nats-io+transport-node@3.4.0/node_modules/@nats-io/transport-node/lib/connect.js"(exports2) {
|
|
20462
20462
|
"use strict";
|
|
20463
20463
|
Object.defineProperty(exports2, "__esModule", { value: true });
|
|
20464
|
-
exports2.connect =
|
|
20464
|
+
exports2.connect = connect7;
|
|
20465
20465
|
var node_transport_1 = require_node_transport();
|
|
20466
20466
|
var nats_base_client_1 = require_nats_base_client();
|
|
20467
20467
|
var nats_base_client_2 = require_nats_base_client();
|
|
20468
|
-
function
|
|
20468
|
+
function connect7(opts = {}) {
|
|
20469
20469
|
if ((0, nats_base_client_2.hasWsProtocol)(opts)) {
|
|
20470
20470
|
return Promise.reject(nats_base_client_2.errors.InvalidArgumentError.format(`servers`, `node client doesn't support websockets, use the 'wsconnect' function instead`));
|
|
20471
20471
|
}
|
|
@@ -20657,7 +20657,7 @@ var require_kv = __commonJS({
|
|
|
20657
20657
|
throw new Error(`invalid bucket name: ${name}`);
|
|
20658
20658
|
}
|
|
20659
20659
|
}
|
|
20660
|
-
var
|
|
20660
|
+
var Kvm9 = class {
|
|
20661
20661
|
js;
|
|
20662
20662
|
/**
|
|
20663
20663
|
* Creates an instance of the Kv that allows you to create and access KV stores.
|
|
@@ -20723,7 +20723,7 @@ var require_kv = __commonJS({
|
|
|
20723
20723
|
return new internal_2.ListerImpl(subj, filter, this.js);
|
|
20724
20724
|
}
|
|
20725
20725
|
};
|
|
20726
|
-
exports2.Kvm =
|
|
20726
|
+
exports2.Kvm = Kvm9;
|
|
20727
20727
|
var Bucket = class _Bucket {
|
|
20728
20728
|
js;
|
|
20729
20729
|
jsm;
|
|
@@ -45764,6 +45764,10 @@ function aclBucket(space) {
|
|
|
45764
45764
|
function aclKey(owner) {
|
|
45765
45765
|
return token(owner);
|
|
45766
45766
|
}
|
|
45767
|
+
function membershipBucket(space) {
|
|
45768
|
+
return `cotal_membership_${token(space)}`;
|
|
45769
|
+
}
|
|
45770
|
+
var MEMBERSHIP_FEED_KEY = "=feed";
|
|
45767
45771
|
function deliveryBucket(space) {
|
|
45768
45772
|
return `cotal_delivery_${token(space)}`;
|
|
45769
45773
|
}
|
|
@@ -47527,6 +47531,7 @@ var import_kv = __toESM(require_mod6(), 1);
|
|
|
47527
47531
|
var MAX_MSGS_PER_SUBJECT = 1e3;
|
|
47528
47532
|
var PLANE3_DEDUP_WINDOW_MS = 2 * 60 * 60 * 1e3;
|
|
47529
47533
|
var DINBOX_MAX_ACK_PENDING = 1e3;
|
|
47534
|
+
var MEMBERSHIP_MAX_BYTES = 64 * 1024 * 1024;
|
|
47530
47535
|
async function createSpaceStreams(jsm, space) {
|
|
47531
47536
|
const p = spacePrefix(space);
|
|
47532
47537
|
await jsm.streams.add({
|
|
@@ -47823,11 +47828,15 @@ async function commitAcl(kv, owner, allowSubscribe) {
|
|
|
47823
47828
|
throw new Error(`acl CAS exhausted retries for ${owner}`);
|
|
47824
47829
|
}
|
|
47825
47830
|
|
|
47826
|
-
// ../../packages/core/dist/
|
|
47827
|
-
var import_kv5 = __toESM(require_mod6(), 1);
|
|
47831
|
+
// ../../packages/core/dist/membership-feed.js
|
|
47828
47832
|
var import_transport_node3 = __toESM(require_transport_node(), 1);
|
|
47833
|
+
var import_kv5 = __toESM(require_mod6(), 1);
|
|
47834
|
+
|
|
47835
|
+
// ../../packages/core/dist/lease.js
|
|
47836
|
+
var import_kv6 = __toESM(require_mod6(), 1);
|
|
47837
|
+
var import_transport_node4 = __toESM(require_transport_node(), 1);
|
|
47829
47838
|
async function openDeliveryRegistry(nc, space) {
|
|
47830
|
-
return new
|
|
47839
|
+
return new import_kv6.Kvm(nc).open(deliveryBucket(space));
|
|
47831
47840
|
}
|
|
47832
47841
|
|
|
47833
47842
|
// ../../packages/core/dist/agent-file.js
|
|
@@ -47945,9 +47954,9 @@ function loadAgentFile(path) {
|
|
|
47945
47954
|
// ../../packages/core/dist/endpoint.js
|
|
47946
47955
|
var import_node_events = require("node:events");
|
|
47947
47956
|
var import_node_crypto = require("node:crypto");
|
|
47948
|
-
var
|
|
47957
|
+
var import_transport_node5 = __toESM(require_transport_node(), 1);
|
|
47949
47958
|
var import_jetstream2 = __toESM(require_mod4(), 1);
|
|
47950
|
-
var
|
|
47959
|
+
var import_kv7 = __toESM(require_mod6(), 1);
|
|
47951
47960
|
var DEFAULT_SERVER = "nats://127.0.0.1:4222";
|
|
47952
47961
|
var READER_MAX_REDELIVERIES = 10;
|
|
47953
47962
|
var CotalEndpoint = class extends import_node_events.EventEmitter {
|
|
@@ -47977,6 +47986,7 @@ var CotalEndpoint = class extends import_node_events.EventEmitter {
|
|
|
47977
47986
|
membersKv;
|
|
47978
47987
|
aclKv;
|
|
47979
47988
|
deliveryKv;
|
|
47989
|
+
membershipKv;
|
|
47980
47990
|
/** The live `ctl.delivery` serve subscription (delivery daemon) — re-created on every (re)connect by
|
|
47981
47991
|
* {@link armDeliveryControl}; tracked so the stale one is dropped on reconnect. */
|
|
47982
47992
|
deliveryServeSub;
|
|
@@ -48095,7 +48105,7 @@ var CotalEndpoint = class extends import_node_events.EventEmitter {
|
|
|
48095
48105
|
* idempotent (durables bind by name, JetStream dedups by msgID, KV opens are idempotent). */
|
|
48096
48106
|
async connectAndBind() {
|
|
48097
48107
|
this.clearConnectionScoped();
|
|
48098
|
-
this.nc = await (0,
|
|
48108
|
+
this.nc = await (0, import_transport_node5.connect)({
|
|
48099
48109
|
servers: this.servers,
|
|
48100
48110
|
name: `cotal:${this.card.name}`,
|
|
48101
48111
|
// Per-identity inbox namespace (the "Private Inbox" pattern). nats.js routes ALL
|
|
@@ -48109,7 +48119,7 @@ var CotalEndpoint = class extends import_node_events.EventEmitter {
|
|
|
48109
48119
|
this.watchStatus();
|
|
48110
48120
|
this.js = (0, import_jetstream2.jetstream)(this.nc);
|
|
48111
48121
|
if (this.doWatch || this.doRegister) {
|
|
48112
|
-
const kvm = new
|
|
48122
|
+
const kvm = new import_kv7.Kvm(this.nc);
|
|
48113
48123
|
this.kv = this.creds ? await kvm.open(presenceBucket(this.space)) : await kvm.create(presenceBucket(this.space), { ttl: this.ttlMs });
|
|
48114
48124
|
}
|
|
48115
48125
|
if (this.doWatch) {
|
|
@@ -48651,6 +48661,57 @@ var CotalEndpoint = class extends import_node_events.EventEmitter {
|
|
|
48651
48661
|
arr.sort(byName);
|
|
48652
48662
|
return map2;
|
|
48653
48663
|
}
|
|
48664
|
+
/** Lazily open the derived membership feed KV (admin/observer read; the delivery daemon writes it).
|
|
48665
|
+
* Read-only here — the dashboard consumes it; agents hold no grant and never call this. */
|
|
48666
|
+
async membershipRegistry() {
|
|
48667
|
+
if (!this.nc)
|
|
48668
|
+
throw new Error("endpoint not started");
|
|
48669
|
+
this.membershipKv ??= await new import_kv7.Kvm(this.nc).open(membershipBucket(this.space));
|
|
48670
|
+
return this.membershipKv;
|
|
48671
|
+
}
|
|
48672
|
+
/**
|
|
48673
|
+
* Snapshot the broker-sourced channel-membership feed (admin/observer read): every agent's
|
|
48674
|
+
* `{live, durable}` record plus `asOf` — the feed's freshness heartbeat (epoch ms of the daemon's last
|
|
48675
|
+
* successful poll, from the reserved {@link MEMBERSHIP_FEED_KEY}). `live` patterns are kept as-is
|
|
48676
|
+
* (wildcards preserved); the consumer expands them against the channel registry. `asOf` is undefined
|
|
48677
|
+
* when the feed has never been written (no daemon → the dashboard degrades to traffic-only).
|
|
48678
|
+
*/
|
|
48679
|
+
async readMembership() {
|
|
48680
|
+
const kv = await this.membershipRegistry();
|
|
48681
|
+
const members = [];
|
|
48682
|
+
let asOf;
|
|
48683
|
+
for await (const key of await kv.keys()) {
|
|
48684
|
+
const e = await kv.get(key);
|
|
48685
|
+
if (!e || e.operation === "DEL" || e.operation === "PURGE")
|
|
48686
|
+
continue;
|
|
48687
|
+
if (key === MEMBERSHIP_FEED_KEY) {
|
|
48688
|
+
try {
|
|
48689
|
+
asOf = e.json().observedAt;
|
|
48690
|
+
} catch {
|
|
48691
|
+
}
|
|
48692
|
+
continue;
|
|
48693
|
+
}
|
|
48694
|
+
try {
|
|
48695
|
+
const rec = e.json();
|
|
48696
|
+
members.push({ id: key, live: rec.live ?? [], durable: rec.durable ?? [], observedAt: rec.observedAt });
|
|
48697
|
+
} catch {
|
|
48698
|
+
}
|
|
48699
|
+
}
|
|
48700
|
+
return { asOf, members };
|
|
48701
|
+
}
|
|
48702
|
+
/** Watch the membership feed for changes (admin/observer): `onChange` fires on every KV entry,
|
|
48703
|
+
* including the initial replay — the caller debounces + re-reads {@link readMembership}. Returns a
|
|
48704
|
+
* stop handle. Best-effort: a feed the cred can't read (or absent) surfaces as an `error` event and
|
|
48705
|
+
* the dashboard keeps its last snapshot. */
|
|
48706
|
+
async watchMembership(onChange) {
|
|
48707
|
+
const kv = await this.membershipRegistry();
|
|
48708
|
+
const iter = await kv.watch();
|
|
48709
|
+
void (async () => {
|
|
48710
|
+
for await (const _ of iter)
|
|
48711
|
+
onChange();
|
|
48712
|
+
})().catch((err2) => this.emit("error", err2));
|
|
48713
|
+
return { stop: () => iter.stop() };
|
|
48714
|
+
}
|
|
48654
48715
|
/** Fetch recent messages from a channel's JetStream backlog. */
|
|
48655
48716
|
async channelHistory(channel, opts) {
|
|
48656
48717
|
return this.streamHistory(chatStream(this.space), chatSubject(this.space, "*", channel), opts?.limit ?? 100);
|
|
@@ -48701,7 +48762,7 @@ var CotalEndpoint = class extends import_node_events.EventEmitter {
|
|
|
48701
48762
|
for await (const s of this.nc.status()) {
|
|
48702
48763
|
if (s.type !== "error")
|
|
48703
48764
|
continue;
|
|
48704
|
-
if (s.error instanceof
|
|
48765
|
+
if (s.error instanceof import_transport_node5.PermissionViolationError && this.confirmingChatSubs.has(s.error.subject))
|
|
48705
48766
|
continue;
|
|
48706
48767
|
this.emit("error", describeStatusError(s.error));
|
|
48707
48768
|
}
|
|
@@ -48974,7 +49035,7 @@ var CotalEndpoint = class extends import_node_events.EventEmitter {
|
|
|
48974
49035
|
filter_subject: subject,
|
|
48975
49036
|
ack_policy: import_jetstream2.AckPolicy.None,
|
|
48976
49037
|
mem_storage: true,
|
|
48977
|
-
inactive_threshold: (0,
|
|
49038
|
+
inactive_threshold: (0, import_transport_node5.nanos)(3e4),
|
|
48978
49039
|
deliver_policy: import_jetstream2.DeliverPolicy.StartSequence,
|
|
48979
49040
|
opt_start_seq: fromSeqExcl + 1
|
|
48980
49041
|
});
|
|
@@ -49374,7 +49435,7 @@ var CotalEndpoint = class extends import_node_events.EventEmitter {
|
|
|
49374
49435
|
* distinct from a responder that errored. nats.js surfaces it as NoRespondersError, or a RequestError
|
|
49375
49436
|
* whose `isNoResponders()` is true. */
|
|
49376
49437
|
isNoResponders(e) {
|
|
49377
|
-
return e instanceof
|
|
49438
|
+
return e instanceof import_transport_node5.NoRespondersError || e instanceof import_transport_node5.RequestError && e.isNoResponders();
|
|
49378
49439
|
}
|
|
49379
49440
|
/** Agent-side: this session's CURRENT durable memberships (channel + join generation) from the
|
|
49380
49441
|
* manager — the agent holds no read on the privileged members KV. `undefined` ⇒ NO control responder
|
|
@@ -49717,7 +49778,7 @@ var CotalEndpoint = class extends import_node_events.EventEmitter {
|
|
|
49717
49778
|
filter_subject: subject,
|
|
49718
49779
|
ack_policy: import_jetstream2.AckPolicy.None,
|
|
49719
49780
|
mem_storage: true,
|
|
49720
|
-
inactive_threshold: (0,
|
|
49781
|
+
inactive_threshold: (0, import_transport_node5.nanos)(3e4),
|
|
49721
49782
|
..."time" in start ? { deliver_policy: import_jetstream2.DeliverPolicy.StartTime, opt_start_time: start.time.toISOString() } : { deliver_policy: import_jetstream2.DeliverPolicy.StartSequence, opt_start_seq: start.seq }
|
|
49722
49783
|
});
|
|
49723
49784
|
try {
|
|
@@ -49866,7 +49927,7 @@ var CotalEndpoint = class extends import_node_events.EventEmitter {
|
|
|
49866
49927
|
}
|
|
49867
49928
|
}
|
|
49868
49929
|
async publishPresence() {
|
|
49869
|
-
if (!this.kv)
|
|
49930
|
+
if (!this.doRegister || !this.kv)
|
|
49870
49931
|
return;
|
|
49871
49932
|
const p = {
|
|
49872
49933
|
card: this.card,
|
|
@@ -50007,28 +50068,28 @@ function authOpts(a) {
|
|
|
50007
50068
|
if (a.creds) {
|
|
50008
50069
|
if (a.token || a.user || a.pass)
|
|
50009
50070
|
throw new Error("creds are mutually exclusive with token/user/pass auth");
|
|
50010
|
-
return { authenticator: (0,
|
|
50071
|
+
return { authenticator: (0, import_transport_node5.credsAuthenticator)(new TextEncoder().encode(a.creds)), tls };
|
|
50011
50072
|
}
|
|
50012
50073
|
return { token: a.token, user: a.user, pass: a.pass, tls };
|
|
50013
50074
|
}
|
|
50014
50075
|
function describeStatusError(err2) {
|
|
50015
|
-
if (err2 instanceof
|
|
50076
|
+
if (err2 instanceof import_transport_node5.PermissionViolationError) {
|
|
50016
50077
|
return new Error(`NATS permission denied: cannot ${err2.operation} "${err2.subject}" \u2014 check this endpoint's ACLs (a denied peer looks "absent" rather than blocked)`, { cause: err2 });
|
|
50017
50078
|
}
|
|
50018
50079
|
return err2;
|
|
50019
50080
|
}
|
|
50020
50081
|
function isPermissionDenied(e) {
|
|
50021
|
-
if (e instanceof
|
|
50082
|
+
if (e instanceof import_transport_node5.PermissionViolationError)
|
|
50022
50083
|
return true;
|
|
50023
|
-
if (e?.cause instanceof
|
|
50084
|
+
if (e?.cause instanceof import_transport_node5.PermissionViolationError)
|
|
50024
50085
|
return true;
|
|
50025
50086
|
return /permissions?\s+violation/i.test(String(e?.message ?? ""));
|
|
50026
50087
|
}
|
|
50027
50088
|
|
|
50028
50089
|
// ../../packages/core/dist/spaces.js
|
|
50029
|
-
var
|
|
50090
|
+
var import_transport_node6 = __toESM(require_transport_node(), 1);
|
|
50030
50091
|
var import_jetstream3 = __toESM(require_mod4(), 1);
|
|
50031
|
-
var
|
|
50092
|
+
var import_kv8 = __toESM(require_mod6(), 1);
|
|
50032
50093
|
|
|
50033
50094
|
// ../../packages/core/dist/registry.js
|
|
50034
50095
|
var Registry = class {
|
|
@@ -50114,7 +50175,7 @@ function configFromEnv(env = process.env) {
|
|
|
50114
50175
|
subscribe: resolvedSubscribe,
|
|
50115
50176
|
allowSubscribe: resolvedAllowSub,
|
|
50116
50177
|
// Post ACL is default-DENY: only what's explicitly declared (env > agent-file). The broker
|
|
50117
|
-
// enforces it under auth; in open mode posting is unrestricted regardless
|
|
50178
|
+
// enforces it under auth; in open mode posting is unrestricted regardless.
|
|
50118
50179
|
allowPublish: resolvedAllowPub,
|
|
50119
50180
|
quiet: resolvedQuiet,
|
|
50120
50181
|
muted: resolvedMuted,
|
|
@@ -50127,17 +50188,6 @@ function configFromEnv(env = process.env) {
|
|
|
50127
50188
|
feedbackUrl: env.COTAL_FEEDBACK_URL?.trim() || void 0
|
|
50128
50189
|
};
|
|
50129
50190
|
}
|
|
50130
|
-
function laneLine(config2) {
|
|
50131
|
-
const fmt = (cs) => cs.map((c) => `#${c}`).join(", ");
|
|
50132
|
-
const subs = config2.subscribe;
|
|
50133
|
-
if (!config2.creds)
|
|
50134
|
-
return `You read and may post to ${fmt(subs)}. `;
|
|
50135
|
-
const pubs = config2.allowPublish;
|
|
50136
|
-
if (!pubs.length)
|
|
50137
|
-
return `You read ${fmt(subs)}; you may not post to any channel (no publish channels granted). `;
|
|
50138
|
-
const same = subs.length === pubs.length && subs.every((c) => pubs.includes(c));
|
|
50139
|
-
return same ? `You read and may post to ${fmt(subs)}. ` : `You read ${fmt(subs)}; you may post only to ${fmt(pubs)} (posts to other channels are rejected). `;
|
|
50140
|
-
}
|
|
50141
50191
|
function feedbackLine(config2) {
|
|
50142
50192
|
const dest = config2.feedbackKey ? "" : `Without a feedback key it goes to the public cotal.ai intake and needs a contact email \u2014 the tool will tell you to ask the user for one if it can't find it. `;
|
|
50143
50193
|
return `Use cotal_feedback with origin="human" when the user asks you to send feedback or gives you feedback to pass along. If you independently hit a major Cotal issue \u2014 for example repeated Cotal tool failures, inability to connect, lost/incorrect mesh messages, or a workflow-blocking bug \u2014 send cotal_feedback yourself with origin="agent". Do not send minor noise or secrets; include diagnostics only when they help debug the Cotal issue. ` + dest;
|
|
@@ -50507,10 +50557,16 @@ var MeshAgent = class extends import_node_events2.EventEmitter {
|
|
|
50507
50557
|
// ---- supervision ---------------------------------------------------------
|
|
50508
50558
|
/** Ask the manager to spawn a new teammate into this space (its `start` op).
|
|
50509
50559
|
* How it lands — a detached PTY, a tmux window, a cmux tab — is the manager's
|
|
50510
|
-
* runtime; from here it just joins the mesh as a lateral peer.
|
|
50511
|
-
|
|
50560
|
+
* runtime; from here it just joins the mesh as a lateral peer. `opts.agent` picks
|
|
50561
|
+
* the harness (default the manager's `cotal`/Claude) and `opts.model` overrides the
|
|
50562
|
+
* persona file's `model:` — the same knobs the operator's `cotal start` carries, so
|
|
50563
|
+
* the agent and operator spawn doors share one control-op contract. */
|
|
50564
|
+
async spawn(name, role, opts) {
|
|
50512
50565
|
this.assertConnected();
|
|
50513
|
-
return this.ep.requestControl(CONTROL_PRIVILEGED, {
|
|
50566
|
+
return this.ep.requestControl(CONTROL_PRIVILEGED, {
|
|
50567
|
+
op: "start",
|
|
50568
|
+
args: { name, role, agent: opts?.agent, model: opts?.model }
|
|
50569
|
+
});
|
|
50514
50570
|
}
|
|
50515
50571
|
/** Ask the manager to tear a teammate down (its `stop` op). Graceful by default —
|
|
50516
50572
|
* the session is told to exit cleanly (so it leaves the mesh) before the
|
|
@@ -50698,6 +50754,69 @@ function controlSocketPath(space, name) {
|
|
|
50698
50754
|
|
|
50699
50755
|
// ../connector-core/dist/tool-specs.js
|
|
50700
50756
|
var import_node_child_process = require("node:child_process");
|
|
50757
|
+
|
|
50758
|
+
// ../connector-core/dist/orientation.js
|
|
50759
|
+
var ORIENTATION_BOOTSTRAP = "Start with cotal_orientation \u2014 it shows your identity, the channels you can read and post to, your capabilities, the tools available to you, and who's present.";
|
|
50760
|
+
var CORE_TOOLS = /* @__PURE__ */ new Set([
|
|
50761
|
+
"cotal_inbox",
|
|
50762
|
+
"cotal_send",
|
|
50763
|
+
"cotal_dm",
|
|
50764
|
+
"cotal_anycast",
|
|
50765
|
+
"cotal_roster",
|
|
50766
|
+
"cotal_status"
|
|
50767
|
+
]);
|
|
50768
|
+
function buildOrientation(agent, config2, visibleTools, generatedAt) {
|
|
50769
|
+
const core = [];
|
|
50770
|
+
const more = [];
|
|
50771
|
+
for (const t of visibleTools) {
|
|
50772
|
+
if (t.name === "cotal_orientation")
|
|
50773
|
+
continue;
|
|
50774
|
+
(CORE_TOOLS.has(t.name) ? core : more).push(t);
|
|
50775
|
+
}
|
|
50776
|
+
const peers = agent.roster().filter((p) => p.card.id !== agent.id);
|
|
50777
|
+
const shown = peers.slice(0, 8).map((p) => `${p.card.role ? `${p.card.name}/${p.card.role}` : p.card.name} (${p.status})`);
|
|
50778
|
+
const summary = peers.length ? shown.join(", ") + (peers.length > shown.length ? `, +${peers.length - shown.length} more` : "") : "no other peers present";
|
|
50779
|
+
return {
|
|
50780
|
+
v: 1,
|
|
50781
|
+
generatedAt,
|
|
50782
|
+
identity: { name: config2.name, role: config2.role, space: config2.space, id: agent.id },
|
|
50783
|
+
access: {
|
|
50784
|
+
authMode: !!config2.creds,
|
|
50785
|
+
read: config2.subscribe,
|
|
50786
|
+
readAcl: config2.allowSubscribe,
|
|
50787
|
+
post: config2.allowPublish
|
|
50788
|
+
},
|
|
50789
|
+
capabilities: config2.capabilities ?? [],
|
|
50790
|
+
tools: { core, more },
|
|
50791
|
+
peers: { present: peers.length, summary },
|
|
50792
|
+
status: agent.status,
|
|
50793
|
+
attention: agent.attention,
|
|
50794
|
+
unread: { total: agent.inboxCount() },
|
|
50795
|
+
actions: {
|
|
50796
|
+
read: "cotal_inbox",
|
|
50797
|
+
replyChannel: "cotal_send",
|
|
50798
|
+
replyPrivate: "cotal_dm",
|
|
50799
|
+
askRole: "cotal_anycast"
|
|
50800
|
+
}
|
|
50801
|
+
};
|
|
50802
|
+
}
|
|
50803
|
+
function renderOrientation(o) {
|
|
50804
|
+
const fmt = (cs) => cs.length ? cs.map((c) => `#${c}`).join(", ") : "\u2014";
|
|
50805
|
+
const who2 = o.identity.role ? `${o.identity.name}/${o.identity.role}` : o.identity.name;
|
|
50806
|
+
const aclDiffers = o.access.readAcl.length !== o.access.read.length || o.access.readAcl.some((c) => !o.access.read.includes(c));
|
|
50807
|
+
const lines = [
|
|
50808
|
+
`You are ${who2} in space "${o.identity.space}" (id ${o.identity.id.slice(0, 8)}\u2026).`,
|
|
50809
|
+
"",
|
|
50810
|
+
`Access \u2014 ${o.access.authMode ? "auth mode (grants are broker-enforced)" : "open mode (grants advisory, host-trusted)"}:`,
|
|
50811
|
+
` \u2022 read: ${fmt(o.access.read)}`
|
|
50812
|
+
];
|
|
50813
|
+
if (aclDiffers)
|
|
50814
|
+
lines.push(` \u2022 may join (read ACL): ${fmt(o.access.readAcl)}`);
|
|
50815
|
+
lines.push(` \u2022 post: ${o.access.post.length ? fmt(o.access.post) : "\u2014 (read-only; no post channels)"}`, ` \u2022 capabilities: ${o.capabilities.length ? o.capabilities.join(", ") : "none beyond defaults"}`, "", `Tools \u2014 core loop: ${o.tools.core.map((t) => t.name).join(", ") || "\u2014"}`, `Tools \u2014 more: ${o.tools.more.map((t) => t.name).join(", ") || "\u2014"}`, "", `Right now (snapshot @ ${new Date(o.generatedAt).toISOString()}):`, ` \u2022 status: ${o.status} \xB7 attention: ${o.attention}`, ` \u2022 peers present: ${o.peers.present} \u2014 ${o.peers.summary}`, ` \u2022 unread: ${o.unread.total}`, "", `Act \u2192 read: ${o.actions.read} \xB7 reply on a channel: ${o.actions.replyChannel} \xB7 private: ${o.actions.replyPrivate} \xB7 ask a role: ${o.actions.askRole}`);
|
|
50816
|
+
return lines.join("\n");
|
|
50817
|
+
}
|
|
50818
|
+
|
|
50819
|
+
// ../connector-core/dist/tool-specs.js
|
|
50701
50820
|
var ok = (text) => ({ text });
|
|
50702
50821
|
var err = (text) => ({ text, isError: true });
|
|
50703
50822
|
function controlFailure(action, e) {
|
|
@@ -50770,6 +50889,21 @@ function channelMeta(i) {
|
|
|
50770
50889
|
function cotalToolSpecs(config2, source = "connector") {
|
|
50771
50890
|
const canSpawn = !config2.creds || (config2.capabilities?.includes("spawn") ?? false);
|
|
50772
50891
|
const specs = [
|
|
50892
|
+
{
|
|
50893
|
+
name: "cotal_orientation",
|
|
50894
|
+
title: "Cotal: orient \u2014 who you are & what you can do",
|
|
50895
|
+
description: "Your orientation card: who you are (name/role/space), the channels you can read and post to, your capabilities, the tools available to you (grouped into a core loop plus the rest), who's present, your status/attention, and how many messages are unread. Call this first to get your bearings; it's read-only and safe to re-check anytime.",
|
|
50896
|
+
run(agent) {
|
|
50897
|
+
const visible = cotalToolSpecs(config2, source).map((s) => ({
|
|
50898
|
+
name: s.name,
|
|
50899
|
+
title: s.title
|
|
50900
|
+
}));
|
|
50901
|
+
const card = renderOrientation(buildOrientation(agent, config2, visible, Date.now()));
|
|
50902
|
+
return ok(agent.connected ? card : `(not connected to the mesh yet \u2014 the live context below is empty)
|
|
50903
|
+
|
|
50904
|
+
${card}`);
|
|
50905
|
+
}
|
|
50906
|
+
},
|
|
50773
50907
|
{
|
|
50774
50908
|
name: "cotal_roster",
|
|
50775
50909
|
title: "Cotal: who's present",
|
|
@@ -51017,12 +51151,14 @@ ${info}${caught}`);
|
|
|
51017
51151
|
title: "Cotal: spawn a new teammate",
|
|
51018
51152
|
description: "Ask the manager to start a new peer endpoint in your space. It joins the mesh as a lateral peer (and, when the manager runs the cmux runtime, appears in its own tab). Use when the team needs another agent.",
|
|
51019
51153
|
schema: {
|
|
51020
|
-
name: external_exports.string().describe("
|
|
51021
|
-
role: external_exports.string().optional().describe("Optional role for the new peer (e.g. worker, reviewer).")
|
|
51154
|
+
name: external_exports.string().describe("Which persona to spawn \u2014 the persona FILENAME in .cotal/agents (e.g. `review-critic`), without the .md. The new peer joins under the persona's own `name:` (auto-numbered, e.g. socrates-2, if that's taken). Fails if no such persona file exists \u2014 spawn an existing persona, don't invent a name."),
|
|
51155
|
+
role: external_exports.string().optional().describe("Optional role for the new peer (e.g. worker, reviewer); overrides the persona file's role."),
|
|
51156
|
+
agent: external_exports.string().optional().describe("Optional harness the new peer runs on \u2014 the agent/connector type (claude, opencode, hermes), NOT the persona to spawn (that's `name`). Defaults to the manager's default (Claude)."),
|
|
51157
|
+
model: external_exports.string().optional().describe("Optional model override (e.g. opus, sonnet) \u2014 wins over the persona file's model:.")
|
|
51022
51158
|
},
|
|
51023
|
-
async run(agent, _config, { name, role }) {
|
|
51159
|
+
async run(agent, _config, { name, role, agent: agentType, model }) {
|
|
51024
51160
|
try {
|
|
51025
|
-
const reply = await agent.spawn(name, role);
|
|
51161
|
+
const reply = await agent.spawn(name, role, { agent: agentType, model });
|
|
51026
51162
|
if (!reply.ok)
|
|
51027
51163
|
return err(`Couldn't spawn ${name}: ${reply.error ?? "manager refused"}`);
|
|
51028
51164
|
const d = reply.data;
|
|
@@ -51451,7 +51587,7 @@ async function main() {
|
|
|
51451
51587
|
// `claude/channel` makes this MCP server a Claude Code *channel*: peer
|
|
51452
51588
|
// messages can be pushed straight into the session (waking it if idle).
|
|
51453
51589
|
capabilities: { experimental: { "claude/channel": {} } },
|
|
51454
|
-
instructions: `You are connected to the Cotal mesh as "${config2.name}"${config2.role ? ` (role: ${config2.role})` : ""} in space "${config2.space}". ` +
|
|
51590
|
+
instructions: `You are connected to the Cotal mesh as "${config2.name}"${config2.role ? ` (role: ${config2.role})` : ""} in space "${config2.space}". ${ORIENTATION_BOOTSTRAP} ` + feedbackLine(config2) + `Other agents coordinate with you here as lateral peers. Peer messages may arrive as <channel source="cotal" from="<name>" role="<role>" kind="dm|channel|anycast" channel="<name>">\u2026</channel> \u2014 read them and, when a reply is warranted, respond with cotal_dm (back to that peer), cotal_send (to a channel), or cotal_anycast (to a role). Use cotal_roster to see who is present, cotal_inbox to pull anything you may have missed, and cotal_status to report what you are doing. If you need to concentrate, cotal_status also sets your attention \u2014 dnd (channel chatter stops waking you; it still arrives on your next turn) or focus (only DMs and @mentions reach your context \u2014 pull the held chatter with cotal_inbox). To silence one channel instead of all of them, cotal_channel_mode sets it quiet (still delivered + readable, never wakes you; @mentions still wake) or muted (you stop receiving it, @mentions included). Reply only when a reply is actually needed \u2014 a silent acknowledgement is correct; "agreed/thanks/good point" messages are noise. And @-mention a peer only when you need THAT specific peer to act: a mention wakes them, so mentioning in acknowledgements or sign-offs makes peers ping-pong wake-ups in an endless loop.`
|
|
51455
51591
|
}
|
|
51456
51592
|
);
|
|
51457
51593
|
registerCotalTools(server, agent, config2, "claude-code");
|
package/dist/mcp.js
CHANGED
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
*/
|
|
11
11
|
import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
|
|
12
12
|
import { StdioServerTransport } from "@modelcontextprotocol/sdk/server/stdio.js";
|
|
13
|
-
import { configFromEnv, hasIdentity, MeshAgent, controlSocketPath, startControlServer, registerCotalTools,
|
|
13
|
+
import { configFromEnv, hasIdentity, MeshAgent, controlSocketPath, startControlServer, registerCotalTools, feedbackLine, ORIENTATION_BOOTSTRAP, formatInjection, fmtFrom, channelMeta, } from "@cotal-ai/connector-core";
|
|
14
14
|
import { TranscriptMirror, transcriptChannel } from "./transcript.js";
|
|
15
15
|
/** Mirrors this session's transcript to `tr-<name>` — set in main() iff COTAL_TRANSCRIPT
|
|
16
16
|
* is on (buildLaunch sets it for managed sessions; personal sessions never mirror). */
|
|
@@ -128,7 +128,7 @@ async function main() {
|
|
|
128
128
|
capabilities: { experimental: { "claude/channel": {} } },
|
|
129
129
|
instructions: `You are connected to the Cotal mesh as "${config.name}"` +
|
|
130
130
|
`${config.role ? ` (role: ${config.role})` : ""} in space "${config.space}". ` +
|
|
131
|
-
|
|
131
|
+
`${ORIENTATION_BOOTSTRAP} ` +
|
|
132
132
|
feedbackLine(config) +
|
|
133
133
|
`Other agents coordinate with you here as lateral peers. ` +
|
|
134
134
|
`Peer messages may arrive as <channel source="cotal" from="<name>" role="<role>" ` +
|
package/dist/mcp.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"mcp.js","sourceRoot":"","sources":["../src/mcp.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AACH,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AACpE,OAAO,EAAE,oBAAoB,EAAE,MAAM,2CAA2C,CAAC;AACjF,OAAO,EACL,aAAa,EACb,WAAW,EACX,SAAS,EACT,iBAAiB,EACjB,kBAAkB,EAClB,kBAAkB,EAClB,
|
|
1
|
+
{"version":3,"file":"mcp.js","sourceRoot":"","sources":["../src/mcp.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AACH,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AACpE,OAAO,EAAE,oBAAoB,EAAE,MAAM,2CAA2C,CAAC;AACjF,OAAO,EACL,aAAa,EACb,WAAW,EACX,SAAS,EACT,iBAAiB,EACjB,kBAAkB,EAClB,kBAAkB,EAClB,YAAY,EACZ,qBAAqB,EACrB,eAAe,EACf,OAAO,EACP,WAAW,GAGZ,MAAM,0BAA0B,CAAC;AAClC,OAAO,EAAE,gBAAgB,EAAE,iBAAiB,EAAE,MAAM,iBAAiB,CAAC;AAEtE;wFACwF;AACxF,IAAI,MAAoC,CAAC;AAEzC;;;;GAIG;AACH,IAAI,WAAyD,CAAC;AAE9D,iGAAiG;AACjG,SAAS,UAAU,CAAC,IAAa,EAAE,KAAc;IAC/C,IAAI,OAAO,IAAI,KAAK,QAAQ,IAAI,CAAC,IAAI;QAAE,OAAO,SAAS,CAAC;IACxD,MAAM,CAAC,GAAG,CAAC,KAAK,IAAI,EAAE,CAA4B,CAAC;IACnD,MAAM,OAAO,GAAG,CAAC,CAAC,OAAO,IAAI,CAAC,CAAC,SAAS,IAAI,CAAC,CAAC,IAAI,IAAI,CAAC,CAAC,GAAG,IAAI,CAAC,CAAC,OAAO,IAAI,CAA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al connector for Claude Code: an installed plugin that joins a session to the mesh.",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.8.0",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"repository": {
|
|
7
7
|
"type": "git",
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
},
|
|
20
20
|
"dependencies": {
|
|
21
21
|
"@modelcontextprotocol/sdk": "^1.29.0",
|
|
22
|
-
"@cotal-ai/connector-core": "0.
|
|
22
|
+
"@cotal-ai/connector-core": "0.8.0"
|
|
23
23
|
},
|
|
24
24
|
"peerDependencies": {
|
|
25
25
|
"@cotal-ai/core": ">=0.1.0"
|
|
@@ -27,7 +27,7 @@
|
|
|
27
27
|
"devDependencies": {
|
|
28
28
|
"esbuild": "^0.28.0",
|
|
29
29
|
"tsx": "^4.22.4",
|
|
30
|
-
"@cotal-ai/core": "0.
|
|
30
|
+
"@cotal-ai/core": "0.8.0"
|
|
31
31
|
},
|
|
32
32
|
"files": [
|
|
33
33
|
"dist",
|