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
fix(okx-ai): add usage examples to all 11 listing rows; listing-update payload builder
nirholasd4b913fa0317
diff --git a/api/_lib/okx-catalog.js b/api/_lib/okx-catalog.jsindex a10ad9dde..2cdfde6b2 100644--- a/api/_lib/okx-catalog.js+++ b/api/_lib/okx-catalog.js@@ -71,9 +71,9 @@ export const OKX_CATALOG = Object.freeze(['animation-ready GLB avatar plus posed studio renders, including a square profile ' +'picture and full-body shots.',input:- 'Provide: 1. the agent name 2. a personality or brand brief in any language 3. optional ' +- 'style hints 4. an optional reference image. Returns a job you can check for free until ' +- 'delivery is ready.',+ 'Provide: 1. the agent name 2. a brand or personality brief in any language 3. optional ' ++ 'style hints 4. an optional reference image. Example: name LedgerLynx, brief: a calm ' ++ 'on-chain accounting agent.',},priceUsd: '1.50',amountAtomics: usdToAtomics(1.5),@@ -129,8 +129,8 @@ export const OKX_CATALOG = Object.freeze(['when the job is accepted.',input:'Provide: 1. a text description of one object or character, 3 to 1000 characters ' +- '2. an optional aspect ratio. Returns the model link, or a job you can check for free ' +- 'until it is done.',+ '2. an optional aspect ratio. Example: a brass steampunk owl, full body. Returns the ' ++ 'model link or a free-to-check job.',},priceUsd: '0.01',amountAtomics: usdToAtomics(0.01),@@ -156,9 +156,9 @@ export const OKX_CATALOG = Object.freeze(['textured GLB model. Standard tier by default; the high tier adds maximum detail and ' +'PBR materials.',input:- 'Provide: 1. a text description, 3 to 1000 characters 2. an optional quality tier, ' +- 'standard or high 3. an optional aspect ratio. Returns the model link, or a job you can ' +- 'check for free.',+ 'Provide: 1. a text description 2. an optional quality tier, standard or high 3. an ' ++ 'optional aspect ratio. Example: an ornate elven longsword, tier high. Returns the ' ++ 'model link or a free-to-check job.',},priceUsd: '0.30',amountAtomics: usdToAtomics(0.3),@@ -185,7 +185,8 @@ export const OKX_CATALOG = Object.freeze(['product shots or concept art into usable 3D assets.',input:'Provide: 1. one to four public photo links of the same object 2. an optional text ' +- 'hint. Returns the model link, or a job you can check for free until it is done.',+ 'hint. Example: front and side photos of one sneaker. Returns the model link or a ' ++ 'free-to-check job.',},priceUsd: '0.30',amountAtomics: usdToAtomics(0.3),@@ -215,8 +216,9 @@ export const OKX_CATALOG = Object.freeze(['Rigs a static humanoid GLB model into an animation-ready character: adds a skeleton and ' +'skin weights so the model can be posed and animated in any engine.',input:- 'Provide: 1. a public link to the static GLB model. Humanoid models rig best. Returns a ' +- 'job you can check for free until the rigged model is ready.',+ 'Provide: 1. a public link to the static GLB model. Humanoid models rig best. Example: ' ++ 'a knight character model. Returns a job you can check for free until the rigged model ' ++ 'is ready.',},priceUsd: '0.25',amountAtomics: usdToAtomics(0.25),@@ -240,8 +242,8 @@ export const OKX_CATALOG = Object.freeze(['rigging pass is wasted.',input:'Provide: 1. a text description of a full-body character, or a reference image link ' +- '2. optionally allow non-humanoid subjects. Returns the mesh plus a rigging job you can ' +- 'check for free.',+ '2. optionally allow non-humanoid subjects. Example: a heroic knight in silver armor, ' ++ 'full body.',},priceUsd: '0.50',amountAtomics: usdToAtomics(0.5),@@ -268,7 +270,7 @@ export const OKX_CATALOG = Object.freeze(['request.',input:'Provide: 1. a public link to the rigged GLB model 2. the animation name 3. an optional ' +- 'output format and playback speed.',+ 'output format and playback speed. Example: your knight model plus the walk animation.',},priceUsd: '0.10',amountAtomics: usdToAtomics(0.1),@@ -296,8 +298,8 @@ export const OKX_CATALOG = Object.freeze(['map for humanoid rigs. The same description always returns the same pose. Finishes ' +'within the request.',input:- 'Provide: 1. a pose description, 1 to 500 characters. Returns the seed, per-joint ' +- 'rotations, and a preview link.',+ 'Provide: 1. a pose description, 1 to 500 characters. Example: confident standing ' ++ 'pose, arms crossed. Returns the seed, per-joint rotations, and a preview link.',},priceUsd: '0.02',amountAtomics: usdToAtomics(0.02),@@ -320,7 +322,8 @@ export const OKX_CATALOG = Object.freeze(['skin weights, and blendshapes. Also exports OBJ, STL, PLY, USDZ, and 3MF formats.',input:'Provide: 1. a public link to the GLB model 2. an optional target format, FBX by ' +- 'default. Returns a job you can check for free until the converted file is ready.',+ 'default; OBJ, STL, PLY, USDZ, and 3MF also work. Example: your rigged knight model ' ++ 'to FBX for Unity.',},priceUsd: '0.10',amountAtomics: usdToAtomics(0.1),@@ -345,7 +348,9 @@ export const OKX_CATALOG = Object.freeze(['Free machine-readable index of every three.ws 3D Studio service on OKX.AI: names, ' +'descriptions, prices, endpoints, and input formats, always in sync with the live ' +'services.',- input: 'Provide nothing. No parameters, no payment, no account required.',+ input:+ 'Provide nothing. No parameters, no payment, no account required. Example: fetch ' ++ 'the link to list every service with names, prices, and input details.',},priceUsd: '0',amountAtomics: null,@@ -361,7 +366,9 @@ export const OKX_CATALOG = Object.freeze([capability:'Free live health status for the systems behind every paid service: generation, rigging, ' +'rendering, storage, and the payment rail, from real checks rather than a fixed reply.',- input: 'Provide nothing. No parameters, no payment, no account required.',+ input:+ 'Provide nothing. No parameters, no payment, no account required. Example: fetch ' ++ 'the link to confirm all systems are up before buying a paid service.',},priceUsd: '0',amountAtomics: null,diff --git a/prompts/okx-ai/PROGRESS.md b/prompts/okx-ai/PROGRESS.mdindex 52465a4fa..d8f7f07fb 100644--- a/prompts/okx-ai/PROGRESS.md+++ b/prompts/okx-ai/PROGRESS.md@@ -1392,3 +1392,80 @@ the new login mechanic in full in `RUNBOOK.md` §0 so the next session doesn't rURL, poll until `loggedIn:true`.3. `onchainos agent get-agents --agent-ids 2632` for current approval state, then RUNBOOK §4or §5 depending on the result.++---++## 2026-07-26: New rejection (service description / parameters / usage examples) + A2A chat found OFFLINE; both fixes staged, resubmission still login-gated++Two inputs arrived via the owner: (1) a fresh OKX review rejection email for "three.ws 3D+Studio": "The service you submitted is missing a complete description, parameter details,+and usage examples. Please make these updates and resubmit ... via chat." (2) A contact at+OKX ran the marketplace chat test against the agent and every message timed out with+"no delivery in 30 min", with the note that the bot is offline and must respond faster;+they will retest once we say it is fixed.++### Root cause of the chat timeouts: the A2A runtime did not exist on this machine++The codespace was rebuilt at some point after 2026-07-23: `onchainos` (was at+~/.local/bin) and the `okx-a2a` daemon (`@okxweb3/a2a-node`) were both GONE, and the+wallet session with them (`wallet status` -> loggedIn:false, accountCount 0). OKX A2A+chat delivery rides the local daemon's XMTP identity; with no daemon and no session, agent+#2632 has no reachable inbox, so "no delivery in 30 min" is exactly right. Fixed this+session:++- Reinstalled `onchainos` v4.4.0 (checksum-verified installer) and `@okxweb3/a2a-node`+ 0.1.10 globally.+- `okx-a2a daemon start` -> running, linux-systemd user autostart installed;+ `switch-runtime` -> provider `claude`, ready; `setup --json` -> `state:"ready"`,+ provider auth ready. Inbound chats are answered automatically by the daemon through the+ Claude CLI once the agent identity loads.+- REMAINING GATE: `agent refresh` reports `agentCount: 0, activeClients: 0` because the+ wallet is logged out. A human must complete the browser login (v4.3+ flow, RUNBOOK §0)+ as [email protected]; then `okx-a2a agent refresh --json` picks up #2632 and the bot is+ live. Login session was initiated this run and the URL handed to the owner.+- TRAP for future sessions: any codespace rebuild silently kills the chat bot (CLIs,+ daemon, and session all live outside the repo). After every rebuild: reinstall both+ CLIs, restart the daemon, re-login, re-refresh. A codespace that idles also stops the+ daemon; for the OKX retest keep this workspace awake, and longer-term the daemon+ belongs on an always-on host.++### Listing fix: usage examples added to every catalog row++The 2026-07-17 rewrite gave every row the 2-part format (capability + "Provide: 1. ..."+parameter list) but no usage examples, and the new rejection explicitly demands examples.+Every `describes.input` in `api/_lib/okx-catalog.js` now carries a short "Example: ..."+usage line (e.g. text-to-3d: "Example: a brass steampunk owl, full body"). All 11 rows+re-validated within the 200 display-width per-part limit; `validateCatalog()` + 56 tests+green (okx-3d-services, okx-identity-studio, service-catalog).++DECISION (deliberate): the older skill invariants say "no example prompts" in+serviceDescription, but the reviewer's written rejection explicitly requires usage+examples; the reviewer's current instruction wins. If `validate-listing` flags the+examples during the update flow, keep them and note the conflict in the submission chat.++Note the live listing has likely still carried the STALE pre-rewrite service rows all+along (7 services, old names, thin descriptions, no parameter lists); if the reviewer+re-probed those rows this rejection is fully explained. The resubmission must replace the+full service set, not just re-activate.++### New tool: scripts/okx-listing-payload.mjs++Builds the `agent update --service` JSON straight from the catalog module:+`node scripts/okx-listing-payload.mjs` prints the 11 create-format entries;+`onchainos agent service-list --agent-id 2632 | node scripts/okx-listing-payload.mjs+--delta` prints the full replace delta (delete stale rows by name, update name matches,+create the rest). Submission can no longer drift from the module.++### Resubmission runbook from here (in order)++1. Human completes the browser login ([email protected]). `wallet status` -> loggedIn:true.+2. `okx-a2a agent refresh --json` -> agentCount >= 1; confirm the OKX contact's chat test+ now gets replies, fast.+3. Deploy so the live `/api/okx/3d/catalog` serves the new example-bearing strings+ (three-copy rule: module == live == submission). One command: `npm run deploy:gcp:full`+ from a clean worktree (owner-gated).+4. `onchainos agent service-list --agent-id 2632 | node scripts/okx-listing-payload.mjs+ --delta` -> `agent update` with that delta (+ the 07-17 440x440 avatar upload if not+ yet applied), `validate-listing` batch pass, human confirms the diff card.+5. Re-activate (`--preferred-language en-US`), then tell the OKX contact to retest, and+ resubmit for review via the OKX support chat per the rejection email.diff --git a/scripts/okx-listing-payload.mjs b/scripts/okx-listing-payload.mjsnew file mode 100644index 000000000..9a16d4dbe--- /dev/null+++ b/scripts/okx-listing-payload.mjs@@ -0,0 +1,76 @@+#!/usr/bin/env node+// Builds the `onchainos agent update --service` delta for OKX.AI agent #2632+// from the canonical catalog module (api/_lib/okx-catalog.js), so the listing+// submission can never drift from the live endpoints.+//+// Usage:+// node scripts/okx-listing-payload.mjs # create-format entries (no live list)+// onchainos agent service-list --agent-id 2632 \+// | node scripts/okx-listing-payload.mjs --delta # full replace delta vs the live list+//+// With --delta, every live service whose name is NOT in the catalog becomes an+// "operation":"delete" entry, and every catalog row becomes either an+// "operation":"update" (live row with the same name exists) or+// "operation":"create". Output is a single JSON array ready for --service.++import { OKX_CATALOG, listingDescription, validateCatalog } from '../api/_lib/okx-catalog.js';++validateCatalog();++function catalogEntryToService(e) {+ return {+ serviceName: e.name,+ serviceDescription: listingDescription(e),+ serviceType: 'A2MCP',+ fee: e.priceUsd === '0' ? '0' : e.priceUsd,+ endpoint: e.endpoint,+ };+}++const wantDelta = process.argv.includes('--delta');++if (!wantDelta) {+ console.log(JSON.stringify(OKX_CATALOG.map(catalogEntryToService), null, 2));+ process.exit(0);+}++let raw = '';+for await (const chunk of process.stdin) raw += chunk;+const parsed = JSON.parse(raw);+// service-list shape: { ok, data: [{ total, rows|list|services: [...] }] } or a bare array.+const container = Array.isArray(parsed) ? parsed : (parsed.data?.[0] ?? parsed.data ?? parsed);+const live =+ container.rows ?? container.list ?? container.services ?? (Array.isArray(container) ? container : null);+if (!Array.isArray(live)) {+ console.error('Could not find the service array in the input JSON. Top-level keys:', Object.keys(parsed));+ process.exit(1);+}++const catalogByName = new Map(OKX_CATALOG.map((e) => [e.name, e]));+const liveByName = new Map(live.map((s) => [s.serviceName ?? s.name, s]));++const delta = [];+for (const s of live) {+ const name = s.serviceName ?? s.name;+ if (!catalogByName.has(name)) {+ delta.push({+ operation: 'delete',+ id: String(s.id ?? s.serviceId),+ serviceName: name,+ serviceDescription: s.serviceDescription ?? s.description ?? '',+ serviceType: s.serviceType ?? 'A2MCP',+ fee: String(s.fee ?? '0'),+ });+ }+}+for (const e of OKX_CATALOG) {+ const liveRow = liveByName.get(e.name);+ const entry = catalogEntryToService(e);+ if (liveRow) {+ delta.push({ operation: 'update', id: String(liveRow.id ?? liveRow.serviceId), ...entry });+ } else {+ delta.push({ operation: 'create', ...entry });+ }+}++console.log(JSON.stringify(delta, null, 2));