/**
 * RuntimeAdapter — provider-routing interface.
 *
 * Used by the provider routing layer (src/providers/) to select candidate
 * runtimes, check health, and dispatch AgentRunRequests.
 *
 * It is stricter than AgentRuntime: runNode operates on AgentRunRequest,
 * and health()/supports()/runNode() are all mandatory.
 *
 * For the internal runtime implementation interface, see
 * src/runtime/agent-runtime.ts (AgentRuntime).
 */
export function isRuntimeId(value) {
    return typeof value === "string" && value.length > 0;
}
export function isRuntimeAdapter(value) {
    if (typeof value !== "object" || value === null)
        return false;
    const r = value;
    return (typeof r.id === "string" &&
        typeof r.displayName === "string" &&
        typeof r.priority === "number" &&
        typeof r.capabilities === "object" &&
        r.capabilities !== null &&
        typeof r.health === "function" &&
        typeof r.supports === "function" &&
        typeof r.runNode === "function");
}
