MVP UI to pair with the FastAPI backend. Left side is Chat (Coze), right side is Proposal Draft (simulate → submit with wallet).
pnpm i # or npm i / yarn
cp .env.local.example .env.local
pnpm dev # http://localhost:3000app/— App Router pagescomponents/— UI & panelslib/— wagmi config, ABI, stores, utilsapp/api/coze/— server route that can proxy to Coze Chat API (optional)
NEXT_PUBLIC_*— used in the browserCOZE_*— used on server route/api/cozeto forward chat messages (optional; falls back to echo)
- User chats; agent may return an Action JSON (type=
proposal_draft). - UI fills Proposal Draft Panel.
- Click Simulate → calls backend
/v1/dao/simulate. - Click Submit on-chain → wallet signs
proposeAI(...).