Sovereign Command Deck
One prompt. Three providers. Zero downtime.
The Command Deck routes a single prompt through Anthropic, Google, and Groq with automatic failover. Connect your wallet, type what you want, watch it ship.
§ 01 — What it does
The Hatchery, in plain English
You type a build request into the Hatchery. The QuackRouter forwards it to the first available AI provider; if that one rate-limits, errors, or times out (10s), the request is automatically retried against the next provider in the stack. The output streams back into the deck — and the System Log tells you which node served you.
Anthropic · primary
Streams code generation via the studio-chat endpoint. SSE tokens flow into the output panel as they arrive.
Google · secondary
JSON-mode chat for general questions and conversational fallback when streaming fails.
Groq · last resort
Treats the prompt as code and runs a full security audit. Returns severity-ranked findings.
§ 02 — How to use it
Five steps from cold start to output
Open the Deck
Connect a wallet
Write a blueprint
- “Build a single-page landing site for a coffee shop in Tailwind.”
- “Write an Express endpoint that signs JWTs with HS256.”
- “Audit this Solidity contract for reentrancy: …”
Hatch
(Optional) Pay for Pro
§ 02b — Your hatches, on-screen
History, copy, and submit for publishing
Every successful hatch is saved to your wallet — you'll see it in the Your Hatches panel under the textarea. Each card expands to show the full output, has a one-click copy button, and (if you're Pro) a Submit for publishing button.
Saved per-wallet. Anonymous users can still hatch, they just won't see a history. Connect → your past hatches load in instantly.
You drop your email; we pick up the hatch, polish it into something worth shipping, and publish it at /builds/<slug>. You get the URL plus advanced support while we're working on it.
Submitted → we've got it, queue entered
Pending → under active review / improvement
Approved → ready to publish, slug assigned
Published → live at /builds/<slug>
Rejected → not a fit (we'll email why)
§ 03 — Under the hood
How the QuackRouter decides who serves
The router walks the skill stack in order. For each provider it shapes the request body to that endpoint's contract (because the three endpoints don't share a schema) and sets a 10-second abort signal.
1. Try Build Studio → if 2xx: stream back, stop
2. ↳ on 429 / 5xx / timeout: try next
3. ↳ on other 4xx: bail (your input is the problem)
4. Try AI Chat → if 2xx: JSON back, stop
5. Try Deep Audit → if 2xx: JSON back, stop
6. All exhausted → 503 “hatchery nodes exhausted”
Every successful response carries X-Hatchery-Node and X-Hatchery-Provider headers so the deck can show you the failover chain in real time.
§ 04 — Wallet model
What the connect button actually does
Calls eth_requestAccounts, fetches a fresh nonce from /api/quackbuilds/wallet-login, signs it via personal_sign, and gets a JWT back. No on-chain transaction; no gas.
Sends eth_sendTransaction with value: 0xb1a2bc2ec50000 (= 0.05 ETH in wei) to NEXT_PUBLIC_QUACK_TREASURY_WALLET. Real transaction, real gas. The tx hash is recorded server-side to flip your wallet to Pro — which is what covers premium-model API costs plus the improvement + hosting labor behind published builds.
§ 05 — When it breaks
Common failures and fixes
You don't have MetaMask (or similar) installed in this browser. Install it and refresh. Mobile? Open the deck inside MetaMask's in-app browser.
All three providers failed within 10s each. Usually rate-limit cascade — wait 30s and re-hatch. Persistent? Check that QUACK_AI_PROVIDER and the API keys are set in env.
You hit "Reject" in the wallet popup. Click Pay again to retry. Nothing was sent.
NEXT_PUBLIC_QUACK_TREASURY_WALLET isn't set on Vercel (or in .env.local). Add it and redeploy.