openclaw
Version:
Multi-channel AI gateway with extensible messaging integrations
26 lines (25 loc) • 1.25 kB
JavaScript
import { t as _usingCtx } from "../usingCtx-rhpPzaNq.mjs";
import { d as resolveOwningPluginIdsForProvider, i as resolveCatalogHookProviderPluginIds } from "../providers-B9AkUbSZ.mjs";
import { r as resolvePluginProvidersCore, t as isPluginProvidersLoadInFlight } from "../providers.runtime-6wA04_U8.mjs";
import { N as augmentModelCatalogWithProviderPlugins } from "../provider-runtime-BddjXkmv.mjs";
import { t as createLegacyPluginSdkProviderProjection } from "../legacy-sdk-provider-projection-Bn9tJIHe.mjs";
//#region src/plugin-sdk/provider-catalog-runtime.ts
/** Bare provider callbacks retain borrowed resources until their SDK host closes. */
function resolvePluginProvidersForSdk(e) {
try {
var t = _usingCtx();
const n = t.u(createLegacyPluginSdkProviderProjection());
const r = resolvePluginProvidersCore(e, (e) => {
const t = n.select(e);
return t ? (e, n) => Object.assign({}, t(e, n), { pluginId: n }) : void 0;
});
n.adopt();
return r;
} catch (e) {
t.e = e;
} finally {
t.d();
}
}
//#endregion
export { augmentModelCatalogWithProviderPlugins, isPluginProvidersLoadInFlight, resolveCatalogHookProviderPluginIds, resolveOwningPluginIdsForProvider, resolvePluginProvidersForSdk as resolvePluginProviders };