@stratusagent/plugins 0.11.3 → 0.11.5

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.
@@ -0,0 +1,102 @@
1
+ import { ChannelRegistry, ContributionRegistry, type ChannelRegistrationHandle, type ChannelTransportSecrets, type ExecutorContribution, type ExecutorRegistrationHandle, type MemoryRegistrationHandle, type MemoryStoreContribution, type ProviderContribution, type ProviderRegistrationHandle } from '@stratusagent/core';
2
+ import { type PluginManifest } from './manifest.ts';
3
+ /**
4
+ * Where a plugin's non-tool contributions land once it has loaded whole.
5
+ * A host passes the registries it serves from; the loader supplies private
6
+ * ones for any it omits, so a plugin contributing a kind this host does not
7
+ * carry still loads — recorded, and going nowhere, the way a contributed
8
+ * skill is ignored by a host with no catalog.
9
+ */
10
+ export interface ContributionTargets {
11
+ providers: ContributionRegistry<ProviderContribution>;
12
+ channels: ChannelRegistry;
13
+ memory: ContributionRegistry<MemoryStoreContribution>;
14
+ executors: ContributionRegistry<ExecutorContribution>;
15
+ }
16
+ export declare const createContributionTargets: (partial?: Partial<ContributionTargets>) => ContributionTargets;
17
+ /**
18
+ * Which package owns each registered name, per kind, across every plugin
19
+ * a loader has committed — so a collision can name both packages, the way
20
+ * the tool `owners` map does. Channels key on (agent, kind).
21
+ */
22
+ export interface ContributionOwners {
23
+ providers: Map<string, string>;
24
+ channels: Map<string, string>;
25
+ memory: Map<string, string>;
26
+ executors: Map<string, string>;
27
+ }
28
+ export declare const createContributionOwners: () => ContributionOwners;
29
+ /**
30
+ * How the host answers a channel plugin's request for its transport
31
+ * secrets: the values under `channels.<kind>.<agentId>` in the credential
32
+ * store, by agent. The host owns this path — see
33
+ * `ChannelRegistrationHandle.transportSecrets` in `@stratusagent/core`.
34
+ */
35
+ export type ChannelSecretSource = (kind: string) => Promise<ChannelTransportSecrets>;
36
+ /** What the daemon knows a loaded plugin contributed besides tools and skills. */
37
+ export interface PluginContributionRecords {
38
+ providers: string[];
39
+ channels: Array<{
40
+ kind: string;
41
+ agents: string[];
42
+ }>;
43
+ memory: string[];
44
+ executors: string[];
45
+ }
46
+ /**
47
+ * The manifest-bound views a plugin's `setup()` registers providers,
48
+ * channels, memory stores, and executors through.
49
+ *
50
+ * Same reasoning as `ManifestBoundToolRegistry`, four kinds over: the
51
+ * manifest says what a plugin *claims*, and only a view that checks
52
+ * registrations against it makes the claim enforceable. A plugin that
53
+ * declares a channel and registers a provider is refused at load, naming
54
+ * the package and the undeclared kind; two plugins registering the same
55
+ * provider name are refused rather than one silently winning.
56
+ *
57
+ * Staged, not committed, for the same reason tools are: a plugin that
58
+ * registers a provider and then throws must not leave the provider live.
59
+ * Unlike the tool view, nothing here stays live after commit — a provider
60
+ * or an executor has no reconnect-time discovery to serve, and a
61
+ * registration after `setup()` returned is refused as the mistake it is.
62
+ */
63
+ export declare class ManifestBoundContributions {
64
+ readonly providers: ProviderRegistrationHandle;
65
+ readonly channels: ChannelRegistrationHandle;
66
+ readonly memory: MemoryRegistrationHandle;
67
+ readonly executors: ExecutorRegistrationHandle;
68
+ private readonly manifest;
69
+ private readonly targets;
70
+ private readonly owners;
71
+ private readonly channelSecrets;
72
+ private readonly stagedProviders;
73
+ private readonly stagedMemory;
74
+ private readonly stagedExecutors;
75
+ private readonly stagedChannels;
76
+ private committed;
77
+ constructor(options: {
78
+ manifest: PluginManifest;
79
+ targets: ContributionTargets;
80
+ owners: ContributionOwners;
81
+ channelSecrets?: ChannelSecretSource;
82
+ });
83
+ private assertDeclared;
84
+ private assertUnclaimed;
85
+ private registerProvider;
86
+ private registerMemory;
87
+ private registerExecutor;
88
+ private registerChannel;
89
+ private assertChannelUnclaimed;
90
+ private transportSecrets;
91
+ /**
92
+ * Refuse now if committing would collide — checked before anything else
93
+ * of the plugin lands, so a plugin never ends up with its tools live and
94
+ * its provider refused. Registration already checked all of this; a
95
+ * second pass costs nothing and holds if a host registers between.
96
+ */
97
+ preflightCommit(): void;
98
+ private assertCommittable;
99
+ /** Land everything staged in the shared registries and record ownership. */
100
+ commit(): PluginContributionRecords;
101
+ }
102
+ //# sourceMappingURL=contributions.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"contributions.d.ts","sourceRoot":"","sources":["../src/contributions.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,eAAe,EACf,oBAAoB,EAIpB,KAAK,yBAAyB,EAC9B,KAAK,uBAAuB,EAC5B,KAAK,oBAAoB,EACzB,KAAK,0BAA0B,EAC/B,KAAK,wBAAwB,EAC7B,KAAK,uBAAuB,EAC5B,KAAK,oBAAoB,EACzB,KAAK,0BAA0B,EAChC,MAAM,oBAAoB,CAAC;AAE5B,OAAO,EAEL,KAAK,cAAc,EAEpB,MAAM,eAAe,CAAC;AAEvB;;;;;;GAMG;AACH,MAAM,WAAW,mBAAmB;IAClC,SAAS,EAAE,oBAAoB,CAAC,oBAAoB,CAAC,CAAC;IACtD,QAAQ,EAAE,eAAe,CAAC;IAC1B,MAAM,EAAE,oBAAoB,CAAC,uBAAuB,CAAC,CAAC;IACtD,SAAS,EAAE,oBAAoB,CAAC,oBAAoB,CAAC,CAAC;CACvD;AAED,eAAO,MAAM,yBAAyB,GAAI,UAAS,OAAO,CAAC,mBAAmB,CAAM,KAAG,mBAKrF,CAAC;AAEH;;;;GAIG;AACH,MAAM,WAAW,kBAAkB;IACjC,SAAS,EAAE,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAC/B,QAAQ,EAAE,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAC9B,MAAM,EAAE,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAC5B,SAAS,EAAE,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;CAChC;AAED,eAAO,MAAM,wBAAwB,QAAO,kBAK1C,CAAC;AAEH;;;;;GAKG;AACH,MAAM,MAAM,mBAAmB,GAAG,CAAC,IAAI,EAAE,MAAM,KAAK,OAAO,CAAC,uBAAuB,CAAC,CAAC;AA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B,OAAO,CAAC,sBAAsB;YAsBhB,gBAAgB;IAgB9B;;;;;OAKG;IACH,eAAe,IAAI,IAAI;IAuBvB,OAAO,CAAC,iBAAiB;IASzB,4EAA4E;IAC5E,MAAM,IAAI,yBAAyB;CAgCpC"}
@@ -0,0 +1,238 @@
1
+ import { ChannelRegistry, ContributionRegistry, MEMORY_STORE_CONTRACT_VERSION, channelClaimKey, } from '@stratusagent/core';
2
+ import { PluginManifestError, } from "./manifest.js";
3
+ export const createContributionTargets = (partial = {}) => ({
4
+ providers: partial.providers ?? new ContributionRegistry(),
5
+ channels: partial.channels ?? new ChannelRegistry(),
6
+ memory: partial.memory ?? new ContributionRegistry(),
7
+ executors: partial.executors ?? new ContributionRegistry(),
8
+ });
9
+ export const createContributionOwners = () => ({
10
+ providers: new Map(),
11
+ channels: new Map(),
12
+ memory: new Map(),
13
+ executors: new Map(),
14
+ });
15
+ const KIND_LABEL = {
16
+ providers: 'provider',
17
+ channels: 'channel',
18
+ memory: 'memory store',
19
+ executors: 'executor',
20
+ };
21
+ /**
22
+ * The manifest-bound views a plugin's `setup()` registers providers,
23
+ * channels, memory stores, and executors through.
24
+ *
25
+ * Same reasoning as `ManifestBoundToolRegistry`, four kinds over: the
26
+ * manifest says what a plugin *claims*, and only a view that checks
27
+ * registrations against it makes the claim enforceable. A plugin that
28
+ * declares a channel and registers a provider is refused at load, naming
29
+ * the package and the undeclared kind; two plugins registering the same
30
+ * provider name are refused rather than one silently winning.
31
+ *
32
+ * Staged, not committed, for the same reason tools are: a plugin that
33
+ * registers a provider and then throws must not leave the provider live.
34
+ * Unlike the tool view, nothing here stays live after commit — a provider
35
+ * or an executor has no reconnect-time discovery to serve, and a
36
+ * registration after `setup()` returned is refused as the mistake it is.
37
+ */
38
+ export class ManifestBoundContributions {
39
+ providers;
40
+ channels;
41
+ memory;
42
+ executors;
43
+ manifest;
44
+ targets;
45
+ owners;
46
+ channelSecrets;
47
+ stagedProviders = new Map();
48
+ stagedMemory = new Map();
49
+ stagedExecutors = new Map();
50
+ stagedChannels = [];
51
+ committed = false;
52
+ constructor(options) {
53
+ this.manifest = options.manifest;
54
+ this.targets = options.targets;
55
+ this.owners = options.owners;
56
+ this.channelSecrets = options.channelSecrets;
57
+ this.providers = { register: (contribution) => this.registerProvider(contribution) };
58
+ this.channels = {
59
+ register: (contribution) => this.registerChannel(contribution),
60
+ transportSecrets: (kind) => this.transportSecrets(kind),
61
+ };
62
+ this.memory = { register: (contribution) => this.registerMemory(contribution) };
63
+ this.executors = { register: (contribution) => this.registerExecutor(contribution) };
64
+ }
65
+ assertDeclared(kind, name) {
66
+ if (this.committed) {
67
+ throw new PluginManifestError(`Plugin ${this.manifest.packageName} tried to register ${KIND_LABEL[kind]} ${name} after it had loaded. `
68
+ + 'Providers, channels, memory stores, and executors register during setup().');
69
+ }
70
+ if (typeof name !== 'string' || name.length === 0) {
71
+ throw new PluginManifestError(`Plugin ${this.manifest.packageName} tried to register a ${KIND_LABEL[kind]} with no name.`);
72
+ }
73
+ if (!this.manifest.contributes[kind].some((declared) => declared.name === name)) {
74
+ throw new PluginManifestError(`Plugin ${this.manifest.packageName} tried to register ${KIND_LABEL[kind]} ${name}, which its manifest does not declare. `
75
+ + `Add it to contributes.${kind} in the package's stratus manifest.`);
76
+ }
77
+ }
78
+ assertUnclaimed(kind, name, staged) {
79
+ if (staged.has(name)) {
80
+ throw new PluginManifestError(`Plugin ${this.manifest.packageName} registered ${KIND_LABEL[kind]} ${name} twice.`);
81
+ }
82
+ const owner = this.owners[kind].get(name);
83
+ if (owner !== undefined) {
84
+ throw new PluginManifestError(`${KIND_LABEL[kind]} name collision: ${name} is contributed by both ${owner} and ${this.manifest.packageName}. `
85
+ + `Disable one of them; a ${KIND_LABEL[kind]} name is unique per install.`);
86
+ }
87
+ if (this.targets[kind].has(name)) {
88
+ throw new PluginManifestError(`${KIND_LABEL[kind]} name collision: ${name} is already registered by the host. `
89
+ + `Plugin ${this.manifest.packageName} cannot replace it.`);
90
+ }
91
+ }
92
+ registerProvider(contribution) {
93
+ this.assertDeclared('providers', contribution.name);
94
+ if (typeof contribution.create !== 'function') {
95
+ throw new PluginManifestError(`Plugin ${this.manifest.packageName}: provider ${contribution.name} has no create(selection). A contributed provider is a factory — see ProviderContribution.`);
96
+ }
97
+ this.assertUnclaimed('providers', contribution.name, this.stagedProviders);
98
+ this.stagedProviders.set(contribution.name, contribution);
99
+ }
100
+ registerMemory(contribution) {
101
+ this.assertDeclared('memory', contribution.name);
102
+ if (!contribution.store || typeof contribution.store.append !== 'function') {
103
+ throw new PluginManifestError(`Plugin ${this.manifest.packageName}: memory store ${contribution.name} is not an AgentMemoryStore.`);
104
+ }
105
+ // Declared, not inferred: a store built against the previous contract
106
+ // still has an `append` and a `search` of the same arity, so nothing
107
+ // about the functions distinguishes it. Routed traffic anyway, it binds
108
+ // an options object where a number belonged and answers an unbounded
109
+ // read — wrong, silently, on every recall. Refusing names the fix.
110
+ if (contribution.contract !== MEMORY_STORE_CONTRACT_VERSION) {
111
+ throw new PluginManifestError(`Plugin ${this.manifest.packageName}: memory store ${contribution.name} is built against memory contract `
112
+ + `${contribution.contract ?? 1}, and this host serves ${MEMORY_STORE_CONTRACT_VERSION}. `
113
+ + 'Upgrade the plugin — a store from the older contract reads `search` limits and `append` provenance differently, '
114
+ + 'and would answer wrongly rather than fail.');
115
+ }
116
+ this.assertUnclaimed('memory', contribution.name, this.stagedMemory);
117
+ this.stagedMemory.set(contribution.name, contribution);
118
+ }
119
+ registerExecutor(contribution) {
120
+ this.assertDeclared('executors', contribution.name);
121
+ if (!contribution.executor || typeof contribution.executor.execute !== 'function') {
122
+ throw new PluginManifestError(`Plugin ${this.manifest.packageName}: executor ${contribution.name} is not an Executor.`);
123
+ }
124
+ this.assertUnclaimed('executors', contribution.name, this.stagedExecutors);
125
+ this.stagedExecutors.set(contribution.name, contribution);
126
+ }
127
+ registerChannel(contribution) {
128
+ const kind = contribution.adapter?.name;
129
+ this.assertDeclared('channels', kind);
130
+ if (typeof contribution.adapter.start !== 'function' || typeof contribution.adapter.stop !== 'function') {
131
+ throw new PluginManifestError(`Plugin ${this.manifest.packageName}: channel ${kind} is not a ChannelAdapter (it needs start and stop).`);
132
+ }
133
+ if (!Array.isArray(contribution.agents)) {
134
+ throw new PluginManifestError(`Plugin ${this.manifest.packageName}: channel ${kind} must say which agents it carries.`);
135
+ }
136
+ const seen = new Set();
137
+ for (const agentId of contribution.agents) {
138
+ if (seen.has(agentId)) {
139
+ throw new PluginManifestError(`Plugin ${this.manifest.packageName} registered channel ${kind} for agent ${agentId} twice.`);
140
+ }
141
+ seen.add(agentId);
142
+ this.assertChannelUnclaimed(kind, agentId);
143
+ }
144
+ this.stagedChannels.push(contribution);
145
+ }
146
+ assertChannelUnclaimed(kind, agentId) {
147
+ const key = channelClaimKey(kind, agentId);
148
+ if (this.stagedChannels.some((staged) => staged.adapter.name === kind && staged.agents.includes(agentId))) {
149
+ throw new PluginManifestError(`Plugin ${this.manifest.packageName} registered channel ${kind} for agent ${agentId} twice.`);
150
+ }
151
+ const owner = this.owners.channels.get(key);
152
+ if (owner !== undefined) {
153
+ throw new PluginManifestError(`channel collision: ${kind} for agent ${agentId} is contributed by both ${owner} and ${this.manifest.packageName}. `
154
+ + 'Disable one of them; an agent is carried on each channel kind by one adapter.');
155
+ }
156
+ if (this.targets.channels.claimed(kind, agentId)) {
157
+ throw new PluginManifestError(`channel collision: ${kind} for agent ${agentId} is already carried by the host. `
158
+ + `Plugin ${this.manifest.packageName} cannot replace it.`);
159
+ }
160
+ }
161
+ async transportSecrets(kind) {
162
+ if (!this.manifest.contributes.channels.some((declared) => declared.name === kind)) {
163
+ throw new PluginManifestError(`Plugin ${this.manifest.packageName} asked for the transport secrets of channel ${kind}, which its manifest does not declare. `
164
+ + 'Add it to contributes.channels in the package\'s stratus manifest.');
165
+ }
166
+ if (!this.channelSecrets) {
167
+ throw new Error(`This host stores no channel transport secrets, so channel ${kind} cannot start here. `
168
+ + 'A channel runs under stratus serve, which reads them from ~/.stratus/credentials.json.');
169
+ }
170
+ return this.channelSecrets(kind);
171
+ }
172
+ /**
173
+ * Refuse now if committing would collide — checked before anything else
174
+ * of the plugin lands, so a plugin never ends up with its tools live and
175
+ * its provider refused. Registration already checked all of this; a
176
+ * second pass costs nothing and holds if a host registers between.
177
+ */
178
+ preflightCommit() {
179
+ for (const name of this.stagedProviders.keys()) {
180
+ this.assertCommittable('providers', name);
181
+ }
182
+ for (const name of this.stagedMemory.keys()) {
183
+ this.assertCommittable('memory', name);
184
+ }
185
+ for (const name of this.stagedExecutors.keys()) {
186
+ this.assertCommittable('executors', name);
187
+ }
188
+ for (const staged of this.stagedChannels) {
189
+ for (const agentId of staged.agents) {
190
+ const key = channelClaimKey(staged.adapter.name, agentId);
191
+ const owner = this.owners.channels.get(key);
192
+ if (owner !== undefined || this.targets.channels.claimed(staged.adapter.name, agentId)) {
193
+ throw new PluginManifestError(`channel collision: ${staged.adapter.name} for agent ${agentId} is contributed by both ${owner ?? 'the host'} and ${this.manifest.packageName}.`);
194
+ }
195
+ }
196
+ }
197
+ }
198
+ assertCommittable(kind, name) {
199
+ const owner = this.owners[kind].get(name);
200
+ if (owner !== undefined || this.targets[kind].has(name)) {
201
+ throw new PluginManifestError(`${KIND_LABEL[kind]} name collision: ${name} is contributed by both ${owner ?? 'the host'} and ${this.manifest.packageName}.`);
202
+ }
203
+ }
204
+ /** Land everything staged in the shared registries and record ownership. */
205
+ commit() {
206
+ this.preflightCommit();
207
+ const packageName = this.manifest.packageName;
208
+ for (const [name, contribution] of this.stagedProviders) {
209
+ this.targets.providers.register(name, contribution);
210
+ this.owners.providers.set(name, packageName);
211
+ }
212
+ for (const [name, contribution] of this.stagedMemory) {
213
+ this.targets.memory.register(name, contribution);
214
+ this.owners.memory.set(name, packageName);
215
+ }
216
+ for (const [name, contribution] of this.stagedExecutors) {
217
+ this.targets.executors.register(name, contribution);
218
+ this.owners.executors.set(name, packageName);
219
+ }
220
+ for (const contribution of this.stagedChannels) {
221
+ this.targets.channels.register(contribution);
222
+ for (const agentId of contribution.agents) {
223
+ this.owners.channels.set(channelClaimKey(contribution.adapter.name, agentId), packageName);
224
+ }
225
+ }
226
+ this.committed = true;
227
+ return {
228
+ providers: [...this.stagedProviders.keys()],
229
+ channels: this.stagedChannels.map((contribution) => ({
230
+ kind: contribution.adapter.name,
231
+ agents: [...contribution.agents],
232
+ })),
233
+ memory: [...this.stagedMemory.keys()],
234
+ executors: [...this.stagedExecutors.keys()],
235
+ };
236
+ }
237
+ }
238
+ //# sourceMappingURL=contributions.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"contributions.js","sourceRoot":"","sources":["../src/contributions.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,eAAe,EACf,oBAAoB,EACpB,6BAA6B,EAC7B,eAAe,GAUhB,MAAM,oBAAoB,CAAC;AAE5B,OAAO,EACL,mBAAmB,GAGpB,MAAM,eAAe,CAAC;AAgBvB,MAAM,CAAC,MAAM,yBAAyB,GAAG,CAAC,UAAwC,EAAE,EAAuB,EAAE,CAAC,CAAC;IAC7G,SAAS,EAAE,OAAO,CAAC,SAAS,IAAI,IAAI,oBAAoB,EAAwB;IAChF,QAAQ,EAAE,OAAO,CAAC,QAAQ,IAAI,IAAI,eAAe,EAAE;IACnD,MAAM,EAAE,OAAO,CAAC,MAAM,IAAI,IAAI,oBAAoB,EAA2B;IAC7E,SAAS,EAAE,OAAO,CAAC,SAAS,IAAI,IAAI,oBAAoB,EAAwB;CACjF,CAAC,CAAC;AAcH,MAAM,CAAC,MAAM,wBAAwB,GAAG,GAAuB,EAAE,CAAC,CAAC;IACjE,SAAS,EAAE,IAAI,GAAG,EAAE;IACpB,QAAQ,EAAE,IAAI,GAAG,EAAE;IACnB,MAAM,EAAE,IAAI,GAAG,EAAE;IACjB,SAAS,EAAE,IAAI,GAAG,EAAE;CACrB,CAAC,CAAC;AAkBH,MAAM,UAAU,GAAgD;IAC9D,SAAS,EAAE,UAAU;IACrB,QAAQ,EAAE,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D,IAAI,CAAC,OAAO,CAAC,SAAS,CAAC,QAAQ,CAAC,IAAI,EAAE,YAAY,CAAC,CAAC;YACpD,IAAI,CAAC,MAAM,CAAC,SAAS,CAAC,GAAG,CAAC,IAAI,EAAE,WAAW,CAAC,CAAC;QAC/C,CAAC;QACD,KAAK,MAAM,YAAY,IAAI,IAAI,CAAC,cAAc,EAAE,CAAC;YAC/C,IAAI,CAAC,OAAO,CAAC,QAAQ,CAAC,QAAQ,CAAC,YAAY,CAAC,CAAC;YAC7C,KAAK,MAAM,OAAO,IAAI,YAAY,CAAC,MAAM,EAAE,CAAC;gBAC1C,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,GAAG,CAAC,eAAe,CAAC,YAAY,CAAC,OAAO,CAAC,IAAI,EAAE,OAAO,CAAC,EAAE,WAAW,CAAC,CAAC;YAC7F,CAAC;QACH,CAAC;QACD,IAAI,CAAC,SAAS,GAAG,IAAI,CAAC;QACtB,OAAO;YACL,SAAS,EAAE,CAAC,GAAG,IAAI,CAAC,eAAe,CAAC,IAAI,EAAE,CAAC;YAC3C,QAAQ,EAAE,IAAI,CAAC,cAAc,CAAC,GAAG,CAAC,CAAC,YAAY,EAAE,EAAE,CAAC,CAAC;gBACnD,IAAI,EAAE,YAAY,CAAC,OAAO,CAAC,IAAI;gBAC/B,MAAM,EAAE,CAAC,GAAG,YAAY,CAAC,MAAM,CAAC;aACjC,CAAC,CAAC;YACH,MAAM,EAAE,CAAC,GAAG,IAAI,CAAC,YAAY,CAAC,IAAI,EAAE,CAAC;YACrC,SAAS,EAAE,CAAC,GAAG,IAAI,CAAC,eAAe,CAAC,IAAI,EAAE,CAAC;SAC5C,CAAC;IACJ,CAAC;CACF"}
package/dist/home.d.ts ADDED
@@ -0,0 +1,9 @@
1
+ /**
2
+ * `~` and `~/x` mean the same thing here as they do in a shell.
3
+ *
4
+ * Lived in `tool-fs` while it was the only plugin reading a path out of
5
+ * its config block; a memory-store plugin was the second, and a second
6
+ * copy of even four lines is a second answer to what `~` means.
7
+ */
8
+ export declare const expandHome: (value: string, home?: string) => string;
9
+ //# sourceMappingURL=home.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"home.d.ts","sourceRoot":"","sources":["../src/home.ts"],"names":[],"mappings":"AAGA;;;;;;GAMG;AACH,eAAO,MAAM,UAAU,GAAI,OAAO,MAAM,EAAE,aAAmB,KAAG,MAQ/D,CAAC"}
package/dist/home.js ADDED
@@ -0,0 +1,19 @@
1
+ import os from 'node:os';
2
+ import path from 'node:path';
3
+ /**
4
+ * `~` and `~/x` mean the same thing here as they do in a shell.
5
+ *
6
+ * Lived in `tool-fs` while it was the only plugin reading a path out of
7
+ * its config block; a memory-store plugin was the second, and a second
8
+ * copy of even four lines is a second answer to what `~` means.
9
+ */
10
+ export const expandHome = (value, home = os.homedir()) => {
11
+ if (value === '~') {
12
+ return home;
13
+ }
14
+ if (value.startsWith('~/')) {
15
+ return path.join(home, value.slice(2));
16
+ }
17
+ return value;
18
+ };
19
+ //# sourceMappingURL=home.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"home.js","sourceRoot":"","sources":["../src/home.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,SAAS,CAAC;AACzB,OAAO,IAAI,MAAM,WAAW,CAAC;AAE7B;;;;;;GAMG;AACH,MAAM,CAAC,MAAM,UAAU,GAAG,CAAC,KAAa,EAAE,IAAI,GAAG,EAAE,CAAC,OAAO,EAAE,EAAU,EAAE;IACvE,IAAI,KAAK,KAAK,GAAG,EAAE,CAAC;QAClB,OAAO,IAAI,CAAC;IACd,CAAC;IACD,IAAI,KAAK,CAAC,UAAU,CAAC,IAAI,CAAC,EAAE,CAAC;QAC3B,OAAO,IAAI,CAAC,IAAI,CAAC,IAAI,EAAE,KAAK,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC;IACzC,CAAC;IACD,OAAO,KAAK,CAAC;AACf,CAAC,CAAC"}
package/dist/index.d.ts CHANGED
@@ -8,9 +8,12 @@
8
8
  * holds `setup()` to that manifest, and a loader that refuses rather than
9
9
  * degrades when a plugin over-reaches.
10
10
  */
11
- export { declaredRiskFor, parsePluginManifest, parseToolRiskOverrides, resolvePluginAgentConfig, validateAgainstSchema, validatePluginConfig, HOST_CONFIG_KEYS, PLUGIN_MANIFEST_VERSION, PluginConfigError, PluginManifestError, type PluginContributions, type PluginManifest, type PluginNamespaceDeclaration, type PluginSkillDeclaration, type PluginToolDeclaration, } from './manifest.ts';
11
+ export { declaredRiskFor, parsePluginManifest, parseToolRiskOverrides, resolvePluginAgentConfig, validateAgainstSchema, validatePluginConfig, HOST_CONFIG_KEYS, PLUGIN_MANIFEST_VERSION, PLUGIN_NAMED_CONTRIBUTION_KINDS, PluginConfigError, PluginManifestError, type PluginContributions, type PluginManifest, type PluginNamedContributionKind, type PluginNamedDeclaration, type PluginNamespaceDeclaration, type PluginSkillDeclaration, type PluginToolDeclaration, } from './manifest.ts';
12
12
  export { createManifestBoundCredentialResolver } from './credentials.ts';
13
+ export { expandHome } from './home.ts';
14
+ export { createContributionOwners, createContributionTargets, ManifestBoundContributions, type ChannelSecretSource, type ContributionOwners, type ContributionTargets, type PluginContributionRecords, } from './contributions.ts';
13
15
  export { ManifestBoundToolRegistry, riskFloorFor, type PluginToolRecord, } from './registry.ts';
14
16
  export { isFirstPartyPackage, loadOptionalModule, loadPlugins, pluginConfigWithHostDefaults, preflightPlugin, installedPackageVersion, readPluginManifest, type CreatePlugin, type LoadedPlugin, type LoadPluginsOptions, type LoadPluginsResult, type OptionalModuleHost, type PluginLoadFailure, type PluginSkillRecord, } from './loader.ts';
15
17
  export { createFileLedger, createProcessLocalLedger, isLedgerPath, LEDGER_FILENAME, ledgerContentTrust, ledgerGuard, ledgerTrustOfContent, nameIdentifiesHandle, type FileIdentity, type LedgerGuard, type TaintedWriteLedger, } from './provenance.ts';
18
+ export { workspaceResolver, workspacePreparer, allAgentWorkspaces } from './workspace.ts';
16
19
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AACH,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,sBAAsB,EACtB,wBAAwB,EACxB,qBAAqB,EACrB,oBAAoB,EACpB,gBAAgB,EAChB,uBAAuB,EACvB,iBAAiB,EACjB,mBAAmB,EACnB,KAAK,mBAAmB,EACxB,KAAK,cAAc,EACnB,KAAK,0BAA0B,EAC/B,KAAK,sBAAsB,EAC3B,KAAK,qBAAqB,GAC3B,MAAM,eAAe,CAAC;AAEvB,OAAO,EAAE,qCAAqC,EAAE,MAAM,kBAAkB,CAAC;AAEzE,OAAO,EACL,yBAAyB,EACzB,YAAY,EACZ,KAAK,gBAAgB,GACtB,MAAM,eAAe,CAAC;AAEvB,OAAO,EACL,mBAAmB,EACnB,kBAAkB,EAClB,WAAW,EACX,4BAA4B,EAC5B,eAAe,EACf,uBAAuB,EACvB,kBAAkB,EAClB,KAAK,YAAY,EACjB,KAAK,YAAY,EACjB,KAAK,kBAAkB,EACvB,KAAK,iBAAiB,EACtB,KAAK,kBAAkB,EACvB,KAAK,iBAAiB,EACtB,KAAK,iBAAiB,GACvB,MAAM,aAAa,CAAC;AAErB,OAAO,EACL,gBAAgB,EAChB,wBAAwB,EACxB,YAAY,EACZ,eAAe,EACf,kBAAkB,EAClB,WAAW,EACX,oBAAoB,EACpB,oBAAoB,EACpB,KAAK,YAAY,EACjB,KAAK,WAAW,EAChB,KAAK,kBAAkB,GACxB,MAAM,iBAAiB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AACH,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,sBAAsB,EACtB,wBAAwB,EACxB,qBAAqB,EACrB,oBAAoB,EACpB,gBAAgB,EAChB,uBAAuB,EACvB,+BAA+B,EAC/B,iBAAiB,EACjB,mBAAmB,EACnB,KAAK,mBAAmB,EACxB,KAAK,cAAc,EACnB,KAAK,2BAA2B,EAChC,KAAK,sBAAsB,EAC3B,KAAK,0BAA0B,EAC/B,KAAK,sBAAsB,EAC3B,KAAK,qBAAqB,GAC3B,MAAM,eAAe,CAAC;AAEvB,OAAO,EAAE,qCAAqC,EAAE,MAAM,kBAAkB,CAAC;AAEzE,OAAO,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AAEvC,OAAO,EACL,wBAAwB,EACxB,yBAAyB,EACzB,0BAA0B,EAC1B,KAAK,mBAAmB,EACxB,KAAK,kBAAkB,EACvB,KAAK,mBAAmB,EACxB,KAAK,yBAAyB,GAC/B,MAAM,oBAAoB,CAAC;AAE5B,OAAO,EACL,yBAAyB,EACzB,YAAY,EACZ,KAAK,gBAAgB,GACtB,MAAM,eAAe,CAAC;AAEvB,OAAO,EACL,mBAAmB,EACnB,kBAAkB,EAClB,WAAW,EACX,4BAA4B,EAC5B,eAAe,EACf,uBAAuB,EACvB,kBAAkB,EAClB,KAAK,YAAY,EACjB,KAAK,YAAY,EACjB,KAAK,kBAAkB,EACvB,KAAK,iBAAiB,EACtB,KAAK,kBAAkB,EACvB,KAAK,iBAAiB,EACtB,KAAK,iBAAiB,GACvB,MAAM,aAAa,CAAC;AAErB,OAAO,EACL,gBAAgB,EAChB,wBAAwB,EACxB,YAAY,EACZ,eAAe,EACf,kBAAkB,EAClB,WAAW,EACX,oBAAoB,EACpB,oBAAoB,EACpB,KAAK,YAAY,EACjB,KAAK,WAAW,EAChB,KAAK,kBAAkB,GACxB,MAAM,iBAAiB,CAAC;AAEzB,OAAO,EAAE,iBAAiB,EAAE,iBAAiB,EAAE,kBAAkB,EAAE,MAAM,gBAAgB,CAAC"}
package/dist/index.js CHANGED
@@ -8,9 +8,12 @@
8
8
  * holds `setup()` to that manifest, and a loader that refuses rather than
9
9
  * degrades when a plugin over-reaches.
10
10
  */
11
- export { declaredRiskFor, parsePluginManifest, parseToolRiskOverrides, resolvePluginAgentConfig, validateAgainstSchema, validatePluginConfig, HOST_CONFIG_KEYS, PLUGIN_MANIFEST_VERSION, PluginConfigError, PluginManifestError, } from "./manifest.js";
11
+ export { declaredRiskFor, parsePluginManifest, parseToolRiskOverrides, resolvePluginAgentConfig, validateAgainstSchema, validatePluginConfig, HOST_CONFIG_KEYS, PLUGIN_MANIFEST_VERSION, PLUGIN_NAMED_CONTRIBUTION_KINDS, PluginConfigError, PluginManifestError, } from "./manifest.js";
12
12
  export { createManifestBoundCredentialResolver } from "./credentials.js";
13
+ export { expandHome } from "./home.js";
14
+ export { createContributionOwners, createContributionTargets, ManifestBoundContributions, } from "./contributions.js";
13
15
  export { ManifestBoundToolRegistry, riskFloorFor, } from "./registry.js";
14
16
  export { isFirstPartyPackage, loadOptionalModule, loadPlugins, pluginConfigWithHostDefaults, preflightPlugin, installedPackageVersion, readPluginManifest, } from "./loader.js";
15
17
  export { createFileLedger, createProcessLocalLedger, isLedgerPath, LEDGER_FILENAME, ledgerContentTrust, ledgerGuard, ledgerTrustOfContent, nameIdentifiesHandle, } from "./provenance.js";
18
+ export { workspaceResolver, workspacePreparer, allAgentWorkspaces } from "./workspace.js";
16
19
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AACH,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,sBAAsB,EACtB,wBAAwB,EACxB,qBAAqB,EACrB,oBAAoB,EACpB,gBAAgB,EAChB,uBAAuB,EACvB,iBAAiB,EACjB,mBAAmB,GAMpB,MAAM,eAAe,CAAC;AAEvB,OAAO,EAAE,qCAAqC,EAAE,MAAM,kBAAkB,CAAC;AAEzE,OAAO,EACL,yBAAyB,EACzB,YAAY,GAEb,MAAM,eAAe,CAAC;AAEvB,OAAO,EACL,mBAAmB,EACnB,kBAAkB,EAClB,WAAW,EACX,4BAA4B,EAC5B,eAAe,EACf,uBAAuB,EACvB,kBAAkB,GAQnB,MAAM,aAAa,CAAC;AAErB,OAAO,EACL,gBAAgB,EAChB,wBAAwB,EACxB,YAAY,EACZ,eAAe,EACf,kBAAkB,EAClB,WAAW,EACX,oBAAoB,EACpB,oBAAoB,GAIrB,MAAM,iBAAiB,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AACH,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,sBAAsB,EACtB,wBAAwB,EACxB,qBAAqB,EACrB,oBAAoB,EACpB,gBAAgB,EAChB,uBAAuB,EACvB,+BAA+B,EAC/B,iBAAiB,EACjB,mBAAmB,GAQpB,MAAM,eAAe,CAAC;AAEvB,OAAO,EAAE,qCAAqC,EAAE,MAAM,kBAAkB,CAAC;AAEzE,OAAO,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AAEvC,OAAO,EACL,wBAAwB,EACxB,yBAAyB,EACzB,0BAA0B,GAK3B,MAAM,oBAAoB,CAAC;AAE5B,OAAO,EACL,yBAAyB,EACzB,YAAY,GAEb,MAAM,eAAe,CAAC;AAEvB,OAAO,EACL,mBAAmB,EACnB,kBAAkB,EAClB,WAAW,EACX,4BAA4B,EAC5B,eAAe,EACf,uBAAuB,EACvB,kBAAkB,GAQnB,MAAM,aAAa,CAAC;AAErB,OAAO,EACL,gBAAgB,EAChB,wBAAwB,EACxB,YAAY,EACZ,eAAe,EACf,kBAAkB,EAClB,WAAW,EACX,oBAAoB,EACpB,oBAAoB,GAIrB,MAAM,iBAAiB,CAAC;AAEzB,OAAO,EAAE,iBAAiB,EAAE,iBAAiB,EAAE,kBAAkB,EAAE,MAAM,gBAAgB,CAAC"}
package/dist/loader.d.ts CHANGED
@@ -1,6 +1,7 @@
1
- import type { CredentialResolver, EventBus, JsonObject, Plugin, SkillRegistry, ToolRegistry } from '@stratusagent/core';
1
+ import type { AgentWorkspaces, CredentialResolver, EventBus, JsonObject, Plugin, SkillRegistry, ToolRegistry } from '@stratusagent/core';
2
2
  import { type PluginManifest } from './manifest.ts';
3
3
  import { type PluginToolRecord } from './registry.ts';
4
+ import { type ChannelSecretSource, type ContributionTargets, type PluginContributionRecords } from './contributions.ts';
4
5
  /**
5
6
  * The two capabilities loading an optional package needs, taken from the
6
7
  * caller rather than used here.
@@ -114,6 +115,8 @@ export interface LoadedPlugin {
114
115
  */
115
116
  tools: PluginToolRecord[];
116
117
  skills: PluginSkillRecord[];
118
+ /** The providers, channels, memory stores, and executors it registered. */
119
+ contributions: PluginContributionRecords;
117
120
  /**
118
121
  * The plugin itself, so the host can shut it down. A browser plugin holds
119
122
  * a Chromium and a listening socket; a daemon that stopped without
@@ -139,6 +142,25 @@ export interface LoadPluginsOptions {
139
142
  */
140
143
  skills?: SkillRegistry;
141
144
  bus: EventBus;
145
+ /**
146
+ * The registries a plugin's providers, channels, memory stores, and
147
+ * executors are committed into once it loads whole — the counterparts
148
+ * of `tools`. Any omitted is replaced by a private one: the plugin still
149
+ * loads, its contribution is recorded on `LoadedPlugin`, and it reaches
150
+ * nothing — the way a contributed skill is ignored by a host with no
151
+ * catalog. `stratus run` is that host for channels.
152
+ */
153
+ providers?: ContributionTargets['providers'];
154
+ channels?: ContributionTargets['channels'];
155
+ memory?: ContributionTargets['memory'];
156
+ executors?: ContributionTargets['executors'];
157
+ /**
158
+ * How a channel plugin receives its transport secrets, by kind. A host
159
+ * that omits it refuses the request with a message saying so — a channel
160
+ * needs the daemon's credential store, and a host without one cannot
161
+ * carry a channel at all.
162
+ */
163
+ channelSecrets?: ChannelSecretSource;
142
164
  /**
143
165
  * Handed to every plugin's `setup` as `PluginContext.credentials`. A host
144
166
  * that omits it leaves a plugin needing a key with no way to resolve one
@@ -146,13 +168,17 @@ export interface LoadPluginsOptions {
146
168
  */
147
169
  credentials?: CredentialResolver;
148
170
  /**
149
- * Where tool output belongs on this machine. Supplied to any plugin whose
150
- * schema declares `workspaceRoot` and whose operator did not set one —
151
- * the host knows the platform's answer (`~/.stratus/workspaces`) and a
152
- * plugin that had to derive it would be re-deriving a path this
153
- * repository owns.
171
+ * Where each agent's tool output belongs on this machine, handed to every
172
+ * plugin's `setup` as `PluginContext.workspaces`.
173
+ *
174
+ * This replaced a single `workspaceRoot` the loader filled in for any
175
+ * plugin whose schema declared it. That worked while the workspace was
176
+ * `~/.stratus/workspaces/<id>` — a root plus the agent id — and stopped
177
+ * working the moment it moved inside the agent's own directory, because
178
+ * the id was no longer the last segment and five plugins had each written
179
+ * that shape down. The host answers the whole question now.
154
180
  */
155
- workspaceRoot?: string;
181
+ workspaces?: AgentWorkspaces;
156
182
  /** Overrides the trusted set. See `isFirstPartyPackage`. */
157
183
  trusted?: (packageName: string) => boolean;
158
184
  /** Handed to every plugin's `setup` as `PluginContext.log` / `.warn`. */
@@ -165,17 +191,15 @@ export interface LoadPluginsResult {
165
191
  }
166
192
  /**
167
193
  * The configuration a plugin will actually be handed: its own block, minus
168
- * the keys the host owns, plus the host defaults its manifest declares.
194
+ * the keys the host owns.
169
195
  *
170
196
  * Exported because validating a block against a manifest is only right on
171
- * *this* object — `validatePluginConfig` on the raw block would refuse a
172
- * manifest that declares `workspaceRoot` required for missing the very
173
- * setting the host supplies. `stratus plugins` has to answer whether a
174
- * daemon would accept a plugin's settings, and answering it from a
175
- * different object than the loader uses is how a diagnostic ends up
176
- * disagreeing with the thing it diagnoses.
197
+ * *this* object — the raw block still carries the keys the host strips, and
198
+ * `stratus plugins` has to answer whether a daemon would accept a plugin's
199
+ * settings. Answering it from a different object than the loader uses is
200
+ * how a diagnostic ends up disagreeing with the thing it diagnoses.
177
201
  */
178
- export declare const pluginConfigWithHostDefaults: (block: JsonObject, manifest: PluginManifest, workspaceRoot: string | undefined) => JsonObject;
202
+ export declare const pluginConfigWithHostDefaults: (block: JsonObject, manifest: PluginManifest) => JsonObject;
179
203
  /**
180
204
  * Everything `loadPlugins` checks before it imports a package: that the
181
205
  * settings match the manifest's own schema, that any `toolRisks` overrides
@@ -200,7 +224,7 @@ export declare const pluginConfigWithHostDefaults: (block: JsonObject, manifest:
200
224
  * path here — only a second caller of each. Anything added to the loader's
201
225
  * preflight belongs in both.
202
226
  */
203
- export declare const preflightPlugin: (manifest: PluginManifest, directory: string, block: JsonObject, workspaceRoot: string | undefined) => Promise<void>;
227
+ export declare const preflightPlugin: (manifest: PluginManifest, directory: string, block: JsonObject) => Promise<void>;
204
228
  /**
205
229
  * Turn a `plugins` config block into running capability.
206
230
  *
@@ -1 +1 @@
1
- {"version":3,"file":"loader.d.ts","sourceRoot":"","sources":["../src/loader.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EACV,kBAAkB,EAClB,QAAQ,EACR,UAAU,EACV,MAAM,EAEN,aAAa,EACb,YAAY,EACb,MAAM,oBAAoB,CAAC;AAG5B,OAAO,EAKL,KAAK,cAAc,EACpB,MAAM,eAAe,CAAC;AAEvB,OAAO,EAA6B,KAAK,gBAAgB,EAAE,MAAM,eAAe,CAAC;AAEjF;;;;;;;;;;GAUG;AACH,MAAM,WAAW,kBAAkB;IACjC,OAAO,CAAC,SAAS,EAAE,MAAM,GAAG,MAAM,CAAC;IACnC,MAAM,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC,CAAC;CAC7C;AAED;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,kBAAkB,GAAU,CAAC,GAAG,OAAO,EAClD,WAAW,MAAM,EACjB,MAAM,kBAAkB,KACvB,OAAO,CAAC,CAAC,GAAG,SAAS,CASvB,CAAC;AAEF,+DAA+D;AAC/D,MAAM,MAAM,YAAY,GAAG,CAAC,MAAM,EAAE,UAAU,KAAK,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC;AA8B5E;;;;;;;;;;;;GAYG;AACH,eAAO,MAAM,uBAAuB,GAClC,WAAW,MAAM,EACjB,MAAM,IAAI,CAAC,kBAAkB,EAAE,SAAS,CAAC,KACxC,OAAO,C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