TamaGo ๐Ÿฅš
Vercel Agent Tracks ยท 2026

Inside TamaGo

A persistent AI companion built to demonstrate durable agent life: stateful care, episodic memory, MCP tool use, and proactive workflows with restraint.

๐ŸA hackathon submission

TamaGo targets the Vercel Agent Tracks by turning infrastructure into product behavior. WDK keeps background life running, MCP gives the chat real-world senses, and v0 helped shape the first usable surface before local iteration.

Track 1 ยท Vercel Workflow (WDK)
Durable workflows run the background life: welcome, companion-tick, idle consolidation, deep-sleep reflection, and wake greeting. The app exposes the next arbiter check and demo controls so judges can see workflows move without waiting hours.
Track 2 ยท v0 + MCPs
The chat consumes six MCP servers hosted as Vercel Functions: `weather`, `time`, `sunrise`, `holidays`, `quote`, and `animal-fact`. Skills are AI SDK tools, model-selected, and rendered as live chips so every lookup is visible.

๐ŸฅšWhat it is

TamaGo is a Tamagotchi-style AI agent. It has three needs that decay slowly with time (hunger, play, bond) and you attend to them by tapping emoji care actions or by chatting. It remembers you across days, devices, and reboots โ€” using stable profile facts plus episodic memories that consolidate during deep sleep. It speaks proactively only when there's a concrete reason, with a hard cap of 2 unanswered nudges before it pauses.

โš™๏ธHow it works

A two-layer memory keeps stable profile facts (name, pet, city, plus long-term patterns extracted during deep sleep) separate from episodic concerns that resolve over time. A per-user intensity profile in Redis tracks how often you want to be reached out to, which topics to leave alone, and quietly decays old signals if they're not reinforced. A single proactivity arbiter ranks every reason TamaGo could speak first (critical need, deep-sleep wake-up, unresolved emotional load, idle curiosity), enforces hard gates, and caps the streak at 2 unanswered before pausing. Durable workflows on Vercel WDK schedule the arbiter on a randomized cadence and run consolidation in the background. When the chat needs a real-world signal, the AI SDK calls our MCP servers as native tools and the UI renders a live chip while the call runs. A small content classifier (same model as the chat, no extra provider) gates age-sensitive topics on the first occurrence.

โ–ฒPowered end-to-end by Vercel

AI Gateway routes the LLM (xAI Grok via a single provider/model string). Vercel WDK runs the agent's durable workflow loop with real `await sleep('3h')` semantics. Vercel Functions host the chat API, the care API, the timezone profile endpoint, and all six MCP servers. Marketplace storage holds the snapshot. v0 sketched the first mockup before the project moved local. One platform, one git push, every preview deploy already production-grade โ€” and a build-version tag in the SSE stream forces open tabs to reload after each new deploy.

The stack

Vercel AI Gateway
One key, one provider/model string. Routes to xAI Grok 4.1 fast for chat, care reactions, deep-sleep reflections, and Capa B insight extraction.
Vercel WDK
Durable workflows with `use workflow` + `use step`. The companion-tick wakes the proactivity arbiter; deep-sleep consolidation runs while you're away. Every loop self-heals across skips.
Vercel Functions
The chat API streams NDJSON of typed events. /api/care drives needs + episodic memory. All six MCP servers are themselves Functions on the same deployment.
AI SDK 6 + @ai-sdk/mcp
streamText with `tools` from createMCPClient. The model decides when to call. The UI shows a live chip while each tool runs.
Proactivity arbiter
Pure decision module. Ranks every reason TamaGo could speak first, applies hard gates and a 2-unanswered budget, publishes verdicts to the cross-runtime event log so the behavior is visible in The Kitchen.
Marketplace storage
Upstash Redis (provisioned via Vercel Marketplace) holds the per-user snapshot โ€” chat turns, memories, facts, state.needs, sleep cursors.
v0
The first landing mockup was sketched in v0, then exported and iterated locally.
dcouplr
The architectural kernel. Every capability โ€” storage, LLM calls, workflow triggers, event bus โ€” is registered as a typed semantic intent that callers resolve at runtime. Built by a friend; deserves more eyes.
Web Push
Service-worker-backed push notifications fire when the arbiter actually decides to speak (need-critical, deep-sleep wake-up, emotional load).
Next.js 16 App Router
React 19, Turbopack dev server, visualViewport-aware layout for iOS keyboard, build-version tag in SSE for forced reload on deploy.
๐Ÿ‘‹Built by
Designed, written, and shipped end-to-end by Pedro Knigge. If you want to follow along or say hi, find me on X.
๐•@PedroKnigge