ToneLens is an AI-powered web application that helps users understand how their written messages are likely to be perceived before they hit Send.
Instead of simply analyzing sentiment, ToneLens identifies the tone behind a message, highlights the exact phrases influencing that tone, explains how different audiences might interpret it, and suggests a rewritten version that better matches the user's intended communication style.
🚀 https://tonelens-git-main-itselodies-projects.vercel.app/
- 🔍 AI-powered tone analysis
- 🎯 Phrase-level highlighting with explanations
- 👥 Audience perception analysis
- Boss
- Friend
- Professor
- 😊 Emotion detection
- 📊 Tone breakdown
- Confidence
- Passive-Aggression
- Urgency
- ✍️ AI-powered message rewriting
- More Neutral
- Warmer
- More Assertive
- 📱 Fully responsive design
- ⚡ Fast and modern Next.js application
- Next.js 16
- React 19
- TypeScript
- Tailwind CSS 4
- Google Gemini API
- Vercel
src/
│
├── app/
│ ├── api/
│ │ ├── analyze/
│ │ └── rewrite/
│ ├── globals.css
│ ├── layout.tsx
│ └── page.tsx
│
├── components/
│ ├── Header
│ ├── Hero
│ ├── MessageInput
│ ├── AnalyzeButton
│ ├── LoadingState
│ ├── HighlightedMessage
│ ├── ToneBreakdown
│ ├── AudienceCards
│ ├── RewriteSection
│ ├── ErrorCard
│ └── Footer
│
├── hooks/
│
├── services/
│
├── types/
│
└── utils/
git clone https://github.com/itselodie/tonelens.gitcd tonelensnpm installCreate a file named:
.env.local
Add your Gemini API key:
GEMINI_API_KEY=YOUR_GEMINI_API_KEYnpm run devOpen:
http://localhost:3000
- Enter a message.
- ToneLens sends the message securely to the Gemini API.
- The AI analyzes:
- Overall tone
- Emotion
- Confidence
- Passive-aggression
- Urgency
- Important phrases are highlighted with explanations.
- The same message is interpreted from different perspectives:
- Boss
- Friend
- Professor
- Users can generate a rewritten version with a different tone while preserving the original meaning.
- API keys remain server-side.
- Sensitive credentials are managed through environment variables.
- No API keys are exposed to the client.
- Conversation thread analysis
- More audience perspectives
- Tone history
- Copy-to-clipboard functionality
- Export analysis as PDF
- Multi-language support
Hira Fatima
GitHub: https://github.com/itselodie
LinkedIn: https://www.linkedin.com/in/itshirafatima
Portfolio: https://hira-portfolio-portfolio.vercel.app/
This project is licensed under the MIT License.
⭐ If you found this project interesting, consider giving it a star!