Skip to main content
Build an agent that learns what a user wants through structured preferences, delivers personalized product recommendations, and can purchase on their behalf. The Beauty Companion is a live implementation of this pattern.

What You’ll Build

Prerequisites

Step 1: Create an Intent Profile

The intent profile is the agent’s understanding of what the user wants. Build it from a quiz, conversation, or any structured input.

Incremental Profile Updates

For step-by-step quiz flows, use PATCH to add fields without overwriting the full profile:

Step 2: Get Personalized Recommendations

The recommendation engine uses the intent profile, interaction history, and enrichment baselines to rank products.

Step 3: Record Interactions

Every interaction signal improves future recommendations. The agent records explicit feedback — not passive tracking.

Retrieve Interaction History

Step 4: Browse the Product Catalog

The companion has its own product catalog with filtering:

Step 5: Place an Order

When the user confirms a purchase, create a concierge order. The order starts in PENDING_PAYMENT and must be settled via x402 USDC.

Track Order Status

Update Order Status (Admin)

Step 6: Award Engagement Points

Reward users for interacting with the agent — quiz completions, swipe sessions, purchases.

Putting It Together

Here’s a complete agent loop — the core of what a Telegram bot, MCP server, or mobile app would run: