Skip to content

DhruvP2205/Reframe

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

5 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

๐Ÿง  REFRAME

AI-powered communication safety for healthier digital conversations

REFRAME is a functional, startup-grade prototype built for MINDCODE 2026 (HealthTech Hackathon).
It helps people rewrite emotionally risky messages before sending, reducing escalation, stress, and misunderstanding across workplace and online messaging platforms.

Reframe Mindcode Banner

MIT License Build Hackathon Prototype OpenAI Gemini Fallback Next.js PRs Welcome


๐ŸŒ The Communication Problem

Work and online communities now run on fast text interactions:

  • Slack in deadline crunches
  • Discord in high-emotion discussion channels
  • Customer support tools under response-time pressure

In these moments, a message that is technically correct can still feel harsh, dismissive, or hostile.
Tone misunderstanding creates emotional strain and professional risk:

  • ๐Ÿ˜Ÿ anxiety from overthinking every message
  • โšก conflict from accidental escalation
  • ๐Ÿง  cognitive load from constant emotional self-editing
  • ๐Ÿ”ฅ burnout from repeated communication friction

REFRAMEโ€™s Core Intervention

REFRAME helps before send-time, not after damage. It suggests healthier wording that:

  • preserves intent
  • reduces emotional intensity
  • improves clarity and social safety

Small daily improvements in language compound into healthier team dynamics and lower stress over time.


๐Ÿง  Why This Matters

Real-world pressure scenarios

  • Customer support pressure: agents responding quickly may write in ways perceived as cold or dismissive.
  • Deadline conflicts: urgency can produce abrupt language that escalates team friction.
  • Tone ambiguity: text lacks vocal cues, so intent is often misinterpreted.

These micro-escalations compound into larger outcomes: team distrust, emotional fatigue, and professional risk.

Preventive Wellbeing Layer

REFRAME does not replace therapy, human empathy, or judgment.
It adds a practical, always-available layer of communication support where stress actually happens: everyday messaging interfaces.


โš™๏ธ How It Works

End-to-end flow

  1. โœ๏ธ User drafts a message in a demo communication interface.
  2. ๐Ÿ” Input is sanitized and processed through secure server-side API routes.
  3. ๐Ÿงญ AI detects emotional escalation risk (low, medium, high).
  4. ๐Ÿช„ REFRAME generates tone-safe alternatives.
  5. ๐Ÿ“ˆ Stress Reduction Meter reflects potential emotional impact improvement.
  6. ๐Ÿ”Ž Transparency features explain why suggestions are shown.
  7. โœ… User chooses whether to keep original or send a reframed version.

Explainability-first behavior

  • Suggestions are assistive, not forced.
  • Users remain in full control.
  • UI communicates both confidence and limitations.

โœจ Product Features

Communication Intelligence

  • ๐Ÿช„ Inline tone rewriting directly in chat flow
  • ๐Ÿšจ Real-time escalation detection for risky language
  • ๐Ÿง  Context-aware reframing that preserves original intent

Multi-Environment Demo Hub

  • ๐Ÿ’ผ Slack-style workspace simulation
  • ๐Ÿ›ฐ๏ธ Discord-style community simulation
  • ๐ŸŽง Customer support portal simulation
  • ๐Ÿ“ฑ Mobile Figma prototype entrypoint

Responsible AI Safeguards

  • ๐Ÿ”’ Server-only AI execution
  • ๐Ÿงฑ Prompt injection defenses
  • ๐Ÿงผ Input sanitization and controlled formatting
  • โ›” Anonymous usage caps and abuse throttling
  • ๐Ÿ“œ Transparent non-clinical AI framing

AI Provider Strategy

  • โœ… OpenAI integration active in current runtime
  • ๐Ÿงญ Gemini fallback planned as roadmap failover

๐Ÿ’š Mental Health Impact

REFRAME is designed around preventative wellbeing, not treatment.

Potential impact areas:

  • Reduced psychological stress: less emotional reactivity in high-pressure chat moments.
  • Improved communication confidence: users learn safer phrasing patterns over time.
  • Healthier workplace dynamics: fewer misunderstandings and lower escalation frequency.
  • Lower cognitive load: AI-assisted phrasing reduces overthinking before sending.
  • Escalation prevention: supports calmer communication loops early, before conflict deepens.

By improving everyday language habits, REFRAME aims to help teams and communities communicate with more emotional safety and resilience.


๐ŸŽฎ Demo Experience

Explore REFRAME in realistic communication contexts:

  • Web demos: interactive Slack-style, Discord-style, and support-style environments
  • Mobile demo: opens an external Figma prototype experience

๐Ÿ”— Live Demo Links

What reviewers can test

  • Emotional risk classification output
  • Suggested rewrites with intent preservation
  • Stress meter response to wording changes
  • Transparency panel explanations

๐Ÿ”’ Security & Ethical Design

REFRAME follows privacy-first health-technology principles:

  • ๐Ÿ” API keys remain server-side only
  • ๐Ÿšซ No client-side key leakage
  • ๐Ÿงฑ Prompt injection resistance via sanitization and controlled prompts
  • ๐Ÿšฆ Rate limiting and cooldown safeguards
  • ๐Ÿ‘ค Anonymous usage restriction without mandatory sign-in
  • ๐Ÿงพ Transparent AI boundaries (assistive, non-diagnostic)

๐Ÿš€ Getting Started

1) Clone

git clone https://github.com/DhruvP2205/Reframe.git
cd Reframe

2) Install dependencies

npm install

3) Configure environment variables

cp .env.example .env.local

.env.local:

OPENAI_API_KEY=your_openai_api_key
GEMINI_API_KEY=your_gemini_api_key_optional

.env.example currently includes OpenAI by default. Gemini is optional and roadmap-oriented.

4) Start development server

npm run dev

Open: http://localhost:3000

5) Validate

npm run lint
npm run build

๐Ÿ—‚๏ธ Project Structure

reframe/
โ”œโ”€ src/
โ”‚  โ”œโ”€ app/
โ”‚  โ”‚  โ”œโ”€ api/analyze/         # Secure AI analysis endpoint
โ”‚  โ”‚  โ”œโ”€ demo/                # Demo hub + simulation pages
โ”‚  โ”‚  โ”œโ”€ about/               # Team / mission page
โ”‚  โ”‚  โ”œโ”€ settings/            # User preferences + controls
โ”‚  โ”‚  โ”œโ”€ layout.tsx
โ”‚  โ”‚  โ””โ”€ page.tsx
โ”‚  โ”œโ”€ components/             # UI components (chat, carousel, meters)
โ”‚  โ”œโ”€ data/                   # Demo conversation seed data
โ”‚  โ”œโ”€ lib/                    # Shared helpers, prompts, env utilities
โ”‚  โ”œโ”€ server/                 # Security, sanitization, rate limit logic
โ”‚  โ””โ”€ types/                  # Shared type contracts
โ”œโ”€ public/
โ”œโ”€ LICENSE
โ””โ”€ README.md

๐Ÿ“Š Usage Limits

To keep prototype behavior stable and fair:

  • Rate limit per IP
  • Cooldown between rapid requests
  • Duplicate-message rejection
  • Anonymous usage caps per visitor/session

These controls support both safety and infrastructure reliability.


โš ๏ธ Known Limitations

  • Prototype-first scope; not yet enterprise production software
  • AI output can be imperfect and requires human review
  • No emergency mental health escalation protocol
  • Gemini fallback is not active in current runtime (roadmap only)

๐Ÿ”ญ Future Vision

  • ๐Ÿ” Full OpenAI โ†” Gemini automatic failover
  • ๐ŸŽฏ Personal tone profiles by team role/context
  • ๐Ÿ“ˆ Communication health analytics dashboards
  • ๐ŸŒ Multilingual reframing support
  • ๐Ÿงฉ Native integrations for Slack/Discord/helpdesk platforms

๐Ÿค Contributing

Contributions are welcome and appreciated.

  1. Fork the repository
  2. Create a feature branch (feat/your-feature-name)
  3. Commit with clear, focused messages
  4. Run npm run lint and npm run build
  5. Open a PR with context, rationale, and screenshots for UI changes

Please align contributions with REFRAMEโ€™s privacy-first, ethical-AI mission.


๐Ÿ“„ License

This project is licensed under the MIT License.

See LICENSE for full terms.


๐Ÿ‘จโ€๐Ÿ’ป Developer Credits

Built by beTheNoob for MINDCODE 2026.


๐Ÿซถ REFRAME Mission

Reduce communication-driven mental stress through thoughtful, transparent, and responsible AI assistance.

About

REFRAME is an AI-powered communication assistant that helps prevent emotional escalation by rewriting messages into calmer, more constructive tones, reducing stress and improving digital wellbeing ๐Ÿ’ฌ๐Ÿง โœจ. It integrates into chat to promote healthier conversations, clearer intent, and more mindful communication in everyday digital interactions๐Ÿ’™.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors