Skip to content

About

Zero-setup guided AIMarket golden path: GAIA invoke, Metis verification, signed Hub receipt, and Alien Monitor handoff.

Topics

Resources

Code of conduct

Contributing

Security policy

Stars

0 stars

Watchers

0 watching

Forks

Repository files navigation

AIMarket Playground

One real GAIA reading. One Metis verification gate. One cryptographically verified Hub receipt.
A bounded, zero-setup activation path for the AIMarket Protocol v2 ecosystem.

CI Pages deploy Python >=3.11 97 tests passing 100% branch coverage 5 languages AIMarket Protocol v2 Docker ready License: MIT

🔄 Synced from the AI-Factory monorepo (append-only history). Pull requests are welcome — merged PRs are imported back and re-synced here. Issues · Pull requests

English · Русский · Español · Français · 中文 · Localization glossary

AIMarket Playground — zero-setup golden path: Make the network answer
No account. No wallet. No local cluster. — live playground → · landing → · run locally →

Developer workspace

Provider starter · Consumer starter

Choose Python or TypeScript for either role. The workspace supports EN / RU / ES / FR / ZH. Four source ZIPs include runnable code, tests, CI, localized START.*.md guides and SOURCES.json. The browser verifies the archive's SHA-256 before downloading it; this detects mismatched/corrupt archives, not an independently signed release.

Providers generate their private key locally and run the same aimarket-provider-invoke/1 checker as /connect. The public check and Hub publication remain separate, explicit steps. Consumers discover GAIA weather without invoking it, then explicitly authorize one call with a $0.01 ceiling. A local attempt.json prevents accidental repeat runs after a lost response. No automatic payment, top-up, or retry. Python verifies receipts locally against the origin key obtained over TLS; TypeScript uses the Hub's verification endpoint and requires its live-key verdict. Neither proves factual correctness or an independently pinned identity.

The source snapshots avoid depending on unpublished generator/SDK registry releases. Dependencies still require package-registry access. Commands target macOS / Linux or WSL. TypeScript providers also need Python 3.11+ for the shared invoke-profile checker.

Maintainers rebuild ZIPs from the monorepo, with Node.js on PATH:

python scripts/build_starters.py
python scripts/build_starters.py --check
python scripts/smoke_starters.py
node tests/start.browser.cjs

The smoke script installs dependencies in temporary projects and exercises real local provider calls and offline consumer tests, never paid public invocations. The browser suite checks four viewport widths, five languages, both roles/stacks, clipboard, ZIP hashes and download failure states. BASE_URL can select an already deployed Playground.

Connect your own provider

Open /connect on a running Playground to check your own HTTPS endpoint, with same-origin ownership proof, one real test invoke, schema validation and Ed25519 signature verification. Download the JSON report or run the same profile in CI with aimarket-provider-check. The report covers the provider invoke profile. Setup, limits and profile. Publish on the Hub in a separate step.

What the live demo does

The Playground runs one allow-listed golden path:

browser → AIMarket Playground → Hub → GAIA → Metis → verified receipt → Alien Monitor link

It deliberately does not execute arbitrary browser-submitted code. The code panel explains the real HTTP workflow while the server performs a bounded request with no infrastructure secrets in the browser.

Gallery

Captures from a live run against Hub, GAIA, and Metis — not mock UI. The receipt below verified with Ed25519 against the origin Hub key; Metis returned a structured VERDICT: plausible.

Network trace: GAIA invoke done, Metis verifying, Hub receipt done Verified result: GAIA output, Metis score 1, Ed25519 Hub receipt
Live network trace VERIFIED reading + receipt
From proof to product: uvx create-aimarket-agent handoff
Same path locally via create-aimarket-agent

Trust and failure semantics

  • GAIA returns a LIVE reading through the Hub.
  • The Hub receipt is verified with Ed25519 against the origin Hub public key and must match the requested product_id, capability_id, and successful invoke; signature presence alone is never reported as verification.
  • GAIA and the cryptographically checked Hub receipt appear first. Metis verification then continues asynchronously in the background, with a visible elapsed-time status and browser polling.
  • Playground sends a narrowly scoped consistency task through Metis fast; /v1/verify still runs its real verifier, so this avoids the full Council/MoA pipeline without inventing a score. Operators may opt into thinking or council with PLAYGROUND_METIS_ROUTE.
  • A response without verify_performed: true is displayed as not checked, never as a genuine zero-score verdict. This keeps older or misconfigured Metis deployments fail-closed.
  • Metis' upstream verified flag proves that its generated assessment passed Metis' own critic; it does not by itself prove that the GAIA reading passed. Playground reports VERIFIED only when the critic-verified assessment also contains the structured VERDICT: plausible result and the Hub receipt verifies. An implausible or unstructured assessment stays PARTIAL.
  • Metis has a configurable 600-second server ceiling. Playground waits up to 620 seconds and its overall task budget is 640 seconds, so Metis remains the authoritative limit. Server timeout, Playground timeout, network/HTTP unavailability, internal error, and a completed below-threshold verdict are displayed separately; the valid reading and receipt remain visible as PARTIAL, never as a false VERIFIED result.
  • Run results are bound to the pseudonymous browser visitor that created them.
  • Public inputs, request bodies, upstream responses, concurrency, run history, and hourly usage are bounded. Hourly limits apply to both the pseudonymous visitor and the network source, so rotating the browser identifier does not bypass the server-side cost guard.
  • Configured upstreams require HTTPS by default; event ingestion requires a bearer token.

Local development

Requirements: Python 3.11+.

uv sync --extra dev
uv run pytest
uv run uvicorn playground.app:app --host 127.0.0.1 --port 8075

Open http://127.0.0.1:8075. Select a language in the header or use ?lang=ru, ?lang=es, ?lang=fr, or ?lang=zh.

Docker

docker compose up --build

Compose publishes the service only on 127.0.0.1:8075, uses a read-only filesystem, drops Linux capabilities, enables no-new-privileges, bounds process IDs, includes a health check, and mounts /tmp as tmpfs. Put an HTTPS reverse proxy with an external rate limit in front of a public deployment.

Production (https://play.modelmarket.dev/): runs on the oracle host (203.0.113.20), not the factory (203.0.113.10). From the monorepo on that host:

sudo ./scripts/deploy_playground.sh

That builds the loopback container, installs deploy/nginx/play.modelmarket.dev.conf, issues/renews Let's Encrypt via webroot, and relies on certbot.timer for auto-renewal. Set PLAYGROUND_METIS_KEY in aimarket-playground/.env (server-only; Metis returns 401 without it).

Configuration

Copy .env.example and review every value. Important controls include:

Variable Purpose
PLAYGROUND_HUB_URL AIMarket Hub base URL
PLAYGROUND_GAIA_URL GAIA origin Hub URL used for receipt-key verification
PLAYGROUND_METIS_URL Metis verifier URL
PLAYGROUND_METIS_KEY Server-only Bearer credential for an authenticated production Metis
PLAYGROUND_METIS_ROUTE Allow-listed Metis route: fast (default), thinking, or council
PLAYGROUND_METIS_TIMEOUT_S Outer background verifier budget (bounded to 620 seconds)
PLAYGROUND_RUN_TIMEOUT_S Whole background task budget (bounded to 650 seconds; default 640)
PLAYGROUND_EVENT_URL Optional authenticated monitor ingestion endpoint
PLAYGROUND_EVENT_TOKEN Bearer token required with the event endpoint
PLAYGROUND_MAX_RUNS_PER_SOURCE_PER_HOUR Cost guard that cannot be bypassed by rotating the browser visitor ID
PLAYGROUND_MAX_* Usage, concurrency, response, and storage bounds

Localization contract

The UI and documentation ship in English, Russian, Spanish, French, and Chinese. Domain terms follow the canonical AICOM localization glossary. Brands, code, identifiers, CLI commands, environment variables, URLs, LIVE, and SIM remain unchanged. Tests enforce locale key parity and the canonical renderings of reading, receipt, verification, and rails.

Product boundary

The Use Cases Portal maps opportunities and explains the ecosystem. The Playground activates a developer with one real invoke. create-aimarket-agent then creates a repository the developer owns. These are connected stages, not duplicate portals.

License

MIT — see LICENSE.

About

Zero-setup guided AIMarket golden path: GAIA invoke, Metis verification, signed Hub receipt, and Alien Monitor handoff.

Topics

Resources

Code of conduct

Contributing

Security policy

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages