DEV Community

Cover image for 🎭 What if fictional characters could actually text you back?
Adil Khan
Adil Khan

Posted on

🎭 What if fictional characters could actually text you back?

DEV Weekend Challenge: Passion Edition Submission

This is a submission for Weekend Challenge: Passion Edition

What I Built

Think of a character from a movie or show you loved. Not the show just them.

How long ago did you watch it? What's the one line, the one expression, the one moment you still remember?

After finishing a great series, I always wished I could keep talking to the characters instead of waiting months (or years) for the next season.

So I built the next best thing.

FandomDial is a WhatsApp-inspired AI chat application where you don't just read about a character you message them, hear their voice, and watch them remember your previous conversations.

Rather than recreating existing fictional characters, I designed three completely original personalities, each with their own conversational style, humour, and voice.

🟢 Gullu

Quiet. Dry. Brutally honest.

He barely talks but when he does, every sentence lands.

🔵 Sohail

The childhood friend who'll help you with almost anything...

...except lending you money.

Every conversation turns into an interrogation about your life choices.

🟠 Zaid

Endlessly confident.

King of jugaad.

Every disaster somehow has a shortcut solution even if it absolutely shouldn't.

Every character remembers previous conversations, generates responses with Google Gemini, and occasionally just like a real friend sends an unexpected voice note generated with ElevenLabs.

The goal wasn't to build another chatbot.

It was to build characters people would actually enjoy talking to.


Demo

🌐 Live Demo

https://fandomdial.onrender.com

Try this first:

Open Gullu, then send him something slightly rude like:

"Why are you like this?"

His reply usually tells people everything they need to know about the project.

Note: The project is hosted on Render's free tier. If the application has been idle, the first request may take around 30–50 seconds while the server wakes up.

Screenshot

Screenshot of FandomDial showing a WhatsApp-style conversation with the AI character Gullu, including text messages and voice note playback.


Code

GitHub logo FanoyG / fandomdial-

WhatsApp-inspired AI chat platform with original characters, voice notes, conversation memory, Google Gemini, ElevenLabs, FastAPI, and Hexagonal Architecture.

FandomDial Logo

FandomDial

A voice for every character worth talking to.

Chat with original AI characters that remember conversations, express unique personalities, and occasionally reply with realistic voice notes

🚀 Built for the DEV Weekend Challenge — Passion Edition (2026)


🎥 Demo

Live Demo: https://fandomdial.onrender.com

Note: hosted on Render's free tier, which sleeps after ~15 minutes of inactivity. First load may take 30-50 seconds to wake up.

FandomDial Demo

What you're seeing

The screenshot below demonstrates a live conversation with Gullu, one of FandomDial's original AI characters.

Responses are generated using Google Gemini, synthesized with ElevenLabs when voice is triggered, and delivered through a WhatsApp-inspired interface that preserves conversational memory.


Table of Contents


✨ Overview

FandomDial is a WhatsApp-inspired conversational platform where users interact with original AI characters, each designed with a unique…




The repository includes:

  • Complete FastAPI backend
  • WhatsApp-style frontend
  • Hexagonal Architecture
  • Full engineering documentation
  • Deployment instructions
  • Detailed README explaining every architectural decision

How I Built It

From the beginning, I wanted this to feel like a real software project rather than a weekend prompt wrapper.

The application follows Hexagonal Architecture (Ports & Adapters) with SOLID principles, allowing the business logic to remain independent from AI providers, voice engines, and storage implementations.

The core services communicate only through interfaces (AIProvider, VoiceProvider, and SessionStore), making providers replaceable without touching the domain logic.

Tech Stack

  • FastAPI
  • Python
  • Google Gemini
  • ElevenLabs
  • HTML
  • CSS
  • JavaScript

🧠 Google Gemini

Google Gemini powers every conversation.

Each character has a carefully designed behavioral prompt built around a different conversational mechanism instead of simply "being funny."

  • Gullu uses deadpan honesty.
  • Sohail constantly questions your decisions.
  • Zaid solves everything with reckless confidence.

One challenge was conversation growth.

Passing the entire message history to the LLM eventually becomes slow and expensive.

To solve that, I built a Context Builder that summarizes older conversations while preserving recent exchanges, keeping token usage predictable without losing conversational memory.

During development I also encountered real 429 quota errors, which led me to implement an ordered fallback chain so conversations continue even when a preferred model becomes temporarily unavailable.


🎙️ ElevenLabs

ElevenLabs powers all voice responses.

Every character has a matched voice, and about 20% of replies are automatically delivered as voice notes instead of plain text.

That randomness isn't arbitrary.

A dedicated VoiceTriggerDecider controls when voice should be generated.

Before using it in the application, I validated the probability over 2,000 simulated message iterations to ensure the distribution matched the intended behavior.

Another unexpected challenge appeared when the ElevenLabs API returned HTTP 402 errors.

It turned out that community Voice Library voices aren't accessible through the free-tier API.

Instead of hardcoding voice IDs, I queried the authenticated account for available voices and dynamically assigned compatible ones to each character.


⚡ Performance & Reliability

Several engineering problems appeared once the application started feeling "real."

To solve them, I implemented:

  • Request-ticket playback, preventing older voice requests from interrupting newer ones.
  • Local audio caching, so replaying the same response never consumes another API call.
  • Latency masking, using lightweight filler audio only when generation exceeds a short threshold, making the application feel responsive even while AI responses are still being generated.

🚧 Design Trade-offs

Some production features were intentionally left out to keep the project achievable within a weekend.

Current limitations include:

  • Conversation sessions are stored in memory and reset when the server restarts.
  • Voice quality is limited by the free ElevenLabs tier.
  • Real-time voice calls were intentionally scoped out in favor of asynchronous voice notes.

Because storage, AI providers, and voice engines are all abstracted behind interfaces, these improvements can be added later without changing the application's core architecture.


What I Learned

Building the interface was actually the easy part.

Making conversations feel believable turned out to be much harder.

The biggest challenges weren't writing prompts they were:

  • managing conversation context,
  • controlling latency,
  • handling API failures gracefully,
  • preventing overlapping voice playback,
  • and making voice notes feel spontaneous without exhausting API quotas.

Those engineering decisions ended up shaping the architecture far more than any single feature.


Prize Categories

🏆 Best Use of Google AI

Google Gemini powers all dialogue generation, contextual memory, model fallback handling, and personality-driven conversations.

🏆 Best Use of ElevenLabs

ElevenLabs provides realistic voice synthesis, smart voice-note generation, caching, and race-condition-safe playback.


Final Thoughts

This started as a weekend hackathon project.

By Sunday night, it had become something much bigger.

I no longer see FandomDial as just an AI chat application.

I see it as the beginning of a platform where writers could publish original AI-powered characters, let readers interact with them, and discover which personalities people genuinely connect with before investing months writing a book, game, or screenplay.

Whether it remains a hackathon project or grows into something more, building it reminded me that memorable software isn't created by APIs alone.

It's created by thoughtful engineering and by designing experiences people actually want to come back to.

Thanks for reading. ❤️

Top comments (0)