<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Kyung-Hoon Kim</title>
    <description>The latest articles on DEV Community by Kyung-Hoon Kim (@beingcognitive).</description>
    <link>https://dev.to/beingcognitive</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3824901%2F4ef3aec9-b4b1-433f-84ff-2d6f36a52dde.jpeg</url>
      <title>DEV Community: Kyung-Hoon Kim</title>
      <link>https://dev.to/beingcognitive</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/beingcognitive"/>
    <language>en</language>
    <item>
      <title>I Built an AI That Lets You Talk to Your Future Self — Here's How</title>
      <dc:creator>Kyung-Hoon Kim</dc:creator>
      <pubDate>Sun, 15 Mar 2026 05:34:17 +0000</pubDate>
      <link>https://dev.to/beingcognitive/i-built-an-ai-that-lets-you-talk-to-your-future-self-heres-how-3k6a</link>
      <guid>https://dev.to/beingcognitive/i-built-an-ai-that-lets-you-talk-to-your-future-self-heres-how-3k6a</guid>
      <description>&lt;p&gt;What if you could sit down and have a real conversation with your future self — not a chatbot, but a version of you who's been where you're going?&lt;/p&gt;

&lt;p&gt;That's what I built with &lt;strong&gt;Mirror8&lt;/strong&gt;. You upload a selfie, AI generates 8 possible future versions of you, and then you pick one and have a live voice conversation. Your future self can see you through your camera, hear your voice, and talk back — all in real time.&lt;/p&gt;

&lt;p&gt;Here's how I built it with 4 Gemini models and Google Cloud.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Idea
&lt;/h2&gt;

&lt;p&gt;Everyone's seen that moment in interviews — "What would you tell your younger self?" People break down. They get real. But that conversation always looks backward.&lt;/p&gt;

&lt;p&gt;Research by psychologist Hal Hershfield at UCLA shows that people treat their future selves like strangers — and this disconnect leads to worse decisions. But when participants interacted with age-progressed avatars of themselves, they allocated &lt;strong&gt;more than twice as much&lt;/strong&gt; toward retirement savings.&lt;/p&gt;

&lt;p&gt;Mirror8 takes this from a lab experiment to a live experience.&lt;/p&gt;

&lt;h2&gt;
  
  
  The 4-Model Gemini Pipeline
&lt;/h2&gt;

&lt;p&gt;Mirror8 isn't powered by a single AI call. It orchestrates &lt;strong&gt;4 different Gemini models&lt;/strong&gt;, each handling a different part of the experience:&lt;/p&gt;

&lt;h3&gt;
  
  
  Phase A: Selfie Analysis (Gemini 3.1 Pro)
&lt;/h3&gt;

&lt;p&gt;When you upload a selfie, &lt;code&gt;gemini-3.1-pro-preview&lt;/code&gt; analyzes your appearance — age, features, vibe — and generates 8 personalized future-self backstories. Each backstory is tied to a different life path: The Visionary (tech founder), The Healer (humanitarian doctor), The Artist, The Explorer, The Sage, The Guardian, The Maverick, The Mystic.&lt;/p&gt;

&lt;p&gt;If you also share something about yourself ("I want to start a company but I'm scared of leaving my job"), every backstory adapts to reference your situation.&lt;/p&gt;

&lt;h3&gt;
  
  
  Phase B: Portrait Generation (Gemini 3.1 Flash Image)
&lt;/h3&gt;

&lt;p&gt;Next, &lt;code&gt;gemini-3.1-flash-image-preview&lt;/code&gt; generates a photorealistic portrait for each future self, using your original selfie as a reference. That's 8 unique AI-generated faces — all variations of you on different paths.&lt;/p&gt;

&lt;p&gt;I hit Gemini's rate limits early on when trying to generate all 8 simultaneously. The fix was a semaphore limiting concurrency to 2 at a time, with exponential backoff and a fallback from photorealistic to artistic style if needed.&lt;/p&gt;

&lt;h3&gt;
  
  
  Live Conversation (Gemini 2.5 Flash Native Audio via ADK)
&lt;/h3&gt;

&lt;p&gt;This is the core experience. When you pick a future self, a WebSocket connection opens, and you enter the &lt;strong&gt;Mirror Room&lt;/strong&gt; — a full-screen conversation where your future self's portrait glows and responds to you.&lt;/p&gt;

&lt;p&gt;Using Google's &lt;strong&gt;Agent Development Kit (ADK)&lt;/strong&gt;, I create a unique agent for each conversation with a dynamically built system prompt:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="n"&gt;agent&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;Agent&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
    &lt;span class="n"&gt;model&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;gemini-2.5-flash-native-audio-preview&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="n"&gt;instruction&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="n"&gt;system_prompt&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;  &lt;span class="c1"&gt;# Built from archetype + analysis + user context
&lt;/span&gt;    &lt;span class="n"&gt;tools&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="n"&gt;ask_reflection_question&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;save_conversation_insight&lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt;
&lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The conversation is &lt;strong&gt;bidirectional&lt;/strong&gt; — audio streams in both directions simultaneously. Your browser captures microphone audio at 16kHz PCM and camera frames at 1 FPS, sends them through the WebSocket, and the agent responds with generated speech. You can interrupt it mid-sentence, just like a real conversation.&lt;/p&gt;

&lt;p&gt;The hardest part wasn't the tech — it was the &lt;strong&gt;prompt&lt;/strong&gt;. Early versions made the future self behave like an interviewer, asking too many questions. I iterated extensively to make it lead with its story, share specific advice, and reference what it sees through the camera. The prompt is the product.&lt;/p&gt;

&lt;h3&gt;
  
  
  Emotion Judge (Gemini 3 Flash)
&lt;/h3&gt;

&lt;p&gt;Here's a detail I'm proud of: the portrait &lt;strong&gt;evolves during the conversation&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;A fourth model — &lt;code&gt;gemini-3-flash-preview&lt;/code&gt; — monitors the conversation's emotional arc. Every few turns, it evaluates whether something meaningful happened: a breakthrough, a fear expressed, a dream shared. If so, it triggers a portrait regeneration that reflects the emotional direction of the conversation.&lt;/p&gt;

&lt;p&gt;The portrait crossfades seamlessly in the browser. It's subtle, but people notice.&lt;/p&gt;

&lt;h2&gt;
  
  
  Architecture
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fkzcj6gxwkhy3qchw8q6u.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fkzcj6gxwkhy3qchw8q6u.jpg" alt="Mirror8 Architecture" width="800" height="713"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The stack:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Frontend:&lt;/strong&gt; Next.js 15 + React 19, deployed on &lt;strong&gt;Cloudflare Pages&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Backend:&lt;/strong&gt; FastAPI + Google ADK, deployed on &lt;strong&gt;Google Cloud Run&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Auth &amp;amp; Storage:&lt;/strong&gt; Supabase (Google OAuth, PostgreSQL, portrait storage)&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Real-time:&lt;/strong&gt; WebSocket with bidirectional PCM audio + camera frames + live transcription&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  The Moment That Made It Real
&lt;/h2&gt;

&lt;p&gt;When someone first enters the Mirror Room, the future self greets them — and references something it sees through the camera. "I can see you sitting at your desk... I remember those late nights." or it notices what you're wearing.&lt;/p&gt;

&lt;p&gt;That moment — when someone realizes &lt;em&gt;it sees me&lt;/em&gt; — is visceral. That's when Mirror8 stops being a demo and starts feeling real.&lt;/p&gt;

&lt;h2&gt;
  
  
  What I Learned
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Gemini's multimodal capabilities are deeper than they appear.&lt;/strong&gt; The Live API's ability to process camera frames in real time creates a level of presence that text-only AI can't match.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;ADK makes complex agent architectures simple.&lt;/strong&gt; Per-session agents with dynamic system prompts, custom tools, and live audio streaming would have been months of work without it.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Prompt engineering is product design.&lt;/strong&gt; The difference between "an AI that asks questions" and "a mentor who shares their journey" came down entirely to the system prompt.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Emotional design matters.&lt;/strong&gt; The technical architecture enables the experience, but the moment that matters is when someone feels genuinely seen by a version of themselves they want to become.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  Try It
&lt;/h2&gt;

&lt;p&gt;Mirror8 is live at &lt;a href="https://mirror8.me" rel="noopener noreferrer"&gt;mirror8.me&lt;/a&gt;. The code is open source at &lt;a href="https://github.com/beingcognitive/mirror8" rel="noopener noreferrer"&gt;github.com/beingcognitive/mirror8&lt;/a&gt;.&lt;/p&gt;




&lt;p&gt;&lt;em&gt;This post was written for my submission to the &lt;a href="https://geminiliveagentchallenge.devpost.com/" rel="noopener noreferrer"&gt;Gemini Live Agent Challenge 2026&lt;/a&gt; on Devpost. Mirror8 uses Google Gemini models and Google Cloud Run.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;#GeminiliveAgentChallenge&lt;/em&gt;&lt;/p&gt;

</description>
      <category>gemini</category>
      <category>ai</category>
      <category>googlecloud</category>
      <category>hackathon</category>
    </item>
  </channel>
</rss>
