@ai-agent-forge/agent-forge 0.86.4 → 0.86.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +52 -0
- package/dist/bundle/.build-manifest.json +470 -404
- package/dist/bundle/chunks/anthropic-messages-ALDZBUKI.js +6 -0
- package/dist/bundle/chunks/anthropic.js +2 -2
- package/dist/bundle/chunks/{azure-openai-responses-WQCZWFAH.js → azure-openai-responses-A2WJWZFB.js} +1 -1
- package/dist/bundle/chunks/bedrock-converse-stream.js +1 -1
- package/dist/bundle/chunks/chunk-A7GUOX2H.js +141 -0
- package/dist/bundle/chunks/{chunk-WGLBM2BP.js → chunk-CIX3FSBK.js} +1 -1
- package/dist/bundle/chunks/{chunk-ZV3W36HK.js → chunk-EALJ5DDX.js} +99 -92
- package/dist/bundle/chunks/chunk-OO6DJ3CL.js +31 -0
- package/dist/bundle/chunks/{chunk-PE3XUHPT.js → chunk-SQFG22WN.js} +1 -1
- package/dist/bundle/chunks/{chunk-V46XUTK3.js → chunk-Y7HXTASS.js} +1 -1
- package/dist/bundle/chunks/{chunk-3WE3W52L.js → chunk-YJCQVXW5.js} +1 -1
- package/dist/bundle/chunks/github-copilot.js +1 -1
- package/dist/bundle/chunks/{google-generative-ai-LQ375GYC.js → google-generative-ai-NIB4WONV.js} +1 -1
- package/dist/bundle/chunks/{google-vertex-HXSRAKEZ.js → google-vertex-DCPYUEUO.js} +1 -1
- package/dist/bundle/chunks/{mistral-conversations-CSNMFR4J.js → mistral-conversations-OC6LA5XL.js} +1 -1
- package/dist/bundle/chunks/{openai-codex-responses-YDJSZOIH.js → openai-codex-responses-IO2X4Y7L.js} +1 -1
- package/dist/bundle/chunks/openai-codex.js +2 -2
- package/dist/bundle/chunks/{openai-completions-UPRWTQPT.js → openai-completions-XYQQHETU.js} +1 -1
- package/dist/bundle/chunks/{openai-responses-O63W6HQ3.js → openai-responses-DLIRN3CI.js} +1 -1
- package/dist/bundle/chunks/{openrouter-images-G3GT5BVT.js → openrouter-images-G4GQRUSG.js} +1 -1
- package/dist/bundle/chunks/openrouter.js +2 -2
- package/dist/bundle/chunks/{pi-messages-SLF355GF.js → pi-messages-E6RRYBO7.js} +1 -1
- package/dist/bundle/chunks/radius.js +2 -2
- package/dist/bundle/chunks/{virtual-modules-O72ICTMQ.js → virtual-modules-3IZ4MYSQ.js} +1 -1
- package/dist/bundle/cli.js +1 -1
- package/dist/bundle/index.js +1 -1
- package/dist/bundle/rpc-entry.js +1 -1
- package/dist/capabilities/builtin.d.ts +4 -2
- package/dist/capabilities/builtin.d.ts.map +1 -1
- package/dist/capabilities/builtin.js +5 -1
- package/dist/capabilities/builtin.js.map +1 -1
- package/dist/cli/plugin-command.d.ts.map +1 -1
- package/dist/cli/plugin-command.js +51 -5
- package/dist/cli/plugin-command.js.map +1 -1
- package/dist/core/agent-session-compaction.d.ts.map +1 -1
- package/dist/core/agent-session-compaction.js +13 -5
- package/dist/core/agent-session-compaction.js.map +1 -1
- package/dist/core/agent-session-internal.d.ts +2 -4
- package/dist/core/agent-session-internal.d.ts.map +1 -1
- package/dist/core/agent-session-internal.js.map +1 -1
- package/dist/core/agent-session-paths.d.ts +2 -0
- package/dist/core/agent-session-paths.d.ts.map +1 -1
- package/dist/core/agent-session-paths.js +2 -1
- package/dist/core/agent-session-paths.js.map +1 -1
- package/dist/core/agent-session-projection.d.ts +10 -4
- package/dist/core/agent-session-projection.d.ts.map +1 -1
- package/dist/core/agent-session-projection.js +17 -4
- package/dist/core/agent-session-projection.js.map +1 -1
- package/dist/core/agent-session.d.ts +19 -5
- package/dist/core/agent-session.d.ts.map +1 -1
- package/dist/core/agent-session.js +30 -4
- package/dist/core/agent-session.js.map +1 -1
- package/dist/core/extensions/bootstrap-lifecycle.d.ts +1 -1
- package/dist/core/extensions/bootstrap-lifecycle.d.ts.map +1 -1
- package/dist/core/extensions/bootstrap-lifecycle.js +5 -2
- package/dist/core/extensions/bootstrap-lifecycle.js.map +1 -1
- package/dist/core/extensions/capability-runtime-store.d.ts.map +1 -1
- package/dist/core/extensions/capability-runtime-store.js +1 -0
- package/dist/core/extensions/capability-runtime-store.js.map +1 -1
- package/dist/core/extensions/capability-runtime-types.d.ts +16 -1
- package/dist/core/extensions/capability-runtime-types.d.ts.map +1 -1
- package/dist/core/extensions/capability-runtime-types.js.map +1 -1
- package/dist/core/extensions/capability-runtime.d.ts.map +1 -1
- package/dist/core/extensions/capability-runtime.js +38 -2
- package/dist/core/extensions/capability-runtime.js.map +1 -1
- package/dist/core/extensions/index.d.ts +1 -1
- package/dist/core/extensions/index.d.ts.map +1 -1
- package/dist/core/extensions/index.js.map +1 -1
- package/dist/core/extensions/lifecycle-catalog.d.ts +46 -0
- package/dist/core/extensions/lifecycle-catalog.d.ts.map +1 -1
- package/dist/core/extensions/lifecycle-catalog.js +101 -0
- package/dist/core/extensions/lifecycle-catalog.js.map +1 -1
- package/dist/core/extensions/provider-failover.d.ts +106 -0
- package/dist/core/extensions/provider-failover.d.ts.map +1 -0
- package/dist/core/extensions/provider-failover.js +692 -0
- package/dist/core/extensions/provider-failover.js.map +1 -0
- package/dist/core/facade/coding-agent-facade.d.ts +13 -6
- package/dist/core/facade/coding-agent-facade.d.ts.map +1 -1
- package/dist/core/facade/coding-agent-facade.js +3 -1
- package/dist/core/facade/coding-agent-facade.js.map +1 -1
- package/dist/core/keybindings.d.ts +6 -6
- package/dist/core/keybindings.d.ts.map +1 -1
- package/dist/core/keybindings.js +23 -6
- package/dist/core/keybindings.js.map +1 -1
- package/dist/core/model-config.d.ts +102 -0
- package/dist/core/model-config.d.ts.map +1 -1
- package/dist/core/model-config.js +46 -14
- package/dist/core/model-config.js.map +1 -1
- package/dist/core/model-resolver.d.ts.map +1 -1
- package/dist/core/model-resolver.js +1 -1
- package/dist/core/model-resolver.js.map +1 -1
- package/dist/core/model-runtime.d.ts +15 -0
- package/dist/core/model-runtime.d.ts.map +1 -1
- package/dist/core/model-runtime.js +30 -18
- package/dist/core/model-runtime.js.map +1 -1
- package/dist/core/remote-catalog-provider.d.ts.map +1 -1
- package/dist/core/remote-catalog-provider.js +4 -9
- package/dist/core/remote-catalog-provider.js.map +1 -1
- package/dist/core/sdk.d.ts.map +1 -1
- package/dist/core/sdk.js +107 -24
- package/dist/core/sdk.js.map +1 -1
- package/dist/core/session-manager.d.ts +2 -0
- package/dist/core/session-manager.d.ts.map +1 -1
- package/dist/core/session-manager.js +10 -5
- package/dist/core/session-manager.js.map +1 -1
- package/dist/core/settings-manager.d.ts +71 -5
- package/dist/core/settings-manager.d.ts.map +1 -1
- package/dist/core/settings-manager.js +138 -9
- package/dist/core/settings-manager.js.map +1 -1
- package/dist/core/slash-commands.d.ts.map +1 -1
- package/dist/core/slash-commands.js +17 -2
- package/dist/core/slash-commands.js.map +1 -1
- package/dist/core/tools/render-utils.d.ts +6 -0
- package/dist/core/tools/render-utils.d.ts.map +1 -1
- package/dist/core/tools/render-utils.js +26 -0
- package/dist/core/tools/render-utils.js.map +1 -1
- package/dist/core/tools/tool-definition.d.ts +21 -2
- package/dist/core/tools/tool-definition.d.ts.map +1 -1
- package/dist/core/tools/tool-definition.js.map +1 -1
- package/dist/main.d.ts.map +1 -1
- package/dist/main.js +3 -6
- package/dist/main.js.map +1 -1
- package/dist/modes/interactive/components/agents-view.d.ts +57 -0
- package/dist/modes/interactive/components/agents-view.d.ts.map +1 -0
- package/dist/modes/interactive/components/agents-view.js +260 -0
- package/dist/modes/interactive/components/agents-view.js.map +1 -0
- package/dist/modes/interactive/components/custom-editor.d.ts.map +1 -1
- package/dist/modes/interactive/components/custom-editor.js +2 -2
- package/dist/modes/interactive/components/custom-editor.js.map +1 -1
- package/dist/modes/interactive/components/footer.d.ts +7 -0
- package/dist/modes/interactive/components/footer.d.ts.map +1 -1
- package/dist/modes/interactive/components/footer.js +51 -6
- package/dist/modes/interactive/components/footer.js.map +1 -1
- package/dist/modes/interactive/components/scoped-models-selector.d.ts +1 -1
- package/dist/modes/interactive/components/scoped-models-selector.d.ts.map +1 -1
- package/dist/modes/interactive/components/scoped-models-selector.js +1 -1
- package/dist/modes/interactive/components/scoped-models-selector.js.map +1 -1
- package/dist/modes/interactive/components/settings-selector.d.ts +3 -1
- package/dist/modes/interactive/components/settings-selector.d.ts.map +1 -1
- package/dist/modes/interactive/components/settings-selector.js +12 -2
- package/dist/modes/interactive/components/settings-selector.js.map +1 -1
- package/dist/modes/interactive/components/thinking-selector.d.ts.map +1 -1
- package/dist/modes/interactive/components/thinking-selector.js +1 -1
- package/dist/modes/interactive/components/thinking-selector.js.map +1 -1
- package/dist/modes/interactive/components/tool-execution.d.ts.map +1 -1
- package/dist/modes/interactive/components/tool-execution.js +89 -10
- package/dist/modes/interactive/components/tool-execution.js.map +1 -1
- package/dist/modes/interactive/components/user-message-selector.d.ts +3 -0
- package/dist/modes/interactive/components/user-message-selector.d.ts.map +1 -1
- package/dist/modes/interactive/components/user-message-selector.js +9 -3
- package/dist/modes/interactive/components/user-message-selector.js.map +1 -1
- package/dist/modes/interactive/components/workflow-view.d.ts +119 -0
- package/dist/modes/interactive/components/workflow-view.d.ts.map +1 -0
- package/dist/modes/interactive/components/workflow-view.js +638 -0
- package/dist/modes/interactive/components/workflow-view.js.map +1 -0
- package/dist/modes/interactive/interactive-commands.d.ts +22 -0
- package/dist/modes/interactive/interactive-commands.d.ts.map +1 -1
- package/dist/modes/interactive/interactive-commands.js +56 -0
- package/dist/modes/interactive/interactive-commands.js.map +1 -1
- package/dist/modes/interactive/interactive-mode.d.ts +51 -1
- package/dist/modes/interactive/interactive-mode.d.ts.map +1 -1
- package/dist/modes/interactive/interactive-mode.js +218 -37
- package/dist/modes/interactive/interactive-mode.js.map +1 -1
- package/dist/modes/interactive/interactive-selectors.d.ts +2 -4
- package/dist/modes/interactive/interactive-selectors.d.ts.map +1 -1
- package/dist/modes/interactive/interactive-selectors.js +10 -1
- package/dist/modes/interactive/interactive-selectors.js.map +1 -1
- package/dist/modes/print-mode.d.ts.map +1 -1
- package/dist/modes/print-mode.js +5 -0
- package/dist/modes/print-mode.js.map +1 -1
- package/dist/modes/rpc/rpc-client.d.ts +3 -1
- package/dist/modes/rpc/rpc-client.d.ts.map +1 -1
- package/dist/modes/rpc/rpc-client.js +4 -2
- package/dist/modes/rpc/rpc-client.js.map +1 -1
- package/dist/modes/rpc/rpc-types.d.ts +1 -0
- package/dist/modes/rpc/rpc-types.d.ts.map +1 -1
- package/dist/modes/rpc/rpc-types.js.map +1 -1
- package/dist/plugins/ecosystem/bootstrap-factory-manifest.d.ts.map +1 -1
- package/dist/plugins/ecosystem/bootstrap-factory-manifest.js +7 -0
- package/dist/plugins/ecosystem/bootstrap-factory-manifest.js.map +1 -1
- package/dist/plugins/ecosystem/cli.d.ts.map +1 -1
- package/dist/plugins/ecosystem/cli.js +1 -1
- package/dist/plugins/ecosystem/cli.js.map +1 -1
- package/dist/plugins/ecosystem/install-store-paths.d.ts +15 -0
- package/dist/plugins/ecosystem/install-store-paths.d.ts.map +1 -0
- package/dist/plugins/ecosystem/install-store-paths.js +58 -0
- package/dist/plugins/ecosystem/install-store-paths.js.map +1 -0
- package/dist/plugins/ecosystem/node-disk-registry-source.d.ts.map +1 -1
- package/dist/plugins/ecosystem/node-disk-registry-source.js +3 -8
- package/dist/plugins/ecosystem/node-disk-registry-source.js.map +1 -1
- package/dist/plugins/ecosystem/node-package-install-host.d.ts.map +1 -1
- package/dist/plugins/ecosystem/node-package-install-host.js +9 -1
- package/dist/plugins/ecosystem/node-package-install-host.js.map +1 -1
- package/dist/plugins/ecosystem/node-package-install-persistence.d.ts.map +1 -1
- package/dist/plugins/ecosystem/node-package-install-persistence.js +3 -8
- package/dist/plugins/ecosystem/node-package-install-persistence.js.map +1 -1
- package/dist/profile/plugin-profiles.d.ts +2 -0
- package/dist/profile/plugin-profiles.d.ts.map +1 -1
- package/dist/profile/plugin-profiles.js +4 -0
- package/dist/profile/plugin-profiles.js.map +1 -1
- package/dist/profiles/builtin-suites.d.ts +19 -2
- package/dist/profiles/builtin-suites.d.ts.map +1 -1
- package/dist/profiles/builtin-suites.js +20 -2
- package/dist/profiles/builtin-suites.js.map +1 -1
- package/dist/profiles/suite-loader.d.ts.map +1 -1
- package/dist/profiles/suite-loader.js +4 -1
- package/dist/profiles/suite-loader.js.map +1 -1
- package/dist/utils/clipboard.d.ts.map +1 -1
- package/dist/utils/clipboard.js +10 -10
- package/dist/utils/clipboard.js.map +1 -1
- package/docs/keybindings.md +8 -8
- package/docs/models.md +1 -1
- package/docs/rpc.md +3 -1
- package/docs/settings.md +2 -1
- package/package.json +4 -4
- package/dist/bundle/chunks/anthropic-messages-EVFQ6MLR.js +0 -6
- package/dist/bundle/chunks/chunk-F6SBZUJG.js +0 -141
- package/dist/bundle/chunks/chunk-NUHFSC37.js +0 -25
|
@@ -107,11 +107,15 @@ export function createCapabilityRuntime(inputHost, options = {}) {
|
|
|
107
107
|
const onOutputArtifactCommit = options.onOutputArtifactCommit;
|
|
108
108
|
const toolExecutionContext = options.toolExecutionContext;
|
|
109
109
|
const state = createCapabilityRuntimeState();
|
|
110
|
-
const { tools, skills, retryPolicies, compactionPolicies, overflowPolicies, branchSummaryPolicies, runLoopStrategies, loopHooks, commands, operations, rpcMethods, contextStrategies, pluginCapabilities, providerHeaderTransforms, contributionPoints, lifecycleDefinitions, lifecycleRegistrations, subscribers, statuses, pluginRegistrations, apiStates, activeOwnerTokens, outputArtifacts, stateByOwner, stateRevisionsByOwner, stateWatchers, stateByInstance, stateRevisionsByInstance, stateWatchersByInstance, logs, spans, lifecycleDeliveryQueues, pluginRejections, } = state;
|
|
110
|
+
const { tools, skills, retryPolicies, compactionPolicies, overflowPolicies, branchSummaryPolicies, runLoopStrategies, loopHooks, commands, operations, rpcMethods, contextStrategies, pluginCapabilities, providerHeaderTransforms, streamFnWrappers, contributionPoints, lifecycleDefinitions, lifecycleRegistrations, subscribers, statuses, pluginRegistrations, apiStates, activeOwnerTokens, outputArtifacts, stateByOwner, stateRevisionsByOwner, stateWatchers, stateByInstance, stateRevisionsByInstance, stateWatchersByInstance, logs, spans, lifecycleDeliveryQueues, pluginRejections, } = state;
|
|
111
111
|
const runtimeState = state;
|
|
112
112
|
let subscriptionSequence = 0;
|
|
113
113
|
let operationSequence = 0;
|
|
114
114
|
let agentTaskSequence = 0;
|
|
115
|
+
// 活任务集合(设计 子代理运行时 §4.2 中断分级,2026-10-02):runtime 级共享,
|
|
116
|
+
// 每个插件 API 的 createAgentTask 入队、任务 dispose 出队;宿主经
|
|
117
|
+
// runtime.getActiveAgentTaskCount() 读有界投影。
|
|
118
|
+
const agentTasks = new Set();
|
|
115
119
|
let artifactSequence = 0;
|
|
116
120
|
let contributionSubscriptionSequence = 0;
|
|
117
121
|
let lifecycleRegistrationSequence = 0;
|
|
@@ -167,6 +171,7 @@ export function createCapabilityRuntime(inputHost, options = {}) {
|
|
|
167
171
|
rpcMethods,
|
|
168
172
|
contextStrategies,
|
|
169
173
|
providerHeaderTransforms,
|
|
174
|
+
streamFnWrappers,
|
|
170
175
|
]) {
|
|
171
176
|
for (const [name, entry] of registry) {
|
|
172
177
|
if (entry.ownerToken === ownerToken) {
|
|
@@ -1124,7 +1129,6 @@ export function createCapabilityRuntime(inputHost, options = {}) {
|
|
|
1124
1129
|
owner: point.owner,
|
|
1125
1130
|
})),
|
|
1126
1131
|
};
|
|
1127
|
-
const agentTasks = new Set();
|
|
1128
1132
|
const createAgentTask = async (request) => {
|
|
1129
1133
|
assertUsable();
|
|
1130
1134
|
assertAgentTaskRequest(request);
|
|
@@ -1648,6 +1652,15 @@ export function createCapabilityRuntime(inputHost, options = {}) {
|
|
|
1648
1652
|
}
|
|
1649
1653
|
return own(register("provider-header-transform", name, transform, owner, ownerToken, providerHeaderTransforms));
|
|
1650
1654
|
},
|
|
1655
|
+
registerStreamFnWrapper(name, wrapper) {
|
|
1656
|
+
assertUsable();
|
|
1657
|
+
if (!name)
|
|
1658
|
+
throw new Error("Stream function wrapper requires a non-empty name");
|
|
1659
|
+
if (typeof wrapper !== "function") {
|
|
1660
|
+
throw new Error("Stream function wrapper requires a callable wrapper");
|
|
1661
|
+
}
|
|
1662
|
+
return own(register("stream-fn-wrapper", name, wrapper, owner, ownerToken, streamFnWrappers));
|
|
1663
|
+
},
|
|
1651
1664
|
registerSkill(definition) {
|
|
1652
1665
|
assertUsable();
|
|
1653
1666
|
const name = capabilityName(definition, "Skill");
|
|
@@ -2097,6 +2110,26 @@ export function createCapabilityRuntime(inputHost, options = {}) {
|
|
|
2097
2110
|
throw new Error(`Tool is not registered: ${name}`);
|
|
2098
2111
|
return invokeRegisteredCapability(registered, (value) => invokeCapabilityTool(asHandler(value, "Tool"), input, toolExecutionContext, options?.signal));
|
|
2099
2112
|
},
|
|
2113
|
+
// 中断分级读面(设计 §4.2,2026-10-02):活任务集合的有界投影。已终态
|
|
2114
|
+
// 任务在显式 dispose 前仍滞留集合(释放钩子语义,见 RuntimeAgentTask),
|
|
2115
|
+
// 因此这里按状态过滤——只计尚未终态的任务。dispose 是多 await 流程,
|
|
2116
|
+
// 任务先置 disposed 再退出集合,中间窗口 status() 会抛——该窗口内的
|
|
2117
|
+
// 任务按非活跃计(宿主按键路径绝不能因投影抛错)。
|
|
2118
|
+
getActiveAgentTaskCount: () => {
|
|
2119
|
+
let active = 0;
|
|
2120
|
+
for (const task of agentTasks) {
|
|
2121
|
+
let status;
|
|
2122
|
+
try {
|
|
2123
|
+
status = task.status();
|
|
2124
|
+
}
|
|
2125
|
+
catch {
|
|
2126
|
+
continue;
|
|
2127
|
+
}
|
|
2128
|
+
if (status !== "succeeded" && status !== "failed" && status !== "cancelled")
|
|
2129
|
+
active += 1;
|
|
2130
|
+
}
|
|
2131
|
+
return active;
|
|
2132
|
+
},
|
|
2100
2133
|
hasCommand: (name) => commands.has(name),
|
|
2101
2134
|
async invokeCommand(name, args, options) {
|
|
2102
2135
|
const registered = commands.get(name);
|
|
@@ -2153,6 +2186,9 @@ export function createCapabilityRuntime(inputHost, options = {}) {
|
|
|
2153
2186
|
}
|
|
2154
2187
|
return headers;
|
|
2155
2188
|
},
|
|
2189
|
+
getStreamFnWrappers: () => Array.from(streamFnWrappers.values())
|
|
2190
|
+
.filter((entry) => activeOwnerTokens.has(entry.ownerToken))
|
|
2191
|
+
.map((entry) => entry.value),
|
|
2156
2192
|
getOperationStatus: (id) => statuses.get(id),
|
|
2157
2193
|
drainLifecycleDeliveries: async () => {
|
|
2158
2194
|
while (true) {
|