0G AI Console: Next.js for Router testnet, Direct SDK, custom OpenAI chat, streaming, tools & Privy.
0G AI Console is a Next.js chat UI for 0G Router testnet and OpenAI-compatible APIs. Streams tokens end-to-end; web-fetch tools run on custom backends only (Router stays tool-free). Privy handles login and embedded wallets. Uses Vercel AI SDK streaming with collapsible tool traces.
This app is built with Next.js 16 App Router, React 19, TypeScript, Tailwind 4, shadcn-style UI, and AI Elements patterns for chat/tool panels. The client uses AI SDK React hooks against app/api/chat, which streams AI SDK v6: OpenAI-compatible mode runs streamText with Zod tools (web-fetch uses server fetch + format sniffing); Router mode proxies SSE, strips x_0g_trace, and omits tools. Direct SDK auth flows through Privy, wagmi/viem, and the 0g-compute-ts SDK.

