try {
  const engineUrl = globalThis.__teWolfEngineUrl;
  if (typeof engineUrl !== "string") throw new Error("missing engine URL");
  const imported = await import(engineUrl);
  globalThis.__teWolfFactory = imported.default;
  globalThis.dispatchEvent(new Event("te-wolf-runtime-ready"));
} catch (_) {
  globalThis.__teWolfFactoryFailed = true;
  globalThis.dispatchEvent(new Event("te-wolf-runtime-ready"));
}
