// behaviors/knob-embeddings.ts
var cache = null;
async function loadManifest() {
  if (cache) return cache;
  try {
    const { readFileSync } = await import('fs');
    const { resolve, dirname } = await import('path');
    const { fileURLToPath } = await import('url');
    const dir = dirname(fileURLToPath(import.meta.url));
    const raw = readFileSync(resolve(dir, "knob-embeddings.json"), "utf-8");
    const parsed = JSON.parse(raw);
    if (typeof parsed?.model !== "string" || typeof parsed?.dimensions !== "number" || typeof parsed?.vectors !== "object" || parsed.vectors === null) {
      return null;
    }
    cache = parsed;
    return cache;
  } catch {
    return null;
  }
}
async function getKnobEmbeddings() {
  return loadManifest();
}

export { getKnobEmbeddings };
//# sourceMappingURL=knob-embeddings.js.map
//# sourceMappingURL=knob-embeddings.js.map