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
ChatGPT pipeline: show the painted concept image, add tiers, unpin the router
nirholasb7c400878e99
diff --git a/CHANGELOG.md b/CHANGELOG.mdindex 22345e218..2cea57b7c 100644--- a/CHANGELOG.md+++ b/CHANGELOG.md@@ -27,6 +27,7 @@ Public history for [three.ws](https://three.ws), newest first. New pages come fr- **Motion Swap: replace yourself in a video with your 3D avatar** — Upload a video of yourself (a house tour, a demo, a walk-through) at /motion-swap and get it back with your avatar performing your exact motion instead of you. The platform tracks your body pose in every frame, masks you out, and pins your chosen avatar over you, matching your position and size; you stay pixelated underneath. Compositing and video export run right in your browser, and any rigged humanoid GLB works, including avatars you generated or captured from a selfie. (`/motion-swap`) `[feature]`- **Switch any coin chart between CoinGecko, TradingView, DexScreener, and GeckoTerminal** — The chart on every /coin page now has a source switcher. Start on the fast native CoinGecko line chart, then flip to TradingView's advanced candlesticks, or to the DexScreener or GeckoTerminal on-chain terminal for the token's live DEX pair. Each option only appears when it can actually chart that coin, your pick is remembered across coins and visits, and every view follows the site theme. (`/coin/bitcoin`) `[feature, improvement]`- **The assistant widget ships as an npm package and an MCP server** — The 3D avatar assistant widget is now installable three ways. Beyond the one-tag script, there is an npm package, @three-ws/assistant, for bundler projects (the one-tag build is generated from it, so they never drift), and a free MCP server, @three-ws/assistant-mcp, published to the official Model Context Protocol registry as io.github.nirholas/assistant-widget. Any AI agent (Claude Code, Cursor, Claude Desktop) can now ask for a widget in plain language and get back a paste-ready embed: build_assistant_widget turns a config into a script tag, a frame URL, and a ThreeAssistant.init() call, and list_assistant_options returns every avatar, background, and mode. Full developer docs at /docs/assistant-widget and a step-by-step tutorial walk through every option, the JavaScript API, and the agent workflow. (`/docs/assistant-widget`) `[sdk, feature, docs]`+- **The ChatGPT studio now shows its work, and goes up to High** — Making a 3D model in ChatGPT now feels like the Forge. The generator paints a concept image before sculpting the mesh, and ChatGPT now shows that painted view the moment it exists, while the 3D model is still generating: in the inline widget it appears instantly as the model loads behind it. You can also ask for quality now: draft for speed, standard by default, or high for maximum detail on our own GPUs (it takes a few minutes and is worth it). Under the hood, ChatGPT requests ride the same smart engine routing as the Forge page instead of a single pinned engine, so an unhealthy lane never blocks your model. (`/docs/chatgpt-ar`) `[feature, improvement]`- **The sniper fleet becomes a live experiment: rules vs AI judgment** — The autonomous pump.fun sniper now runs ten labeled strategies side by side to learn which entry conditions actually make money. Some agents trade strict rule shields (market-cap bands, socials, Oracle conviction), and three new agents have no rules at all: an AI model (Grok, Claude, or an auto-router) reads every launch and decides with a written thesis, while the same hard safety rails (no Mayhem tokens, honeypot firewall, budgets and stop-losses) protect every trade. A new scoreboard at /sniper/experiments compares each arm by real on-chain results. Under the hood the sniper also got three reliability fixes that unblocked buying: safety reads now rotate across many RPC providers with retries, provisional Oracle scores on brand-new coins no longer disqualify launch snipes, and a stuck position whose sell had already landed on-chain is now reconciled from the chain instead of retrying forever. (`/sniper/experiments`) `[feature, improvement, fix]`- **TradingView charts on every coin page** — Every /coin page (like /coin/bitcoin) now has a chart-source toggle. Keep the fast native line chart, or switch to a full advanced candlestick chart with indicators and drawing tools. Listed coins open on TradingView; Solana DEX tokens that TradingView doesn't carry open on DexScreener instead, so the advanced view works on every coin. Your choice is remembered across coins and visits, and the chart follows the site theme. (`/coin/bitcoin`) `[feature]`diff --git a/api/3d/studio.js b/api/3d/studio.jsindex b97c5adb7..3178e1e58 100644--- a/api/3d/studio.js+++ b/api/3d/studio.js@@ -9,22 +9,26 @@// age-13+ content-safety gate before any GPU work starts.//// It is a thin shaper, not a second pipeline: generation runs through the-// gpt-forge-client → /api/gpt-forge free lane (the ChatGPT-dedicated clone of-// /api/forge — NVIDIA NIM TRELLIS, standard tier) and draws from the SAME-// per-IP quota buckets as /api/3d/generate, so adding this surface creates no-// new capacity and no new limiter. (High tier waits on the async self-host-// Hunyuan3D worker — see the dispatch comment below.)+// gpt-forge-client → /api/gpt-forge free-first router (the ChatGPT-dedicated+// clone of /api/forge) with no pinned backend, and draws from the SAME per-IP+// quota buckets as /api/3d/generate, so adding this surface creates no new+// capacity and no new limiter. High tier rides the async self-host lanes+// operator-funded (internal seed) through the pending/poll contract.//-// POST { prompt }-// → 200 { status:'done', glbUrl, viewerUrl, arUrl, format } (finished inline)-// → 200 { status:'pending', job, poll, format } (queued — poll below)+// POST { prompt, tier? } (tier: draft | standard (default) | high)+// → 200 { status:'done', glbUrl, viewerUrl, arUrl, format, previewImageUrl?, tier? }+// → 200 { status:'pending', job, poll, format, previewImageUrl?, tier?, etaSeconds? }// → 400 { error:'prompt_rejected', message } (safety gate refusal)//// GET ?job=<id>&title=<prompt> (title optional — labels the AR/viewer pages)-// → 200 { status:'pending', job, poll } (still generating)-// → 200 { status:'done', glbUrl, viewerUrl, arUrl, format } (GLB ready)+// → 200 { status:'pending', job, poll, previewImageUrl?, tier? }+// → 200 { status:'done', glbUrl, viewerUrl, arUrl, format, previewImageUrl?, tier? }// → 200 { status:'error', error } (upstream failed — retry is free)//+// previewImageUrl is the forge's painted concept view — the image-generation+// first step of the text path — surfaced on pending states so the GPT can show+// the user what is being sculpted while the mesh is still generating.+//// arUrl is the flagship link: the device-aware AR launch (api/ar.js) that puts// the model in the user's real room — Scene Viewer on Android, Quick Look on// iOS (GLB→USDZ converted in-page), WebGL viewer on desktop. It is the same@@ -51,11 +55,27 @@ const MAX_BODY_BYTES = 8_000;// /api/gpt-forge does the authoritative validation, this just keeps junk off the wire.const JOB_HANDLE_RE = /^[A-Za-z0-9._-]{8,1024}$/;+// The painted reference view of the model — the forge's first, image-generation+// step. Surfaced on every state (pending included) so the GPT can show the+// concept image the moment it exists, while the mesh is still generating —+// the same paint-then-reconstruct experience the /forge page gives.+function previewOf(payload) {+ const u = payload?.preview_image_url;+ return typeof u === 'string' && /^https:\/\//.test(u) ? u : null;+}++function tierOf(payload) {+ const t = payload?.tier;+ return t === 'draft' || t === 'standard' || t === 'high' ? t : null;+}+// Shape a forge submit response into the Actions contract: model URLs and job// state only. Pure + exported so tests pin the boundary against real captured// forge shapes without any network.export function shapeSubmit(job, base, prompt) {const glbUrl = typeof job?.glb_url === 'string' ? job.glb_url : '';+ const preview = previewOf(job);+ const tier = tierOf(job);if (job?.status === 'done' && glbUrl) {return {status: 'done',@@ -63,23 +83,31 @@ export function shapeSubmit(job, base, prompt) {viewerUrl: viewerUrl(base, glbUrl),arUrl: arLaunchUrl(base, glbUrl, prompt),format: 'glb',+ ...(preview ? { previewImageUrl: preview } : {}),+ ...(tier ? { tier } : {}),};}const handle = job?.job_id ?? null;// The poll URL carries the prompt as `title` so the eventual done response// can label the AR/viewer pages without the GPT having to resend anything.const t = typeof prompt === 'string' && prompt.trim() ? `&title=${encodeURIComponent(prompt.trim().slice(0, 80))}` : '';+ const eta = Number(job?.eta_seconds);return {status: 'pending',job: handle,poll: handle ? `/api/3d/studio?job=${encodeURIComponent(handle)}${t}` : null,format: 'glb',+ ...(preview ? { previewImageUrl: preview } : {}),+ ...(tier ? { tier } : {}),+ ...(Number.isFinite(eta) && eta > 0 ? { etaSeconds: Math.round(eta) } : {}),};}// Shape a forge poll response into { status:'pending'|'done'|'error', ... }.export function shapePoll(data, base, jobId, title) {const glbUrl = typeof data?.glb_url === 'string' ? data.glb_url : '';+ const preview = previewOf(data);+ const tier = tierOf(data);if (data?.status === 'done' && glbUrl) {return {status: 'done',@@ -88,6 +116,8 @@ export function shapePoll(data, base, jobId, title) {viewerUrl: viewerUrl(base, glbUrl),arUrl: arLaunchUrl(base, glbUrl, title),format: 'glb',+ ...(preview ? { previewImageUrl: preview } : {}),+ ...(tier ? { tier } : {}),};}if (data?.status === 'failed') {@@ -102,7 +132,13 @@ export function shapePoll(data, base, jobId, title) {// queued / running / anything transient → still pending; keep the title on the// poll URL so it survives to the done response.const t = typeof title === 'string' && title.trim() ? `&title=${encodeURIComponent(title.trim().slice(0, 80))}` : '';- return { status: 'pending', job: jobId, poll: `/api/3d/studio?job=${encodeURIComponent(jobId)}${t}` };+ return {+ status: 'pending',+ job: jobId,+ poll: `/api/3d/studio?job=${encodeURIComponent(jobId)}${t}`,+ ...(preview ? { previewImageUrl: preview } : {}),+ ...(tier ? { tier } : {}),+ };}// Map a startForge lane failure to an honest boundary response. A well-formed@@ -163,6 +199,18 @@ async function generate(req, res) {});}+ // Optional quality tier. High runs operator-funded (internal seed) on the+ // async self-host lanes and simply takes longer through the pending/poll+ // contract — no payment surface exists on this endpoint.+ const rawTier = body?.tier === undefined ? 'standard' : body.tier;+ const tier = rawTier === 'draft' || rawTier === 'standard' || rawTier === 'high' ? rawTier : null;+ if (!tier) {+ return json(res, 400, {+ error: 'invalid_tier',+ message: '"tier" must be "draft", "standard", or "high" (default "standard").',+ });+ }+// Age-13+ content gate BEFORE any quota spend or GPU work. The category// message is the user-facing refusal the GPT relays verbatim.const safety = checkPromptSafety(prompt);@@ -186,20 +234,19 @@ async function generate(req, res) {const subject = knownMark ? knownMark.prompt : prompt;let job;try {- // Pinned to the fast free lane: ChatGPT Actions abandon the HTTP call at- // ~45s, and the only high-tier free engine currently deployed (Hunyuan3D- // via HF Spaces) BLOCKS the submit for 50-280s with no poll handle, so a- // high request here can never answer in time. To raise quality later:- // deploy the async self-host Hunyuan3D worker (workers/model-hunyuan3d,- // forge lane already wired behind GCP_HUNYUAN3D_URL), then request tier- // 'high' with internal: true — startForge degrades to standard on- // 402/timeout. A known mark with a reference view goes image→3D unpinned- // (image jobs return a poll handle, which the Actions contract handles).+ // No pinned backend: the health-aware free-first router picks the best+ // healthy lane for the prompt exactly as the /forge page does (the fast+ // NIM lane is its own named default for standard text, so the happy path+ // is unchanged). Slow/async lanes return a poll handle, which the+ // pending/poll contract absorbs — ChatGPT Actions' ~45s deadline only+ // bounds the submit, never the generation. High rides the async+ // self-host lanes with the internal seed; startForge degrades a high+ // submit to standard on 402/timeout rather than dead-ending.job = await startForge(base,knownMark?.imagePath- ? { prompt: subject, imageUrls: [`${base}${knownMark.imagePath}`], tier: 'standard' }- : { prompt: subject, backend: 'nvidia', path: 'image', tier: 'standard' },+ ? { prompt: subject, imageUrls: [`${base}${knownMark.imagePath}`], tier }+ : { prompt: subject, path: 'image', tier, ...(tier === 'high' ? { internal: true } : {}) },);} catch (err) {return failFromLane(res, err);diff --git a/api/_mcp-studio/component.js b/api/_mcp-studio/component.jsindex 546a7a100..f0ee0559e 100644--- a/api/_mcp-studio/component.js+++ b/api/_mcp-studio/component.js@@ -243,6 +243,11 @@ export const COMPONENT_HTML = `<!doctype html>show(loading);mv.classList.remove('fading');mv.classList.add('veiled');+ // The forge paints a concept image before sculpting the mesh — use it as+ // the model-viewer poster so the user sees the painted reference the+ // instant the widget renders, while the GLB is still streaming in.+ if (isHttps(out.referenceImageUrl)) { mv.setAttribute('poster', out.referenceImageUrl); }+ else { mv.removeAttribute('poster'); }mv.setAttribute('src', glb);armWatchdog();diff --git a/api/_mcp-studio/tools.js b/api/_mcp-studio/tools.jsindex 5ba5b9252..2367f2066 100644--- a/api/_mcp-studio/tools.js+++ b/api/_mcp-studio/tools.js@@ -59,7 +59,7 @@ function firstPartyGlbUrl(glbUrl, base) {// Minimal, identifier-free success envelope. structuredContent is the contract// the widget + model read; content is the human/agent-readable narration.-function ok({ glbUrl, base, kind, prompt, rigged }) {+function ok({ glbUrl, base, kind, prompt, rigged, referenceImageUrl }) {glbUrl = firstPartyGlbUrl(glbUrl, base);// An avatar (rigged or humanoid) is an agent's body, not a prop: it also gets// the IRL living handoff: walk it, talk to it, camera AR in the real room.@@ -67,6 +67,13 @@ function ok({ glbUrl, base, kind, prompt, rigged }) {const vUrl = viewerUrl(base, glbUrl);const aUrl = arLaunchUrl(base, glbUrl, prompt, { live });const iUrl = live ? irlUrl(base, glbUrl) : '';+ // The painted concept view the generator sculpted from — the forge's+ // image-generation first step. https-only; the widget uses it as the+ // model-viewer poster so something visual shows while the GLB streams in.+ const refImg =+ typeof referenceImageUrl === 'string' && /^https:\/\//.test(referenceImageUrl)+ ? firstPartyGlbUrl(referenceImageUrl, base)+ : '';const structured = {kind,glbUrl,@@ -76,6 +83,7 @@ function ok({ glbUrl, base, kind, prompt, rigged }) {...(prompt ? { prompt } : {}),...(rigged ? { rigged: true } : {}),...(iUrl ? { irlUrl: iUrl } : {}),+ ...(refImg ? { referenceImageUrl: refImg } : {}),// Spatial MCP artifact — the open, coin-clean shape for a 3D-native tool// result (specs/SPATIAL_MCP.md). Additive to the fields the widget already// reads, so any Spatial-MCP renderer can display this model, not just ours.@@ -89,6 +97,7 @@ function ok({ glbUrl, base, kind, prompt, rigged }) {}),};const label = rigged ? 'rigged 3D model' : '3D model';+ const refLine = refImg ? `\nConcept image it was sculpted from: ${refImg}` : '';return {content: [{@@ -96,9 +105,11 @@ function ok({ glbUrl, base, kind, prompt, rigged }) {text: iUrl? `Generated a ${label} (GLB). View it: ${structured.viewerUrl}\n` +`Bring it to life in your real room (it moves and talks through the camera, open on a phone): ${iUrl}\n` +- `Place a static copy in AR: ${aUrl}\nDownload: ${glbUrl}`+ `Place a static copy in AR: ${aUrl}\nDownload: ${glbUrl}` ++ refLine: `Generated a ${label} (GLB). View it: ${structured.viewerUrl}\n` +- `Place it in your room (AR, open on a phone): ${aUrl}\nDownload: ${glbUrl}`,+ `Place it in your room (AR, open on a phone): ${aUrl}\nDownload: ${glbUrl}` ++ refLine,},],structuredContent: structured,@@ -223,7 +234,7 @@ async function handleForgeFree(args, _auth, req) {return toolError(failureMessage(err));}if (job._timedOut || !job.glb_url) return toolError('Generation is taking longer than expected. Please try again.');- return ok({ glbUrl: job.glb_url, base, kind: 'model', prompt });+ return ok({ glbUrl: job.glb_url, base, kind: 'model', prompt, referenceImageUrl: job.preview_image_url });}async function handleTextToAvatar(args, _auth, req) {@@ -251,7 +262,7 @@ async function handleTextToAvatar(args, _auth, req) {return toolError(failureMessage(err));}if (job._timedOut || !job.glb_url) return toolError('Generation is taking longer than expected. Please try again.');- return ok({ glbUrl: job.glb_url, base, kind: 'avatar', prompt: prompt || undefined });+ return ok({ glbUrl: job.glb_url, base, kind: 'avatar', prompt: prompt || undefined, referenceImageUrl: job.preview_image_url });}async function handleMeshForge(args, _auth, req) {@@ -302,7 +313,7 @@ async function handleMeshForge(args, _auth, req) {return toolError(failureMessage(err));}if (job._timedOut || !job.glb_url) return toolError('Generation is taking longer than expected. Please try again.');- return ok({ glbUrl: job.glb_url, base, kind: 'mesh', prompt: prompt || undefined });+ return ok({ glbUrl: job.glb_url, base, kind: 'mesh', prompt: prompt || undefined, referenceImageUrl: job.preview_image_url });}async function handleRigMesh(args, _auth, req) {@@ -385,7 +396,7 @@ async function handleForgeAvatar(args, _auth, req) {};}if (rigged._timedOut || !rigged.glb_url) return toolError('Rigging is taking longer than expected. Please try again.');- return ok({ glbUrl: rigged.glb_url, base, kind: 'avatar', prompt: prompt || undefined, rigged: true });+ return ok({ glbUrl: rigged.glb_url, base, kind: 'avatar', prompt: prompt || undefined, rigged: true, referenceImageUrl: gen.preview_image_url });}// Conversational refinement — carry a prior model forward with a natural-languagediff --git a/api/gpt-forge.js b/api/gpt-forge.jsindex 7e9f8d629..92020ac6f 100644--- a/api/gpt-forge.js+++ b/api/gpt-forge.js@@ -2731,6 +2731,14 @@ async function pollJob(req, res, jobId) {backend: meta.backend ?? null,tier: meta.tier ?? null,path: meta.path ?? null,+ // ChatGPT-pipeline divergence from api/forge.js: polls surface the+ // painted reference view (and the model that painted it) so the+ // ChatGPT surfaces can show the concept image while the mesh is+ // still generating — the submit response already carries these,+ // but ChatGPT's Actions poll loop only ever sees poll responses.+ prompt: meta.prompt ?? null,+ preview_image_url: meta.preview_image_url ?? null,+ text_to_image_model: meta.text_to_image_model ?? null,}: {};diff --git a/data/changelog.json b/data/changelog.jsonindex f3cb89b61..96c6d956b 100644--- a/data/changelog.json+++ b/data/changelog.json@@ -14915,6 +14915,16 @@"fix"],"link": "/sniper/experiments"+ },+ {+ "date": "2026-07-19",+ "title": "The ChatGPT studio now shows its work, and goes up to High",+ "summary": "Making a 3D model in ChatGPT now feels like the Forge. The generator paints a concept image before sculpting the mesh, and ChatGPT now shows that painted view the moment it exists, while the 3D model is still generating: in the inline widget it appears instantly as the model loads behind it. You can also ask for quality now: draft for speed, standard by default, or high for maximum detail on our own GPUs (it takes a few minutes and is worth it). Under the hood, ChatGPT requests ride the same smart engine routing as the Forge page instead of a single pinned engine, so an unhealthy lane never blocks your model.",+ "tags": [+ "feature",+ "improvement"+ ],+ "link": "/docs/chatgpt-ar"}]}diff --git a/docs/chatgpt-ar.md b/docs/chatgpt-ar.mdindex 5ecc3fa2f..ba6257156 100644--- a/docs/chatgpt-ar.md+++ b/docs/chatgpt-ar.md@@ -63,7 +63,8 @@ Submit returns either the finished model or a job to poll:Design decisions on this endpoint, all deliberate:-- **Store-clean responses.** The payload carries model URLs and job state only: no pricing, no upgrade hints, no internal identifiers, no wallet or token surface. That is what makes it publishable as a GPT Store action. (The agent-facing twin, `POST /api/3d/generate`, returns the same core fields plus `tier`/`free`/`upgrade`; see [the free 3D API](./3d-api.md).)+- **Store-clean responses.** The payload carries model URLs and job state only: no pricing, no upgrade hints, no internal identifiers, no wallet or token surface. That is what makes it publishable as a GPT Store action. (The agent-facing twin, `POST /api/3d/generate`, returns the same core fields plus `free`/`upgrade`; see [the free 3D API](./3d-api.md).)+- **The full forge experience.** The request accepts an optional `tier` (`draft` | `standard` | `high`; High runs the deepest sampler and texture budget on the self-host GPU lanes, operator-funded, and simply takes minutes through the poll loop). Routing is the same health-aware free-first router the /forge page uses, with no pinned backend. And because the forge paints a concept image before sculpting the mesh, pending and done states carry `previewImageUrl`, so ChatGPT shows the painted view the moment it exists while the 3D model is still generating.- **The title-carrying poll.** ChatGPT Actions never resend context, so the submit response embeds the prompt in the poll URL as `&title=`. When the poll finally returns `done`, the `arUrl` and `viewerUrl` are labeled with the original prompt without the GPT doing anything except calling the poll path verbatim.- **Timeout honesty.** Actions calls time out around 45 seconds; generation takes 20 to 60. The endpoint holds the request as long as it safely can and falls back to `pending` + poll rather than dying mid-request.- **Safety before GPU.** Every prompt passes an age-13+ appropriateness gate ([api/_mcp-studio/safety.js](../api/_mcp-studio/safety.js)) before any provider work; refusals return `400 prompt_rejected` with a clear message.diff --git a/docs/forge-pipeline.md b/docs/forge-pipeline.mdindex 2dc760562..4da6ec597 100644--- a/docs/forge-pipeline.md+++ b/docs/forge-pipeline.md@@ -59,7 +59,7 @@ Three properties define the design:| Flagship free API | `POST /api/v1/ai/text-to-3d` (`api/v1/ai/text-to-3d.js`) | NVIDIA NIM TRELLIS draft lane, 10 generations per IP per day, 429 + x402 upsell above quota. || Refinement | `POST /api/forge-iterate` (`api/forge-iterate.js`) | Conversational refinement with version lineage for the signed-in Studio. || MCP (paid stdio) | `mesh_forge`, `forge_avatar`, `forge_free`, `text_to_avatar`, `rig_mesh`, `refine_model`, `restyle_material` (`mcp-server/src/tools/`) | Shared cores in `mcp-server/src/tools/_studio-core.js`; thin clients over `/api/forge`. |-| ChatGPT clone | `POST /api/gpt-forge` (`api/gpt-forge.js`) | Exact clone of the orchestrator dedicated to the ChatGPT surfaces (the Apps SDK MCP connector `api/mcp-studio` and the custom-GPT Actions endpoint `api/3d/studio`, via `api/_mcp-studio/gpt-forge-client.js`), so the ChatGPT pipeline can evolve without touching `/api/forge`. Same lanes, tiers, job tokens, and `forge_creations` rows. |+| ChatGPT clone | `POST /api/gpt-forge` (`api/gpt-forge.js`) | Clone of the orchestrator dedicated to the ChatGPT surfaces (the Apps SDK MCP connector `api/mcp-studio` and the custom-GPT Actions endpoint `api/3d/studio`, via `api/_mcp-studio/gpt-forge-client.js`), so the ChatGPT pipeline can evolve without touching `/api/forge`. Same lanes, tiers, job tokens, and `forge_creations` rows. First divergence: its poll responses also carry `prompt`, `preview_image_url` (the painted concept view), and `text_to_image_model`, so the ChatGPT surfaces can show the concept image while the mesh generates. || MCP (hosted HTTP) | `text_to_3d`, `image_to_3d`, `auto_rig_model` (`api/mcp-3d.js`, tools in `api/_mcp3d/tools/studio.js`) | Streamable HTTP server registered as `io.github.nirholas/three-ws-3d-studio`. || DCC plugins | `integrations/blender/`, `integrations/comfyui/`, `integrations/_pyclient/` | First-party clients driving the same API. |diff --git a/docs/mcp-studio.md b/docs/mcp-studio.mdindex 0c7d163b0..9fbefa25c 100644--- a/docs/mcp-studio.md+++ b/docs/mcp-studio.md@@ -91,10 +91,16 @@ needs to display the model — no internal identifiers:"viewerUrl": "https://three.ws/viewer?src=…","arUrl": "https://three.ws/api/ar?src=…&title=…","format": "glb",- "prompt": "a friendly round robot mascot, glossy white plastic"+ "prompt": "a friendly round robot mascot, glossy white plastic",+ "referenceImageUrl": "https://three.ws/cdn/creations/…/model-ref.png"}```+`referenceImageUrl` is the concept image the generator paints first and then+sculpts into 3D (the forge's image-generation step). The inline widget uses it+as the model-viewer poster so the painted view shows while the GLB streams in,+and the result narration links it for non-widget clients.+`arUrl` is the one-tap place-in-your-room link (see [AR in ChatGPT](./chatgpt-ar.md)).Rigged avatars additionally carry `irlUrl`, the living-agent handoff into[IRL](./irl.md), and the inline widget's AR button becomes **Bring it to life**.diff --git a/prompts/store-submissions/_generated/openai-actions.yaml b/prompts/store-submissions/_generated/openai-actions.yamlindex bb2e2e73f..b41af8940 100644--- a/prompts/store-submissions/_generated/openai-actions.yaml+++ b/prompts/store-submissions/_generated/openai-actions.yaml@@ -16,7 +16,11 @@ info:Contract: POST /api/3d/studio either finishes inline (status "done" withglbUrl + viewerUrl + arUrl) or returns status "pending" with a "job"handle. Poll GET /api/3d/studio?job=... every few seconds until status is- "done" or "error". Generation typically takes 20-60 seconds. arUrl is the+ "done" or "error". Generation typically takes 20-60 seconds at the default+ tier; tier "high" produces far more detail and can take several minutes,+ so keep polling patiently. Responses may carry previewImageUrl - the+ concept image the generator paints first and then sculpts into 3D; show+ it to the user while the model is still generating. arUrl is theaugmented-reality launch link: opened on a phone it places the model inthe user's real room (Quick Look on iPhone, Scene Viewer on Android);always offer it alongside the viewer link.@@ -39,10 +43,13 @@ paths:summary: Generate a 3D model (GLB) from a text promptdescription: >-Start a free text-to-3D generation. Describe ONE subject concretely- (shape, colors, style). Returns status "done" with glbUrl (download),+ (shape, colors, style). Optionally pick a tier: "draft" (fastest),+ "standard" (default), or "high" (maximum detail, slower - expect+ minutes, not seconds). Returns status "done" with glbUrl (download),viewerUrl (preview), and arUrl (see it in your room in AR), or- "pending" with a "job" handle for checkModelJob. Unsafe prompts return- error "prompt_rejected".+ "pending" with a "job" handle for checkModelJob plus, once available,+ previewImageUrl - the painted concept image to show the user while+ the 3D model finishes. Unsafe prompts return error "prompt_rejected".requestBody:required: truecontent:@@ -59,6 +66,13 @@ paths:description: >-A concrete description of one subject to model, e.g."a small ceramic robot figurine with round eyes".+ tier:+ type: string+ enum: [draft, standard, high]+ description: >-+ Quality tier. draft = fastest, low detail; standard+ (default) = balanced; high = maximum geometric and+ texture detail, takes several minutes - keep polling.examples:fox:summary: Low-poly animal@@ -120,9 +134,10 @@ paths:description: >-Poll a generation started by generate3DModel. Use the "poll" path fromthe pending response verbatim (it carries the job handle and title).- Keep polling every few seconds while "pending"; stop on "done"- (present glbUrl + viewerUrl + arUrl) or "error" (offer to retry -- generation is free).+ Keep polling every few seconds while "pending"; when a pending state+ carries previewImageUrl, show that concept image to the user while+ they wait. Stop on "done" (present glbUrl + viewerUrl + arUrl) or+ "error" (offer to retry - generation is free).parameters:- name: jobin: query@@ -209,6 +224,22 @@ components:type: stringconst: glbdescription: Output format - always GLB (binary glTF).+ previewImageUrl:+ type: string+ format: uri+ description: >-+ The concept image the generator paints first and then sculpts+ into 3D. Present on pending and done states once painted - show+ it to the user while the model is still generating.+ tier:+ type: string+ enum: [draft, standard, high]+ description: The quality tier this generation is running at.+ etaSeconds:+ type: integer+ description: >-+ Rough estimate of remaining generation time in seconds (pending+ states only).job:type: stringdescription: Job handle to pass to checkModelJob (present when pending).diff --git a/prompts/store-submissions/_generated/openai-gpt-config.md b/prompts/store-submissions/_generated/openai-gpt-config.mdindex 0a5fd5194..5d7465aad 100644--- a/prompts/store-submissions/_generated/openai-gpt-config.md+++ b/prompts/store-submissions/_generated/openai-gpt-config.md@@ -59,6 +59,10 @@ WHAT YOU DOsitting down", "a small ceramic robot figurine with round eyes". Keep it toone subject. The generator models a single object best, not whole scenes.- If the user already gives plenty of detail, pass it through largely as-is.+- Quality tiers: generate3DModel accepts an optional "tier". Use "standard"+ (the default) unless the user asks: "draft" when they want something fast or+ low-poly, "high" when they ask for maximum detail, realism, or final+ quality. Warn that "high" takes several minutes, then poll patiently.- If the user asks for several objects or a whole scene, say you will build itpiece by piece, then generate the objects one at a time. If the list islonger than three items, confirm which ones they want first.@@ -74,6 +78,9 @@ HANDLING THE RESPONSE1. See it in your space (AR): the "arUrl" value.2. Preview in your browser: the "viewerUrl" value.3. Download (GLB): the "glbUrl" value.+ If the response carries "previewImageUrl" and you have not shown it yet,+ include it as a markdown image above the links - it is the painted concept+ view the model was sculpted from.Tell them the AR link, opened on a phone, places the model in their realroom (iPhone and Android both work; on a computer it shows the 3D viewerinstead). Say they can open the viewer link to spin the model in 3D, and@@ -81,9 +88,15 @@ HANDLING THE RESPONSE- status "pending": generation is still running. Call checkModelJob with the"job" value plus the "title" query parameter embedded in the returned"poll" path (using that path verbatim is easiest - the title labels the AR- page), and keep polling while the status stays "pending". On the first pending response, tell the user it usually takes- 20-60 seconds. If it is still pending after about 10 polls, stop polling,- say it is taking longer than usual, and offer to keep checking.+ page), and keep polling while the status stays "pending". When a pending+ response carries "previewImageUrl", show that image to the user right away+ as a markdown image - it is the concept view the generator painted first+ and is now sculpting into 3D. On the first pending response, tell the user+ it usually takes 20-60 seconds (several minutes on tier "high"; the+ "etaSeconds" value, when present, is a fair estimate to relay). If it is+ still pending after about 10 polls at the default tier (about 25 on+ "high"), stop polling, say it is taking longer than usual, and offer to+ keep checking.Never claim the model is finished until a response has status "done" witha glbUrl.- Never invent, guess, or fabricate a glbUrl, viewerUrl, or arUrl. Only everdiff --git a/public/.well-known/3d-studio-openapi.yaml b/public/.well-known/3d-studio-openapi.yamlindex bb2e2e73f..b41af8940 100644--- a/public/.well-known/3d-studio-openapi.yaml+++ b/public/.well-known/3d-studio-openapi.yaml@@ -16,7 +16,11 @@ info:Contract: POST /api/3d/studio either finishes inline (status "done" withglbUrl + viewerUrl + arUrl) or returns status "pending" with a "job"handle. Poll GET /api/3d/studio?job=... every few seconds until status is- "done" or "error". Generation typically takes 20-60 seconds. arUrl is the+ "done" or "error". Generation typically takes 20-60 seconds at the default+ tier; tier "high" produces far more detail and can take several minutes,+ so keep polling patiently. Responses may carry previewImageUrl - the+ concept image the generator paints first and then sculpts into 3D; show+ it to the user while the model is still generating. arUrl is theaugmented-reality launch link: opened on a phone it places the model inthe user's real room (Quick Look on iPhone, Scene Viewer on Android);always offer it alongside the viewer link.@@ -39,10 +43,13 @@ paths:summary: Generate a 3D model (GLB) from a text promptdescription: >-Start a free text-to-3D generation. Describe ONE subject concretely- (shape, colors, style). Returns status "done" with glbUrl (download),+ (shape, colors, style). Optionally pick a tier: "draft" (fastest),+ "standard" (default), or "high" (maximum detail, slower - expect+ minutes, not seconds). Returns status "done" with glbUrl (download),viewerUrl (preview), and arUrl (see it in your room in AR), or- "pending" with a "job" handle for checkModelJob. Unsafe prompts return- error "prompt_rejected".+ "pending" with a "job" handle for checkModelJob plus, once available,+ previewImageUrl - the painted concept image to show the user while+ the 3D model finishes. Unsafe prompts return error "prompt_rejected".requestBody:required: truecontent:@@ -59,6 +66,13 @@ paths:description: >-A concrete description of one subject to model, e.g."a small ceramic robot figurine with round eyes".+ tier:+ type: string+ enum: [draft, standard, high]+ description: >-+ Quality tier. draft = fastest, low detail; standard+ (default) = balanced; high = maximum geometric and+ texture detail, takes several minutes - keep polling.examples:fox:summary: Low-poly animal@@ -120,9 +134,10 @@ paths:description: >-Poll a generation started by generate3DModel. Use the "poll" path fromthe pending response verbatim (it carries the job handle and title).- Keep polling every few seconds while "pending"; stop on "done"- (present glbUrl + viewerUrl + arUrl) or "error" (offer to retry -- generation is free).+ Keep polling every few seconds while "pending"; when a pending state+ carries previewImageUrl, show that concept image to the user while+ they wait. Stop on "done" (present glbUrl + viewerUrl + arUrl) or+ "error" (offer to retry - generation is free).parameters:- name: jobin: query@@ -209,6 +224,22 @@ components:type: stringconst: glbdescription: Output format - always GLB (binary glTF).+ previewImageUrl:+ type: string+ format: uri+ description: >-+ The concept image the generator paints first and then sculpts+ into 3D. Present on pending and done states once painted - show+ it to the user while the model is still generating.+ tier:+ type: string+ enum: [draft, standard, high]+ description: The quality tier this generation is running at.+ etaSeconds:+ type: integer+ description: >-+ Rough estimate of remaining generation time in seconds (pending+ states only).job:type: stringdescription: Job handle to pass to checkModelJob (present when pending).diff --git a/public/changelog.json b/public/changelog.jsonindex d54b93b69..57ca01b25 100644--- a/public/changelog.json+++ b/public/changelog.json@@ -1,5 +1,5 @@{- "generated_at": "2026-07-19T14:45:53.567Z",+ "generated_at": "2026-07-19T15:04:56.972Z","generated_by": "scripts/build-page-index.mjs from data/pages.json + data/changelog.json","site": {"name": "three.ws",@@ -229,6 +229,17 @@"docs"]},+ {+ "date": "2026-07-19",+ "type": "update",+ "title": "The ChatGPT studio now shows its work, and goes up to High",+ "summary": "Making a 3D model in ChatGPT now feels like the Forge. The generator paints a concept image before sculpting the mesh, and ChatGPT now shows that painted view the moment it exists, while the 3D model is still generating: in the inline widget it appears instantly as the model loads behind it. You can also ask for quality now: draft for speed, standard by default, or high for maximum detail on our own GPUs (it takes a few minutes and is worth it). Under the hood, ChatGPT requests ride the same smart engine routing as the Forge page instead of a single pinned engine, so an unhealthy lane never blocks your model.",+ "link": "/docs/chatgpt-ar",+ "tags": [+ "feature",+ "improvement"+ ]+ },{"date": "2026-07-19","type": "update",diff --git a/public/changelog.xml b/public/changelog.xmlindex 610835261..00d152050 100644--- a/public/changelog.xml+++ b/public/changelog.xml@@ -174,6 +174,14 @@<category>sdk</category><description>The 3D avatar assistant widget is now installable three ways. Beyond the one-tag script, there is an npm package, @three-ws/assistant, for bundler projects (the one-tag build is generated from it, so they never drift), and a free MCP server, @three-ws/assistant-mcp, published to the official Model Context Protocol registry as io.github.nirholas/assistant-widget. Any AI agent (Claude Code, Cursor, Claude Desktop) can now ask for a widget in plain language and get back a paste-ready embed: build_assistant_widget turns a config into a script tag, a frame URL, and a ThreeAssistant.init() call, and list_assistant_options returns every avatar, background, and mode. Full developer docs at /docs/assistant-widget and a step-by-step tutorial walk through every option, the JavaScript API, and the agent workflow.</description></item>+ <item>+ <title>The ChatGPT studio now shows its work, and goes up to High</title>+ <link>https://three.ws/docs/chatgpt-ar</link>+ <guid isPermaLink="false">2026-07-19:The ChatGPT studio now shows its work, and goes up to High</guid>+ <pubDate>Sun, 19 Jul 2026 12:00:00 GMT</pubDate>+ <category>feature</category>+ <description>Making a 3D model in ChatGPT now feels like the Forge. The generator paints a concept image before sculpting the mesh, and ChatGPT now shows that painted view the moment it exists, while the 3D model is still generating: in the inline widget it appears instantly as the model loads behind it. You can also ask for quality now: draft for speed, standard by default, or high for maximum detail on our own GPUs (it takes a few minutes and is worth it). Under the hood, ChatGPT requests ride the same smart engine routing as the Forge page instead of a single pinned engine, so an unhealthy lane never blocks your model.</description>+ </item><item><title>The sniper fleet becomes a live experiment: rules vs AI judgment</title><link>https://three.ws/sniper/experiments</link>diff --git a/public/features.json b/public/features.jsonindex 3c90a6f4a..e846600b0 100644--- a/public/features.json+++ b/public/features.json@@ -1,5 +1,5 @@{- "generated_at": "2026-07-19T14:45:53.554Z",+ "generated_at": "2026-07-19T15:04:56.957Z","generated_by": "scripts/build-page-index.mjs from data/pages.json","site": {"name": "three.ws",diff --git a/tests/api/3d-studio.test.js b/tests/api/3d-studio.test.jsindex 7629ec626..03148b256 100644--- a/tests/api/3d-studio.test.js+++ b/tests/api/3d-studio.test.js@@ -118,7 +118,7 @@ function expectCleanWire(body) {}describe('shape helpers — Actions wire contract', () => {- it('shapeSubmit maps inline-done to { done, glbUrl, viewerUrl, arUrl } with nothing else attached', async () => {+ it('shapeSubmit maps inline-done to { done, glbUrl, viewerUrl, arUrl, tier } with nothing else attached', async () => {const { shapeSubmit } = await import('../../api/3d/studio.js');const out = shapeSubmit(SUBMIT_DONE, 'https://three.ws', 'a small ceramic robot figurine');expect(out).toEqual({@@ -131,10 +131,27 @@ describe('shape helpers — Actions wire contract', () => {'&title=' +encodeURIComponent('a small ceramic robot figurine'),format: 'glb',+ tier: 'draft',});expectCleanWire(out);});+ it('shapeSubmit surfaces the painted concept image on done and pending states', async () => {+ const { shapeSubmit } = await import('../../api/3d/studio.js');+ const preview = 'https://cdn.three.ws/forge/anon/ref-view.png';+ const done = shapeSubmit({ ...SUBMIT_DONE, preview_image_url: preview }, 'https://three.ws', 'a robot');+ expect(done.previewImageUrl).toBe(preview);+ const pending = shapeSubmit(+ { ...SUBMIT_QUEUED, preview_image_url: preview, tier: 'high', eta_seconds: 240 },+ 'https://three.ws',+ 'a robot',+ );+ expect(pending).toMatchObject({ status: 'pending', previewImageUrl: preview, tier: 'high', etaSeconds: 240 });+ // Non-https preview never leaks onto the wire.+ const dirty = shapeSubmit({ ...SUBMIT_QUEUED, preview_image_url: 'http://evil/ref.png' }, 'https://three.ws', 'x');+ expect(dirty.previewImageUrl).toBeUndefined();+ });+it('shapeSubmit maps queued to { pending, job, poll } carrying the prompt as the AR title', async () => {const { shapeSubmit } = await import('../../api/3d/studio.js');const out = shapeSubmit(SUBMIT_QUEUED, 'https://three.ws', 'a small ceramic robot figurine');@@ -254,8 +271,39 @@ describe('POST /api/3d/studio — response contract', () => {encodeURIComponent('a small ceramic robot figurine'),);expectCleanWire(body);+ // No pinned backend: the free-first health-aware router picks the lane,+ // exactly like the /forge page.+ const [, opts] = globalThis.fetch.mock.calls[0];+ const sent = JSON.parse(opts.body);+ expect(sent).toMatchObject({ prompt: 'a small ceramic robot figurine', path: 'image', tier: 'standard' });+ expect(sent.backend).toBeUndefined();+ });++ it('accepts tier "high" and runs it operator-funded through the internal seed header', async () => {+ globalThis.fetch = vi.fn(async () => jsonResponse(SUBMIT_QUEUED));+ process.env.CRON_SECRET = 'test-seed-secret';+ const { res, body } = await dispatch(+ makeReq({ body: { prompt: 'a small ceramic robot figurine', tier: 'high' } }),+ makeRes(),+ );+ delete process.env.CRON_SECRET;+ expect(res.statusCode).toBe(200);+ expect(body.status).toBe('pending');const [, opts] = globalThis.fetch.mock.calls[0];- expect(JSON.parse(opts.body)).toMatchObject({ prompt: 'a small ceramic robot figurine', backend: 'nvidia', path: 'image', tier: 'standard' });+ expect(JSON.parse(opts.body)).toMatchObject({ tier: 'high' });+ expect(opts.headers['x-forge-seed']).toBe('test-seed-secret');+ expectCleanWire(body);+ });++ it('rejects an invalid tier with a designed 400', async () => {+ globalThis.fetch = vi.fn(async () => jsonResponse(SUBMIT_DONE));+ const { res, body } = await dispatch(+ makeReq({ body: { prompt: 'a small ceramic robot figurine', tier: 'ultra' } }),+ makeRes(),+ );+ expect(res.statusCode).toBe(400);+ expect(body.error).toBe('invalid_tier');+ expect(globalThis.fetch).not.toHaveBeenCalled();});it('submits a known brand-mark prompt as image→3D against the deployment-hosted reference view', async () => {diff --git a/tests/api/gpt-forge-clone.test.js b/tests/api/gpt-forge-clone.test.jsindex 04ebe2699..ca3b53d2b 100644--- a/tests/api/gpt-forge-clone.test.js+++ b/tests/api/gpt-forge-clone.test.js@@ -66,6 +66,15 @@ describe('surface wiring — ChatGPT on the clone, agents on the original', () =});});+describe('gpt-forge divergences — ChatGPT-side improvements stay in place', () => {+ it('poll metadata surfaces the painted concept view (preview_image_url) to the ChatGPT surfaces', () => {+ const src = read('api/gpt-forge.js');+ const metaBlock = src.slice(src.indexOf('const metaFields'), src.indexOf('const metaFields') + 900);+ expect(metaBlock).toContain('preview_image_url');+ expect(metaBlock).toContain('text_to_image_model');+ });+});+describe('/api/gpt-forge — the cloned orchestrator serves', () => {function makeReq(url) {return { method: 'GET', url, headers: {} };diff --git a/tests/mcp-studio.test.js b/tests/mcp-studio.test.jsindex 8b00bf88f..42d63799b 100644--- a/tests/mcp-studio.test.js+++ b/tests/mcp-studio.test.js@@ -200,6 +200,31 @@ describe('mcp-studio dispatch', () => {expect(serialized).not.toContain('creation_id');});+ it('forge_free surfaces the painted concept image (the forge paint-then-sculpt step) in result + widget contract', async () => {+ globalThis.fetch = vi.fn(async () => ({+ ok: true,+ status: 200,+ json: async () => ({+ status: 'done',+ glb_url: 'https://three.ws/cdn/creations/model.glb',+ preview_image_url: 'https://three.ws/cdn/creations/model-ref.png',+ }),+ }));+ const r = await dispatch(+ { jsonrpc: '2.0', id: 61, method: 'tools/call', params: { name: 'forge_free', arguments: { prompt: 'a friendly round robot mascot' } } },+ auth,+ mkReq(),+ );+ const sc = r.result.structuredContent;+ expect(sc.referenceImageUrl).toBe('https://three.ws/cdn/creations/model-ref.png');+ // The narration offers the concept image so non-widget clients see it too.+ expect(r.result.content[0].text).toContain('https://three.ws/cdn/creations/model-ref.png');+ // The widget uses it as the model-viewer poster while the GLB streams in.+ const { COMPONENT_HTML } = await import('../api/_mcp-studio/component.js');+ expect(COMPONENT_HTML).toContain('referenceImageUrl');+ expect(COMPONENT_HTML).toContain('poster');+ });+it('avatar results carry the IRL living-agent handoff; props stay static (AR bridges agents into the real world)', async () => {globalThis.fetch = vi.fn(async () => ({ok: true,