Spaces:
Sleeping
Sleeping
๐ญ Explainor
Learn anything through the voice of your favorite characters!
Tags: mcp-in-action-track-creative
๐ What is Explainor?
Explainor is an AI agent that takes any topic you want to learn about and explains it through the voice of fun characters! Choose from 6 unique personas:
| Persona | Style |
|---|---|
| ๐ถ 5-Year-Old | Simple words, excited, curious questions |
| ๐จโ๐ณ Gordon Ramsay | Intense, food metaphors, "It's RAW!" |
| ๐ดโโ ๏ธ Pirate | "Arrr!", treasure metaphors, swashbuckling |
| ๐ญ Shakespeare | Dramatic, old English, theatrical |
| ๐ Surfer Dude | "Brooo", chill vibes, wave metaphors |
| ๐ง Yoda | Inverted syntax, wise, Force references |
๐ฌ Demo
[Demo Video Placeholder]
๐ ๏ธ How It Works
- Enter a topic - Anything from "Quantum Computing" to "How do volcanoes work?"
- Choose a persona - Pick your favorite character
- Choose your audience - Who are you explaining to?
- Watch the magic - The AI agent:
- ๐ Researches your topic using web search
- ๐ Extracts key facts from sources
- ๐ญ Transforms the explanation into the character's voice
- ๐ Reads it aloud with a matching voice!
๐ค Who's Listening?
Make the explanation even more tailored by choosing your audience:
| Audience | Effect |
|---|---|
| ๐ค Just me | Standard explanation |
| ๐ต My confused grandmother | Extra simple, patient |
| ๐ค A skeptical robot | Logical, evidence-based |
| ๐ฝ An alien visiting Earth | Explain Earth concepts |
| ๐ง A zombie | Very short, simple words |
| ๐ฆ A very smart fox | Clever, quick |
| ๐ A stressed CEO | Bottom-line focused |
| ๐ฎ A distracted gamer | Keep it engaging |
๐ MCP Server Integration
This app is a real MCP server! When running, it exposes its functionality as tools that other AI agents can call via the Model Context Protocol.
MCP Endpoint: http://localhost:7860/gradio_api/mcp/
This means:
- Other AI agents can use Explainor as a tool
- Enables agent-to-agent communication
- Part of the growing MCP ecosystem
๐ Tech Stack
- MCP: Model Context Protocol - App exposes itself as an MCP server
- LLM: Nebius AI - Llama 3.3 70B for intelligent explanations
- TTS: ElevenLabs - Realistic voice synthesis with character-matched voices
- Web Search: DuckDuckGo API for topic research
- Frontend: Gradio with MCP integration
- Deployment: Modal - Serverless infrastructure
๐ป Local Development
Prerequisites
- Python 3.11+
- Nebius API key
- ElevenLabs API key
Setup
# Clone the repository
git clone https://huggingface.co/spaces/MCP-1st-Birthday/explainor
# Install dependencies
pip install -r requirements.txt
# Set up environment variables
cp .env.example .env
# Edit .env with your API keys
# Run locally
python app.py
Environment Variables
NEBIUS_API_KEY=your_nebius_api_key_here
ELEVENLABS_API_KEY=your_elevenlabs_api_key_here
๐ Deployment
Modal Deployment
# Set up Modal secrets
modal secret create nebius-api-key NEBIUS_API_KEY=your_key
modal secret create elevenlabs-api-key ELEVENLABS_API_KEY=your_key
# Deploy
modal deploy modal_app.py
Hugging Face Spaces
This app is designed to run on Hugging Face Spaces with the Gradio SDK.
๐ Project Structure
explainor/
โโโ app.py # Main Gradio application
โโโ modal_app.py # Modal deployment config
โโโ requirements.txt # Python dependencies
โโโ src/
โ โโโ __init__.py
โ โโโ personas.py # Persona definitions & voice mappings
โ โโโ agent.py # Agent logic & web search
โ โโโ tts.py # ElevenLabs integration
โโโ README.md
๐ Hackathon Submission
- Event: MCP's 1st Birthday Hackathon
- Track: MCP in Action (Track 2)
- Category: Creative
- Team: kaiser-data
- Sponsor Integration: ElevenLabs for text-to-speech
๐ License
MIT License - Feel free to use and modify!
Made with โค๏ธ for MCP's 1st Birthday Hackathon