@deepseek-ai/dsh-api-remotes 0.0.1-rc.2 → 0.0.1-rc.3

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/lib/index.js CHANGED
@@ -1,4 +1,4 @@
1
- import { TypeRTLookupFailure } from "@deepseek-ai/dsh-type-meta";
1
+ import { TypertLookupFailure } from "@deepseek-ai/dsh-typert-protocol";
2
2
  //#region lib/types/remote-events.js
3
3
  /**
4
4
  * The one home of this application's forwarded-Host-event allowlist. Both
@@ -19,6 +19,12 @@ const API_REMOTE_FORWARDED_EVENTS = [
19
19
  "agent-preset/selected",
20
20
  "commands/change",
21
21
  "credentials/updated",
22
+ "cordis/request-run",
23
+ "cordis/request-run-resolved",
24
+ "cordis/dynamic-package",
25
+ "cordis/dynamic-retract",
26
+ "cordis/inspect-query",
27
+ "cordis/inspect-query-resolved",
22
28
  "llm/adapters-updated",
23
29
  "settings/document-updated"
24
30
  ];
@@ -85,12 +91,12 @@ async function inspectApiRemoteSession(ctx, sessionId) {
85
91
  };
86
92
  }
87
93
  /**
88
- * Create the Host's shared Agent resolver and configure Agent/Session TypeRT lookups.
94
+ * Create the Host's shared Agent resolver and configure Agent/Session Typert lookups.
89
95
  * Live Agents are reused, ordinary cold sessions resume once per identity, and
90
96
  * subagent-owned identities retain the legacy `agent-busy` fence.
91
97
  * @param ctx - owning Host Context.
92
98
  * @param options - defaults and Agent-scope setup used only for cold resume.
93
- * @returns resolver shared by legacy API Proxy methods and TypeRT lookups.
99
+ * @returns resolver shared by legacy API Proxy methods and Typert lookups.
94
100
  */
95
101
  function createApiRemoteAgentResolver(ctx, options) {
96
102
  const resumes = /* @__PURE__ */ new Map();
@@ -149,7 +155,7 @@ function createApiRemoteAgentResolver(ctx, options) {
149
155
  ctx.inject(["typert"], (typeCtx) => {
150
156
  const resolveAgent = async (sessionId) => {
151
157
  const found = await agentFor(sessionId);
152
- if ("error" in found) throw new TypeRTLookupFailure(found.error);
158
+ if ("error" in found) throw new TypertLookupFailure(found.error);
153
159
  return found.agent;
154
160
  };
155
161
  typeCtx.typert.lookups.configure("agent", resolveAgent);
package/lib/invariant.js CHANGED
@@ -5,7 +5,7 @@ const PACKAGE_NAME = "@deepseek-ai/dsh-api-remotes";
5
5
  const name = "api-remotes-invariant";
6
6
  /** Service required before the companion can reserve package ownership. */
7
7
  const inject = ["invariants"];
8
- /** No runtime invariant: TypeRT and the Agent/Session registries own the observed relationships. */
8
+ /** No runtime invariant: Typert and the Agent/Session registries own the observed relationships. */
9
9
  const install = () => {};
10
10
  /**
11
11
  * Register this package's invariant companion.
@@ -84,12 +84,12 @@ export declare function inspectApiRemoteSession(ctx: Context, sessionId: Session
84
84
  events: SessionEvent[];
85
85
  }>;
86
86
  /**
87
- * Create the Host's shared Agent resolver and configure Agent/Session TypeRT lookups.
87
+ * Create the Host's shared Agent resolver and configure Agent/Session Typert lookups.
88
88
  * Live Agents are reused, ordinary cold sessions resume once per identity, and
89
89
  * subagent-owned identities retain the legacy `agent-busy` fence.
90
90
  * @param ctx - owning Host Context.
91
91
  * @param options - defaults and Agent-scope setup used only for cold resume.
92
- * @returns resolver shared by legacy API Proxy methods and TypeRT lookups.
92
+ * @returns resolver shared by legacy API Proxy methods and Typert lookups.
93
93
  */
94
94
  export declare function createApiRemoteAgentResolver(ctx: Context, options: ApiRemoteAgentOptions): (sessionId: SessionId) => Promise<ApiRemoteAgentResult>;
95
95
  //# sourceMappingURL=agent-lookup.d.ts.map
@@ -1,5 +1,5 @@
1
1
  /** Host BFF policy for resolving Remote Agent and Session identities. */
2
- import { TypeRTLookupFailure } from '@deepseek-ai/dsh-type-meta';
2
+ import { TypertLookupFailure } from '@deepseek-ai/dsh-typert-protocol';
3
3
  /** Cold identity absent from the durable session store. */
4
4
  export class ApiRemoteSessionNotFound extends Error {
5
5
  }
@@ -66,12 +66,12 @@ export async function inspectApiRemoteSession(ctx, sessionId) {
66
66
  return { meta: inspected.meta, events: [...inspected.events] };
67
67
  }
68
68
  /**
69
- * Create the Host's shared Agent resolver and configure Agent/Session TypeRT lookups.
69
+ * Create the Host's shared Agent resolver and configure Agent/Session Typert lookups.
70
70
  * Live Agents are reused, ordinary cold sessions resume once per identity, and
71
71
  * subagent-owned identities retain the legacy `agent-busy` fence.
72
72
  * @param ctx - owning Host Context.
73
73
  * @param options - defaults and Agent-scope setup used only for cold resume.
74
- * @returns resolver shared by legacy API Proxy methods and TypeRT lookups.
74
+ * @returns resolver shared by legacy API Proxy methods and Typert lookups.
75
75
  */
76
76
  export function createApiRemoteAgentResolver(ctx, options) {
77
77
  const resumes = new Map();
@@ -154,7 +154,7 @@ export function createApiRemoteAgentResolver(ctx, options) {
154
154
  const resolveAgent = async (sessionId) => {
155
155
  const found = await agentFor(sessionId);
156
156
  if ('error' in found)
157
- throw new TypeRTLookupFailure(found.error);
157
+ throw new TypertLookupFailure(found.error);
158
158
  return found.agent;
159
159
  };
160
160
  typeCtx.typert.lookups.configure('agent', resolveAgent);
@@ -1,24 +1,33 @@
1
1
  /** Platform-neutral assembly of generated Host Remote contributions. */
2
2
  import type { Context } from '@deepseek-ai/cordis';
3
- import type { TypeRTClientRemote } from '@deepseek-ai/dsh-type-meta';
4
- export type { TypeRTClientRemote as ClientRemote } from '@deepseek-ai/dsh-type-meta';
3
+ import type { TypertClientRemote } from '@deepseek-ai/dsh-typert-protocol';
4
+ export type { TypertClientRemote as ClientRemote } from '@deepseek-ai/dsh-typert-protocol';
5
+ export type { PluginInventorySnapshot } from '@deepseek-ai/dsh-host-plugin-inventory/types';
6
+ export type {} from '@deepseek-ai/dsh-commands/remote';
5
7
  export type {} from '@deepseek-ai/dsh-goal/remote';
8
+ export type {} from '@deepseek-ai/dsh-host-plugin-inventory/remote';
9
+ export type {} from '@deepseek-ai/dsh-message-feedback/remote';
6
10
  export type { ApiRemoteForwardedEvent } from '../types.ts';
7
11
  export type {} from '@deepseek-ai/dsh-commands/types';
12
+ export type {} from '@deepseek-ai/dsh-cordis-host-runner/types';
8
13
  export type {} from '@deepseek-ai/dsh-credentials/types';
9
14
  export type {} from '@deepseek-ai/dsh-llm/types';
10
15
  export type {} from '@deepseek-ai/dsh-agent-presets/types';
11
16
  export type {} from '@deepseek-ai/dsh-settings/types';
12
17
  /**
13
- * The Gateway Client face's own declaration merges, type-only: `ctx.remote` and
14
- * with it the `$on`/`$dispatch` surface. Erased at emit, so this facade still
15
- * carries no runtime edge to the Gateway implementation.
18
+ * The carrier's Client-facing types, re-exported so a business package names one
19
+ * assembly package instead of both this facade and the Connection plugin. Type-only:
20
+ * the carrier's runtime values stay behind their own module edge.
16
21
  */
22
+ export type { ClientResponse, ConfigurableProviderView, ConnectionHandle, ConnectionSinks, ContentBlock, CredentialView, DirectoryListing, DiscoveredModelView, HistoryEntry, HostFrame, IApiClient, MessageId, ModelCatalogFailure, ModelProviderGroup, ModelReasoningEffort, ModelSelection, MuxFrame, PromptContentPart, QuestionResponsePayload, QueueAction, RpcError, RpcId, RpcReceipt, RpcRequest, RpcResponse, RpcResult, SessionId, SessionModels, SessionSearchItem, SessionSummary, SettingsNamespaceView, SettingsPathOpView, SkillEntry, StreamChunk, SubagentAddress, SubagentCatalog, JobView, ToolCallView, ToolEventView, ToolResultView, WorkspaceId, WorkspaceView, } from '@deepseek-ai/dsh-client-connection/client';
17
23
  export type {} from '@deepseek-ai/dsh-api-gateway/client';
24
+ export type {} from '@deepseek-ai/dsh-cordis-host-runner/remote';
25
+ export type { ApprovalRequestId, CordisHalfState, CordisDynamicPackageId, CordisDynamicPluginId, CordisDynamicPluginRunId, CordisDynamicRunMode, CordisInspectMethodManifest, CordisInspectPlatform, CordisInspectProviderManifest, CordisInspectProviderView, CordisInspectQueryRequest, CordisInspectQueryResolution, CordisInspectQueryResolved, CordisInspectRequestId, CordisInspectResolveAck, CordisRunDiagnostic, CordisRunStatus, DynamicCordisClientSource, DynamicCordisHostHalfResult, DynamicCordisInventoryRow, DynamicCordisInvokeResult, DynamicCordisPackage, DynamicCordisRequestResolved, DynamicCordisResolveAck, DynamicCordisRetracted, DynamicCordisRunRequest, DynamicCordisRunResolution, DynamicCordisRunAttempt, DynamicCordisRunResponse, DynamicCordisStopResponse, DynamicCordisUndefineReceipt, RequestRunOutcome, } from '@deepseek-ai/dsh-cordis-host-runner/types';
26
+ export type { JsonValue } from '@deepseek-ai/dsh-session/types';
18
27
  declare module '@deepseek-ai/cordis' {
19
28
  interface Context {
20
29
  /** Generated Remote namespaces selected by this Client assembly. */
21
- remote: TypeRTClientRemote;
30
+ remote: TypertClientRemote;
22
31
  }
23
32
  }
24
33
  /** Required service: the typed Client Remote contribution mount. */
@@ -1,5 +1,9 @@
1
1
  /** Platform-neutral assembly of generated Host Remote contributions. */
2
+ import commandsRemote from '@deepseek-ai/dsh-commands/remote';
2
3
  import goalsRemote from '@deepseek-ai/dsh-goal/remote';
4
+ import dynamicRemote from '@deepseek-ai/dsh-cordis-host-runner/remote';
5
+ import pluginInventoryRemote from '@deepseek-ai/dsh-host-plugin-inventory/remote';
6
+ import messageFeedbackRemote from '@deepseek-ai/dsh-message-feedback/remote';
3
7
  /** Required service: the typed Client Remote contribution mount. */
4
8
  export const inject = ['remote'];
5
9
  /**
@@ -8,6 +12,24 @@ export const inject = ['remote'];
8
12
  * @returns disposer after every selected Remote namespace is ready.
9
13
  */
10
14
  export async function apply(ctx) {
11
- return await ctx.remote.$mount(goalsRemote);
15
+ const disposers = [];
16
+ try {
17
+ for (const contribution of [
18
+ commandsRemote, goalsRemote, dynamicRemote, pluginInventoryRemote, messageFeedbackRemote,
19
+ ]) {
20
+ disposers.push(await ctx.remote.$mount(contribution));
21
+ }
22
+ }
23
+ catch (error) {
24
+ for (const dispose of disposers.reverse())
25
+ await dispose();
26
+ throw error;
27
+ }
28
+ // Unwound in reverse mount order, so a namespace never outlives one mounted
29
+ // after it.
30
+ return async () => {
31
+ for (const dispose of disposers.reverse())
32
+ await dispose();
33
+ };
12
34
  }
13
35
  //# sourceMappingURL=index.js.map
@@ -4,7 +4,7 @@ const PACKAGE_NAME = '@deepseek-ai/dsh-api-remotes';
4
4
  export const name = 'api-remotes-invariant';
5
5
  /** Service required before the companion can reserve package ownership. */
6
6
  export const inject = ['invariants'];
7
- /** No runtime invariant: TypeRT and the Agent/Session registries own the observed relationships. */
7
+ /** No runtime invariant: Typert and the Agent/Session registries own the observed relationships. */
8
8
  const install = () => { };
9
9
  /**
10
10
  * Register this package's invariant companion.
@@ -13,5 +13,5 @@
13
13
  * `ctx.remote.$on`. Forwarding one more event is an entry here and nothing
14
14
  * else.
15
15
  */
16
- export declare const API_REMOTE_FORWARDED_EVENTS: readonly ["agent-preset/selected", "commands/change", "credentials/updated", "llm/adapters-updated", "settings/document-updated"];
16
+ export declare const API_REMOTE_FORWARDED_EVENTS: readonly ["agent-preset/selected", "commands/change", "credentials/updated", "cordis/request-run", "cordis/request-run-resolved", "cordis/dynamic-package", "cordis/dynamic-retract", "cordis/inspect-query", "cordis/inspect-query-resolved", "llm/adapters-updated", "settings/document-updated"];
17
17
  //# sourceMappingURL=remote-events.d.ts.map
@@ -17,6 +17,12 @@ export const API_REMOTE_FORWARDED_EVENTS = [
17
17
  'agent-preset/selected',
18
18
  'commands/change',
19
19
  'credentials/updated',
20
+ 'cordis/request-run',
21
+ 'cordis/request-run-resolved',
22
+ 'cordis/dynamic-package',
23
+ 'cordis/dynamic-retract',
24
+ 'cordis/inspect-query',
25
+ 'cordis/inspect-query-resolved',
20
26
  'llm/adapters-updated',
21
27
  'settings/document-updated',
22
28
  ];
@@ -11,8 +11,8 @@
11
11
  import type { API_REMOTE_FORWARDED_EVENTS } from './remote-events.ts';
12
12
  /** Type projection of the allowlist; the consumer and the Host read this one. */
13
13
  export type ApiRemoteForwardedEvent = typeof API_REMOTE_FORWARDED_EVENTS[number];
14
- declare module '@deepseek-ai/dsh-type-meta' {
15
- interface TypeRTRemoteEventSelection extends Record<ApiRemoteForwardedEvent, true> {
14
+ declare module '@deepseek-ai/dsh-typert-protocol' {
15
+ interface TypertRemoteEventSelection extends Record<ApiRemoteForwardedEvent, true> {
16
16
  }
17
17
  }
18
18
  //# sourceMappingURL=types.d.ts.map
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@deepseek-ai/dsh-api-remotes",
3
3
  "description": "Remote BFF assembly and Host Agent/Session lookup policy",
4
- "version": "0.0.1-rc.2",
4
+ "version": "0.0.1-rc.3",
5
5
  "publishConfig": {
6
6
  "access": "restricted"
7
7
  },
@@ -51,37 +51,43 @@
51
51
  "lib/types/**/*.d.ts"
52
52
  ],
53
53
  "dependencies": {
54
- "@deepseek-ai/dsh-type-meta": "^0.0.1-rc.2"
54
+ "@deepseek-ai/dsh-typert-protocol": "^0.0.1-rc.3"
55
55
  },
56
56
  "peerDependencies": {
57
57
  "@deepseek-ai/cordis": "^4.0.1-rc.1",
58
- "@deepseek-ai/dsh-api-gateway": "^0.0.1-rc.2",
59
- "@deepseek-ai/dsh-commands": "^0.0.1-rc.2",
60
- "@deepseek-ai/dsh-credentials": "^0.0.1-rc.2",
61
- "@deepseek-ai/dsh-goal": "^0.0.1-rc.2",
62
- "@deepseek-ai/dsh-invariants": "^0.0.1-rc.2",
63
- "@deepseek-ai/dsh-agent": "^0.0.1-rc.2",
64
- "@deepseek-ai/dsh-llm": "^0.0.1-rc.2",
65
- "@deepseek-ai/dsh-session": "^0.0.1-rc.2",
66
- "@deepseek-ai/dsh-session-persistence": "^0.0.1-rc.2",
67
- "@deepseek-ai/dsh-settings": "^0.0.1-rc.2",
68
- "@deepseek-ai/dsh-typert-registry": "^0.0.1-rc.2",
69
- "@deepseek-ai/dsh-agent-presets": "^0.0.1-rc.2"
58
+ "@deepseek-ai/dsh-api-gateway": "^0.0.1-rc.3",
59
+ "@deepseek-ai/dsh-agent": "^0.0.1-rc.3",
60
+ "@deepseek-ai/dsh-commands": "^0.0.1-rc.3",
61
+ "@deepseek-ai/dsh-credentials": "^0.0.1-rc.3",
62
+ "@deepseek-ai/dsh-goal": "^0.0.1-rc.3",
63
+ "@deepseek-ai/dsh-cordis-host-runner": "^0.0.1-rc.3",
64
+ "@deepseek-ai/dsh-invariants": "^0.0.1-rc.3",
65
+ "@deepseek-ai/dsh-host-plugin-inventory": "^0.0.1-rc.3",
66
+ "@deepseek-ai/dsh-agent-presets": "^0.0.1-rc.3",
67
+ "@deepseek-ai/dsh-llm": "^0.0.1-rc.3",
68
+ "@deepseek-ai/dsh-session": "^0.0.1-rc.3",
69
+ "@deepseek-ai/dsh-session-persistence": "^0.0.1-rc.3",
70
+ "@deepseek-ai/dsh-settings": "^0.0.1-rc.3",
71
+ "@deepseek-ai/dsh-typert-registry": "^0.0.1-rc.3",
72
+ "@deepseek-ai/dsh-message-feedback": "^0.0.1-rc.3"
70
73
  },
71
74
  "devDependencies": {
72
- "@deepseek-ai/dsh-api-gateway": "^0.0.1-rc.2",
73
- "@deepseek-ai/dsh-agent": "^0.0.1-rc.2",
74
- "@deepseek-ai/dsh-commands": "^0.0.1-rc.2",
75
- "@deepseek-ai/dsh-credentials": "^0.0.1-rc.2",
76
- "@deepseek-ai/dsh-goal": "^0.0.1-rc.2",
77
- "@deepseek-ai/dsh-invariants": "^0.0.1-rc.2",
78
- "@deepseek-ai/dsh-llm": "^0.0.1-rc.2",
79
- "@deepseek-ai/dsh-agent-presets": "^0.0.1-rc.2",
80
- "@deepseek-ai/dsh-session": "^0.0.1-rc.2",
81
- "@deepseek-ai/dsh-settings": "^0.0.1-rc.2",
82
- "@deepseek-ai/dsh-typert-registry": "^0.0.1-rc.2",
75
+ "@deepseek-ai/dsh-agent": "^0.0.1-rc.3",
76
+ "@deepseek-ai/dsh-api-gateway": "^0.0.1-rc.3",
77
+ "@deepseek-ai/dsh-commands": "^0.0.1-rc.3",
78
+ "@deepseek-ai/dsh-credentials": "^0.0.1-rc.3",
79
+ "@deepseek-ai/dsh-goal": "^0.0.1-rc.3",
80
+ "@deepseek-ai/dsh-cordis-host-runner": "^0.0.1-rc.3",
81
+ "@deepseek-ai/dsh-host-plugin-inventory": "^0.0.1-rc.3",
82
+ "@deepseek-ai/dsh-invariants": "^0.0.1-rc.3",
83
+ "@deepseek-ai/dsh-agent-presets": "^0.0.1-rc.3",
84
+ "@deepseek-ai/dsh-message-feedback": "^0.0.1-rc.3",
85
+ "@deepseek-ai/dsh-session": "^0.0.1-rc.3",
86
+ "@deepseek-ai/dsh-session-persistence": "^0.0.1-rc.3",
87
+ "@deepseek-ai/dsh-settings": "^0.0.1-rc.3",
88
+ "@deepseek-ai/dsh-typert-registry": "^0.0.1-rc.3",
83
89
  "@deepseek-ai/cordis": "^4.0.1-rc.1",
84
- "@deepseek-ai/dsh-session-persistence": "^0.0.1-rc.2"
90
+ "@deepseek-ai/dsh-llm": "^0.0.1-rc.3"
85
91
  },
86
92
  "scripts": {
87
93
  "bundle": "tsdown",