@copilotkitnext/runtime 1.54.0 → 1.54.1-next.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/endpoints/express-single.cjs.map +1 -1
- package/dist/endpoints/express-single.d.cts +2 -2
- package/dist/endpoints/express-single.d.cts.map +1 -1
- package/dist/endpoints/express-single.d.mts +2 -2
- package/dist/endpoints/express-single.d.mts.map +1 -1
- package/dist/endpoints/express-single.mjs.map +1 -1
- package/dist/endpoints/express.cjs +38 -0
- package/dist/endpoints/express.cjs.map +1 -1
- package/dist/endpoints/express.d.cts +2 -2
- package/dist/endpoints/express.d.cts.map +1 -1
- package/dist/endpoints/express.d.mts +2 -2
- package/dist/endpoints/express.d.mts.map +1 -1
- package/dist/endpoints/express.mjs +38 -0
- package/dist/endpoints/express.mjs.map +1 -1
- package/dist/endpoints/hono-single.cjs.map +1 -1
- package/dist/endpoints/hono-single.d.cts +2 -2
- package/dist/endpoints/hono-single.d.cts.map +1 -1
- package/dist/endpoints/hono-single.d.mts +2 -2
- package/dist/endpoints/hono-single.d.mts.map +1 -1
- package/dist/endpoints/hono-single.mjs.map +1 -1
- package/dist/endpoints/hono.cjs +83 -0
- package/dist/endpoints/hono.cjs.map +1 -1
- package/dist/endpoints/hono.d.cts +3 -3
- package/dist/endpoints/hono.d.cts.map +1 -1
- package/dist/endpoints/hono.d.mts +3 -3
- package/dist/endpoints/hono.d.mts.map +1 -1
- package/dist/endpoints/hono.mjs +83 -0
- package/dist/endpoints/hono.mjs.map +1 -1
- package/dist/handlers/get-runtime-info.cjs +2 -0
- package/dist/handlers/get-runtime-info.cjs.map +1 -1
- package/dist/handlers/get-runtime-info.mjs +3 -1
- package/dist/handlers/get-runtime-info.mjs.map +1 -1
- package/dist/handlers/handle-connect.cjs +18 -80
- package/dist/handlers/handle-connect.cjs.map +1 -1
- package/dist/handlers/handle-connect.mjs +18 -79
- package/dist/handlers/handle-connect.mjs.map +1 -1
- package/dist/handlers/handle-run.cjs +26 -98
- package/dist/handlers/handle-run.cjs.map +1 -1
- package/dist/handlers/handle-run.mjs +26 -97
- package/dist/handlers/handle-run.mjs.map +1 -1
- package/dist/handlers/handle-stop.cjs.map +1 -1
- package/dist/handlers/handle-stop.mjs.map +1 -1
- package/dist/handlers/handle-threads.cjs +1 -0
- package/dist/handlers/handle-threads.mjs +3 -0
- package/dist/handlers/handle-transcribe.cjs.map +1 -1
- package/dist/handlers/handle-transcribe.mjs.map +1 -1
- package/dist/handlers/intelligence/connect.cjs +28 -0
- package/dist/handlers/intelligence/connect.cjs.map +1 -0
- package/dist/handlers/intelligence/connect.mjs +28 -0
- package/dist/handlers/intelligence/connect.mjs.map +1 -0
- package/dist/handlers/intelligence/run.cjs +77 -0
- package/dist/handlers/intelligence/run.cjs.map +1 -0
- package/dist/handlers/intelligence/run.mjs +76 -0
- package/dist/handlers/intelligence/run.mjs.map +1 -0
- package/dist/handlers/intelligence/thread-names.cjs +144 -0
- package/dist/handlers/intelligence/thread-names.cjs.map +1 -0
- package/dist/handlers/intelligence/thread-names.mjs +143 -0
- package/dist/handlers/intelligence/thread-names.mjs.map +1 -0
- package/dist/handlers/intelligence/threads.cjs +133 -0
- package/dist/handlers/intelligence/threads.cjs.map +1 -0
- package/dist/handlers/intelligence/threads.mjs +128 -0
- package/dist/handlers/intelligence/threads.mjs.map +1 -0
- package/dist/handlers/shared/agent-utils.cjs +73 -0
- package/dist/handlers/shared/agent-utils.cjs.map +1 -0
- package/dist/handlers/shared/agent-utils.mjs +69 -0
- package/dist/handlers/shared/agent-utils.mjs.map +1 -0
- package/dist/handlers/shared/intelligence-utils.cjs +20 -0
- package/dist/handlers/shared/intelligence-utils.cjs.map +1 -0
- package/dist/handlers/shared/intelligence-utils.mjs +19 -0
- package/dist/handlers/shared/intelligence-utils.mjs.map +1 -0
- package/dist/handlers/shared/json-response.cjs +7 -0
- package/dist/handlers/shared/json-response.cjs.map +1 -0
- package/dist/handlers/shared/json-response.mjs +6 -0
- package/dist/handlers/shared/json-response.mjs.map +1 -0
- package/dist/handlers/shared/sse-response.cjs +63 -0
- package/dist/handlers/shared/sse-response.cjs.map +1 -0
- package/dist/handlers/shared/sse-response.mjs +62 -0
- package/dist/handlers/shared/sse-response.mjs.map +1 -0
- package/dist/handlers/sse/connect.cjs +17 -0
- package/dist/handlers/sse/connect.cjs.map +1 -0
- package/dist/handlers/sse/connect.mjs +17 -0
- package/dist/handlers/sse/connect.mjs.map +1 -0
- package/dist/handlers/sse/run.cjs +17 -0
- package/dist/handlers/sse/run.cjs.map +1 -0
- package/dist/handlers/sse/run.mjs +17 -0
- package/dist/handlers/sse/run.mjs.map +1 -0
- package/dist/index.cjs +8 -2
- package/dist/index.d.cts +3 -2
- package/dist/index.d.mts +4 -2
- package/dist/index.mjs +5 -3
- package/dist/intelligence-platform/client.cjs +318 -0
- package/dist/intelligence-platform/client.cjs.map +1 -0
- package/dist/intelligence-platform/client.d.cts +327 -0
- package/dist/intelligence-platform/client.d.cts.map +1 -0
- package/dist/intelligence-platform/client.d.mts +327 -0
- package/dist/intelligence-platform/client.d.mts.map +1 -0
- package/dist/intelligence-platform/client.mjs +316 -0
- package/dist/intelligence-platform/client.mjs.map +1 -0
- package/dist/intelligence-platform/index.cjs +1 -0
- package/dist/intelligence-platform/index.d.mts +1 -0
- package/dist/intelligence-platform/index.mjs +3 -0
- package/dist/middleware.cjs.map +1 -1
- package/dist/middleware.d.cts +3 -3
- package/dist/middleware.d.cts.map +1 -1
- package/dist/middleware.d.mts +3 -3
- package/dist/middleware.d.mts.map +1 -1
- package/dist/middleware.mjs.map +1 -1
- package/dist/package.cjs +1 -1
- package/dist/package.mjs +1 -1
- package/dist/runner/agent-runner.cjs.map +1 -1
- package/dist/runner/agent-runner.d.cts +4 -1
- package/dist/runner/agent-runner.d.cts.map +1 -1
- package/dist/runner/agent-runner.d.mts +4 -1
- package/dist/runner/agent-runner.d.mts.map +1 -1
- package/dist/runner/agent-runner.mjs.map +1 -1
- package/dist/runner/in-memory.cjs +1 -1
- package/dist/runner/in-memory.mjs +1 -1
- package/dist/runner/intelligence.cjs +87 -24
- package/dist/runner/intelligence.cjs.map +1 -1
- package/dist/runner/intelligence.d.cts +8 -3
- package/dist/runner/intelligence.d.cts.map +1 -1
- package/dist/runner/intelligence.d.mts +8 -3
- package/dist/runner/intelligence.d.mts.map +1 -1
- package/dist/runner/intelligence.mjs +87 -24
- package/dist/runner/intelligence.mjs.map +1 -1
- package/dist/runtime.cjs +76 -6
- package/dist/runtime.cjs.map +1 -1
- package/dist/runtime.d.cts +71 -21
- package/dist/runtime.d.cts.map +1 -1
- package/dist/runtime.d.mts +72 -21
- package/dist/runtime.d.mts.map +1 -1
- package/dist/runtime.mjs +73 -7
- package/dist/runtime.mjs.map +1 -1
- package/package.json +5 -5
package/dist/runtime.cjs
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
+
const require_runtime = require('./_virtual/_rolldown/runtime.cjs');
|
|
1
2
|
const require_package = require('./package.cjs');
|
|
2
3
|
const require_in_memory = require('./runner/in-memory.cjs');
|
|
4
|
+
const require_intelligence = require('./runner/intelligence.cjs');
|
|
5
|
+
let _copilotkitnext_shared = require("@copilotkitnext/shared");
|
|
3
6
|
|
|
4
7
|
//#region src/runtime.ts
|
|
5
8
|
const VERSION = require_package.version;
|
|
6
|
-
|
|
7
|
-
* Central runtime object passed to all request handlers.
|
|
8
|
-
*/
|
|
9
|
-
var CopilotRuntime = class {
|
|
9
|
+
var BaseCopilotRuntime = class {
|
|
10
10
|
agents;
|
|
11
11
|
transcriptionService;
|
|
12
12
|
beforeRequestMiddleware;
|
|
@@ -14,18 +14,88 @@ var CopilotRuntime = class {
|
|
|
14
14
|
runner;
|
|
15
15
|
a2ui;
|
|
16
16
|
mcpApps;
|
|
17
|
-
constructor(
|
|
17
|
+
constructor(options, runner) {
|
|
18
|
+
const { agents, transcriptionService, beforeRequestMiddleware, afterRequestMiddleware, a2ui, mcpApps } = options;
|
|
18
19
|
this.agents = agents;
|
|
19
20
|
this.transcriptionService = transcriptionService;
|
|
20
21
|
this.beforeRequestMiddleware = beforeRequestMiddleware;
|
|
21
22
|
this.afterRequestMiddleware = afterRequestMiddleware;
|
|
22
|
-
this.runner = runner ?? new require_in_memory.InMemoryAgentRunner();
|
|
23
23
|
this.a2ui = a2ui;
|
|
24
24
|
this.mcpApps = mcpApps;
|
|
25
|
+
this.runner = runner;
|
|
26
|
+
}
|
|
27
|
+
};
|
|
28
|
+
var CopilotSseRuntime = class extends BaseCopilotRuntime {
|
|
29
|
+
intelligence = void 0;
|
|
30
|
+
mode = _copilotkitnext_shared.RUNTIME_MODE_SSE;
|
|
31
|
+
constructor(options) {
|
|
32
|
+
super(options, options.runner ?? new require_in_memory.InMemoryAgentRunner());
|
|
33
|
+
}
|
|
34
|
+
};
|
|
35
|
+
var CopilotIntelligenceRuntime = class extends BaseCopilotRuntime {
|
|
36
|
+
intelligence;
|
|
37
|
+
generateThreadNames;
|
|
38
|
+
mode = _copilotkitnext_shared.RUNTIME_MODE_INTELLIGENCE;
|
|
39
|
+
constructor(options) {
|
|
40
|
+
super(options, new require_intelligence.IntelligenceAgentRunner({
|
|
41
|
+
url: options.intelligence.ɵgetRunnerWsUrl(),
|
|
42
|
+
authToken: options.intelligence.ɵgetRunnerAuthToken()
|
|
43
|
+
}));
|
|
44
|
+
this.intelligence = options.intelligence;
|
|
45
|
+
this.generateThreadNames = options.generateThreadNames ?? true;
|
|
46
|
+
}
|
|
47
|
+
};
|
|
48
|
+
function hasIntelligenceOptions(options) {
|
|
49
|
+
return "intelligence" in options && !!options.intelligence;
|
|
50
|
+
}
|
|
51
|
+
function isIntelligenceRuntime(runtime) {
|
|
52
|
+
return runtime.mode === _copilotkitnext_shared.RUNTIME_MODE_INTELLIGENCE && !!runtime.intelligence;
|
|
53
|
+
}
|
|
54
|
+
/**
|
|
55
|
+
* Compatibility shim that preserves the legacy `CopilotRuntime` entrypoint.
|
|
56
|
+
* New code should prefer `CopilotSseRuntime` or `CopilotIntelligenceRuntime`.
|
|
57
|
+
*/
|
|
58
|
+
var CopilotRuntime = class {
|
|
59
|
+
delegate;
|
|
60
|
+
constructor(options) {
|
|
61
|
+
this.delegate = hasIntelligenceOptions(options) ? new CopilotIntelligenceRuntime(options) : new CopilotSseRuntime(options);
|
|
62
|
+
}
|
|
63
|
+
get agents() {
|
|
64
|
+
return this.delegate.agents;
|
|
65
|
+
}
|
|
66
|
+
get transcriptionService() {
|
|
67
|
+
return this.delegate.transcriptionService;
|
|
68
|
+
}
|
|
69
|
+
get beforeRequestMiddleware() {
|
|
70
|
+
return this.delegate.beforeRequestMiddleware;
|
|
71
|
+
}
|
|
72
|
+
get afterRequestMiddleware() {
|
|
73
|
+
return this.delegate.afterRequestMiddleware;
|
|
74
|
+
}
|
|
75
|
+
get runner() {
|
|
76
|
+
return this.delegate.runner;
|
|
77
|
+
}
|
|
78
|
+
get a2ui() {
|
|
79
|
+
return this.delegate.a2ui;
|
|
80
|
+
}
|
|
81
|
+
get mcpApps() {
|
|
82
|
+
return this.delegate.mcpApps;
|
|
83
|
+
}
|
|
84
|
+
get intelligence() {
|
|
85
|
+
return this.delegate.intelligence;
|
|
86
|
+
}
|
|
87
|
+
get generateThreadNames() {
|
|
88
|
+
return isIntelligenceRuntime(this.delegate) ? this.delegate.generateThreadNames : void 0;
|
|
89
|
+
}
|
|
90
|
+
get mode() {
|
|
91
|
+
return this.delegate.mode;
|
|
25
92
|
}
|
|
26
93
|
};
|
|
27
94
|
|
|
28
95
|
//#endregion
|
|
96
|
+
exports.CopilotIntelligenceRuntime = CopilotIntelligenceRuntime;
|
|
29
97
|
exports.CopilotRuntime = CopilotRuntime;
|
|
98
|
+
exports.CopilotSseRuntime = CopilotSseRuntime;
|
|
30
99
|
exports.VERSION = VERSION;
|
|
100
|
+
exports.isIntelligenceRuntime = isIntelligenceRuntime;
|
|
31
101
|
//# sourceMappingURL=runtime.cjs.map
|
package/dist/runtime.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"runtime.cjs","names":["InMemoryAgentRunner"],"sources":["../src/runtime.ts"],"sourcesContent":["import {
|
|
1
|
+
{"version":3,"file":"runtime.cjs","names":["RUNTIME_MODE_SSE","InMemoryAgentRunner","RUNTIME_MODE_INTELLIGENCE","IntelligenceAgentRunner"],"sources":["../src/runtime.ts"],"sourcesContent":["import {\n MaybePromise,\n NonEmptyRecord,\n RuntimeMode,\n RUNTIME_MODE_SSE,\n RUNTIME_MODE_INTELLIGENCE,\n} from \"@copilotkitnext/shared\";\nimport { AbstractAgent } from \"@ag-ui/client\";\nimport type { MCPClientConfig } from \"@ag-ui/mcp-apps-middleware\";\nimport { A2UIMiddlewareConfig } from \"@ag-ui/a2ui-middleware\";\nimport pkg from \"../package.json\";\nimport type {\n BeforeRequestMiddleware,\n AfterRequestMiddleware,\n} from \"./middleware\";\nimport { TranscriptionService } from \"./transcription-service/transcription-service\";\nimport { AgentRunner } from \"./runner/agent-runner\";\nimport { InMemoryAgentRunner } from \"./runner/in-memory\";\nimport { IntelligenceAgentRunner } from \"./runner/intelligence\";\nimport { CopilotKitIntelligence } from \"./intelligence-platform\";\n\nexport const VERSION = pkg.version;\n\ninterface BaseCopilotRuntimeMiddlewareOptions {\n /** If set, middleware only applies to these named agents. Applies to all agents if omitted. */\n agents?: string[];\n}\n\nexport type McpAppsServerConfig = MCPClientConfig & {\n /** Agent to bind this server to. If omitted, the server is available to all agents. */\n agentId?: string;\n};\n\nexport interface McpAppsConfig {\n /** List of MCP server configurations. */\n servers: McpAppsServerConfig[];\n}\n\ninterface CopilotRuntimeMiddlewares {\n /** Auto-apply A2UIMiddleware to agents at run time. */\n a2ui?: BaseCopilotRuntimeMiddlewareOptions & A2UIMiddlewareConfig;\n /** Auto-apply MCPAppsMiddleware to agents at run time. */\n mcpApps?: McpAppsConfig;\n}\n\ninterface BaseCopilotRuntimeOptions extends CopilotRuntimeMiddlewares {\n /** Map of available agents (loaded lazily is fine). */\n agents: MaybePromise<NonEmptyRecord<Record<string, AbstractAgent>>>;\n /** Optional transcription service for audio processing. */\n transcriptionService?: TranscriptionService;\n /** Optional *before* middleware – callback function or webhook URL. */\n beforeRequestMiddleware?: BeforeRequestMiddleware;\n /** Optional *after* middleware – callback function or webhook URL. */\n afterRequestMiddleware?: AfterRequestMiddleware;\n}\n\nexport interface CopilotSseRuntimeOptions extends BaseCopilotRuntimeOptions {\n /** The runner to use for running agents in SSE mode. */\n runner?: AgentRunner;\n intelligence?: undefined;\n generateThreadNames?: undefined;\n}\n\nexport interface CopilotIntelligenceRuntimeOptions extends BaseCopilotRuntimeOptions {\n /** Configures Intelligence mode for durable threads and realtime events. */\n intelligence: CopilotKitIntelligence;\n /** Auto-generate short names for newly created threads. */\n generateThreadNames?: boolean;\n}\n\nexport type CopilotRuntimeOptions =\n | CopilotSseRuntimeOptions\n | CopilotIntelligenceRuntimeOptions;\n\nexport interface CopilotRuntimeLike {\n agents: CopilotRuntimeOptions[\"agents\"];\n transcriptionService: CopilotRuntimeOptions[\"transcriptionService\"];\n beforeRequestMiddleware: CopilotRuntimeOptions[\"beforeRequestMiddleware\"];\n afterRequestMiddleware: CopilotRuntimeOptions[\"afterRequestMiddleware\"];\n runner: AgentRunner;\n a2ui: CopilotRuntimeOptions[\"a2ui\"];\n mcpApps: CopilotRuntimeOptions[\"mcpApps\"];\n intelligence?: CopilotKitIntelligence;\n mode: RuntimeMode;\n}\n\nexport interface CopilotSseRuntimeLike extends CopilotRuntimeLike {\n intelligence?: undefined;\n mode: RUNTIME_MODE_SSE;\n}\n\nexport interface CopilotIntelligenceRuntimeLike extends CopilotRuntimeLike {\n intelligence: CopilotKitIntelligence;\n generateThreadNames: boolean;\n mode: RUNTIME_MODE_INTELLIGENCE;\n}\n\nabstract class BaseCopilotRuntime implements CopilotRuntimeLike {\n public agents: CopilotRuntimeOptions[\"agents\"];\n public transcriptionService: CopilotRuntimeOptions[\"transcriptionService\"];\n public beforeRequestMiddleware: CopilotRuntimeOptions[\"beforeRequestMiddleware\"];\n public afterRequestMiddleware: CopilotRuntimeOptions[\"afterRequestMiddleware\"];\n public runner: AgentRunner;\n public a2ui: CopilotRuntimeOptions[\"a2ui\"];\n public mcpApps: CopilotRuntimeOptions[\"mcpApps\"];\n\n abstract readonly intelligence?: CopilotKitIntelligence;\n abstract readonly mode: RuntimeMode;\n\n constructor(options: BaseCopilotRuntimeOptions, runner: AgentRunner) {\n const {\n agents,\n transcriptionService,\n beforeRequestMiddleware,\n afterRequestMiddleware,\n a2ui,\n mcpApps,\n } = options;\n\n this.agents = agents;\n this.transcriptionService = transcriptionService;\n this.beforeRequestMiddleware = beforeRequestMiddleware;\n this.afterRequestMiddleware = afterRequestMiddleware;\n this.a2ui = a2ui;\n this.mcpApps = mcpApps;\n this.runner = runner;\n }\n}\n\nexport class CopilotSseRuntime\n extends BaseCopilotRuntime\n implements CopilotSseRuntimeLike\n{\n readonly intelligence = undefined;\n readonly mode = RUNTIME_MODE_SSE;\n\n constructor(options: CopilotSseRuntimeOptions) {\n super(options, options.runner ?? new InMemoryAgentRunner());\n }\n}\n\nexport class CopilotIntelligenceRuntime\n extends BaseCopilotRuntime\n implements CopilotIntelligenceRuntimeLike\n{\n readonly intelligence: CopilotKitIntelligence;\n readonly generateThreadNames: boolean;\n readonly mode = RUNTIME_MODE_INTELLIGENCE;\n\n constructor(options: CopilotIntelligenceRuntimeOptions) {\n super(\n options,\n new IntelligenceAgentRunner({\n url: options.intelligence.ɵgetRunnerWsUrl(),\n authToken: options.intelligence.ɵgetRunnerAuthToken(),\n }),\n );\n this.intelligence = options.intelligence;\n this.generateThreadNames = options.generateThreadNames ?? true;\n }\n}\n\nfunction hasIntelligenceOptions(\n options: CopilotRuntimeOptions,\n): options is CopilotIntelligenceRuntimeOptions {\n return \"intelligence\" in options && !!options.intelligence;\n}\n\nexport function isIntelligenceRuntime(\n runtime: CopilotRuntimeLike,\n): runtime is CopilotIntelligenceRuntimeLike {\n return runtime.mode === RUNTIME_MODE_INTELLIGENCE && !!runtime.intelligence;\n}\n\n/**\n * Compatibility shim that preserves the legacy `CopilotRuntime` entrypoint.\n * New code should prefer `CopilotSseRuntime` or `CopilotIntelligenceRuntime`.\n */\nexport class CopilotRuntime implements CopilotRuntimeLike {\n private delegate: CopilotRuntimeLike;\n\n constructor(options: CopilotRuntimeOptions) {\n this.delegate = hasIntelligenceOptions(options)\n ? new CopilotIntelligenceRuntime(options)\n : new CopilotSseRuntime(options);\n }\n\n get agents(): CopilotRuntimeOptions[\"agents\"] {\n return this.delegate.agents;\n }\n\n get transcriptionService(): CopilotRuntimeOptions[\"transcriptionService\"] {\n return this.delegate.transcriptionService;\n }\n\n get beforeRequestMiddleware(): CopilotRuntimeOptions[\"beforeRequestMiddleware\"] {\n return this.delegate.beforeRequestMiddleware;\n }\n\n get afterRequestMiddleware(): CopilotRuntimeOptions[\"afterRequestMiddleware\"] {\n return this.delegate.afterRequestMiddleware;\n }\n\n get runner(): AgentRunner {\n return this.delegate.runner;\n }\n\n get a2ui(): CopilotRuntimeOptions[\"a2ui\"] {\n return this.delegate.a2ui;\n }\n\n get mcpApps(): CopilotRuntimeOptions[\"mcpApps\"] {\n return this.delegate.mcpApps;\n }\n\n get intelligence(): CopilotKitIntelligence | undefined {\n return this.delegate.intelligence;\n }\n\n get generateThreadNames(): boolean | undefined {\n return isIntelligenceRuntime(this.delegate)\n ? this.delegate.generateThreadNames\n : undefined;\n }\n\n get mode(): RuntimeMode {\n return this.delegate.mode;\n }\n}\n"],"mappings":";;;;;;;AAqBA,MAAa;AA4Eb,IAAe,qBAAf,MAAgE;CAC9D,AAAO;CACP,AAAO;CACP,AAAO;CACP,AAAO;CACP,AAAO;CACP,AAAO;CACP,AAAO;CAKP,YAAY,SAAoC,QAAqB;EACnE,MAAM,EACJ,QACA,sBACA,yBACA,wBACA,MACA,YACE;AAEJ,OAAK,SAAS;AACd,OAAK,uBAAuB;AAC5B,OAAK,0BAA0B;AAC/B,OAAK,yBAAyB;AAC9B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sBACd;;CAGN,IAAI,OAAoB;AACtB,SAAO,KAAK,SAAS"}
|
package/dist/runtime.d.cts
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { AfterRequestMiddleware, BeforeRequestMiddleware } from "./middleware.cjs";
|
|
2
2
|
import { TranscriptionService } from "./transcription-service/transcription-service.cjs";
|
|
3
3
|
import { AgentRunner } from "./runner/agent-runner.cjs";
|
|
4
|
-
import {
|
|
4
|
+
import { CopilotKitIntelligence } from "./intelligence-platform/client.cjs";
|
|
5
|
+
import { MaybePromise, NonEmptyRecord, RUNTIME_MODE_INTELLIGENCE, RUNTIME_MODE_SSE, RuntimeMode } from "@copilotkitnext/shared";
|
|
5
6
|
import { AbstractAgent } from "@ag-ui/client";
|
|
6
7
|
import { MCPClientConfig } from "@ag-ui/mcp-apps-middleware";
|
|
7
8
|
import { A2UIMiddlewareConfig } from "@ag-ui/a2ui-middleware";
|
|
@@ -25,14 +26,9 @@ interface CopilotRuntimeMiddlewares {
|
|
|
25
26
|
/** Auto-apply MCPAppsMiddleware to agents at run time. */
|
|
26
27
|
mcpApps?: McpAppsConfig;
|
|
27
28
|
}
|
|
28
|
-
|
|
29
|
-
* Options used to construct a `CopilotRuntime` instance.
|
|
30
|
-
*/
|
|
31
|
-
interface CopilotRuntimeOptions extends CopilotRuntimeMiddlewares {
|
|
29
|
+
interface BaseCopilotRuntimeOptions extends CopilotRuntimeMiddlewares {
|
|
32
30
|
/** Map of available agents (loaded lazily is fine). */
|
|
33
31
|
agents: MaybePromise<NonEmptyRecord<Record<string, AbstractAgent>>>;
|
|
34
|
-
/** The runner to use for running agents. */
|
|
35
|
-
runner?: AgentRunner;
|
|
36
32
|
/** Optional transcription service for audio processing. */
|
|
37
33
|
transcriptionService?: TranscriptionService;
|
|
38
34
|
/** Optional *before* middleware – callback function or webhook URL. */
|
|
@@ -40,10 +36,20 @@ interface CopilotRuntimeOptions extends CopilotRuntimeMiddlewares {
|
|
|
40
36
|
/** Optional *after* middleware – callback function or webhook URL. */
|
|
41
37
|
afterRequestMiddleware?: AfterRequestMiddleware;
|
|
42
38
|
}
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
39
|
+
interface CopilotSseRuntimeOptions extends BaseCopilotRuntimeOptions {
|
|
40
|
+
/** The runner to use for running agents in SSE mode. */
|
|
41
|
+
runner?: AgentRunner;
|
|
42
|
+
intelligence?: undefined;
|
|
43
|
+
generateThreadNames?: undefined;
|
|
44
|
+
}
|
|
45
|
+
interface CopilotIntelligenceRuntimeOptions extends BaseCopilotRuntimeOptions {
|
|
46
|
+
/** Configures Intelligence mode for durable threads and realtime events. */
|
|
47
|
+
intelligence: CopilotKitIntelligence;
|
|
48
|
+
/** Auto-generate short names for newly created threads. */
|
|
49
|
+
generateThreadNames?: boolean;
|
|
50
|
+
}
|
|
51
|
+
type CopilotRuntimeOptions = CopilotSseRuntimeOptions | CopilotIntelligenceRuntimeOptions;
|
|
52
|
+
interface CopilotRuntimeLike {
|
|
47
53
|
agents: CopilotRuntimeOptions["agents"];
|
|
48
54
|
transcriptionService: CopilotRuntimeOptions["transcriptionService"];
|
|
49
55
|
beforeRequestMiddleware: CopilotRuntimeOptions["beforeRequestMiddleware"];
|
|
@@ -51,16 +57,60 @@ declare class CopilotRuntime {
|
|
|
51
57
|
runner: AgentRunner;
|
|
52
58
|
a2ui: CopilotRuntimeOptions["a2ui"];
|
|
53
59
|
mcpApps: CopilotRuntimeOptions["mcpApps"];
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
60
|
+
intelligence?: CopilotKitIntelligence;
|
|
61
|
+
mode: RuntimeMode;
|
|
62
|
+
}
|
|
63
|
+
interface CopilotSseRuntimeLike extends CopilotRuntimeLike {
|
|
64
|
+
intelligence?: undefined;
|
|
65
|
+
mode: RUNTIME_MODE_SSE;
|
|
66
|
+
}
|
|
67
|
+
interface CopilotIntelligenceRuntimeLike extends CopilotRuntimeLike {
|
|
68
|
+
intelligence: CopilotKitIntelligence;
|
|
69
|
+
generateThreadNames: boolean;
|
|
70
|
+
mode: RUNTIME_MODE_INTELLIGENCE;
|
|
71
|
+
}
|
|
72
|
+
declare abstract class BaseCopilotRuntime implements CopilotRuntimeLike {
|
|
73
|
+
agents: CopilotRuntimeOptions["agents"];
|
|
74
|
+
transcriptionService: CopilotRuntimeOptions["transcriptionService"];
|
|
75
|
+
beforeRequestMiddleware: CopilotRuntimeOptions["beforeRequestMiddleware"];
|
|
76
|
+
afterRequestMiddleware: CopilotRuntimeOptions["afterRequestMiddleware"];
|
|
77
|
+
runner: AgentRunner;
|
|
78
|
+
a2ui: CopilotRuntimeOptions["a2ui"];
|
|
79
|
+
mcpApps: CopilotRuntimeOptions["mcpApps"];
|
|
80
|
+
abstract readonly intelligence?: CopilotKitIntelligence;
|
|
81
|
+
abstract readonly mode: RuntimeMode;
|
|
82
|
+
constructor(options: BaseCopilotRuntimeOptions, runner: AgentRunner);
|
|
83
|
+
}
|
|
84
|
+
declare class CopilotSseRuntime extends BaseCopilotRuntime implements CopilotSseRuntimeLike {
|
|
85
|
+
readonly intelligence: undefined;
|
|
86
|
+
readonly mode: any;
|
|
87
|
+
constructor(options: CopilotSseRuntimeOptions);
|
|
88
|
+
}
|
|
89
|
+
declare class CopilotIntelligenceRuntime extends BaseCopilotRuntime implements CopilotIntelligenceRuntimeLike {
|
|
90
|
+
readonly intelligence: CopilotKitIntelligence;
|
|
91
|
+
readonly generateThreadNames: boolean;
|
|
92
|
+
readonly mode: any;
|
|
93
|
+
constructor(options: CopilotIntelligenceRuntimeOptions);
|
|
94
|
+
}
|
|
95
|
+
declare function isIntelligenceRuntime(runtime: CopilotRuntimeLike): runtime is CopilotIntelligenceRuntimeLike;
|
|
96
|
+
/**
|
|
97
|
+
* Compatibility shim that preserves the legacy `CopilotRuntime` entrypoint.
|
|
98
|
+
* New code should prefer `CopilotSseRuntime` or `CopilotIntelligenceRuntime`.
|
|
99
|
+
*/
|
|
100
|
+
declare class CopilotRuntime implements CopilotRuntimeLike {
|
|
101
|
+
private delegate;
|
|
102
|
+
constructor(options: CopilotRuntimeOptions);
|
|
103
|
+
get agents(): CopilotRuntimeOptions["agents"];
|
|
104
|
+
get transcriptionService(): CopilotRuntimeOptions["transcriptionService"];
|
|
105
|
+
get beforeRequestMiddleware(): CopilotRuntimeOptions["beforeRequestMiddleware"];
|
|
106
|
+
get afterRequestMiddleware(): CopilotRuntimeOptions["afterRequestMiddleware"];
|
|
107
|
+
get runner(): AgentRunner;
|
|
108
|
+
get a2ui(): CopilotRuntimeOptions["a2ui"];
|
|
109
|
+
get mcpApps(): CopilotRuntimeOptions["mcpApps"];
|
|
110
|
+
get intelligence(): CopilotKitIntelligence | undefined;
|
|
111
|
+
get generateThreadNames(): boolean | undefined;
|
|
112
|
+
get mode(): RuntimeMode;
|
|
63
113
|
}
|
|
64
114
|
//#endregion
|
|
65
|
-
export { CopilotRuntime, CopilotRuntimeOptions, McpAppsConfig, McpAppsServerConfig, VERSION };
|
|
115
|
+
export { CopilotIntelligenceRuntime, CopilotIntelligenceRuntimeLike, CopilotIntelligenceRuntimeOptions, CopilotRuntime, CopilotRuntimeLike, CopilotRuntimeOptions, CopilotSseRuntime, CopilotSseRuntimeLike, CopilotSseRuntimeOptions, McpAppsConfig, McpAppsServerConfig, VERSION, isIntelligenceRuntime };
|
|
66
116
|
//# sourceMappingURL=runtime.d.cts.map
|
package/dist/runtime.d.cts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"runtime.d.cts","names":[],"sources":["../src/runtime.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"runtime.d.cts","names":[],"sources":["../src/runtime.ts"],"mappings":";;;;;;;;;;cAqBa,OAAA;AAAA,UAEH,mCAAA;EAFG;EAIX,MAAA;AAAA;AAAA,KAGU,mBAAA,GAAsB,eAAA;EAPA,uFAShC,OAAA;AA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A,EAAS,qBAAA;EAAA,kBAEE,YAAA,GAAe,sBAAA;EAAA,kBACf,IAAA,EAAM,WAAA;cAEZ,OAAA,EAAS,yBAAA,EAA2B,MAAA,EAAQ,WAAA;AAAA;AAAA,cAoB7C,iBAAA,SACH,kBAAA,YACG,qBAAA;EAAA,SAEF,YAAA;EAAA,SACA,IAAA;cAEG,OAAA,EAAS,wBAAA;AAAA;AAAA,cAKV,0BAAA,SACH,kBAAA,YACG,8BAAA;EAAA,SAEF,YAAA,EAAc,sBAAA;EAAA,SACd,mBAAA;EAAA,SACA,IAAA;cAEG,OAAA,EAAS,iCAAA;AAAA;AAAA,iBAmBP,qBAAA,CACd,OAAA,EAAS,kBAAA,GACR,OAAA,IAAW,8BAAA;;;;;cAQD,cAAA,YAA0B,kBAAA;EAAA,QAC7B,QAAA;cAEI,OAAA,EAAS,qBAAA;EAAA,IAMjB,MAAA,CAAA,GAAU,qBAAA;EAAA,IAIV,oBAAA,CAAA,GAAwB,qBAAA;EAAA,IAIxB,uBAAA,CAAA,GAA2B,qBAAA;EAAA,IAI3B,sBAAA,CAAA,GAA0B,qBAAA;EAAA,IAI1B,MAAA,CAAA,GAAU,WAAA;EAAA,IAIV,IAAA,CAAA,GAAQ,qBAAA;EAAA,IAIR,OAAA,CAAA,GAAW,qBAAA;EAAA,IAIX,YAAA,CAAA,GAAgB,sBAAA;EAAA,IAIhB,mBAAA,CAAA;EAAA,IAMA,IAAA,CAAA,GAAQ,WAAA;AAAA"}
|
package/dist/runtime.d.mts
CHANGED
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
import { AfterRequestMiddleware, BeforeRequestMiddleware } from "./middleware.mjs";
|
|
2
2
|
import { TranscriptionService } from "./transcription-service/transcription-service.mjs";
|
|
3
3
|
import { AgentRunner } from "./runner/agent-runner.mjs";
|
|
4
|
+
import { CopilotKitIntelligence } from "./intelligence-platform/client.mjs";
|
|
5
|
+
import "./intelligence-platform/index.mjs";
|
|
6
|
+
import { MaybePromise, NonEmptyRecord, RUNTIME_MODE_INTELLIGENCE, RUNTIME_MODE_SSE, RuntimeMode } from "@copilotkitnext/shared";
|
|
4
7
|
import { AbstractAgent } from "@ag-ui/client";
|
|
5
|
-
import { MaybePromise, NonEmptyRecord } from "@copilotkitnext/shared";
|
|
6
8
|
import { A2UIMiddlewareConfig } from "@ag-ui/a2ui-middleware";
|
|
7
9
|
import { MCPClientConfig } from "@ag-ui/mcp-apps-middleware";
|
|
8
10
|
|
|
@@ -25,14 +27,9 @@ interface CopilotRuntimeMiddlewares {
|
|
|
25
27
|
/** Auto-apply MCPAppsMiddleware to agents at run time. */
|
|
26
28
|
mcpApps?: McpAppsConfig;
|
|
27
29
|
}
|
|
28
|
-
|
|
29
|
-
* Options used to construct a `CopilotRuntime` instance.
|
|
30
|
-
*/
|
|
31
|
-
interface CopilotRuntimeOptions extends CopilotRuntimeMiddlewares {
|
|
30
|
+
interface BaseCopilotRuntimeOptions extends CopilotRuntimeMiddlewares {
|
|
32
31
|
/** Map of available agents (loaded lazily is fine). */
|
|
33
32
|
agents: MaybePromise<NonEmptyRecord<Record<string, AbstractAgent>>>;
|
|
34
|
-
/** The runner to use for running agents. */
|
|
35
|
-
runner?: AgentRunner;
|
|
36
33
|
/** Optional transcription service for audio processing. */
|
|
37
34
|
transcriptionService?: TranscriptionService;
|
|
38
35
|
/** Optional *before* middleware – callback function or webhook URL. */
|
|
@@ -40,10 +37,20 @@ interface CopilotRuntimeOptions extends CopilotRuntimeMiddlewares {
|
|
|
40
37
|
/** Optional *after* middleware – callback function or webhook URL. */
|
|
41
38
|
afterRequestMiddleware?: AfterRequestMiddleware;
|
|
42
39
|
}
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
40
|
+
interface CopilotSseRuntimeOptions extends BaseCopilotRuntimeOptions {
|
|
41
|
+
/** The runner to use for running agents in SSE mode. */
|
|
42
|
+
runner?: AgentRunner;
|
|
43
|
+
intelligence?: undefined;
|
|
44
|
+
generateThreadNames?: undefined;
|
|
45
|
+
}
|
|
46
|
+
interface CopilotIntelligenceRuntimeOptions extends BaseCopilotRuntimeOptions {
|
|
47
|
+
/** Configures Intelligence mode for durable threads and realtime events. */
|
|
48
|
+
intelligence: CopilotKitIntelligence;
|
|
49
|
+
/** Auto-generate short names for newly created threads. */
|
|
50
|
+
generateThreadNames?: boolean;
|
|
51
|
+
}
|
|
52
|
+
type CopilotRuntimeOptions = CopilotSseRuntimeOptions | CopilotIntelligenceRuntimeOptions;
|
|
53
|
+
interface CopilotRuntimeLike {
|
|
47
54
|
agents: CopilotRuntimeOptions["agents"];
|
|
48
55
|
transcriptionService: CopilotRuntimeOptions["transcriptionService"];
|
|
49
56
|
beforeRequestMiddleware: CopilotRuntimeOptions["beforeRequestMiddleware"];
|
|
@@ -51,16 +58,60 @@ declare class CopilotRuntime {
|
|
|
51
58
|
runner: AgentRunner;
|
|
52
59
|
a2ui: CopilotRuntimeOptions["a2ui"];
|
|
53
60
|
mcpApps: CopilotRuntimeOptions["mcpApps"];
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
61
|
+
intelligence?: CopilotKitIntelligence;
|
|
62
|
+
mode: RuntimeMode;
|
|
63
|
+
}
|
|
64
|
+
interface CopilotSseRuntimeLike extends CopilotRuntimeLike {
|
|
65
|
+
intelligence?: undefined;
|
|
66
|
+
mode: RUNTIME_MODE_SSE;
|
|
67
|
+
}
|
|
68
|
+
interface CopilotIntelligenceRuntimeLike extends CopilotRuntimeLike {
|
|
69
|
+
intelligence: CopilotKitIntelligence;
|
|
70
|
+
generateThreadNames: boolean;
|
|
71
|
+
mode: RUNTIME_MODE_INTELLIGENCE;
|
|
72
|
+
}
|
|
73
|
+
declare abstract class BaseCopilotRuntime implements CopilotRuntimeLike {
|
|
74
|
+
agents: CopilotRuntimeOptions["agents"];
|
|
75
|
+
transcriptionService: CopilotRuntimeOptions["transcriptionService"];
|
|
76
|
+
beforeRequestMiddleware: CopilotRuntimeOptions["beforeRequestMiddleware"];
|
|
77
|
+
afterRequestMiddleware: CopilotRuntimeOptions["afterRequestMiddleware"];
|
|
78
|
+
runner: AgentRunner;
|
|
79
|
+
a2ui: CopilotRuntimeOptions["a2ui"];
|
|
80
|
+
mcpApps: CopilotRuntimeOptions["mcpApps"];
|
|
81
|
+
abstract readonly intelligence?: CopilotKitIntelligence;
|
|
82
|
+
abstract readonly mode: RuntimeMode;
|
|
83
|
+
constructor(options: BaseCopilotRuntimeOptions, runner: AgentRunner);
|
|
84
|
+
}
|
|
85
|
+
declare class CopilotSseRuntime extends BaseCopilotRuntime implements CopilotSseRuntimeLike {
|
|
86
|
+
readonly intelligence: undefined;
|
|
87
|
+
readonly mode: any;
|
|
88
|
+
constructor(options: CopilotSseRuntimeOptions);
|
|
89
|
+
}
|
|
90
|
+
declare class CopilotIntelligenceRuntime extends BaseCopilotRuntime implements CopilotIntelligenceRuntimeLike {
|
|
91
|
+
readonly intelligence: CopilotKitIntelligence;
|
|
92
|
+
readonly generateThreadNames: boolean;
|
|
93
|
+
readonly mode: any;
|
|
94
|
+
constructor(options: CopilotIntelligenceRuntimeOptions);
|
|
95
|
+
}
|
|
96
|
+
declare function isIntelligenceRuntime(runtime: CopilotRuntimeLike): runtime is CopilotIntelligenceRuntimeLike;
|
|
97
|
+
/**
|
|
98
|
+
* Compatibility shim that preserves the legacy `CopilotRuntime` entrypoint.
|
|
99
|
+
* New code should prefer `CopilotSseRuntime` or `CopilotIntelligenceRuntime`.
|
|
100
|
+
*/
|
|
101
|
+
declare class CopilotRuntime implements CopilotRuntimeLike {
|
|
102
|
+
private delegate;
|
|
103
|
+
constructor(options: CopilotRuntimeOptions);
|
|
104
|
+
get agents(): CopilotRuntimeOptions["agents"];
|
|
105
|
+
get transcriptionService(): CopilotRuntimeOptions["transcriptionService"];
|
|
106
|
+
get beforeRequestMiddleware(): CopilotRuntimeOptions["beforeRequestMiddleware"];
|
|
107
|
+
get afterRequestMiddleware(): CopilotRuntimeOptions["afterRequestMiddleware"];
|
|
108
|
+
get runner(): AgentRunner;
|
|
109
|
+
get a2ui(): CopilotRuntimeOptions["a2ui"];
|
|
110
|
+
get mcpApps(): CopilotRuntimeOptions["mcpApps"];
|
|
111
|
+
get intelligence(): CopilotKitIntelligence | undefined;
|
|
112
|
+
get generateThreadNames(): boolean | undefined;
|
|
113
|
+
get mode(): RuntimeMode;
|
|
63
114
|
}
|
|
64
115
|
//#endregion
|
|
65
|
-
export { CopilotRuntime, CopilotRuntimeOptions, McpAppsConfig, McpAppsServerConfig, VERSION };
|
|
116
|
+
export { CopilotIntelligenceRuntime, CopilotIntelligenceRuntimeLike, CopilotIntelligenceRuntimeOptions, CopilotRuntime, CopilotRuntimeLike, CopilotRuntimeOptions, CopilotSseRuntime, CopilotSseRuntimeLike, CopilotSseRuntimeOptions, McpAppsConfig, McpAppsServerConfig, VERSION, isIntelligenceRuntime };
|
|
66
117
|
//# sourceMappingURL=runtime.d.mts.map
|
package/dist/runtime.d.mts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"runtime.d.mts","names":[],"sources":["../src/runtime.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"runtime.d.mts","names":[],"sources":["../src/runtime.ts"],"mappings":";;;;;;;;;;;cAqBa,OAAA;AAAA,UAEH,mCAAA;;EAER,MAAA;AAAA;AAAA,KAGU,mBAAA,GAAsB,eAAA;EAPA,uFAShC,OAAA;AAAA;AAAA,UAGe,aAAA;;EAEf,OAAA,EAAS,mBAAA;AAAA;AAAA,UAGD,yBAAA;EAVqB;EAY7B,IAAA,GAAO,mCAAA,GAAsC,oBAAA;EAZb;EAchC,OAAA,GAAU,aAAA;AAAA;AAAA,UAGF,yBAAA,SAAkC,yBAAA;;EAE1C,MAAA,EAAQ,YAAA,CAAa,cAAA,CAAe,MAAA,SAAe,aAAA;EAZvB;EAc5B,oBAAA,GAAuB,oBA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AAA;EAAA,SAEF,YAAA,EAAc,sBAAA;EAAA,SACd,mBAAA;EAAA,SACA,IAAA;cAEG,OAAA,EAAS,iCAAA;AAAA;AAAA,iBAmBP,qBAAA,CACd,OAAA,EAAS,kBAAA,GACR,OAAA,IAAW,8BAAA;AApGd;;;;AAAA,cA4Ga,cAAA,YAA0B,kBAAA;EAAA,QAC7B,QAAA;cAEI,OAAA,EAAS,qBAAA;EAAA,IAMjB,MAAA,CAAA,GAAU,qBAAA;EAAA,IAIV,oBAAA,CAAA,GAAwB,qBAAA;EAAA,IAIxB,uBAAA,CAAA,GAA2B,qBAAA;EAAA,IAI3B,sBAAA,CAAA,GAA0B,qBAAA;EAAA,IAI1B,MAAA,CAAA,GAAU,WAAA;EAAA,IAIV,IAAA,CAAA,GAAQ,qBAAA;EAAA,IAIR,OAAA,CAAA,GAAW,qBAAA;EAAA,IAIX,YAAA,CAAA,GAAgB,sBAAA;EAAA,IAIhB,mBAAA,CAAA;EAAA,IAMA,IAAA,CAAA,GAAQ,WAAA;AAAA"}
|
package/dist/runtime.mjs
CHANGED
|
@@ -1,12 +1,11 @@
|
|
|
1
1
|
import { version } from "./package.mjs";
|
|
2
2
|
import { InMemoryAgentRunner } from "./runner/in-memory.mjs";
|
|
3
|
+
import { IntelligenceAgentRunner } from "./runner/intelligence.mjs";
|
|
4
|
+
import { RUNTIME_MODE_INTELLIGENCE, RUNTIME_MODE_SSE } from "@copilotkitnext/shared";
|
|
3
5
|
|
|
4
6
|
//#region src/runtime.ts
|
|
5
7
|
const VERSION = version;
|
|
6
|
-
|
|
7
|
-
* Central runtime object passed to all request handlers.
|
|
8
|
-
*/
|
|
9
|
-
var CopilotRuntime = class {
|
|
8
|
+
var BaseCopilotRuntime = class {
|
|
10
9
|
agents;
|
|
11
10
|
transcriptionService;
|
|
12
11
|
beforeRequestMiddleware;
|
|
@@ -14,17 +13,84 @@ var CopilotRuntime = class {
|
|
|
14
13
|
runner;
|
|
15
14
|
a2ui;
|
|
16
15
|
mcpApps;
|
|
17
|
-
constructor(
|
|
16
|
+
constructor(options, runner) {
|
|
17
|
+
const { agents, transcriptionService, beforeRequestMiddleware, afterRequestMiddleware, a2ui, mcpApps } = options;
|
|
18
18
|
this.agents = agents;
|
|
19
19
|
this.transcriptionService = transcriptionService;
|
|
20
20
|
this.beforeRequestMiddleware = beforeRequestMiddleware;
|
|
21
21
|
this.afterRequestMiddleware = afterRequestMiddleware;
|
|
22
|
-
this.runner = runner ?? new InMemoryAgentRunner();
|
|
23
22
|
this.a2ui = a2ui;
|
|
24
23
|
this.mcpApps = mcpApps;
|
|
24
|
+
this.runner = runner;
|
|
25
|
+
}
|
|
26
|
+
};
|
|
27
|
+
var CopilotSseRuntime = class extends BaseCopilotRuntime {
|
|
28
|
+
intelligence = void 0;
|
|
29
|
+
mode = RUNTIME_MODE_SSE;
|
|
30
|
+
constructor(options) {
|
|
31
|
+
super(options, options.runner ?? new InMemoryAgentRunner());
|
|
32
|
+
}
|
|
33
|
+
};
|
|
34
|
+
var CopilotIntelligenceRuntime = class extends BaseCopilotRuntime {
|
|
35
|
+
intelligence;
|
|
36
|
+
generateThreadNames;
|
|
37
|
+
mode = RUNTIME_MODE_INTELLIGENCE;
|
|
38
|
+
constructor(options) {
|
|
39
|
+
super(options, new IntelligenceAgentRunner({
|
|
40
|
+
url: options.intelligence.ɵgetRunnerWsUrl(),
|
|
41
|
+
authToken: options.intelligence.ɵgetRunnerAuthToken()
|
|
42
|
+
}));
|
|
43
|
+
this.intelligence = options.intelligence;
|
|
44
|
+
this.generateThreadNames = options.generateThreadNames ?? true;
|
|
45
|
+
}
|
|
46
|
+
};
|
|
47
|
+
function hasIntelligenceOptions(options) {
|
|
48
|
+
return "intelligence" in options && !!options.intelligence;
|
|
49
|
+
}
|
|
50
|
+
function isIntelligenceRuntime(runtime) {
|
|
51
|
+
return runtime.mode === RUNTIME_MODE_INTELLIGENCE && !!runtime.intelligence;
|
|
52
|
+
}
|
|
53
|
+
/**
|
|
54
|
+
* Compatibility shim that preserves the legacy `CopilotRuntime` entrypoint.
|
|
55
|
+
* New code should prefer `CopilotSseRuntime` or `CopilotIntelligenceRuntime`.
|
|
56
|
+
*/
|
|
57
|
+
var CopilotRuntime = class {
|
|
58
|
+
delegate;
|
|
59
|
+
constructor(options) {
|
|
60
|
+
this.delegate = hasIntelligenceOptions(options) ? new CopilotIntelligenceRuntime(options) : new CopilotSseRuntime(options);
|
|
61
|
+
}
|
|
62
|
+
get agents() {
|
|
63
|
+
return this.delegate.agents;
|
|
64
|
+
}
|
|
65
|
+
get transcriptionService() {
|
|
66
|
+
return this.delegate.transcriptionService;
|
|
67
|
+
}
|
|
68
|
+
get beforeRequestMiddleware() {
|
|
69
|
+
return this.delegate.beforeRequestMiddleware;
|
|
70
|
+
}
|
|
71
|
+
get afterRequestMiddleware() {
|
|
72
|
+
return this.delegate.afterRequestMiddleware;
|
|
73
|
+
}
|
|
74
|
+
get runner() {
|
|
75
|
+
return this.delegate.runner;
|
|
76
|
+
}
|
|
77
|
+
get a2ui() {
|
|
78
|
+
return this.delegate.a2ui;
|
|
79
|
+
}
|
|
80
|
+
get mcpApps() {
|
|
81
|
+
return this.delegate.mcpApps;
|
|
82
|
+
}
|
|
83
|
+
get intelligence() {
|
|
84
|
+
return this.delegate.intelligence;
|
|
85
|
+
}
|
|
86
|
+
get generateThreadNames() {
|
|
87
|
+
return isIntelligenceRuntime(this.delegate) ? this.delegate.generateThreadNames : void 0;
|
|
88
|
+
}
|
|
89
|
+
get mode() {
|
|
90
|
+
return this.delegate.mode;
|
|
25
91
|
}
|
|
26
92
|
};
|
|
27
93
|
|
|
28
94
|
//#endregion
|
|
29
|
-
export { CopilotRuntime, VERSION };
|
|
95
|
+
export { CopilotIntelligenceRuntime, CopilotRuntime, CopilotSseRuntime, VERSION, isIntelligenceRuntime };
|
|
30
96
|
//# sourceMappingURL=runtime.mjs.map
|
package/dist/runtime.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"runtime.mjs","names":["pkg.version"],"sources":["../src/runtime.ts"],"sourcesContent":["import {
|
|
1
|
+
{"version":3,"file":"runtime.mjs","names":["pkg.version"],"sources":["../src/runtime.ts"],"sourcesContent":["import {\n MaybePromise,\n NonEmptyRecord,\n RuntimeMode,\n RUNTIME_MODE_SSE,\n RUNTIME_MODE_INTELLIGENCE,\n} from \"@copilotkitnext/shared\";\nimport { AbstractAgent } from \"@ag-ui/client\";\nimport type { MCPClientConfig } from \"@ag-ui/mcp-apps-middleware\";\nimport { A2UIMiddlewareConfig } from \"@ag-ui/a2ui-middleware\";\nimport pkg from \"../package.json\";\nimport type {\n BeforeRequestMiddleware,\n AfterRequestMiddleware,\n} from \"./middleware\";\nimport { TranscriptionService } from \"./transcription-service/transcription-service\";\nimport { AgentRunner } from \"./runner/agent-runner\";\nimport { InMemoryAgentRunner } from \"./runner/in-memory\";\nimport { IntelligenceAgentRunner } from \"./runner/intelligence\";\nimport { CopilotKitIntelligence } from \"./intelligence-platform\";\n\nexport const VERSION = pkg.version;\n\ninterface BaseCopilotRuntimeMiddlewareOptions {\n /** If set, middleware only applies to these named agents. Applies to all agents if omitted. */\n agents?: string[];\n}\n\nexport type McpAppsServerConfig = MCPClientConfig & {\n /** Agent to bind this server to. If omitted, the server is available to all agents. */\n agentId?: string;\n};\n\nexport interface McpAppsConfig {\n /** List of MCP server configurations. */\n servers: McpAppsServerConfig[];\n}\n\ninterface CopilotRuntimeMiddlewares {\n /** Auto-apply A2UIMiddleware to agents at run time. */\n a2ui?: BaseCopilotRuntimeMiddlewareOptions & A2UIMiddlewareConfig;\n /** Auto-apply MCPAppsMiddleware to agents at run time. */\n mcpApps?: McpAppsConfig;\n}\n\ninterface BaseCopilotRuntimeOptions extends CopilotRuntimeMiddlewares {\n /** Map of available agents (loaded lazily is fine). */\n agents: MaybePromise<NonEmptyRecord<Record<string, AbstractAgent>>>;\n /** Optional transcription service for audio processing. */\n transcriptionService?: TranscriptionService;\n /** Optional *before* middleware – callback function or webhook URL. */\n beforeRequestMiddleware?: BeforeRequestMiddleware;\n /** Optional *after* middleware – callback function or webhook URL. */\n afterRequestMiddleware?: AfterRequestMiddleware;\n}\n\nexport interface CopilotSseRuntimeOptions extends BaseCopilotRuntimeOptions {\n /** The runner to use for running agents in SSE mode. */\n runner?: AgentRunner;\n intelligence?: undefined;\n generateThreadNames?: undefined;\n}\n\nexport interface CopilotIntelligenceRuntimeOptions extends BaseCopilotRuntimeOptions {\n /** Configures Intelligence mode for durable threads and realtime events. */\n intelligence: CopilotKitIntelligence;\n /** Auto-generate short names for newly created threads. */\n generateThreadNames?: boolean;\n}\n\nexport type CopilotRuntimeOptions =\n | CopilotSseRuntimeOptions\n | CopilotIntelligenceRuntimeOptions;\n\nexport interface CopilotRuntimeLike {\n agents: CopilotRuntimeOptions[\"agents\"];\n transcriptionService: CopilotRuntimeOptions[\"transcriptionService\"];\n beforeRequestMiddleware: CopilotRuntimeOptions[\"beforeRequestMiddleware\"];\n afterRequestMiddleware: CopilotRuntimeOptions[\"afterRequestMiddleware\"];\n runner: AgentRunner;\n a2ui: CopilotRuntimeOptions[\"a2ui\"];\n mcpApps: CopilotRuntimeOptions[\"mcpApps\"];\n intelligence?: CopilotKitIntelligence;\n mode: RuntimeMode;\n}\n\nexport interface CopilotSseRuntimeLike extends CopilotRuntimeLike {\n intelligence?: undefined;\n mode: RUNTIME_MODE_SSE;\n}\n\nexport interface CopilotIntelligenceRuntimeLike extends CopilotRuntimeLike {\n intelligence: CopilotKitIntelligence;\n generateThreadNames: boolean;\n mode: RUNTIME_MODE_INTELLIGENCE;\n}\n\nabstract class BaseCopilotRuntime implements CopilotRuntimeLike {\n public agents: CopilotRuntimeOptions[\"agents\"];\n public transcriptionService: CopilotRuntimeOptions[\"transcriptionService\"];\n public beforeRequestMiddleware: CopilotRuntimeOptions[\"beforeRequestMiddleware\"];\n public afterRequestMiddleware: CopilotRuntimeOptions[\"afterRequestMiddleware\"];\n public runner: AgentRunner;\n public a2ui: CopilotRuntimeOptions[\"a2ui\"];\n public mcpApps: CopilotRuntimeOptions[\"mcpApps\"];\n\n abstract readonly intelligence?: CopilotKitIntelligence;\n abstract readonly mode: RuntimeMode;\n\n constructor(options: BaseCopilotRuntimeOptions, runner: AgentRunner) {\n const {\n agents,\n transcriptionService,\n beforeRequestMiddleware,\n afterRequestMiddleware,\n a2ui,\n mcpApps,\n } = options;\n\n this.agents = agents;\n this.transcriptionService = transcriptionService;\n this.beforeRequestMiddleware = beforeRequestMiddleware;\n this.afterRequestMiddleware = afterRequestMiddleware;\n this.a2ui = a2ui;\n this.mcpApps = mcpApps;\n this.runner = runner;\n }\n}\n\nexport class CopilotSseRuntime\n extends BaseCopilotRuntime\n implements CopilotSseRuntimeLike\n{\n readonly intelligence = undefined;\n readonly mode = RUNTIME_MODE_SSE;\n\n constructor(options: CopilotSseRuntimeOptions) {\n super(options, options.runner ?? new InMemoryAgentRunner());\n }\n}\n\nexport class CopilotIntelligenceRuntime\n extends BaseCopilotRuntime\n implements CopilotIntelligenceRuntimeLike\n{\n readonly intelligence: CopilotKitIntelligence;\n readonly generateThreadNames: boolean;\n readonly mode = RUNTIME_MODE_INTELLIGENCE;\n\n constructor(options: CopilotIntelligenceRuntimeOptions) {\n super(\n options,\n new IntelligenceAgentRunner({\n url: options.intelligence.ɵgetRunnerWsUrl(),\n authToken: options.intelligence.ɵgetRunnerAuthToken(),\n }),\n );\n this.intelligence = options.intelligence;\n this.generateThreadNames = options.generateThreadNames ?? true;\n }\n}\n\nfunction hasIntelligenceOptions(\n options: CopilotRuntimeOptions,\n): options is CopilotIntelligenceRuntimeOptions {\n return \"intelligence\" in options && !!options.intelligence;\n}\n\nexport function isIntelligenceRuntime(\n runtime: CopilotRuntimeLike,\n): runtime is CopilotIntelligenceRuntimeLike {\n return runtime.mode === RUNTIME_MODE_INTELLIGENCE && !!runtime.intelligence;\n}\n\n/**\n * Compatibility shim that preserves the legacy `CopilotRuntime` entrypoint.\n * New code should prefer `CopilotSseRuntime` or `CopilotIntelligenceRuntime`.\n */\nexport class CopilotRuntime implements CopilotRuntimeLike {\n private delegate: CopilotRuntimeLike;\n\n constructor(options: CopilotRuntimeOptions) {\n this.delegate = hasIntelligenceOptions(options)\n ? new CopilotIntelligenceRuntime(options)\n : new CopilotSseRuntime(options);\n }\n\n get agents(): CopilotRuntimeOptions[\"agents\"] {\n return this.delegate.agents;\n }\n\n get transcriptionService(): CopilotRuntimeOptions[\"transcriptionService\"] {\n return this.delegate.transcriptionService;\n }\n\n get beforeRequestMiddleware(): CopilotRuntimeOptions[\"beforeRequestMiddleware\"] {\n return this.delegate.beforeRequestMiddleware;\n }\n\n get afterRequestMiddleware(): CopilotRuntimeOptions[\"afterRequestMiddleware\"] {\n return this.delegate.afterRequestMiddleware;\n }\n\n get runner(): AgentRunner {\n return this.delegate.runner;\n }\n\n get a2ui(): CopilotRuntimeOptions[\"a2ui\"] {\n return this.delegate.a2ui;\n }\n\n get mcpApps(): CopilotRuntimeOptions[\"mcpApps\"] {\n return this.delegate.mcpApps;\n }\n\n get intelligence(): CopilotKitIntelligence | undefined {\n return this.delegate.intelligence;\n }\n\n get generateThreadNames(): boolean | undefined {\n return isIntelligenceRuntime(this.delegate)\n ? this.delegate.generateThreadNames\n : undefined;\n }\n\n get mode(): RuntimeMode {\n return this.delegate.mode;\n }\n}\n"],"mappings":";;;;;;AAqBA,MAAa,UAAUA;AA4EvB,IAAe,qBAAf,MAAgE;CAC9D,AAAO;CACP,AAAO;CACP,AAAO;CACP,AAAO;CACP,AAAO;CACP,AAAO;CACP,AAAO;CAKP,YAAY,SAAoC,QAAqB;EACnE,MAAM,EACJ,QACA,sBACA,yBACA,wBACA,MACA,YACE;AAEJ,OAAK,SAAS;AACd,OAAK,uBAAuB;AAC5B,OAAK,0BAA0B;AAC/B,OAAK,yBAAyB;AAC9B,OAAK,OAAO;AACZ,OAAK,UAAU;AACf,OAAK,SAAS;;;AAIlB,IAAa,oBAAb,cACU,mBAEV;CACE,AAAS,eA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1
|
{
|
|
2
2
|
"name": "@copilotkitnext/runtime",
|
|
3
|
-
"version": "1.54.0",
|
|
3
|
+
"version": "1.54.1-next.0",
|
|
4
4
|
"deprecated": "This package is deprecated. Use @copilotkit/runtime instead. V2 features are being integrated into the main @copilotkit exports and will be available under the /v2 subpath.",
|
|
5
5
|
"description": "Server-side runtime package for CopilotKit2",
|
|
6
6
|
"main": "./dist/index.cjs",
|
|
@@ -30,8 +30,8 @@
|
|
|
30
30
|
"tsdown": "^0.20.3",
|
|
31
31
|
"typescript": "5.8.2",
|
|
32
32
|
"vitest": "^3.0.5",
|
|
33
|
-
"@copilotkitnext/eslint-config": "1.54.0",
|
|
34
|
-
"@copilotkitnext/typescript-config": "1.54.0"
|
|
33
|
+
"@copilotkitnext/eslint-config": "1.54.1-next.0",
|
|
34
|
+
"@copilotkitnext/typescript-config": "1.54.1-next.0"
|
|
35
35
|
},
|
|
36
36
|
"dependencies": {
|
|
37
37
|
"@ag-ui/a2ui-middleware": "0.0.2",
|
|
@@ -45,13 +45,13 @@
|
|
|
45
45
|
"express": "^4.21.2",
|
|
46
46
|
"hono": "^4.11.4",
|
|
47
47
|
"rxjs": "7.8.1",
|
|
48
|
-
"@copilotkitnext/shared": "1.54.0"
|
|
48
|
+
"@copilotkitnext/shared": "1.54.1-next.0"
|
|
49
49
|
},
|
|
50
50
|
"peerDependencies": {
|
|
51
51
|
"@ag-ui/client": "0.0.47",
|
|
52
52
|
"@ag-ui/core": "0.0.47",
|
|
53
53
|
"@ag-ui/encoder": "0.0.47",
|
|
54
|
-
"@copilotkitnext/shared": "1.54.0"
|
|
54
|
+
"@copilotkitnext/shared": "1.54.1-next.0"
|
|
55
55
|
},
|
|
56
56
|
"peerDependenciesMeta": {},
|
|
57
57
|
"engines": {
|