Skip to content

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.

fix(constellation): let a click actually open a star, and name the model that really answered

nirholasf64958e200d1
diff --git a/docs/ibm.md b/docs/ibm.md
index 872d52d40..626d3d434 100644
--- a/docs/ibm.md
+++ b/docs/ibm.md
@@ -213,6 +213,22 @@ curl -s https://three.ws/api/watsonx/embed \
It returns one vector per input (the response reports the model and its native `dimensions`), plus a `cachedHits` count: a warm process-local LRU keeps repeat embeddings free, and per-IP + global rate limits cap watsonx spend. The response itself is sent `cache-control: no-store`, because a POST body varies per request and must never be shared-cached.
+**Always read `model` from the response.** The endpoint leads with Granite on watsonx.ai and falls through to the platform's free-first embedding chain (NVIDIA NIM, then Vertex, then OpenAI) when watsonx cannot serve a full batch, so a 200 does not by itself mean Granite answered. Every vector in one response comes from one provider, so `dimensions` is uniform. Only when no provider at all is configured does it answer `503 embed_unconfigured`, which is what lets a caller show an honest "not configured" state instead of inventing vectors.
+
+## watsonx Constellation
+
+**Page:** [`/constellation`](https://three.ws/constellation)
+
+The Constellation applies the same Granite embedding space to live market data instead of agents. It pulls trending Solana tokens from `GET /api/pump/trending`, embeds each token's name and ticker through `POST /api/watsonx/embed`, projects the vectors to three axes with classical MDS in the browser, and renders each token as a star, so tokens that mean similar things sit near each other. Picking a star opens its detail panel and streams an IBM Granite analysis of that token from `POST /api/brain/chat` with `provider: ibm-granite`.
+
+Three behaviours matter if you are reading the page or building on it:
+
+- **It names what actually served.** Both backing endpoints have failover chains, so the status line reports the embedder that really placed the stars and the analysis panel reports the model that really wrote the text, saying so plainly when watsonx Granite could not serve the request. It never credits Granite for another model's output.
+- **It never fabricates a layout.** Tokens first render in a deterministic by-rank layout and animate into their semantic positions once the vectors land. If embeddings are unavailable the by-rank layout stays and the status line says the semantic layout is off.
+- **The analysis needs a signed-in account.** `/api/brain/chat` restricts anonymous callers to its free-tier providers, so the panel links to sign-in rather than failing. The galaxy itself, its live market data and the semantic layout are open to everyone.
+
+The page is keyboard operable: the canvas takes focus, arrow keys walk the stars in trending order, Enter opens the focused star, and Escape closes the panel and returns focus to the galaxy.
+
A batch is 1 to 96 texts, each truncated to 512 characters. When watsonx is not configured on a deployment (or is failing), the endpoint falls through to the platform's free-first embedding chain (NVIDIA NIM, then Vertex `text-embedding-005`, then OpenAI `text-embedding-3-small`) and reports whichever `model` actually served, so `dimensions` is uniform within a response but can differ between them. A provider that covers only part of a batch counts as a failure and the next provider takes over: the response never carries a null where a vector belongs. With no provider configured at all you get a `503 embed_unconfigured` naming the env vars to set, never invented vectors.
---
@@ -285,12 +301,13 @@ It reads the same `WATSONX_*` environment variables documented above. See the [M
## Live pages and API surfaces
-The two live IBM pages on the product:
+The live IBM pages on the product:
| Route | What it is |
| -------------------------------------------------------- | ---------------------------------------------------------------- |
| [`/ibm/hello`](https://three.ws/ibm/hello) | The IBM and three.ws partnership page |
| [`/ibm/x402-demo`](https://three.ws/ibm/x402-demo) | Live x402 micropayment demo built with IBM |
+| [`/constellation`](https://three.ws/constellation) | watsonx Constellation: trending Solana tokens in embedding space |
The Granite demo pages that used to live under `/ibm/*` (galaxy, oracle, twin, trust-layer, identity, proof, vision) were retired from navigation and removed. Their API endpoints remain live and callable:
diff --git a/pages/constellation.html b/pages/constellation.html
index c531c8b6d..b823dfb2e 100644
--- a/pages/constellation.html
+++ b/pages/constellation.html
@@ -63,11 +63,13 @@
.c-status code { font-family: ui-monospace, Menlo, monospace; font-size: 11.5px; color: var(--brand-blue-light); }
.c-hint { position: fixed; bottom: 18px; left: 50%; transform: translateX(-50%); z-index: 5; color: var(--muted); font-size: 12.5px; background: var(--panel); backdrop-filter: blur(10px); border: 1px solid var(--border); border-radius: 999px; padding: 7px 16px; white-space: nowrap; transition: opacity .4s; }
- /* Narrow viewports: the hint wraps instead of overflowing the screen, and
- sits above the language switcher rather than underneath it. */
- @media (max-width: 720px) {
- .c-hint { font-size: 11px; padding: 6px 14px; bottom: 74px; white-space: normal; text-align: center; max-width: calc(100vw - 28px); border-radius: 14px; line-height: 1.45; }
+ /* The hint is centered and the language switcher is pinned bottom-right, so
+ below roughly 1120px the full-width pill runs underneath the switcher.
+ There it wraps and sits above the switcher instead of colliding with it. */
+ @media (max-width: 1120px) {
+ .c-hint { padding: 6px 14px; bottom: 74px; white-space: normal; text-align: center; max-width: calc(100vw - 28px); border-radius: 14px; line-height: 1.45; }
}
+ @media (max-width: 720px) { .c-hint { font-size: 11px; } }
.c-tooltip { position: fixed; z-index: 6; pointer-events: none; background: var(--panel); backdrop-filter: blur(10px); border: 1px solid var(--border); border-radius: 9px; padding: 6px 10px; font-size: 12.5px; opacity: 0; transition: opacity .12s; transform: translate(-50%, -130%); white-space: nowrap; }
.c-tooltip .sym { color: var(--brand-blue-light); font-weight: 700; }
diff --git a/public/features.json b/public/features.json
index 26e0d12e5..a25ab7473 100644
--- a/public/features.json
+++ b/public/features.json
@@ -1,5 +1,5 @@
{
- "generated_at": "2026-08-17T06:53:05.783Z",
+ "generated_at": "2026-08-17T06:57:02.679Z",
"generated_by": "scripts/build-page-index.mjs from data/pages.json",
"site": {
"name": "three.ws",
diff --git a/src/constellation/main.js b/src/constellation/main.js
index 4036f2155..064b18f61 100644
--- a/src/constellation/main.js
+++ b/src/constellation/main.js
@@ -374,9 +374,12 @@ function onPointerMove(e) {
}
}
-let downAt = 0; let downXY = [0, 0]; let downNode = null;
+// How far the pointer may travel between press and release and still count as a
+// tap rather than an orbit drag. Fingers wobble more than a mouse does.
+function tapSlopPx() { return coarsePointer() ? 12 : 6; }
+
+let downXY = [0, 0]; let downNode = null;
function onPointerDown(e) {
- downAt = performance.now();
downXY = [e.clientX, e.clientY];
// Resolve the target at press time as well. The galaxy keeps auto-rotating,
// so the star can slide out from under a stationary cursor between the press
@@ -386,7 +389,11 @@ function onPointerDown(e) {
}
function onPointerUp(e) {
const moved = Math.hypot(e.clientX - downXY[0], e.clientY - downXY[1]);
- if (moved >= 6 || performance.now() - downAt >= 450) return; // an orbit drag, not a tap
+ // Movement is the only honest test for "orbit drag vs tap". A press that ends
+ // where it started is a tap however long it was held: gating on duration made
+ // a deliberate slow click, or any press on a loaded device, silently do
+ // nothing, which is exactly the interaction this whole page is built around.
+ if (moved >= tapSlopPx()) return;
updatePointer(e);
// The star under the release wins; then the star the tooltip is naming; then
// the one that was under the press. Any of the three is the intended target.