@xopcai/xopc 0.0.462 → 0.0.463
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/browser-ext/_locales/en/messages.json +1 -0
- package/dist/browser-ext/_locales/zh_CN/messages.json +1 -0
- package/dist/browser-ext/dist/assets/{auth-CQmxIyWw.js → auth-YPMDpWOW.js} +32 -1
- package/dist/browser-ext/dist/background.js +24 -19
- package/dist/browser-ext/dist/sidepanel.html +1 -1
- package/dist/browser-ext/dist/sidepanel.js +7 -7
- package/dist/browser-ext/manifest.json +1 -1
- package/dist/extensions/telegram/xopc.extension.json +1 -1
- package/dist/gateway/static/root/assets/agent-plugin-dialog-C_rlXuEe.js +1 -0
- package/dist/gateway/static/root/assets/{apps-page-QLOYw2QR.js → apps-page-D1qzENN_.js} +1 -1
- package/dist/gateway/static/root/assets/{automations-page-DpKnqajR.js → automations-page-HYFnPiNG.js} +1 -1
- package/dist/gateway/static/root/assets/{automations-workspace-BXT_EDON.js → automations-workspace-JCQ1IXFk.js} +2 -2
- package/dist/gateway/static/root/assets/{capabilities-page-CnU0htlO.js → capabilities-page-kPv2dOzf.js} +2 -2
- package/dist/gateway/static/root/assets/{chat-page-U2a7d6wP.js → chat-page-CalELOKj.js} +6 -6
- package/dist/gateway/static/root/assets/{connectors-page-Bs29RvXz.js → connectors-page-B9mpz_Rt.js} +1 -1
- package/dist/gateway/static/root/assets/{index-CEBDMkde.js → index-DUo6H0PC.js} +4 -4
- package/dist/gateway/static/root/assets/mcp-conversation-setup-page-DCIEL5bA.js +1 -0
- package/dist/gateway/static/root/assets/{note-detail-panel-D_l5jkV9.js → note-detail-panel-DsXb1qjW.js} +2 -2
- package/dist/gateway/static/root/assets/{notes-page-R4uJroeD.js → notes-page-BTpiOw67.js} +1 -1
- package/dist/gateway/static/root/assets/{personal-page-BsONyPfQ.js → personal-page-I3IGVSJh.js} +1 -1
- package/dist/gateway/static/root/assets/{plugin-details-dialog-nSDw8sfo.js → plugin-details-dialog-F08k_k2u.js} +1 -1
- package/dist/gateway/static/root/assets/{project-detail-page-xNSy6SAv.js → project-detail-page-Dy46uSEt.js} +1 -1
- package/dist/gateway/static/root/assets/{route-preload-Dwb_N8L-.js → route-preload-ChTaYgpA.js} +2 -2
- package/dist/gateway/static/root/assets/{service-recommendation-list-DDlMyPvC.js → service-recommendation-list-BmRtbJz2.js} +1 -1
- package/dist/gateway/static/root/assets/{settings-page-8MiJzbbl.js → settings-page-C39lKVRv.js} +1 -1
- package/dist/gateway/static/root/assets/{task-detail-page-DxKXoBbE.js → task-detail-page-D1dNWTnP.js} +1 -1
- package/dist/gateway/static/root/assets/{work-discovery-overlay-UvWbDUXi.js → work-discovery-overlay-BJ15p4rH.js} +1 -1
- package/dist/gateway/static/root/assets/{work-discovery-page-BM1HsYz6.js → work-discovery-page-8XciWNs5.js} +1 -1
- package/dist/gateway/static/root/index.html +6 -6
- package/dist/package.js +1 -1
- package/dist/src/agent/embedded/session-runner.js +2 -2
- package/dist/src/agent/external-tools/gateway-tools.js +8 -1
- package/dist/src/agent/mcp/connection-setup.js +46 -42
- package/dist/src/agent/mcp/conversation-setup.js +13 -8
- package/dist/src/agent/mcp/discovery.d.ts +22 -1
- package/dist/src/agent/mcp/discovery.js +19 -3
- package/dist/src/agent/mcp/managed-discovery.d.ts +8 -0
- package/dist/src/agent/mcp/managed-discovery.js +77 -0
- package/dist/src/agent/mcp/tool-catalog.js +1 -1
- package/dist/src/agent/prompt/conversational-configuration-guide.js +1 -1
- package/dist/src/agent/skills/marketplace/adapters/store/store-api-client.d.ts +6 -2
- package/dist/src/agent/skills/marketplace/adapters/store/store-api-client.js +10 -7
- package/dist/src/agent/tool-manuals/xopc-configuration.d.ts +1 -1
- package/dist/src/agent/tool-manuals/xopc-configuration.js +12 -4
- package/dist/src/cli/commands/extension-agent-plugin.js +1 -1
- package/dist/src/cli/commands/gateway/lifecycle.js +2 -2
- package/dist/src/cli/commands/update.js +1 -1
- package/dist/src/connectors/connection-recovery-service.js +38 -5
- package/dist/src/connectors/excluded-connectors.d.ts +1 -0
- package/dist/src/connectors/excluded-connectors.js +5 -1
- package/dist/src/connectors/plugin-connection.d.ts +10 -0
- package/dist/src/connectors/plugin-connection.js +105 -0
- package/dist/src/extensions/agent-plugins/setup.js +1 -1
- package/dist/src/extensions/agent-plugins/skill-catalog.js +1 -1
- package/dist/src/gateway/hono/middleware/auth.js +1 -1
- package/dist/src/gateway/hono/routes/agent-plugins.js +2 -2
- package/dist/src/gateway/hono/routes/auth-registry-extensions.js +1 -1
- package/dist/src/gateway/hono/routes/connectors.js +1 -1
- package/dist/src/gateway/hono/routes/desktop-host.js +1 -1
- package/dist/src/gateway/hono/routes/home.js +1 -1
- package/dist/src/gateway/hono/routes/imports.js +1 -1
- package/dist/src/gateway/hono/routes/personal-agent.js +3 -3
- package/dist/src/gateway/hono/routes/update.js +2 -2
- package/dist/src/gateway/index.js +1 -1
- package/dist/src/gateway/run-loop.js +2 -2
- package/dist/src/gateway/security/gateway-scopes.js +1 -0
- package/dist/src/gateway/service/agent-runner.js +1 -1
- package/dist/src/gateway/service/run-gateway-agent.js +1 -1
- package/dist/src/gateway/service.js +11 -11
- package/dist/src/home-intelligence/host.js +5 -5
- package/dist/src/infra/gateway-processes.js +1 -1
- package/dist/src/infra/update-restart.js +2 -2
- package/dist/src/infra/update-runner.js +2 -2
- package/dist/src/infra/update-startup.js +1 -1
- package/dist/src/notifications/service.js +2 -2
- package/dist/src/phone/stream-gateway.js +1 -1
- package/dist/src/tui/tui-management.js +2 -2
- package/package.json +1 -1
- package/dist/gateway/static/root/assets/agent-plugin-dialog-CikzCYAG.js +0 -1
- package/dist/gateway/static/root/assets/mcp-conversation-setup-page-CsTSmjmX.js +0 -1
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
import { init_agent_scope, resolveAgentWorkspaceDir } from "../agent/agent-scope.js";
|
|
2
|
+
import { resolvePluginCapabilityAccess } from "../extensions/agent-plugins/capability-access.js";
|
|
3
|
+
import { AgentPluginStore } from "../extensions/agent-plugins/store.js";
|
|
4
|
+
import { fetchMarketplacePackageDetail, resolveExtensionsStoreBaseUrl } from "../agent/skills/marketplace/adapters/store/store-api-client.js";
|
|
5
|
+
import { agentPluginInventoryRow } from "../extensions/agent-plugins/inventory.js";
|
|
6
|
+
import { PluginSetupService } from "../extensions/agent-plugins/setup.js";
|
|
7
|
+
import { resolve } from "node:path";
|
|
8
|
+
import { existsSync, realpathSync } from "node:fs";
|
|
9
|
+
//#region src/connectors/plugin-connection.ts
|
|
10
|
+
init_agent_scope();
|
|
11
|
+
async function resolvePluginConnectionCandidate(ref, config) {
|
|
12
|
+
const installed = /^agent-plugin:([a-z0-9.-]+)$/.exec(ref)?.[1];
|
|
13
|
+
if (installed) {
|
|
14
|
+
const plugin = new AgentPluginStore().get(installed);
|
|
15
|
+
if (!plugin) throw new Error("The requested plugin is no longer installed.");
|
|
16
|
+
return {
|
|
17
|
+
key: ref,
|
|
18
|
+
label: plugin.manifest.name,
|
|
19
|
+
capabilities: ["tools"],
|
|
20
|
+
target: {
|
|
21
|
+
type: "plugin",
|
|
22
|
+
pluginId: installed,
|
|
23
|
+
revision: plugin.receipt.revision
|
|
24
|
+
},
|
|
25
|
+
unavailable: true
|
|
26
|
+
};
|
|
27
|
+
}
|
|
28
|
+
const packageName = /^store-plugin:([a-z0-9.-]+)$/.exec(ref)?.[1];
|
|
29
|
+
if (!packageName) return void 0;
|
|
30
|
+
if (!config) throw new Error("The Store is unavailable in this session.");
|
|
31
|
+
const detail = await fetchMarketplacePackageDetail(resolveExtensionsStoreBaseUrl(config), packageName, AbortSignal.timeout(6e3));
|
|
32
|
+
if (detail.type !== "plugin" || !detail.latestVersion?.version) throw new Error("No matching plugin is available in the Store.");
|
|
33
|
+
return {
|
|
34
|
+
key: ref,
|
|
35
|
+
label: detail.localizations?.en?.displayName ?? packageName,
|
|
36
|
+
capabilities: ["tools"],
|
|
37
|
+
target: {
|
|
38
|
+
type: "plugin",
|
|
39
|
+
packageName,
|
|
40
|
+
version: detail.latestVersion.version
|
|
41
|
+
},
|
|
42
|
+
unavailable: true
|
|
43
|
+
};
|
|
44
|
+
}
|
|
45
|
+
function readPluginConnection(need, agentId) {
|
|
46
|
+
const { target } = need;
|
|
47
|
+
const base = {
|
|
48
|
+
...need,
|
|
49
|
+
authorizationMode: "desktop",
|
|
50
|
+
accounts: []
|
|
51
|
+
};
|
|
52
|
+
const blocked = (reason) => ({
|
|
53
|
+
view: {
|
|
54
|
+
...base,
|
|
55
|
+
phase: "blocked",
|
|
56
|
+
reason
|
|
57
|
+
},
|
|
58
|
+
verified: false
|
|
59
|
+
});
|
|
60
|
+
try {
|
|
61
|
+
const store = new AgentPluginStore();
|
|
62
|
+
const plugin = "pluginId" in target ? store.get(target.pluginId) : store.list().find((item) => item.receipt.provenance?.packageName === target.packageName);
|
|
63
|
+
if (!plugin) return "packageName" in target ? {
|
|
64
|
+
view: {
|
|
65
|
+
...base,
|
|
66
|
+
phase: "install"
|
|
67
|
+
},
|
|
68
|
+
verified: false
|
|
69
|
+
} : blocked("The plugin is no longer installed.");
|
|
70
|
+
if (!("pluginId" in target ? plugin.receipt.revision === target.revision : plugin.receipt.provenance?.version === target.version) || plugin.readiness === "blocked" || store.pending(plugin.id)) return blocked("The plugin has changed or is unavailable. Review it in the plugin manager.");
|
|
71
|
+
const workspace = resolveAgentWorkspaceDir(agentId);
|
|
72
|
+
const scope = plugin.receipt.workspacePaths;
|
|
73
|
+
if (scope && !scope.includes(existsSync(workspace) ? realpathSync(workspace) : resolve(workspace))) return blocked("The plugin is unavailable in this workspace. Review its workspace access in the plugin manager.");
|
|
74
|
+
const inventory = agentPluginInventoryRow(plugin, store);
|
|
75
|
+
const job = new PluginSetupService(store).get(plugin.id, "gateway-owner");
|
|
76
|
+
const setup = job?.packageRevision === plugin.receipt.revision ? job : void 0;
|
|
77
|
+
const revision = JSON.stringify([
|
|
78
|
+
plugin.receipt.revision,
|
|
79
|
+
plugin.receipt.enabled,
|
|
80
|
+
setup?.id,
|
|
81
|
+
setup?.revision
|
|
82
|
+
]);
|
|
83
|
+
const active = store.active(agentId, workspace).some((item) => item.id === plugin.id && item.receipt.revision === plugin.receipt.revision);
|
|
84
|
+
const access = resolvePluginCapabilityAccess(plugin, store);
|
|
85
|
+
const usable = plugin.skills.some((skill) => access.skill(skill.name)) || Object.keys(plugin.servers).some((name) => access.server(name) && (!setup || setup.connections.some((item) => item.name === name && (item.toolCount ?? 0) > 0)));
|
|
86
|
+
const finished = !setup || !setup.deferred && (setup.state === "completed" || Boolean(need.connectionId) && setup.installed && setup.resources === "ready" && setup.state === "action_required");
|
|
87
|
+
const setupVerified = active && usable && inventory.authorizationStatus !== "required" && finished;
|
|
88
|
+
const freshSetup = need.attempt && (!setup || need.attempt.connectionId !== revision);
|
|
89
|
+
const verified = setupVerified && (!need.unavailable || Boolean(freshSetup));
|
|
90
|
+
const phase = verified ? "ready" : setup?.state === "running" ? "authorizing" : plugin.receipt.enabled && (need.unavailable || inventory.authorizationStatus === "required") ? "reconnect" : "connect";
|
|
91
|
+
return {
|
|
92
|
+
revision,
|
|
93
|
+
verified,
|
|
94
|
+
view: {
|
|
95
|
+
...base,
|
|
96
|
+
pluginId: plugin.id,
|
|
97
|
+
phase
|
|
98
|
+
}
|
|
99
|
+
};
|
|
100
|
+
} catch {
|
|
101
|
+
return blocked("The plugin setup state is unavailable. Review it in the plugin manager.");
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
//#endregion
|
|
105
|
+
export { readPluginConnection, resolvePluginConnectionCandidate };
|
|
@@ -7,12 +7,12 @@ import { pluginName, pluginServerId } from "./validation.js";
|
|
|
7
7
|
import { AgentPluginStore } from "./store.js";
|
|
8
8
|
import { readPluginAuthBinding, savePluginAuthBinding, savePluginOAuthReference } from "./auth.js";
|
|
9
9
|
import { pluginConfigMissing, readPluginUserConfig, savePluginUserConfig } from "./user-config.js";
|
|
10
|
+
import { cancelPluginCliAuthorizations, getPluginCliAuthorization, inspectPluginCliAuthorization, startPluginCliAuthorization } from "./cli-authorization.js";
|
|
10
11
|
import { materializePluginServers } from "./mcp-adapter.js";
|
|
11
12
|
import { connectionFingerprint, matchingReusableConnection } from "./connection-reuse.js";
|
|
12
13
|
import { createNativeMcpCredentials } from "../../agent/mcp/credential-store.js";
|
|
13
14
|
import { getNativePiAgentDir } from "../../agent/mcp/native-mcp.js";
|
|
14
15
|
import { cancelMcpAuthorization, getMcpAuthorization, probeMcpConnection, startMcpAuthorization, submitMcpRedirect } from "../../agent/mcp/connection-setup.js";
|
|
15
|
-
import { cancelPluginCliAuthorizations, getPluginCliAuthorization, inspectPluginCliAuthorization, startPluginCliAuthorization } from "./cli-authorization.js";
|
|
16
16
|
import { join } from "node:path";
|
|
17
17
|
import { existsSync, readFileSync } from "node:fs";
|
|
18
18
|
import { randomUUID } from "node:crypto";
|
|
@@ -2,10 +2,10 @@ import { containedPath } from "./contained-path.js";
|
|
|
2
2
|
import "./validation.js";
|
|
3
3
|
import { AgentPluginStore } from "./store.js";
|
|
4
4
|
import { parseFrontmatter } from "../../markdown/frontmatter.js";
|
|
5
|
+
import { agentPluginInventoryRow } from "./inventory.js";
|
|
5
6
|
import { createSkillConfigManager } from "../../agent/skills/config.js";
|
|
6
7
|
import { parseSkillLocalizations } from "../../agent/skills/parse-skill-metadata.js";
|
|
7
8
|
import { buildSkillMarkdownPreviewFromRaw } from "../../agent/skills/skill-markdown-preview-from-raw.js";
|
|
8
|
-
import { agentPluginInventoryRow } from "./inventory.js";
|
|
9
9
|
import { basename, dirname } from "node:path";
|
|
10
10
|
import { readFileSync } from "node:fs";
|
|
11
11
|
//#region src/extensions/agent-plugins/skill-catalog.ts
|
|
@@ -8,9 +8,9 @@ import "../../rate-limit/index.js";
|
|
|
8
8
|
import { authenticateDeviceAccessToken, getDevice } from "../../../storage/sqlite/device-access-repository.js";
|
|
9
9
|
import { getOrCreateGatewayIdentity } from "../../../storage/sqlite/gateway-identity-repository.js";
|
|
10
10
|
import { getDesktopExecutionGrant } from "../../../storage/sqlite/desktop-execution-repository.js";
|
|
11
|
+
import { PROOF_HEADER, acquireProofBodyBudget, consumeRequestNonce, parseRequestProof, proofDigest, requestProofMessage, verifyRequestProofSignature } from "../../security/device-request-proof.js";
|
|
11
12
|
import { safeEqualSecret } from "../../security/secret-equal.js";
|
|
12
13
|
import { resolveClientIpFromRequest } from "../../client-ip.js";
|
|
13
|
-
import { PROOF_HEADER, acquireProofBodyBudget, consumeRequestNonce, parseRequestProof, proofDigest, requestProofMessage, verifyRequestProofSignature } from "../../security/device-request-proof.js";
|
|
14
14
|
import { authenticateBrowserSession } from "../../../storage/sqlite/browser-session-repository.js";
|
|
15
15
|
import { isChromeExtensionOrigin } from "../../security/origin-check.js";
|
|
16
16
|
import { browserCookieRequestAllowed, readBrowserSessionCookie, writeBrowserSessionCookie } from "../../security/browser-session.js";
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { PluginSelectionRequired } from "../../../extensions/agent-plugins/source-catalog.js";
|
|
2
2
|
import { AgentPluginStore } from "../../../extensions/agent-plugins/store.js";
|
|
3
3
|
import { getWorkspacePath } from "../../../config/workspace-path-helpers.js";
|
|
4
|
+
import { agentPluginInventoryRow } from "../../../extensions/agent-plugins/inventory.js";
|
|
4
5
|
import { savePluginAuthBinding } from "../../../extensions/agent-plugins/auth.js";
|
|
5
|
-
import { evictAllEmbeddedSessionRunners } from "../../../agent/embedded/session-runner.js";
|
|
6
6
|
import { cancelPluginCliAuthorizations } from "../../../extensions/agent-plugins/cli-authorization.js";
|
|
7
7
|
import { PluginSetupService, setupActionSchema } from "../../../extensions/agent-plugins/setup.js";
|
|
8
|
-
import {
|
|
8
|
+
import { evictAllEmbeddedSessionRunners } from "../../../agent/embedded/session-runner.js";
|
|
9
9
|
import { withAgentPluginSource } from "../../../extensions/agent-plugins/sources.js";
|
|
10
10
|
import { getGatewayPrincipal } from "../../security/gateway-principal.js";
|
|
11
11
|
import { removePluginCredentials } from "../../../extensions/agent-plugins/credentials.js";
|
|
@@ -5,6 +5,7 @@ import { getAllModels, getAvailableModels, init_providers } from "../../../provi
|
|
|
5
5
|
import { CapabilityError } from "../../../capabilities/runtime/errors.js";
|
|
6
6
|
import { listAutomations } from "../../../automations/storage/automation-repository.js";
|
|
7
7
|
import "../../../automations/storage/index.js";
|
|
8
|
+
import { listAgentPluginInventory } from "../../../extensions/agent-plugins/inventory.js";
|
|
8
9
|
import { automationConfigurationDigest } from "../../../local-apps/capabilities/automation-policy.js";
|
|
9
10
|
import { assertProposalCurrent, automationProposalReview, readAutomationProposal, resolveAutomationProposal } from "../../../local-apps/automation-proposals.js";
|
|
10
11
|
import { assertResourceRequest, localAppConnectorOptions, readAppResourceRequest, resolveAppResourceRequest } from "../../../local-apps/p1-services.js";
|
|
@@ -15,7 +16,6 @@ import { mergeActivationContext } from "../../../extensions/activation-context.j
|
|
|
15
16
|
import { validateExtensionConfig } from "../../../extensions/config-validation.js";
|
|
16
17
|
import { fetchRegistry, listExtensions, searchExtensions } from "../../../extensions/marketplace.js";
|
|
17
18
|
import { getGatewayFileSpaceService } from "../../file-space-service.js";
|
|
18
|
-
import { listAgentPluginInventory } from "../../../extensions/agent-plugins/inventory.js";
|
|
19
19
|
import { getGatewayPrincipal } from "../../security/gateway-principal.js";
|
|
20
20
|
import { createOAuthAsyncHandler } from "../oauth-async.js";
|
|
21
21
|
import { createOAuthHandler } from "../oauth.js";
|
|
@@ -20,7 +20,6 @@ import { createConnectorSetupSecretRequest, submitConnectorSetupSecret } from ".
|
|
|
20
20
|
import { recordConnectorHealthUsage } from "../../../connectors/usage.js";
|
|
21
21
|
import { getConnectorInstance, getInstalledConnectorDefinition, listConnectorInstances } from "../../../connectors/instances.js";
|
|
22
22
|
import { installConnector, installConnectorDefinition, uninstallConnector, updateConnectorConfig } from "../../../connectors/install.js";
|
|
23
|
-
import { ConfigPersistenceError, persistConfigMutation } from "../../../config/config-mutation.js";
|
|
24
23
|
import { resumeApprovedConnectorAction } from "../../../connectors/approval-resume.js";
|
|
25
24
|
import { startConnectorAuthorization } from "../../../connectors/auth-provider-registry.js";
|
|
26
25
|
import { composioLogoResponse } from "../../../connectors/composio-logo.js";
|
|
@@ -28,6 +27,7 @@ import { inspectManagedComposioStatus } from "../../../connectors/composio-manag
|
|
|
28
27
|
import { appendComposioTriggerEvent, listComposioTriggerEvents } from "../../../connectors/composio-triggers.js";
|
|
29
28
|
import { listUnderstandingSourceGrants, revokeUnderstandingSourceGrant } from "../../../user-context/sources/repository.js";
|
|
30
29
|
import { ingestLocalFolderSource } from "../../../connectors/connected-source-ingestion.js";
|
|
30
|
+
import { ConfigPersistenceError, persistConfigMutation } from "../../../config/config-mutation.js";
|
|
31
31
|
import { testConnectorInstance } from "../../../connectors/health.js";
|
|
32
32
|
import { setConnectorEnabled } from "../../../connectors/lifecycle.js";
|
|
33
33
|
import { projectComposioConnectionStatus } from "../../../connectors/runtime-status.js";
|
|
@@ -8,8 +8,8 @@ import { init_src as init_src$1 } from "../../../../packages/endpoint-tools-prot
|
|
|
8
8
|
import { getDesktopExecutionGrant, revokeDesktopExecutionGrant, setDesktopExecutionGrant } from "../../../storage/sqlite/desktop-execution-repository.js";
|
|
9
9
|
import { getDesktopOperationForReview, listDesktopOperationsForReview, reviewDesktopOperation } from "../../../storage/sqlite/desktop-operation-repository.js";
|
|
10
10
|
import { signDesktopAuthorityResponse } from "../../../endpoint-tools/desktop-authority-response.js";
|
|
11
|
-
import { resolveSecureDeviceRoutes } from "../../device-routes.js";
|
|
12
11
|
import { PROOF_HEADER, parseRequestProof } from "../../security/device-request-proof.js";
|
|
12
|
+
import { resolveSecureDeviceRoutes } from "../../device-routes.js";
|
|
13
13
|
import { getGatewayPrincipal } from "../../security/gateway-principal.js";
|
|
14
14
|
import { z } from "zod";
|
|
15
15
|
//#region src/gateway/hono/routes/desktop-host.ts
|
|
@@ -8,8 +8,8 @@ import { acknowledgeHomeAttention } from "../../../storage/sqlite/home-attention
|
|
|
8
8
|
import "../../../storage/sqlite/index.js";
|
|
9
9
|
import { HomeQueryService, buildHomeWorkbench, decisionFromTask } from "../../../tasks/home-query-service.js";
|
|
10
10
|
import { resumeApprovedConnectorAction } from "../../../connectors/approval-resume.js";
|
|
11
|
-
import { ObservationConflictError } from "../../../home-intelligence/observation.js";
|
|
12
11
|
import { HomeOpportunityActionError, HomeOpportunityNotFoundError } from "../../../home-intelligence/application-service.js";
|
|
12
|
+
import { ObservationConflictError } from "../../../home-intelligence/observation.js";
|
|
13
13
|
//#region src/gateway/hono/routes/home.ts
|
|
14
14
|
init_src();
|
|
15
15
|
/** Register the unified work-home read model and its decision actions. */
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { getGatewayPrincipal } from "../../security/gateway-principal.js";
|
|
2
1
|
import { ImportError } from "../../../imports/types.js";
|
|
3
2
|
import { isImportSource } from "../../../imports/sources.js";
|
|
4
3
|
import { ImportSelectionRepository } from "../../../storage/sqlite/import-selection-repository.js";
|
|
5
4
|
import { getLiveInventory, previewInventoryItem, publicInventory, scanProduct } from "../../../imports/inventory.js";
|
|
6
5
|
import { importSelection, listImportSources } from "../../../imports/productImport.js";
|
|
7
6
|
import { createRuntimeImportService } from "../../../imports/runtime.js";
|
|
7
|
+
import { getGatewayPrincipal } from "../../security/gateway-principal.js";
|
|
8
8
|
import { z } from "zod";
|
|
9
9
|
//#region src/gateway/hono/routes/imports.ts
|
|
10
10
|
const selectionSchema = z.object({
|
|
@@ -4,12 +4,12 @@ import { init_voice, voiceCallPreferencesPatchSchema } from "../../../../package
|
|
|
4
4
|
import { getPersonalAgent } from "../../../personal-agent/repository.js";
|
|
5
5
|
import { TaskOriginRepository } from "../../../tasks/task-origin-repository.js";
|
|
6
6
|
import { cancelPersonalRequest, personalRequestSnapshot, publishPersonalRequest } from "../../../personal-agent/request-service.js";
|
|
7
|
-
import { writeAgentAvatarFromBase64 } from "../../agents-admin.js";
|
|
8
|
-
import { legacyNaturalModel } from "../../../voice/realtime/omniRoute.js";
|
|
9
|
-
import { getGatewayPrincipal } from "../../security/gateway-principal.js";
|
|
10
7
|
import { PersonalOnboardingDraftSchema, PersonalOnboardingStepSchema, finishPersonalWelcome, getPersonalOnboarding, savePersonalOnboarding } from "../../../personal-agent/onboarding.js";
|
|
11
8
|
import { PersonalAppearanceSchema, createOrResumePersonalAgent, ensurePersonalConversationVisibility, listPersonalModels, patchPersonalProfile, refreshPersonalDelegationGuidance } from "../../../personal-agent/service.js";
|
|
12
9
|
import { markPersonalRead, personalUnreadSnapshot } from "../../../personal-agent/unread.js";
|
|
10
|
+
import { writeAgentAvatarFromBase64 } from "../../agents-admin.js";
|
|
11
|
+
import { legacyNaturalModel } from "../../../voice/realtime/omniRoute.js";
|
|
12
|
+
import { getGatewayPrincipal } from "../../security/gateway-principal.js";
|
|
13
13
|
import { registerProactivityRoutes } from "../../../personal-agent/proactivity/routes.js";
|
|
14
14
|
import { z } from "zod";
|
|
15
15
|
//#region src/gateway/hono/routes/personal-agent.ts
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { PACKAGE_VERSION, init_package_version } from "../../../package-version.js";
|
|
2
2
|
import { loadConfig } from "../../../config/loader.js";
|
|
3
3
|
import "../../../config/index.js";
|
|
4
|
-
import { acquireUpdateLock } from "../../../infra/update-lock.js";
|
|
5
4
|
import { normalizeUpdateChannel } from "../../../infra/update-channels.js";
|
|
5
|
+
import { acquireUpdateLock } from "../../../infra/update-lock.js";
|
|
6
|
+
import { formatUpdateApiResult, runGatewayUpdateWithPostSteps } from "../../../infra/update-runner.js";
|
|
6
7
|
import { getUpdateAvailable, runGatewayUpdateCheck } from "../../../infra/update-startup.js";
|
|
7
8
|
import { createGatewayRouteLogger } from "../lib/route-logger.js";
|
|
8
|
-
import { formatUpdateApiResult, runGatewayUpdateWithPostSteps } from "../../../infra/update-runner.js";
|
|
9
9
|
import { streamSSE } from "hono/streaming";
|
|
10
10
|
//#region src/gateway/hono/routes/update.ts
|
|
11
11
|
init_package_version();
|
|
@@ -3,6 +3,7 @@ import { buildDefaultCorsOrigins, isAllInterfacesHost, isLoopbackHost, resolveEf
|
|
|
3
3
|
import { isGatewayStrictSecurityEnabled } from "./rate-limit/env-flags.js";
|
|
4
4
|
import "./rate-limit/index.js";
|
|
5
5
|
import { defaultGatewayBindMode, isContainerEnvironment, resolveGatewayBindHost, resolveGatewayBindHostSync, resolveGatewayBindMode, resolveGatewayEffectiveHost } from "../config/gateway-bind.js";
|
|
6
|
+
import { checkPortAvailable, forceFreePortAndWait, listPortListeners, parseLsofOutput } from "./ports.js";
|
|
6
7
|
import { assertGatewayAuthConfigured, extractToken, resolveGatewayAuth, validateToken } from "./auth.js";
|
|
7
8
|
import { resolveGatewayListenHost, resolveGatewayListenPlan } from "./listen.js";
|
|
8
9
|
import { assertGatewayRuntimeConfig } from "./runtime-config.js";
|
|
@@ -12,7 +13,6 @@ import { createHonoApp } from "./hono/app.js";
|
|
|
12
13
|
import { GatewayServer } from "./server.js";
|
|
13
14
|
import { GatewayLockError, acquireGatewayLock } from "./lock.js";
|
|
14
15
|
import { runGatewayLoop } from "./run-loop.js";
|
|
15
|
-
import { checkPortAvailable, forceFreePortAndWait, listPortListeners, parseLsofOutput } from "./ports.js";
|
|
16
16
|
import { apiError, apiOk } from "./protocol.js";
|
|
17
17
|
import "./hono/index.js";
|
|
18
18
|
import { assertSecureGatewayHttpUrl, assertSecureWebSocketUrl, isInsecurePrivateWsAllowed, isSecureWebSocketUrl } from "./ws-security.js";
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { loadConfig } from "../config/loader.js";
|
|
2
2
|
import { isRestartEnabled } from "../config/commands.flags.js";
|
|
3
|
+
import { consumeGatewayRestartIntentSync, consumeGatewaySigusr1RestartAuthorization, isGatewaySigusr1RestartExternallyAllowed, resetGatewayRestartStateForInProcessRestart, scheduleGatewaySigusr1Restart, setGatewaySigusr1RestartPolicy } from "../infra/restart.js";
|
|
4
|
+
import { runBootstrapMigrationsSync } from "../migrations/runner.js";
|
|
3
5
|
import { restartGatewayProcessWithFreshPid } from "./respawn.js";
|
|
4
6
|
import { acquireGatewayLock } from "./lock.js";
|
|
5
|
-
import { runBootstrapMigrationsSync } from "../migrations/runner.js";
|
|
6
|
-
import { consumeGatewayRestartIntentSync, consumeGatewaySigusr1RestartAuthorization, isGatewaySigusr1RestartExternallyAllowed, resetGatewayRestartStateForInProcessRestart, scheduleGatewaySigusr1Restart, setGatewaySigusr1RestartPolicy } from "../infra/restart.js";
|
|
7
7
|
//#region src/gateway/run-loop.ts
|
|
8
8
|
/**
|
|
9
9
|
* Gateway Run Loop - Core run loop for gateway process management
|
|
@@ -54,6 +54,7 @@ function requiredGatewayScope(method, path) {
|
|
|
54
54
|
if (path.startsWith("/api/automations") || path.startsWith("/api/automation-runs")) return methodScope(method, "automations.read", "automations.write");
|
|
55
55
|
if (path === "/api/voice/selection" || path === "/api/voice/catalog/refresh" || path === "/api/voice/boson" || path === "/api/voice/boson/reveal-api-key") return "voice.configure";
|
|
56
56
|
if (path.startsWith("/api/voice") || path.startsWith("/api/media") || path.startsWith("/api/clarifications")) return "sessions.write";
|
|
57
|
+
if (method === "GET" && path === "/api/chat/skills") return "agents.read";
|
|
57
58
|
if (path.startsWith("/api/commands") || path.startsWith("/api/skills")) return methodScope(method, "agents.read", "gateway.admin");
|
|
58
59
|
if (path === "/api/user-model/refresh" || path.startsWith("/api/user-model/refresh/")) return "gateway.admin";
|
|
59
60
|
if (path === "/api/user-model" || path.startsWith("/api/user-model/")) return methodScope(method, "workspace.read", "workspace.write");
|
|
@@ -15,8 +15,8 @@ import { TaskConversationRepository } from "../../tasks/task-conversation-reposi
|
|
|
15
15
|
import { TaskCollaborationRepository } from "../../tasks/task-collaboration-repository.js";
|
|
16
16
|
import { reserveEmbeddedRunCancellation } from "../../agent/embedded/runs.js";
|
|
17
17
|
import { TaskApplicationService } from "../../tasks/task-application-service.js";
|
|
18
|
-
import { EphemeralClarificationWaiter } from "../ephemeral-clarification-waiter.js";
|
|
19
18
|
import { completePhoneAssistanceFromUser, preparePhoneContinuation } from "../../phone/assistance-service.js";
|
|
19
|
+
import { EphemeralClarificationWaiter } from "../ephemeral-clarification-waiter.js";
|
|
20
20
|
import { describeActiveExecution } from "./active-execution.js";
|
|
21
21
|
import { runGatewayAgent } from "./run-gateway-agent.js";
|
|
22
22
|
import { NextTurnSuggestionService } from "../next-turn-suggestions/service.js";
|
|
@@ -20,8 +20,8 @@ import { recordPersonalPerformance } from "../../personal-agent/performance.js";
|
|
|
20
20
|
import { formatAgentRunErrorForClient } from "../../agent/client-error-format.js";
|
|
21
21
|
import "../chat-limits.js";
|
|
22
22
|
import { prependEnvelopeTimestamp } from "../../channels/envelope-timestamp.js";
|
|
23
|
-
import { ChatStreamMapper } from "../chat-stream/mapper.js";
|
|
24
23
|
import { markdownNotificationPreview } from "../../notifications/plain-text.js";
|
|
24
|
+
import { ChatStreamMapper } from "../chat-stream/mapper.js";
|
|
25
25
|
import { resolveWebchatConversationId } from "../resolve-webchat-session-key.js";
|
|
26
26
|
import { recordExplicitRelationshipFollowUp } from "../../user-context/relationship-continuity.js";
|
|
27
27
|
import { coalesceThinkingDeltas } from "../chat-stream/thinking-delta-coalescer.js";
|
|
@@ -107,6 +107,17 @@ import { DiscussionSealer } from "../discussions/sealer.js";
|
|
|
107
107
|
import "../discussions/index.js";
|
|
108
108
|
import { EndpointToolRuntime } from "../endpoint-tools/runtime.js";
|
|
109
109
|
import "../endpoint-tools/index.js";
|
|
110
|
+
import { HomeCapabilityPreflightService } from "../home-intelligence/capability-preflight.js";
|
|
111
|
+
import { HomeAdviceGenerator } from "../home-intelligence/generator.js";
|
|
112
|
+
import { HomeIntelligenceHost } from "../home-intelligence/host.js";
|
|
113
|
+
import { HomeSnapshotBuilder } from "../home-intelligence/snapshot.js";
|
|
114
|
+
import { createBackgroundTask } from "../infra/background-task.js";
|
|
115
|
+
import { scheduleGatewayUpdateCheck } from "../infra/update-startup.js";
|
|
116
|
+
import "../local-apps/index.js";
|
|
117
|
+
import "../notes/index.js";
|
|
118
|
+
import { NotificationService } from "../notifications/service.js";
|
|
119
|
+
import { allowsPersonalTaskNotification, personalReplyNotification, personalRunDelegated } from "../personal-agent/notifications.js";
|
|
120
|
+
import { PhoneStreamGateway } from "../phone/stream-gateway.js";
|
|
110
121
|
import { assertGatewayAuthConfigured, extractToken, resolveGatewayAuth, validateToken } from "./auth.js";
|
|
111
122
|
import { prepareAutomationAgentSession } from "./automation-agent-session.js";
|
|
112
123
|
import { deliverAutomationCompletion } from "./automation-completion-delivery.js";
|
|
@@ -117,10 +128,8 @@ import { createPhoneSetupService } from "./hono/routes/phone-setup.js";
|
|
|
117
128
|
import { BrowserSetupService } from "../browser/setup/service.js";
|
|
118
129
|
import { McpConversationSetup } from "../agent/mcp/conversation-setup.js";
|
|
119
130
|
import { withGatewayConfigWriteLock } from "./hono/lib/config-write-lock.js";
|
|
120
|
-
import { PhoneStreamGateway } from "../phone/stream-gateway.js";
|
|
121
131
|
import { PersonalProactivityService } from "../personal-agent/proactivity/service.js";
|
|
122
132
|
import { reconcilePersonalProactivityAutomation } from "../personal-agent/proactivity/automation.js";
|
|
123
|
-
import { createBackgroundTask } from "../infra/background-task.js";
|
|
124
133
|
import { buildFileAgentContext } from "../agent/source-context/file-context.js";
|
|
125
134
|
import { buildSessionAgentContext } from "../agent/source-context/session-context.js";
|
|
126
135
|
import { buildBrowserTabAgentContext } from "../agent/source-context/browser-tab.js";
|
|
@@ -129,7 +138,6 @@ import { buildVoiceMemoryContext } from "../voice/realtime/memory-context.js";
|
|
|
129
138
|
import { buildVoicePersonaContext } from "../voice/realtime/persona-context.js";
|
|
130
139
|
import { buildVoiceUserContext } from "../voice/realtime/user-context.js";
|
|
131
140
|
import { buildVoiceHistory, voiceMemoryBudget, voicePersonaBudget } from "../voice/realtime/conversation-context.js";
|
|
132
|
-
import "../notes/index.js";
|
|
133
141
|
import { EphemeralSideChatManager } from "./side-chat/manager.js";
|
|
134
142
|
import { SideChatRunService } from "./side-chat/run-service.js";
|
|
135
143
|
import { SideChatPromotionService } from "./side-chat/promotion-service.js";
|
|
@@ -142,11 +150,8 @@ import { assertGatewayRuntimeConfig } from "./runtime-config.js";
|
|
|
142
150
|
import { auditGatewayConfig } from "./security/audit.js";
|
|
143
151
|
import { getXopcCloudCatalogCoordinator } from "../providers/xopc-cloud-catalog-coordinator.js";
|
|
144
152
|
import { ModelCatalogSyncService } from "../providers/model-catalog-sync-service.js";
|
|
145
|
-
import { NotificationService } from "../notifications/service.js";
|
|
146
|
-
import "../local-apps/index.js";
|
|
147
153
|
import { TaskAllocationDispatcher } from "../tasks/task-allocation-service.js";
|
|
148
154
|
import { TaskResultDeliveryService } from "../tasks/task-result-delivery-service.js";
|
|
149
|
-
import { scheduleGatewayUpdateCheck } from "../infra/update-startup.js";
|
|
150
155
|
import { resolveChannelConnectDeferSet } from "./resolve-channel-connect-defer.js";
|
|
151
156
|
import { restartGatewayProcessWithFreshPid } from "./respawn.js";
|
|
152
157
|
import { GatewaySessionsApi } from "./service/sessions-api.js";
|
|
@@ -165,15 +170,10 @@ import { TaskCollaborationDelivery } from "../tasks/task-collaboration-delivery.
|
|
|
165
170
|
import { enqueueTaskDelayNotices } from "../tasks/task-delay-notice.js";
|
|
166
171
|
import { TaskMainUpdateExhaustedError } from "../tasks/task-main-update-retry.js";
|
|
167
172
|
import { TaskMainUpdateDelivery } from "../tasks/task-main-update-delivery.js";
|
|
168
|
-
import { allowsPersonalTaskNotification, personalReplyNotification, personalRunDelegated } from "../personal-agent/notifications.js";
|
|
169
173
|
import { TaskMainUpdateDecisionService } from "../tasks/task-main-update-decision-service.js";
|
|
170
174
|
import { selectTaskMainUpdateAttempt, submitAndConfirmTaskMainUpdate } from "../tasks/task-main-update-input.js";
|
|
171
175
|
import { checkAppContextAccess, prepareAppContext } from "./service/app-context-access.js";
|
|
172
176
|
import { applyAutomaticVoiceLanguage, inferProductLanguageFromEnvironment, initializeVoiceDefaults } from "../voice/language-profile.js";
|
|
173
|
-
import { HomeAdviceGenerator } from "../home-intelligence/generator.js";
|
|
174
|
-
import { HomeIntelligenceHost } from "../home-intelligence/host.js";
|
|
175
|
-
import { HomeSnapshotBuilder } from "../home-intelligence/snapshot.js";
|
|
176
|
-
import { HomeCapabilityPreflightService } from "../home-intelligence/capability-preflight.js";
|
|
177
177
|
import crypto from "node:crypto";
|
|
178
178
|
//#region src/gateway/service.ts
|
|
179
179
|
init_session_repository();
|
|
@@ -7,14 +7,14 @@ import { TaskRepository, init_task_repository } from "../tasks/task-repository.j
|
|
|
7
7
|
import { appendTranscriptEntry } from "../storage/sqlite/transcript-repository.js";
|
|
8
8
|
import { createConversation, init_conversation_repository } from "../storage/sqlite/conversation-repository.js";
|
|
9
9
|
import { TaskApplicationService } from "../tasks/task-application-service.js";
|
|
10
|
-
import { HomeObservation, ObservationConflictError } from "./observation.js";
|
|
11
|
-
import { HomeFollowUps } from "./follow-ups.js";
|
|
12
|
-
import { observationStarters } from "./observation-starters.js";
|
|
13
|
-
import { HomeAdviceBudgetExceededError, isHomeProseLocalized } from "./generator.js";
|
|
14
10
|
import { homePatternKey } from "./strategy.js";
|
|
15
|
-
import { HomeAdvicePolicy } from "./policy.js";
|
|
16
11
|
import { HomeIntelligenceRepository } from "./repository.js";
|
|
17
12
|
import { HomeOpportunityApplicationService } from "./application-service.js";
|
|
13
|
+
import { HomeAdvicePolicy } from "./policy.js";
|
|
14
|
+
import { HomeObservation, ObservationConflictError } from "./observation.js";
|
|
15
|
+
import { HomeFollowUps } from "./follow-ups.js";
|
|
16
|
+
import { HomeAdviceBudgetExceededError, isHomeProseLocalized } from "./generator.js";
|
|
17
|
+
import { observationStarters } from "./observation-starters.js";
|
|
18
18
|
import { buildHomeOpportunityNotification } from "./notification.js";
|
|
19
19
|
import { ObservationRoutines } from "./routines.js";
|
|
20
20
|
import { createHash } from "node:crypto";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { listPortListeners } from "../gateway/ports.js";
|
|
2
1
|
import { isGatewayArgv, parseProcCmdline } from "./gateway-process-argv.js";
|
|
2
|
+
import { listPortListeners } from "../gateway/ports.js";
|
|
3
3
|
import fs from "node:fs";
|
|
4
4
|
import { spawnSync } from "node:child_process";
|
|
5
5
|
//#region src/infra/gateway-processes.ts
|
|
@@ -2,10 +2,10 @@ import { createLogger } from "../utils/logger/index.js";
|
|
|
2
2
|
import { init_logger } from "../utils/logger.js";
|
|
3
3
|
import { init_paths, resolveConfigPath } from "../config/paths.js";
|
|
4
4
|
import { loadConfig } from "../config/loader.js";
|
|
5
|
-
import { isRestartEnabled } from "../config/commands.flags.js";
|
|
6
5
|
import { resolveGatewayService } from "../daemon/service.js";
|
|
7
|
-
import {
|
|
6
|
+
import { isRestartEnabled } from "../config/commands.flags.js";
|
|
8
7
|
import { findVerifiedGatewayListenerPidsOnPortSync, signalVerifiedGatewayPidSync } from "./gateway-processes.js";
|
|
8
|
+
import { authorizeGatewaySigusr1Restart, writeGatewayRestartIntentSync } from "./restart.js";
|
|
9
9
|
import { refreshGatewayServiceAfterUpdate } from "./update-service-refresh.js";
|
|
10
10
|
//#region src/infra/update-restart.ts
|
|
11
11
|
/**
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { PACKAGE_VERSION, init_package_version } from "../package-version.js";
|
|
2
2
|
import { runPostUpdateExtensionSync } from "../extensions/update.js";
|
|
3
|
-
import "./update-channels.js";
|
|
4
|
-
import { compareSemver, resolveNpmChannelTag } from "./update-check.js";
|
|
5
3
|
import { readPackageName, readPackageVersion } from "./package-json.js";
|
|
6
4
|
import { runCommandWithTimeout } from "./run-command.js";
|
|
7
5
|
import { XOPC_PACKAGE_NAME, cleanupGlobalRenameDirs, createGlobalInstallEnv, detectGlobalInstallManagerForRoot, resolveGlobalInstallSpec, resolveGlobalInstallTarget } from "./update-global.js";
|
|
8
6
|
import { runGlobalPackageUpdateSteps } from "./package-update-steps.js";
|
|
9
7
|
import { resolveStableNodePath } from "./stable-node-path.js";
|
|
8
|
+
import "./update-channels.js";
|
|
9
|
+
import { compareSemver, resolveNpmChannelTag } from "./update-check.js";
|
|
10
10
|
import { trimLogTail } from "./update-log.js";
|
|
11
11
|
import { maybeRestartGatewayAfterUpdate, prepareGatewayRestart } from "./update-restart.js";
|
|
12
12
|
import path from "node:path";
|
|
@@ -3,9 +3,9 @@ import { init_paths_state, resolveUpdateCheckStatePath } from "../config/paths-s
|
|
|
3
3
|
import { createLogger } from "../utils/logger/index.js";
|
|
4
4
|
import { init_logger } from "../utils/logger.js";
|
|
5
5
|
import { init_write_file_atomic, writeTextAtomic } from "./write-file-atomic.js";
|
|
6
|
-
import { acquireUpdateLock } from "./update-lock.js";
|
|
7
6
|
import { normalizeUpdateChannel } from "./update-channels.js";
|
|
8
7
|
import { compareSemver, detectInstallKind, resolveNpmChannelTag, resolvePackageRoot } from "./update-check.js";
|
|
8
|
+
import { acquireUpdateLock } from "./update-lock.js";
|
|
9
9
|
import { createHash, randomUUID } from "node:crypto";
|
|
10
10
|
import { readFile } from "node:fs/promises";
|
|
11
11
|
//#region src/infra/update-startup.ts
|
|
@@ -3,11 +3,11 @@ import { init_logger } from "../utils/logger.js";
|
|
|
3
3
|
import { localizeNotification } from "../../packages/gateway-contract/src/notifications.js";
|
|
4
4
|
import { init_src } from "../../packages/gateway-contract/src/index.js";
|
|
5
5
|
import { getOrCreateGatewayIdentity } from "../storage/sqlite/gateway-identity-repository.js";
|
|
6
|
+
import { flushClarificationNotifications, isClarificationNotificationActionable } from "./clarification.js";
|
|
6
7
|
import { getNotificationDevice, listDeliverableNotificationDevices } from "./device-store.js";
|
|
8
|
+
import { sendHarmonyPush } from "./harmony-push.js";
|
|
7
9
|
import { notificationPlanFromGatewayEvent } from "./planner.js";
|
|
8
10
|
import { cancelNotificationDelivery, createNotificationEvent, expireUndeliverableNotificationDeliveries, listDueNotificationDeliveries, markNotificationDeliveryAccepted, markNotificationDeliveryDead, pruneNotificationEvents, rescheduleNotificationDelivery } from "./store.js";
|
|
9
|
-
import { sendHarmonyPush } from "./harmony-push.js";
|
|
10
|
-
import { flushClarificationNotifications, isClarificationNotificationActionable } from "./clarification.js";
|
|
11
11
|
//#region src/notifications/service.ts
|
|
12
12
|
init_src();
|
|
13
13
|
init_logger();
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { createLogger } from "../utils/logger/index.js";
|
|
2
2
|
import { init_logger } from "../utils/logger.js";
|
|
3
3
|
import { PhoneError, init_contracts } from "./contracts.js";
|
|
4
|
-
import { verifyDeviceConnectionProof } from "../gateway/security/device-request-proof.js";
|
|
5
4
|
import { PhonePointerSchema } from "./live-provider.js";
|
|
5
|
+
import { verifyDeviceConnectionProof } from "../gateway/security/device-request-proof.js";
|
|
6
6
|
import { createRequire } from "node:module";
|
|
7
7
|
import { createHash, randomBytes } from "node:crypto";
|
|
8
8
|
import { z } from "zod";
|
|
@@ -6,17 +6,17 @@ import { isEmbeddedRunActive } from "../agent/embedded/runs.js";
|
|
|
6
6
|
import { commandRegistry } from "../agent/commands/command-registry.js";
|
|
7
7
|
import { listChildRuns } from "../agent/orchestration/child-run-monitor.js";
|
|
8
8
|
import { getSessionInteractionPolicy } from "../agent/session/interaction-policy.js";
|
|
9
|
+
import { agentPluginInventoryRow } from "../extensions/agent-plugins/inventory.js";
|
|
9
10
|
import { resolveMcpSetupConfig } from "../agent/mcp/effective-server.js";
|
|
10
11
|
import { createNativeMcpCredentials } from "../agent/mcp/credential-store.js";
|
|
11
12
|
import { prepareNativeMcpConfig } from "../agent/mcp/native-mcp.js";
|
|
12
13
|
import { discoverMcpTools } from "../agent/mcp/tool-catalog.js";
|
|
13
14
|
import { cancelMcpAuthorization, getMcpAuthorization, probeMcpConnection, startMcpAuthorization, submitMcpRedirect } from "../agent/mcp/connection-setup.js";
|
|
15
|
+
import { PluginSetupService, setupActionSchema } from "../extensions/agent-plugins/setup.js";
|
|
14
16
|
import { evictAllEmbeddedSessionRunners } from "../agent/embedded/session-runner.js";
|
|
15
17
|
import { LocalWorktreeManager } from "../execution-environments/local-worktree-manager.js";
|
|
16
18
|
import { SessionEnvironmentService } from "../execution-environments/session-environment-service.js";
|
|
17
|
-
import { PluginSetupService, setupActionSchema } from "../extensions/agent-plugins/setup.js";
|
|
18
19
|
import { fetchRegistry } from "../extensions/marketplace.js";
|
|
19
|
-
import { agentPluginInventoryRow } from "../extensions/agent-plugins/inventory.js";
|
|
20
20
|
import { withAgentPluginSource } from "../extensions/agent-plugins/sources.js";
|
|
21
21
|
import { removePluginCredentials } from "../extensions/agent-plugins/credentials.js";
|
|
22
22
|
import { z } from "zod";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@xopcai/xopc",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.463",
|
|
4
4
|
"description": "An open-source AI assistant for work and everyday life. Remembers context and helps you get things done. Local-first, on a computer you choose.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/src/index.js",
|