/** * Semantic Kernel Adapter * * Integrates Microsoft Semantic Kernel agents and functions with the * SwarmOrchestrator. Semantic Kernel is Microsoft's enterprise SDK for * building AI-powered apps with plugins, planners, and memory. * * Usage: * const adapter = new SemanticKernelAdapter(); * adapter.registerKernel("planner", myKernel); * adapter.registerFunction("summarise", mySKFunction); * await registry.addAdapter(adapter); * * Then in the orchestrator: * delegateTask({ targetAgent: "semantic-kernel:planner", ... }) * * @module SemanticKernelAdapter * @version 1.0.0 */ import { BaseAdapter } from './base-adapter'; import type { AdapterCapabilities, AgentPayload, AgentContext, AgentResult } from '../types/agent-adapter'; /** Matches SK's Kernel interface */ export interface SKKernel { /** Invoke a function within the kernel */ invokeFunction?(functionName: string, args?: Record): Promise; /** Invoke a prompt directly */ invokePrompt?(prompt: string, args?: Record): Promise; /** Run a planner */ runPlan?(goal: string, options?: Record): Promise; } /** Matches SK's KernelFunction */ export interface SKFunction { /** Function name */ name: string; /** Invoke the function */ invoke(args?: Record): Promise; } /** Matches SK's FunctionResult */ export interface SKFunctionResult { value?: unknown; toString?(): string; metadata?: Record; } /** Planner result */ export interface SKPlanResult { result?: string; steps?: Array<{ plugin: string; function: string; result?: string; }>; error?: string; } export declare class SemanticKernelAdapter extends BaseAdapter { readonly name = "semantic-kernel"; readonly version = "1.0.0"; private entries; get capabilities(): AdapterCapabilities; registerKernel(agentId: string, kernel: SKKernel, metadata?: { description?: string; capabilities?: string[]; }): void; registerFunction(agentId: string, fn: SKFunction, metadata?: { description?: string; capabilities?: string[]; }): void; executeAgent(agentId: string, payload: AgentPayload, context: AgentContext): Promise; private executeSKFunction; private executeKernel; private buildArgs; private normalizeResult; } //# sourceMappingURL=semantic-kernel-adapter.d.ts.map