qlogicagent 2.10.21 → 2.10.23
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/README.md +29 -4
- package/dist/agent.js +11 -11
- package/dist/cli.js +701 -604
- package/dist/index.js +700 -603
- package/dist/permissions.js +1 -0
- package/dist/protocol.js +1 -1
- package/dist/types/agent/tool-access.d.ts +1 -30
- package/dist/types/agent/tunable-defaults.d.ts +1 -249
- package/dist/types/agent/types.d.ts +7 -0
- package/dist/types/cli/acp-extended-handlers.d.ts +41 -0
- package/dist/types/cli/acp-extended-host-adapter.d.ts +28 -0
- package/dist/types/cli/acp-extended-host-adapter.test.d.ts +1 -0
- package/dist/types/cli/acp-session-handlers.d.ts +39 -0
- package/dist/types/cli/acp-session-handlers.test.d.ts +1 -0
- package/dist/types/cli/agent-config-coordinator.d.ts +13 -0
- package/dist/types/cli/agent-config-runtime.d.ts +11 -0
- package/dist/types/cli/agent-runner-factory.d.ts +2 -0
- package/dist/types/cli/agent-runtime-bootstrap.d.ts +64 -0
- package/dist/types/cli/agent-status-notifier.d.ts +11 -0
- package/dist/types/cli/agent-status-notifier.test.d.ts +1 -0
- package/dist/types/cli/base-tool-bootstrap.d.ts +7 -0
- package/dist/types/cli/cli-acp-request-handler.d.ts +9 -0
- package/dist/types/cli/cli-acp-request-handler.test.d.ts +1 -0
- package/dist/types/cli/cli-agent-builder.d.ts +35 -0
- package/dist/types/cli/community-skill-installer.d.ts +12 -0
- package/dist/types/cli/community-skill-installer.test.d.ts +1 -0
- package/dist/types/cli/core-tool-coordinator.d.ts +30 -0
- package/dist/types/cli/core-tools/agent-tool-bootstrap.d.ts +10 -0
- package/dist/types/cli/core-tools/agent-tool-service.d.ts +18 -0
- package/dist/types/cli/core-tools/checkpoint-tool-bootstrap.d.ts +7 -0
- package/dist/types/cli/core-tools/checkpoint-tool-service.d.ts +7 -0
- package/dist/types/cli/core-tools/config-tool-bootstrap.d.ts +7 -0
- package/dist/types/cli/core-tools/config-tool-service.d.ts +7 -0
- package/dist/types/cli/core-tools/cron-tool-bootstrap.d.ts +7 -0
- package/dist/types/cli/core-tools/cron-tool-service.d.ts +22 -0
- package/dist/types/cli/core-tools/cron-tool-service.test.d.ts +1 -0
- package/dist/types/cli/core-tools/monitor-tool-bootstrap.d.ts +5 -0
- package/dist/types/cli/core-tools/monitor-tool-service.d.ts +6 -0
- package/dist/types/cli/core-tools/registry.d.ts +9 -0
- package/dist/types/cli/core-tools/team-tool-bootstrap.d.ts +7 -0
- package/dist/types/cli/core-tools/team-tool-service.d.ts +21 -0
- package/dist/types/cli/core-tools/utility-tool-bootstrap.d.ts +8 -0
- package/dist/types/cli/default-project-bootstrap.d.ts +8 -0
- package/dist/types/cli/dev-tool-bootstrap.d.ts +4 -0
- package/dist/types/cli/dev-tools/lsp-tool-service.d.ts +5 -0
- package/dist/types/cli/dev-tools/repl-lsp-tool-services.test.d.ts +1 -0
- package/dist/types/cli/dev-tools/repl-tool-service.d.ts +5 -0
- package/dist/types/cli/dream-host-adapter.d.ts +19 -0
- package/dist/types/cli/handlers/agents-handler.d.ts +28 -14
- package/dist/types/cli/handlers/community-handler.d.ts +25 -0
- package/dist/types/cli/handlers/community-handler.test.d.ts +1 -0
- package/dist/types/cli/handlers/config-handler.d.ts +15 -9
- package/dist/types/cli/handlers/config-handler.test.d.ts +1 -0
- package/dist/types/cli/handlers/control-handler.d.ts +23 -0
- package/dist/types/cli/handlers/dream-handler.d.ts +21 -1
- package/dist/types/cli/handlers/files-handler.d.ts +15 -9
- package/dist/types/cli/handlers/files-handler.instructions.test.d.ts +1 -0
- package/dist/types/cli/handlers/media-handler.d.ts +10 -4
- package/dist/types/cli/handlers/media-handler.test.d.ts +1 -0
- package/dist/types/cli/handlers/memory-handler.d.ts +39 -12
- package/dist/types/cli/handlers/pet-confirm-handler.d.ts +7 -0
- package/dist/types/cli/handlers/pet-handler.d.ts +29 -4
- package/dist/types/cli/handlers/pet-handler.test.d.ts +1 -0
- package/dist/types/cli/handlers/product-handler.d.ts +40 -14
- package/dist/types/cli/handlers/project-handler.d.ts +23 -14
- package/dist/types/cli/handlers/session-handler.d.ts +36 -17
- package/dist/types/cli/handlers/session-handler.resume.test.d.ts +1 -0
- package/dist/types/cli/handlers/settings-handler.d.ts +16 -12
- package/dist/types/cli/handlers/skills-handler.d.ts +19 -10
- package/dist/types/cli/handlers/skills-handler.profile.test.d.ts +1 -0
- package/dist/types/cli/handlers/solo-handler.d.ts +31 -9
- package/dist/types/cli/handlers/turn-handler.approval.test.d.ts +1 -0
- package/dist/types/cli/handlers/turn-handler.d.ts +17 -11
- package/dist/types/cli/idle-dream-coordinator.d.ts +46 -0
- package/dist/types/cli/idle-dream-coordinator.test.d.ts +1 -0
- package/dist/types/cli/mcp-plugin-bootstrap.d.ts +27 -0
- package/dist/types/cli/mcp-plugin-bootstrap.test.d.ts +1 -0
- package/dist/types/cli/mcp-tool-proxy.d.ts +7 -0
- package/dist/types/cli/media-file-api-service.d.ts +73 -0
- package/dist/types/cli/media-file-api-service.test.d.ts +1 -0
- package/dist/types/cli/media-file-tool-service.d.ts +13 -0
- package/dist/types/cli/memory-coordinator.d.ts +36 -0
- package/dist/types/cli/model-client-resolver.d.ts +22 -0
- package/dist/types/cli/multi-agent-handler-host.d.ts +27 -0
- package/dist/types/cli/multi-agent-handler-host.test.d.ts +1 -0
- package/dist/types/cli/multi-agent-state-coordinator.d.ts +11 -0
- package/dist/types/cli/permission-bootstrap.d.ts +33 -0
- package/dist/types/cli/permission-bootstrap.test.d.ts +1 -0
- package/dist/types/cli/permission-settings-store.d.ts +2 -0
- package/dist/types/cli/permission-settings-store.test.d.ts +1 -0
- package/dist/types/cli/pet-confirm-coordinator.d.ts +20 -0
- package/dist/types/cli/pet-confirm-coordinator.test.d.ts +1 -0
- package/dist/types/cli/pet-runtime.d.ts +34 -0
- package/dist/types/cli/pet-runtime.test.d.ts +1 -0
- package/dist/types/cli/project-context.d.ts +1 -0
- package/dist/types/cli/project-memory-store-factory.d.ts +2 -0
- package/dist/types/cli/project-template-seeder.d.ts +5 -0
- package/dist/types/cli/provider-core-facade.d.ts +27 -0
- package/dist/types/cli/rpc-registry.community.test.d.ts +1 -0
- package/dist/types/cli/rpc-registry.d.ts +8 -0
- package/dist/types/cli/runtime-hook-bootstrap.d.ts +34 -0
- package/dist/types/cli/runtime-watcher-bootstrap.d.ts +15 -0
- package/dist/types/cli/session-coordinator.d.ts +10 -0
- package/dist/types/cli/session-coordinator.test.d.ts +1 -0
- package/dist/types/cli/session-history-coordinator.d.ts +11 -0
- package/dist/types/cli/session-history-coordinator.test.d.ts +1 -0
- package/dist/types/cli/skill-meta-tool-bootstrap.d.ts +25 -0
- package/dist/types/cli/skill-meta-tool-bootstrap.test.d.ts +1 -0
- package/dist/types/cli/stdio-server.d.ts +17 -134
- package/dist/types/cli/tool-bootstrap.d.ts +1 -4
- package/dist/types/cli/tool-bootstrap.instructions.test.d.ts +1 -0
- package/dist/types/cli/tool-bootstrap.media-provider-alias.test.d.ts +1 -0
- package/dist/types/cli/tool-catalog.d.ts +2 -0
- package/dist/types/cli/tool-invoker-factory.d.ts +10 -0
- package/dist/types/cli/tool-result-processor.d.ts +14 -0
- package/dist/types/cli/transport.d.ts +2 -12
- package/dist/types/cli/turn-ask-user-setup.d.ts +9 -0
- package/dist/types/cli/turn-event-forwarder.d.ts +10 -0
- package/dist/types/cli/turn-lifecycle.d.ts +19 -0
- package/dist/types/cli/turn-lifecycle.test.d.ts +1 -0
- package/dist/types/cli/turn-media-setup.d.ts +16 -0
- package/dist/types/cli/turn-permission-sync.d.ts +7 -0
- package/dist/types/cli/turn-permission-sync.test.d.ts +1 -0
- package/dist/types/cli/turn-project-router.d.ts +22 -0
- package/dist/types/cli/turn-project-router.test.d.ts +1 -0
- package/dist/types/cli/turn-skill-autopersist.d.ts +47 -0
- package/dist/types/cli/turn-skill-autopersist.test.d.ts +1 -0
- package/dist/types/cli/turn-suggestion-generator.d.ts +15 -0
- package/dist/types/orchestration/agent-instance.d.ts +1 -1
- package/dist/types/orchestration/dag-scheduler.d.ts +135 -86
- package/dist/types/orchestration/index.d.ts +2 -2
- package/dist/types/orchestration/product-budget.d.ts +1 -1
- package/dist/types/orchestration/product-persistence.d.ts +3 -12
- package/dist/types/orchestration/product-planner.d.ts +1 -1
- package/dist/types/orchestration/skill-improvement.d.ts +1 -1
- package/dist/types/orchestration/solo-evaluator.d.ts +1 -1
- package/dist/types/orchestration/solo-persistence.d.ts +1 -1
- package/dist/types/orchestration/subagent/fork-subagent.d.ts +1 -1
- package/dist/types/orchestration/subagent/task-types.d.ts +1 -146
- package/dist/types/orchestration/tool-cascade.d.ts +2 -2
- package/dist/types/orchestration/workflow/budget-permission-gate.d.ts +85 -0
- package/dist/types/orchestration/workflow/builtin-executors.d.ts +12 -0
- package/dist/types/orchestration/workflow/cron-schedule.d.ts +37 -0
- package/dist/types/orchestration/workflow/data-item.d.ts +39 -0
- package/dist/types/orchestration/workflow/expression.d.ts +52 -0
- package/dist/types/orchestration/workflow/host-executors.d.ts +15 -0
- package/dist/types/orchestration/workflow/n8n-import.d.ts +35 -0
- package/dist/types/orchestration/workflow/node-registry.d.ts +19 -0
- package/dist/types/orchestration/workflow/node-schema.d.ts +119 -0
- package/dist/types/orchestration/workflow/run-checkpoint-store.d.ts +53 -0
- package/dist/types/orchestration/workflow/trigger-validation.d.ts +22 -0
- package/dist/types/orchestration/workflow/workflow-controller.d.ts +143 -0
- package/dist/types/orchestration/workflow/workflow-patch.d.ts +101 -0
- package/dist/types/orchestration/workflow/workflow-render.d.ts +41 -0
- package/dist/types/orchestration/workflow/workflow-runtime.d.ts +127 -0
- package/dist/types/orchestration/workflow/workflow-scheduler.d.ts +83 -0
- package/dist/types/orchestration/workflow/workflow-store.d.ts +40 -0
- package/dist/types/orchestration/workflow/workflow-trigger.d.ts +14 -0
- package/dist/types/permissions.d.ts +2 -0
- package/dist/types/permissions.public-api.test.d.ts +1 -0
- package/dist/types/protocol/methods.d.ts +262 -11
- package/dist/types/{runtime/infra/acp-types.d.ts → protocol/wire/acp-agent-management.d.ts} +3 -3
- package/dist/types/protocol/wire/agent-methods.d.ts +15 -11
- package/dist/types/protocol/wire/agent-rpc.d.ts +11 -0
- package/dist/types/protocol/wire/chat-types.d.ts +9 -0
- package/dist/types/protocol/wire/gateway-rpc.d.ts +13 -0
- package/dist/types/protocol/wire/index.d.ts +2 -1
- package/dist/types/protocol/wire/notification-payloads.d.ts +18 -3
- package/dist/types/runtime/community/community-consent-client.d.ts +117 -0
- package/dist/types/runtime/community/community-consent-client.test.d.ts +1 -0
- package/dist/types/runtime/community/community-desensitization-red-team-cli.d.ts +7 -0
- package/dist/types/runtime/community/community-desensitization-red-team-cli.test.d.ts +1 -0
- package/dist/types/runtime/community/community-desensitization.d.ts +29 -0
- package/dist/types/runtime/community/community-desensitization.test.d.ts +1 -0
- package/dist/types/runtime/community/community-telemetry-recorder.d.ts +6 -0
- package/dist/types/runtime/config/tunable-defaults.d.ts +249 -0
- package/dist/types/runtime/execution/dream-agent.d.ts +4 -2
- package/dist/types/runtime/execution/dream-category-context.d.ts +1 -1
- package/dist/types/runtime/execution/forked-agent.d.ts +3 -1
- package/dist/types/runtime/execution/streaming-tool-executor.d.ts +4 -2
- package/dist/types/runtime/execution/tool-eligibility.d.ts +1 -1
- package/dist/types/runtime/hooks/context-compression.d.ts +2 -2
- package/dist/types/runtime/hooks/memory-hooks.d.ts +6 -6
- package/dist/types/runtime/infra/acp-detector.d.ts +2 -2
- package/dist/types/runtime/infra/acp-protocol-adapter.d.ts +1 -1
- package/dist/types/runtime/infra/acp-usage-tracker.d.ts +1 -1
- package/dist/types/runtime/infra/agent-config-store.d.ts +2 -2
- package/dist/types/runtime/infra/agent-paths.d.ts +14 -10
- package/dist/types/runtime/infra/agent-paths.test.d.ts +1 -0
- package/dist/types/runtime/infra/agent-process.d.ts +2 -2
- package/dist/types/runtime/infra/checkpoint-backend.d.ts +2 -2
- package/dist/types/runtime/infra/index.d.ts +1 -1
- package/dist/types/runtime/infra/llmrouter-catalog.d.ts +10 -0
- package/dist/types/runtime/infra/mcp-bridge.d.ts +1 -1
- package/dist/types/runtime/infra/model-registry.d.ts +3 -0
- package/dist/types/runtime/infra/profile-storage.test.d.ts +1 -0
- package/dist/types/runtime/infra/skill-injector.d.ts +3 -2
- package/dist/types/runtime/infra/skill-injector.test.d.ts +1 -0
- package/dist/types/runtime/infra/task-runtime.d.ts +1 -1
- package/dist/types/runtime/infra/worktree-backend.d.ts +2 -2
- package/dist/types/runtime/memory/categories.d.ts +5 -0
- package/dist/types/runtime/memory/find-relevant-memories.d.ts +70 -0
- package/dist/types/runtime/memory/implicit-extraction.d.ts +58 -0
- package/dist/types/runtime/memory/recall-category-filter.d.ts +54 -0
- package/dist/types/runtime/pet/index.d.ts +1 -1
- package/dist/types/runtime/pet/pet-growth-engine.d.ts +10 -9
- package/dist/types/runtime/pet/pet-growth-engine.test.d.ts +1 -0
- package/dist/types/runtime/pet/pet-soul-service.d.ts +1 -2
- package/dist/types/runtime/pet/pet-soul-service.test.d.ts +1 -0
- package/dist/types/runtime/ports/agent-execution-contracts.d.ts +182 -0
- package/dist/types/runtime/ports/checkpoint-contracts.d.ts +19 -0
- package/dist/types/runtime/ports/index.d.ts +13 -0
- package/dist/types/runtime/ports/memory-provider.d.ts +146 -0
- package/dist/types/runtime/ports/memory-recall-source.d.ts +3 -0
- package/dist/types/runtime/ports/memory-writer.d.ts +21 -0
- package/dist/types/runtime/ports/path-service.d.ts +5 -0
- package/dist/types/runtime/ports/permission-contracts.d.ts +107 -0
- package/dist/types/runtime/ports/project-memory-store.d.ts +44 -0
- package/dist/types/runtime/ports/tool-call-contracts.d.ts +16 -0
- package/dist/types/runtime/ports/tool-contracts.d.ts +23 -0
- package/dist/types/runtime/ports/web-search-contracts.d.ts +17 -0
- package/dist/types/runtime/ports/worktree-contracts.d.ts +22 -0
- package/dist/types/runtime/prompt/environment-context.test.d.ts +1 -0
- package/dist/types/runtime/prompt/fresh-workspace-evidence.d.ts +19 -0
- package/dist/types/runtime/prompt/fresh-workspace-evidence.test.d.ts +1 -0
- package/dist/types/runtime/prompt/instruction-loader.d.ts +9 -3
- package/dist/types/runtime/prompt/instruction-loader.test.d.ts +1 -0
- package/dist/types/runtime/session/session-persistence.test.d.ts +1 -0
- package/dist/types/runtime/tasks/task-types.d.ts +146 -0
- package/dist/types/skills/index.d.ts +2 -2
- package/dist/types/skills/mcp/mcp-http-client.d.ts +2 -0
- package/dist/types/skills/mcp/mcp-manager.d.ts +7 -4
- package/dist/types/skills/mcp/mcp-stdio-client.d.ts +2 -0
- package/dist/types/skills/mcp/mcp-tool-metadata.d.ts +18 -0
- package/dist/types/skills/memory/categories.d.ts +1 -5
- package/dist/types/skills/memory/find-relevant-memories.d.ts +1 -70
- package/dist/types/skills/memory/implicit-extraction.d.ts +1 -58
- package/dist/types/skills/memory/local-memory-provider.d.ts +4 -10
- package/dist/types/skills/memory/local-store.d.ts +4 -4
- package/dist/types/skills/memory/memory-consolidation.d.ts +9 -1
- package/dist/types/skills/memory/memory-provider-factory.d.ts +2 -0
- package/dist/types/skills/memory/memory-tool.d.ts +4 -6
- package/dist/types/skills/memory/recall-category-filter.d.ts +1 -54
- package/dist/types/skills/permissions/community-sandbox-policy.d.ts +3 -0
- package/dist/types/skills/permissions/community-sandbox-red-team-cli.d.ts +7 -0
- package/dist/types/skills/permissions/community-sandbox-red-team.d.ts +30 -0
- package/dist/types/skills/permissions/hook-runner.d.ts +15 -2
- package/dist/types/skills/permissions/settings-watcher.d.ts +2 -0
- package/dist/types/skills/permissions/types.d.ts +2 -113
- package/dist/types/skills/portable-tool.d.ts +22 -0
- package/dist/types/skills/skill-system/skill-lifecycle.d.ts +5 -0
- package/dist/types/skills/skill-system/skill-source.d.ts +2 -148
- package/dist/types/skills/tool-access.d.ts +30 -0
- package/dist/types/skills/tools/skill-tool.d.ts +2 -10
- package/dist/types/skills/tools/web-search-tool.d.ts +3 -20
- package/dist/types/skills/tools.d.ts +1 -1
- package/dist/types/transport/acp-server.d.ts +1 -1
- package/dist/types/transport/index.d.ts +1 -0
- package/dist/types/transport/io-transport.d.ts +19 -0
- package/package.json +93 -80
- package/dist/types/llm/index.d.ts +0 -1
- /package/dist/types/{orchestration/context/context-compression.d.ts → runtime/context/context-compression-strategies.d.ts} +0 -0
|
@@ -2,12 +2,18 @@
|
|
|
2
2
|
* Media handlers — extracted from StdioServer.
|
|
3
3
|
* Handles: media.listModels, media.cancel, media.status, media.stt
|
|
4
4
|
*/
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
export
|
|
5
|
+
import { type MediaClient } from "../provider-core-facade.js";
|
|
6
|
+
import { type AgentRpcError, type AgentRpcRequest } from "../../protocol/wire/index.js";
|
|
7
|
+
export interface MediaHandlerHost {
|
|
8
|
+
mediaClient?: Pick<MediaClient, "getTransport" | "listMediaModels"> | null;
|
|
9
|
+
sendResponse(id: string | number, result?: unknown, error?: AgentRpcError): void;
|
|
10
|
+
}
|
|
11
|
+
export declare function handleMediaListModels(this: MediaHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
12
|
+
export declare function handleMediaCancel(this: MediaHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
13
|
+
export declare function handleMediaStatus(this: MediaHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
8
14
|
/**
|
|
9
15
|
* `media.stt` — Speech-to-text transcription.
|
|
10
16
|
* Accepts base64-encoded audio, calls the designated STT provider (zhipu GLM-ASR-2512).
|
|
11
17
|
* This is a non-session utility: no turn/session is created.
|
|
12
18
|
*/
|
|
13
|
-
export declare function handleMediaStt(this:
|
|
19
|
+
export declare function handleMediaStt(this: MediaHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -2,24 +2,51 @@
|
|
|
2
2
|
* Memory CRUD + search handlers — extracted from StdioServer.
|
|
3
3
|
* Handles: memory.list, memory.read, memory.write, memory.search, memory.delete
|
|
4
4
|
*/
|
|
5
|
-
|
|
5
|
+
import { type AgentRpcError, type AgentRpcRequest } from "../../protocol/wire/index.js";
|
|
6
|
+
import type { MemoryHandlerProvider, ProjectMemoryStore, ProjectMemoryStoreFactory } from "../../runtime/ports/index.js";
|
|
7
|
+
interface MemoryLlmClient {
|
|
8
|
+
model: string;
|
|
9
|
+
apiKey: string;
|
|
10
|
+
transport: {
|
|
11
|
+
stream(request: Record<string, unknown>, apiKey: string): AsyncIterable<{
|
|
12
|
+
type: string;
|
|
13
|
+
text?: string;
|
|
14
|
+
}>;
|
|
15
|
+
};
|
|
16
|
+
}
|
|
17
|
+
export interface MemoryHandlerHost {
|
|
18
|
+
memdir: ProjectMemoryStore | null;
|
|
19
|
+
memoryProvider?: MemoryHandlerProvider | null;
|
|
20
|
+
memoryUserId?: string;
|
|
21
|
+
projectMemoryStoreFactory: ProjectMemoryStoreFactory;
|
|
22
|
+
projectLocator?: {
|
|
23
|
+
resolveProjectRoot(projectId: string): string | undefined;
|
|
24
|
+
};
|
|
25
|
+
ensureMemoryProvider?(): void;
|
|
26
|
+
getActiveProjectRoot(): string;
|
|
27
|
+
resolveClientForPurpose?(purpose: "smallModel" | "textGeneration"): MemoryLlmClient | null;
|
|
28
|
+
sendNotification(method: string, params: Record<string, unknown>): void;
|
|
29
|
+
sendResponse(id: string | number, result?: unknown, error?: AgentRpcError): void;
|
|
30
|
+
}
|
|
31
|
+
export declare function handleMemoryList(this: MemoryHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
6
32
|
/** memory.list-files — Returns actual topic files from memdir. */
|
|
7
|
-
export declare function handleMemoryListFiles(this:
|
|
33
|
+
export declare function handleMemoryListFiles(this: MemoryHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
8
34
|
/**
|
|
9
35
|
* memory.atlas — Returns full L2 vector-memory records (wire-safe, no embedding
|
|
10
36
|
* blob) plus category roll-ups, for the 3D memory atlas visualization.
|
|
11
37
|
*/
|
|
12
|
-
export declare function handleMemoryAtlas(this:
|
|
38
|
+
export declare function handleMemoryAtlas(this: MemoryHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
13
39
|
/**
|
|
14
40
|
* memory.activity — Daily activity counts + highlights over the recent window,
|
|
15
41
|
* powering the atlas timeline ticks and the "memory digest" panel.
|
|
16
42
|
*/
|
|
17
|
-
export declare function handleMemoryActivity(this:
|
|
18
|
-
export declare function handleMemoryObserve(this:
|
|
19
|
-
export declare function handleMemoryPropose(this:
|
|
20
|
-
export declare function handleMemoryConsolidate(this:
|
|
21
|
-
export declare function handleMemoryRead(this:
|
|
22
|
-
export declare function handleMemoryWrite(this:
|
|
23
|
-
export declare function handleMemorySearch(this:
|
|
24
|
-
export declare function handleMemoryDelete(this:
|
|
25
|
-
export declare function handleMemoryUpdate(this:
|
|
43
|
+
export declare function handleMemoryActivity(this: MemoryHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
44
|
+
export declare function handleMemoryObserve(this: MemoryHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
45
|
+
export declare function handleMemoryPropose(this: MemoryHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
46
|
+
export declare function handleMemoryConsolidate(this: MemoryHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
47
|
+
export declare function handleMemoryRead(this: MemoryHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
48
|
+
export declare function handleMemoryWrite(this: MemoryHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
49
|
+
export declare function handleMemorySearch(this: MemoryHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
50
|
+
export declare function handleMemoryDelete(this: MemoryHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
51
|
+
export declare function handleMemoryUpdate(this: MemoryHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
52
|
+
export {};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { AgentRpcRequest } from "../../protocol/wire/index.js";
|
|
2
|
+
import type { PetConfirmCoordinator } from "../pet-confirm-coordinator.js";
|
|
3
|
+
export interface PetConfirmHandlerHost {
|
|
4
|
+
petConfirmCoordinator: PetConfirmCoordinator;
|
|
5
|
+
sendResponse(id: string | number, result?: unknown, error?: unknown): void;
|
|
6
|
+
}
|
|
7
|
+
export declare function handlePetConfirmResponse(this: PetConfirmHandlerHost, msg: AgentRpcRequest): void;
|
|
@@ -7,9 +7,33 @@
|
|
|
7
7
|
* - pet.status: Get current pet soul + stats
|
|
8
8
|
* - pet.forge: Generate a custom .pet file from image/text (P4)
|
|
9
9
|
*/
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
10
|
+
import { type AgentRpcError, type AgentRpcRequest } from "../../protocol/wire/index.js";
|
|
11
|
+
import type { PetRuntime } from "../pet-runtime.js";
|
|
12
|
+
interface PetMemoryActivitySummary {
|
|
13
|
+
highlights?: Array<{
|
|
14
|
+
text?: string;
|
|
15
|
+
}>;
|
|
16
|
+
}
|
|
17
|
+
interface PetMemoryProviderLike {
|
|
18
|
+
getActivitySummary(userId: string, days: number): PetMemoryActivitySummary | undefined;
|
|
19
|
+
}
|
|
20
|
+
interface PetSessionStateLike {
|
|
21
|
+
turnCount?: number;
|
|
22
|
+
}
|
|
23
|
+
export interface PetHandlerHost {
|
|
24
|
+
deviceId?: string;
|
|
25
|
+
sessionState?: PetSessionStateLike | null;
|
|
26
|
+
memoryProvider?: PetMemoryProviderLike | null;
|
|
27
|
+
memoryUserId?: string;
|
|
28
|
+
petRuntime: Pick<PetRuntime, "createPetSoulGenerator" | "createSmallLLMCall" | "forgeAnalyzeImage" | "forgeGenerateSkeleton">;
|
|
29
|
+
getActiveProjectRoot(): string;
|
|
30
|
+
sendNotification(method: string, params: Record<string, unknown>): void;
|
|
31
|
+
sendResponse(id: string | number, result?: unknown, error?: AgentRpcError): void;
|
|
32
|
+
ensureModelRegistryHydrated?(): Promise<void>;
|
|
33
|
+
}
|
|
34
|
+
export declare function handlePetHatch(this: PetHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
35
|
+
export declare function handlePetInteract(this: PetHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
36
|
+
export declare function handlePetStatus(this: PetHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
13
37
|
/**
|
|
14
38
|
* P4: Pet Forge — generate a custom .pet file from image/text description.
|
|
15
39
|
*
|
|
@@ -21,4 +45,5 @@ export declare function handlePetStatus(this: any, msg: any): Promise<void>;
|
|
|
21
45
|
* 5. Structural consistency check; retry skeleton if score too low
|
|
22
46
|
* 6. Package and emit pet.forged
|
|
23
47
|
*/
|
|
24
|
-
export declare function handlePetForge(this:
|
|
48
|
+
export declare function handlePetForge(this: PetHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
49
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -2,31 +2,57 @@
|
|
|
2
2
|
* Product mode handlers — extracted from StdioServer.
|
|
3
3
|
* Handles: product.plan/confirm/message/create/resume/pause/checkpoint/status/list/delete/cancel/rollback
|
|
4
4
|
*/
|
|
5
|
+
import { AgentProcessManager } from "../../runtime/infra/agent-process.js";
|
|
6
|
+
import type { AgentConfigStore } from "../../runtime/infra/agent-config-store.js";
|
|
7
|
+
import type { AcpDetector } from "../../runtime/infra/acp-detector.js";
|
|
5
8
|
import { ProductOrchestrator } from "../../orchestration/agent-instance.js";
|
|
6
9
|
import { ProductPlanner } from "../../orchestration/product-planner.js";
|
|
7
|
-
|
|
10
|
+
import { type AgentRpcError, type AgentRpcRequest } from "../../protocol/wire/index.js";
|
|
11
|
+
export interface ProductCoordinatorHost {
|
|
12
|
+
acpDetector: AcpDetector;
|
|
13
|
+
agentConfigStore: AgentConfigStore | null;
|
|
14
|
+
productOrchestrator: ProductOrchestrator | null;
|
|
15
|
+
productPlanner: ProductPlanner | null;
|
|
16
|
+
productProcessManager: AgentProcessManager | null;
|
|
17
|
+
emitAgentStatus(agentId: string, state: string, extra?: {
|
|
18
|
+
missedBeats?: number;
|
|
19
|
+
lastActivityAt?: number;
|
|
20
|
+
usage?: {
|
|
21
|
+
inputTokens: number;
|
|
22
|
+
outputTokens: number;
|
|
23
|
+
totalTokens: number;
|
|
24
|
+
};
|
|
25
|
+
}): void;
|
|
26
|
+
getActiveProjectRoot(): string;
|
|
27
|
+
handleMcpToolCall(memberId: string, tool: string, args: Record<string, unknown>): Promise<unknown>;
|
|
28
|
+
sendNotification(method: string, params: Record<string, unknown>): void;
|
|
29
|
+
}
|
|
30
|
+
export interface ProductHandlerHost extends ProductCoordinatorHost {
|
|
31
|
+
sendResponse(id: string | number, result?: unknown, error?: AgentRpcError): void;
|
|
32
|
+
}
|
|
33
|
+
export declare function ensureProductOrchestrator(this: ProductCoordinatorHost): ProductOrchestrator;
|
|
8
34
|
/** Ensure ProductPlanner is initialized. */
|
|
9
|
-
export declare function ensureProductPlanner(this:
|
|
35
|
+
export declare function ensureProductPlanner(this: ProductCoordinatorHost): ProductPlanner;
|
|
10
36
|
/** `product.plan` — Start interactive planning with leader agent. */
|
|
11
|
-
export declare function handleProductPlan(this:
|
|
37
|
+
export declare function handleProductPlan(this: ProductHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
12
38
|
/** `product.confirm` — User confirms the plan, transition to execution. */
|
|
13
|
-
export declare function handleProductConfirm(this:
|
|
39
|
+
export declare function handleProductConfirm(this: ProductHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
14
40
|
/** `product.message` — User sends message to leader (multi-turn planning or execution intervention). */
|
|
15
|
-
export declare function handleProductMessage(this:
|
|
41
|
+
export declare function handleProductMessage(this: ProductHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
16
42
|
/** `product.create` — Create a new Product Mode session. */
|
|
17
|
-
export declare function handleProductCreate(this:
|
|
43
|
+
export declare function handleProductCreate(this: ProductHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
18
44
|
/** `product.resume` — Resume a paused product. */
|
|
19
|
-
export declare function handleProductResume(this:
|
|
45
|
+
export declare function handleProductResume(this: ProductHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
20
46
|
/** `product.pause` — Pause a running product. */
|
|
21
|
-
export declare function handleProductPause(this:
|
|
47
|
+
export declare function handleProductPause(this: ProductHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
22
48
|
/** `product.checkpoint` — Manual checkpoint. */
|
|
23
|
-
export declare function handleProductCheckpoint(this:
|
|
49
|
+
export declare function handleProductCheckpoint(this: ProductHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
24
50
|
/** `product.status` — Query product status. */
|
|
25
|
-
export declare function handleProductStatus(this:
|
|
51
|
+
export declare function handleProductStatus(this: ProductHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
26
52
|
/** `product.list` — List all products. */
|
|
27
|
-
export declare function handleProductList(this:
|
|
28
|
-
export declare function handleProductDelete(this:
|
|
53
|
+
export declare function handleProductList(this: ProductHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
54
|
+
export declare function handleProductDelete(this: ProductHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
29
55
|
/** `product.cancel` — Cancel a running product. */
|
|
30
|
-
export declare function handleProductCancel(this:
|
|
56
|
+
export declare function handleProductCancel(this: ProductHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
31
57
|
/** `product.rollback` — Rollback a product to a checkpoint. */
|
|
32
|
-
export declare function handleProductRollback(this:
|
|
58
|
+
export declare function handleProductRollback(this: ProductHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
@@ -3,17 +3,26 @@
|
|
|
3
3
|
* Handles: project.create, project.list, project.delete, project.rename,
|
|
4
4
|
* project.archive, project.unarchive, project.archiveByGroup
|
|
5
5
|
*/
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
6
|
+
import { type AgentRpcError, type AgentRpcRequest } from "../../protocol/wire/index.js";
|
|
7
|
+
import type { ProjectMemoryStore, ProjectMemoryStoreFactory } from "../../runtime/ports/index.js";
|
|
8
|
+
export interface ProjectHandlerHost {
|
|
9
|
+
memdir: ProjectMemoryStore | null;
|
|
10
|
+
projectMemoryStoreFactory: ProjectMemoryStoreFactory;
|
|
11
|
+
mediaPersistence: {
|
|
12
|
+
setProjectDir(projectDir: string): void;
|
|
13
|
+
releaseProjectDir?(projectDir: string): void;
|
|
14
|
+
};
|
|
15
|
+
getActiveProjectRoot(): string;
|
|
16
|
+
setActiveWorkdir(dir: string): void;
|
|
17
|
+
sendNotification(method: string, params: Record<string, unknown>): void;
|
|
18
|
+
sendResponse(id: string | number, result?: unknown, error?: AgentRpcError): void;
|
|
19
|
+
}
|
|
20
|
+
export declare function handleProjectCreate(this: ProjectHandlerHost, msg: AgentRpcRequest): void;
|
|
21
|
+
export declare function handleProjectList(this: ProjectHandlerHost, msg: AgentRpcRequest): void;
|
|
22
|
+
export declare function handleProjectDelete(this: ProjectHandlerHost, msg: AgentRpcRequest): void;
|
|
23
|
+
export declare function handleProjectPurgeAll(this: ProjectHandlerHost, msg: AgentRpcRequest): void;
|
|
24
|
+
export declare function handleProjectRename(this: ProjectHandlerHost, msg: AgentRpcRequest): void;
|
|
25
|
+
export declare function handleProjectArchive(this: ProjectHandlerHost, msg: AgentRpcRequest): void;
|
|
26
|
+
export declare function handleProjectUnarchive(this: ProjectHandlerHost, msg: AgentRpcRequest): void;
|
|
27
|
+
export declare function handleProjectArchiveByGroup(this: ProjectHandlerHost, msg: AgentRpcRequest): void;
|
|
28
|
+
export declare function handleProjectUpdate(this: ProjectHandlerHost, msg: AgentRpcRequest): void;
|
|
@@ -10,29 +10,48 @@
|
|
|
10
10
|
* never via the global `currentProjectRoot`. Sessions are immutably bound
|
|
11
11
|
* to a project at creation time.
|
|
12
12
|
*/
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
export
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
13
|
+
import { SessionState } from "../../runtime/session/session-state.js";
|
|
14
|
+
import { createMemoryPrefetchState } from "../../runtime/hooks/memory-hooks.js";
|
|
15
|
+
import { type AgentRpcError, type AgentRpcErrorCode, type AgentRpcRequest } from "../../protocol/wire/index.js";
|
|
16
|
+
import type { SessionHistoryCoordinator } from "../session-history-coordinator.js";
|
|
17
|
+
export interface SessionHandlerHost {
|
|
18
|
+
currentSessionId?: string;
|
|
19
|
+
currentModel?: string;
|
|
20
|
+
sessionState?: SessionState | null;
|
|
21
|
+
sessionTaskDomain?: unknown;
|
|
22
|
+
memoryPrefetchState?: ReturnType<typeof createMemoryPrefetchState>;
|
|
23
|
+
sessionHistory: Pick<SessionHistoryCoordinator, "saveResumedSession">;
|
|
24
|
+
log(message: string): void;
|
|
25
|
+
setActiveWorkdir(workdir: string): void;
|
|
26
|
+
getActiveProjectRoot(): string;
|
|
27
|
+
enableIdleDream(): void;
|
|
28
|
+
sendNotification(method: string, params: Record<string, unknown>): void;
|
|
29
|
+
sendResponse(id: string | number, result?: unknown, error?: AgentRpcError): void;
|
|
30
|
+
sendError(id: string | number, code: AgentRpcErrorCode | number, message: string, data?: unknown): void;
|
|
31
|
+
}
|
|
32
|
+
export declare function handleThreadCreate(this: SessionHandlerHost, msg: AgentRpcRequest): void;
|
|
33
|
+
export declare function handleThreadList(this: SessionHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
34
|
+
export declare function handleSessionCreate(this: SessionHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
35
|
+
export declare function handleSessionResolve(this: SessionHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
36
|
+
export declare function handleSessionList(this: SessionHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
37
|
+
export declare function handleSessionGet(this: SessionHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
38
|
+
export declare function handleSessionGetMessages(this: SessionHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
39
|
+
export declare function handleSessionUpdate(this: SessionHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
40
|
+
export declare function handleSessionDelete(this: SessionHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
41
|
+
export declare function handleSessionDeleteAll(this: SessionHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
42
|
+
export declare function handleSessionArchive(this: SessionHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
43
|
+
export declare function handleSessionResume(this: SessionHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
44
|
+
export declare function handleSessionGetInfo(this: SessionHandlerHost, msg: AgentRpcRequest): void;
|
|
45
|
+
export declare function handleSessionSwitchProject(this: SessionHandlerHost, msg: AgentRpcRequest): void;
|
|
46
|
+
export declare function handleSessionGetState(this: SessionHandlerHost, msg: AgentRpcRequest): void;
|
|
28
47
|
/**
|
|
29
48
|
* `session.focus` — Desktop UI reports which session is currently focused.
|
|
30
49
|
* Agent switches active project/cwd to the session's owning project.
|
|
31
50
|
*/
|
|
32
|
-
export declare function handleSessionFocus(this:
|
|
51
|
+
export declare function handleSessionFocus(this: SessionHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
33
52
|
/**
|
|
34
53
|
* `session.moveToProject` — Move a session from one project to another.
|
|
35
54
|
* Physically copies session files, updates metadata.projectId, then removes the source.
|
|
36
55
|
* Emits session:updated notification.
|
|
37
56
|
*/
|
|
38
|
-
export declare function handleSessionMoveToProject(this:
|
|
57
|
+
export declare function handleSessionMoveToProject(this: SessionHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -1,12 +1,16 @@
|
|
|
1
|
-
import type
|
|
2
|
-
export
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
export declare function
|
|
7
|
-
export declare function
|
|
8
|
-
export declare function
|
|
9
|
-
export declare function
|
|
10
|
-
export declare function
|
|
11
|
-
export declare function
|
|
12
|
-
export declare function
|
|
1
|
+
import { type AgentRpcError, type AgentRpcRequest } from "../../protocol/wire/index.js";
|
|
2
|
+
export interface SettingsHandlerHost {
|
|
3
|
+
sendError?(id: string | number, code: number, message: string): void;
|
|
4
|
+
sendResponse(id: string | number, result?: unknown, error?: AgentRpcError): void;
|
|
5
|
+
}
|
|
6
|
+
export declare function handleSettingsListProviders(this: SettingsHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
7
|
+
export declare function handleSettingsAddKey(this: SettingsHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
8
|
+
export declare function handleSettingsRemoveKey(this: SettingsHandlerHost, msg: AgentRpcRequest): void;
|
|
9
|
+
export declare function handleSettingsToggleKey(this: SettingsHandlerHost, msg: AgentRpcRequest): void;
|
|
10
|
+
export declare function handleSettingsToggleModel(this: SettingsHandlerHost, msg: AgentRpcRequest): void;
|
|
11
|
+
export declare function handleSettingsListModels(this: SettingsHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
12
|
+
export declare function handleSettingsSetActiveModel(this: SettingsHandlerHost, msg: AgentRpcRequest): void;
|
|
13
|
+
export declare function handleSettingsGetActiveModel(this: SettingsHandlerHost, msg: AgentRpcRequest): void;
|
|
14
|
+
export declare function handleSettingsGetOverview(this: SettingsHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
15
|
+
export declare function handleSettingsRefreshModels(this: SettingsHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
16
|
+
export declare function handleSettingsValidateKey(this: SettingsHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
@@ -4,17 +4,26 @@
|
|
|
4
4
|
* skills.promote, skills.stats, skills.pin, skills.unpin,
|
|
5
5
|
* skills.curator, skills.lifecycle
|
|
6
6
|
*/
|
|
7
|
+
import { type AgentRpcError, type AgentRpcRequest } from "../../protocol/wire/index.js";
|
|
8
|
+
export interface SkillsHandlerHost {
|
|
9
|
+
projectLocator?: {
|
|
10
|
+
resolveProjectRoot(projectId: string): string | undefined;
|
|
11
|
+
};
|
|
12
|
+
getActiveProjectRoot(): string;
|
|
13
|
+
sendNotification(method: string, params: Record<string, unknown>): void;
|
|
14
|
+
sendResponse(id: string | number, result?: unknown, error?: AgentRpcError): void;
|
|
15
|
+
}
|
|
7
16
|
export declare function extractSkillMeta(skillMdPath: string): {
|
|
8
17
|
version?: string;
|
|
9
18
|
description?: string;
|
|
10
19
|
};
|
|
11
|
-
export declare function handleSkillsList(this:
|
|
12
|
-
export declare function handleSkillsActivate(this:
|
|
13
|
-
export declare function handleSkillsDeactivate(this:
|
|
14
|
-
export declare function handleSkillsDelete(this:
|
|
15
|
-
export declare function handleSkillsPromote(this:
|
|
16
|
-
export declare function handleSkillsStats(this:
|
|
17
|
-
export declare function handleSkillsPin(this:
|
|
18
|
-
export declare function handleSkillsUnpin(this:
|
|
19
|
-
export declare function handleSkillsCurator(this:
|
|
20
|
-
export declare function handleSkillsLifecycle(this:
|
|
20
|
+
export declare function handleSkillsList(this: SkillsHandlerHost, msg: AgentRpcRequest): void;
|
|
21
|
+
export declare function handleSkillsActivate(this: SkillsHandlerHost, msg: AgentRpcRequest): void;
|
|
22
|
+
export declare function handleSkillsDeactivate(this: SkillsHandlerHost, msg: AgentRpcRequest): void;
|
|
23
|
+
export declare function handleSkillsDelete(this: SkillsHandlerHost, msg: AgentRpcRequest): void;
|
|
24
|
+
export declare function handleSkillsPromote(this: SkillsHandlerHost, msg: AgentRpcRequest): void;
|
|
25
|
+
export declare function handleSkillsStats(this: SkillsHandlerHost, msg: AgentRpcRequest): void;
|
|
26
|
+
export declare function handleSkillsPin(this: SkillsHandlerHost, msg: AgentRpcRequest): void;
|
|
27
|
+
export declare function handleSkillsUnpin(this: SkillsHandlerHost, msg: AgentRpcRequest): void;
|
|
28
|
+
export declare function handleSkillsCurator(this: SkillsHandlerHost, msg: AgentRpcRequest): void;
|
|
29
|
+
export declare function handleSkillsLifecycle(this: SkillsHandlerHost, msg: AgentRpcRequest): void;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -3,13 +3,35 @@
|
|
|
3
3
|
* Handles: solo.start, solo.status, solo.cancel, solo.select,
|
|
4
4
|
* solo.list, solo.delete, solo.message, solo.evaluate
|
|
5
5
|
*/
|
|
6
|
+
import { AgentProcessManager } from "../../runtime/infra/agent-process.js";
|
|
7
|
+
import type { AcpDetector } from "../../runtime/infra/acp-detector.js";
|
|
8
|
+
import type { AgentConfigStore } from "../../runtime/infra/agent-config-store.js";
|
|
6
9
|
import { SoloEvaluator } from "../../orchestration/solo-evaluator.js";
|
|
7
|
-
|
|
8
|
-
export
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
10
|
+
import { type AgentRpcError, type AgentRpcRequest } from "../../protocol/wire/index.js";
|
|
11
|
+
export interface SoloHandlerHost {
|
|
12
|
+
soloEvaluator: SoloEvaluator | null;
|
|
13
|
+
soloProcessManager: AgentProcessManager | null;
|
|
14
|
+
acpDetector: AcpDetector;
|
|
15
|
+
agentConfigStore: AgentConfigStore | null;
|
|
16
|
+
sendNotification(method: string, params: Record<string, unknown>): void;
|
|
17
|
+
sendResponse(id: string | number, result?: unknown, error?: AgentRpcError): void;
|
|
18
|
+
emitAgentStatus(agentId: string, state: string, extra?: {
|
|
19
|
+
missedBeats?: number;
|
|
20
|
+
lastActivityAt?: number;
|
|
21
|
+
usage?: {
|
|
22
|
+
inputTokens: number;
|
|
23
|
+
outputTokens: number;
|
|
24
|
+
totalTokens: number;
|
|
25
|
+
};
|
|
26
|
+
}): void;
|
|
27
|
+
handleMcpToolCall(memberId: string, toolName: string, args: Record<string, unknown>): Promise<unknown>;
|
|
28
|
+
}
|
|
29
|
+
export declare function ensureSoloEvaluator(this: SoloHandlerHost): SoloEvaluator;
|
|
30
|
+
export declare function handleSoloStart(this: SoloHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
31
|
+
export declare function handleSoloStatus(this: SoloHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
32
|
+
export declare function handleSoloCancel(this: SoloHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
33
|
+
export declare function handleSoloSelect(this: SoloHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
34
|
+
export declare function handleSoloList(this: SoloHandlerHost, msg: AgentRpcRequest): void;
|
|
35
|
+
export declare function handleSoloDelete(this: SoloHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
36
|
+
export declare function handleSoloMessage(this: SoloHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
37
|
+
export declare function handleSoloEvaluate(this: SoloHandlerHost, msg: AgentRpcRequest): Promise<void>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -2,16 +2,22 @@
|
|
|
2
2
|
* Turn execution handlers — extracted from StdioServer.
|
|
3
3
|
* Handles: thread.turn, agent.abort, tool.approval.response, thread.user_response
|
|
4
4
|
*/
|
|
5
|
-
import type {
|
|
5
|
+
import type { PermissionMetadataResolver } from "../../runtime/ports/index.js";
|
|
6
|
+
import type { ToolDefinition } from "../../agent/types.js";
|
|
6
7
|
import type { AgentRpcRequest } from "../../protocol/wire/agent-rpc.js";
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
export
|
|
8
|
+
interface PendingAskUserRequest {
|
|
9
|
+
resolve(answers: Record<string, string> | null): void;
|
|
10
|
+
}
|
|
11
|
+
export interface TurnControlHandlerHost {
|
|
12
|
+
activeTurn: AbortController | null;
|
|
13
|
+
permissionChecker?: PermissionMetadataResolver | null;
|
|
14
|
+
pendingAskUser: Map<string, PendingAskUserRequest>;
|
|
15
|
+
log(message: string): void;
|
|
16
|
+
sendResponse(id: string | number, result?: unknown, error?: unknown): void;
|
|
17
|
+
}
|
|
18
|
+
export declare function handleAbort(this: TurnControlHandlerHost, msg: AgentRpcRequest): void;
|
|
19
|
+
export declare function handleApprovalResponse(this: TurnControlHandlerHost, msg: AgentRpcRequest): void;
|
|
20
|
+
export declare function refreshPermissionCheckerToolMeta(permissionChecker: PermissionMetadataResolver | null | undefined, tools: ToolDefinition[]): void;
|
|
21
|
+
export declare function handleUserResponse(this: TurnControlHandlerHost, msg: AgentRpcRequest): void;
|
|
11
22
|
export declare function handleTurn(this: any, msg: AgentRpcRequest): Promise<void>;
|
|
12
|
-
export
|
|
13
|
-
/**
|
|
14
|
-
* Generate follow-up suggestions after a turn completes.
|
|
15
|
-
* Fire-and-forget — failures are silently logged. Non-blocking.
|
|
16
|
-
*/
|
|
17
|
-
export declare function generateSuggestions(this: any, turnId: string, messages: ChatMessage[], transport: LLMTransport, apiKey: string, model: string): Promise<void>;
|
|
23
|
+
export {};
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import { type DreamState } from "../agent/runtime-vars.js";
|
|
2
|
+
import type { AgentRpcRequest } from "../protocol/wire/index.js";
|
|
3
|
+
type TimerHandle = {
|
|
4
|
+
unref?: () => void;
|
|
5
|
+
};
|
|
6
|
+
export interface IdleDreamTimers {
|
|
7
|
+
setTimeout(callback: () => void, delayMs: number): TimerHandle;
|
|
8
|
+
clearTimeout(timerId: TimerHandle): void;
|
|
9
|
+
}
|
|
10
|
+
export interface IdleDreamClient {
|
|
11
|
+
model: string;
|
|
12
|
+
apiKey: string;
|
|
13
|
+
}
|
|
14
|
+
export interface IdleDreamCoordinatorOptions {
|
|
15
|
+
dreamState?: DreamState;
|
|
16
|
+
now?: () => number;
|
|
17
|
+
randomId?: () => string;
|
|
18
|
+
timers?: IdleDreamTimers;
|
|
19
|
+
log(message: string): void;
|
|
20
|
+
sendNotification(method: string, params: Record<string, unknown>): void;
|
|
21
|
+
getCurrentSessionId(): string;
|
|
22
|
+
getCurrentTurnCount(): number;
|
|
23
|
+
getActiveTurn(): AbortController | null;
|
|
24
|
+
resolveDreamClient(): IdleDreamClient | null;
|
|
25
|
+
getAgentHome(): string;
|
|
26
|
+
listRecentSessions(): Promise<Array<{
|
|
27
|
+
sessionId: string;
|
|
28
|
+
}>>;
|
|
29
|
+
runDream(message: AgentRpcRequest): Promise<void>;
|
|
30
|
+
}
|
|
31
|
+
export declare class IdleDreamCoordinator {
|
|
32
|
+
private readonly options;
|
|
33
|
+
private readonly dreamState;
|
|
34
|
+
private readonly now;
|
|
35
|
+
private readonly randomId;
|
|
36
|
+
private readonly timers;
|
|
37
|
+
private idleTimer;
|
|
38
|
+
constructor(options: IdleDreamCoordinatorOptions);
|
|
39
|
+
applyEnvOverrides(env: Record<string, string | undefined>): void;
|
|
40
|
+
enable(minutes?: number): void;
|
|
41
|
+
handleTurnNotification(method: string): void;
|
|
42
|
+
cancelTimer(): void;
|
|
43
|
+
resetTimer(): void;
|
|
44
|
+
triggerIdleDream(): Promise<void>;
|
|
45
|
+
}
|
|
46
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { McpManager } from "../skills/mcp/mcp-manager.js";
|
|
2
|
+
import { PluginLoader } from "../skills/plugins/plugin-loader.js";
|
|
3
|
+
import type { HookRegistry } from "../contracts/hooks.js";
|
|
4
|
+
import type { RuntimeLogger } from "../runtime/hooks/hook-registry.js";
|
|
5
|
+
import type { ToolCatalog } from "../runtime/ports/index.js";
|
|
6
|
+
export interface McpBootstrapDeps {
|
|
7
|
+
config: Record<string, unknown>;
|
|
8
|
+
projectRoot: string;
|
|
9
|
+
log: RuntimeLogger;
|
|
10
|
+
toolCatalog: ToolCatalog;
|
|
11
|
+
currentManager: McpManager | null;
|
|
12
|
+
setManager(manager: McpManager | null): void;
|
|
13
|
+
setReady(ready: Promise<void>): void;
|
|
14
|
+
}
|
|
15
|
+
export declare function configureMcpBootstrap(deps: McpBootstrapDeps): void;
|
|
16
|
+
export declare function buildMcpBootstrapEntries(params: {
|
|
17
|
+
turnMcpConfig?: unknown;
|
|
18
|
+
userMcpConfig?: unknown;
|
|
19
|
+
projectRoot: string;
|
|
20
|
+
}): import("../skills/mcp/mcp-manager.js").McpServerEntry[];
|
|
21
|
+
export interface PluginBootstrapDeps {
|
|
22
|
+
config: Record<string, unknown>;
|
|
23
|
+
hooks: HookRegistry;
|
|
24
|
+
log: RuntimeLogger;
|
|
25
|
+
setPluginLoader(loader: PluginLoader): void;
|
|
26
|
+
}
|
|
27
|
+
export declare function configurePluginBootstrap(deps: PluginBootstrapDeps): void;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|