Open-source platform for 3D AI agents. Turn text or a photo into a rigged, animated GLB avatar, give it an LLM brain, memory and a wallet, and embed it anywhere with one web component. Remote MCP server, x402 payments, Three.js, browser-native.
JavaScript 3d-generationai-agentsanimationavatardigital-humangenerative-aiglbgltfimage-to-3dllmmcpmcp-servermodel-context-protocolsolanatext-to-3dthreejsweb-componentswebglwebxrx402
export function resolveDetailPreviewSource(fallback: string) {
const absolute = /^https?:\/\//i.test(fallback);
const url = new URL(fallback, "https://threeui.local");
const filename = url.pathname.split("/").pop();
if (!filename || !/\.(?:mp4|webm)$/i.test(filename)) return fallback;
const previewIndex = url.pathname.lastIndexOf("/previews/");
if (previewIndex < 0) return fallback;
url.pathname = `${url.pathname.slice(0, previewIndex)}/previews/detail/${filename.replace(/\.(?:mp4|webm)$/i, ".webm")}`;
return absolute ? url.href : `${url.pathname}${url.search}${url.hash}`;
}