Less Scrolling. More Living.
A personalized event recommendation engine that uses psychology-backed assessments to match users with meaningful real-world activities and communities.
- Overview
- Features
- Tech Stack
- Project Structure
- Getting Started
- Key Documentation
- Recent Updates
- Development
Empower Social is a web application that helps people find events, activities, and communities that match their personality, motivations, and social needsβnot just their interests. By combining validated psychological assessments (TIPI for Big Five traits, Situational Motivation Scale) with AI-powered recommendation generation, Empower provides personalized suggestions that truly resonate.
-
User completes a 7-page intake survey (~5 minutes)
- Demographics and location
- Personality assessment (Big Five traits)
- Social connection metrics
- Core motivations
- Interest categories and specific activities
- Activity preferences and affinity groups
-
Backend processes and calculates scores
- Personality dimensions (Extraversion, Conscientiousness, Openness)
- Social need scoring (prioritizes community for isolated users)
- Motivation factors (Intrinsic, Social, Achievement)
-
AI generates personalized recommendations
- GPT-4-turbo creates conceptual activity recommendations
- Recommendations consider personality fit, social needs, motivations, and practical constraints
- Cached for performance, regenerated on profile updates
-
User views and manages recommendations
- Card-based display with personalized explanations
- Ability to regenerate recommendations
- Edit profile/survey to update preferences
- Comprehensive intake survey (7 pages, ~5 minutes)
- Psychology-backed assessments
- TIPI (Ten-Item Personality Inventory) for Big Five traits
- Situational Motivation Scale for core motivations
- Smart score calculation (automated via Airtable formulas)
- AI-powered recommendations (GPT-4-turbo with personalized prompts)
- User authentication (email-based login for returning users)
- Profile editing (update survey responses and regenerate recommendations)
- Recommendation regeneration (bypasses cache for fresh results)
- Responsive design (mobile-friendly UI)
- Airtable integration (cloud-based database)
- Users table
- Survey_Responses table
- Calculated_Scores table (formula fields)
- GPT_Prompts table (audit trail)
- Data validation (frontend and backend)
- Empty field handling (proper cleanup for optional fields)
- Multi-select field support (interests, affinity groups)
- ESLint configuration (code style enforcement)
- Pre-commit hooks (Husky for linting before commits)
- Error handling (comprehensive try-catch blocks)
- Logging (structured error and info logs)
- Vanilla HTML/CSS/JavaScript (no frameworks)
- Responsive CSS (mobile-first design)
- Modern typography (Montserrat + DM Sans)
- Node.js (v14+)
- Express.js (RESTful API)
- Airtable API (database)
- OpenAI API (GPT-4-turbo for recommendations)
- Airtable (cloud-based relational database)
- Linked records for relationships
- Formula fields for automatic calculations
- Lookup fields for data aggregation
- AWS Amplify (hosting and auto-deployment)
- GitHub (version control and CI/CD)
- ESLint (code linting)
- Husky (Git hooks)
- npm (package management)
- Playwright (end-to-end testing)
Empower-Social/
βββ backend/
β βββ routes/
β β βββ login.js # User authentication
β β βββ recommendations.js # Recommendation endpoints
β β βββ survey.js # Survey submission/retrieval
β βββ services/
β β βββ airtable.js # Airtable database operations
β β βββ openai-conceptual.js # GPT prompt generation
β β βββ recommendations-v2.js # Recommendation generation logic
β β βββ events.js # Event-related utilities
β βββ scripts/ # Utility scripts
β βββ server.js # Express server entry point
β
βββ frontend/
β βββ assets/
β β βββ css/ # Stylesheets
β β βββ js/
β β βββ recommendations.js # Frontend recommendation logic
β βββ profile/
β β βββ login.html # Login page
β β βββ recommendations.html # Recommendations display
β βββ survey/
β β βββ intake-survey.html # Main survey form
β βββ config.js # Frontend configuration
β βββ index.html # Landing page
β
βββ docs/
β βββ SURVEY_FIELDS_REFERENCE.md # Complete survey field documentation
β βββ GPT_PROMPT_TEMPLATE.md # GPT prompt structure
β βββ AIRTABLE_SETUP_GUIDE.md # Database setup instructions
β βββ API_SETUP_GUIDE.md # API key configuration
β βββ AMPLIFY_SETUP.md # Deployment guide
β βββ EMPOWER_SYSTEM_GUIDE.md # System overview
β βββ RECOMMENDATION_SYSTEM_DEVELOPMENT.md # Development documentation
β
βββ tests/
β βββ config.spec.js # Configuration tests
β βββ welcome-page.spec.js # Landing page tests
β βββ survey-flow.spec.js # Survey flow tests
β βββ recommendations-page.spec.js # Recommendations tests
β βββ login-flow.spec.js # Login tests
β βββ integration-flow.spec.js # End-to-end tests
β βββ accessibility.spec.js # Accessibility tests
β βββ README.md # Test documentation
β
βββ package.json # Root package.json (ESLint, Husky, Playwright)
βββ playwright.config.js # Playwright test configuration
βββ .eslintrc.json # ESLint configuration
βββ .husky/ # Git hooks
βββ README.md # This file
- Node.js (v14 or higher)
- npm (comes with Node.js)
- Airtable account and API key
- OpenAI API key
- AWS Amplify account (for deployment)
-
Clone the repository
git clone https://github.com/empowersocialapp/Empower-Social-2.git cd Empower-Social -
Install backend dependencies
cd backend npm install -
Install root dependencies (for ESLint/Husky)
cd .. npm install -
Set up environment variables
Create
backend/.envfile:AIRTABLE_API_KEY=your_airtable_api_key AIRTABLE_BASE_ID=your_base_id OPENAI_API_KEY=your_openai_api_key PORT=3000
-
Set up Airtable database
See
docs/AIRTABLE_SETUP_GUIDE.mdfor detailed instructions on:- Creating tables (Users, Survey_Responses, Calculated_Scores, GPT_Prompts)
- Setting up fields and formulas
- Configuring linked records
-
Start the backend server
cd backend npm start -
Open the frontend
Open
frontend/index.htmlin your browser, or serve it via a local server:# Using Python cd frontend python -m http.server 8000 # Or using Node.js http-server npx http-server frontend -p 8000
- Frontend API endpoint: Edit
frontend/config.jsto point to your backend URL - Backend CORS: Configure in
backend/server.jsif needed - Airtable field names: Must match exactly as specified in
docs/SURVEY_FIELDS_REFERENCE.md
- Survey Fields Reference - Complete technical specification of all survey fields, calculations, and data handling
- GPT Prompt Template - Structure and examples of GPT prompts used for recommendations
- Airtable Setup Guide - Step-by-step database setup instructions
- API Setup Guide - Configuration for Airtable and OpenAI APIs
- Amplify Setup - Deployment instructions for AWS Amplify
- Empower System Guide - High-level overview of how the system works
- Cursor Context - Project context for AI assistants
- Backend Verification - Backend testing and verification
- β Added Playwright test suite - Comprehensive end-to-end testing with 108 tests across 3 browsers
- β
Added configuration tests - Tests for
config.jsenvironment detection and API setup - β Added descriptive file headers - All code files now include comprehensive headers documenting purpose, inputs, outputs, and dependencies
- β Improved code documentation - Enhanced inline comments throughout codebase
- β Updated documentation - README and docs updated to reflect current project state
- β Fixed recommendation caching - Recommendations now properly regenerate when users edit their profiles
- β Fixed data saving issues - Close friends count, free time, travel distance, and affinity selections now save correctly
- β Fixed interests auto-select - Interests no longer reset to all selected when editing survey
- β Improved navigation - Standardized all navigation paths to use absolute paths for AWS Amplify compatibility
- β
Fixed JavaScript errors - Converted inline
onclickhandlers to event listeners, fixed syntax errors - β Added code quality tools - ESLint configuration and pre-commit hooks (Husky)
- β Created comprehensive documentation - Survey fields reference document for technical specifications
- β Added recommendation feedback system - Users can evaluate recommendations (Interested/Maybe/Not for Me)
- β Added evaluation summary - Summary appears after all recommendations are evaluated
- Cache invalidation: Recommendations now bypass cache on regenerate/edit
- Empty field handling: Proper cleanup of empty strings and arrays
- Multi-select preservation: Empty arrays preserved for Airtable multi-select fields
- Event listener migration: All buttons now use event listeners instead of inline handlers
- Path standardization: All navigation uses absolute paths (
/path/to/file.html)
- Indentation: 2 spaces
- Semicolons: Required
- Quotes: Single quotes preferred
- Trailing spaces: Not allowed
- ESLint: Run
npm run lintto check,npm run lint:fixto auto-fix
- Pre-commit hook runs ESLint automatically
- Commit messages should be descriptive
- Push to
mainbranch triggers AWS Amplify deployment
Automated Tests (Playwright):
# Run all tests
npm test
# Run tests in UI mode (interactive)
npm run test:ui
# Run specific test file
npx playwright test tests/config.spec.jsTest Coverage:
- β
Configuration tests (
config.spec.js) - API configuration and environment detection - β
Welcome page tests (
welcome-page.spec.js) - Landing page functionality - β
Survey flow tests (
survey-flow.spec.js) - Complete survey journey - β
Recommendations tests (
recommendations-page.spec.js) - Recommendation display and interaction - β
Login flow tests (
login-flow.spec.js) - User authentication - β
Integration tests (
integration-flow.spec.js) - End-to-end user journeys - β
Accessibility tests (
accessibility.spec.js) - WCAG compliance
Manual Testing:
- Test survey submission: Fill out all 7 pages and verify data saves correctly
- Test recommendation generation: Verify recommendations appear after submission
- Test profile editing: Edit survey and verify recommendations regenerate
- Test login: Use username to login as returning user
- Test empty fields: Submit survey with optional fields empty
- Test feedback buttons: Evaluate recommendations (Interested/Maybe/Not for Me)
- Backend logs: Check
backend.logor console output - Frontend console: Check browser developer console for JavaScript errors
- Airtable: Verify records are created correctly in Airtable UI
- API responses: Check network tab in browser dev tools
See LICENSE file for details.
This is a private repository. For questions or issues, contact the project maintainer.
For technical questions or issues:
- Check the documentation in the
docs/folder - Review
docs/SURVEY_FIELDS_REFERENCE.mdfor data handling questions - Check
docs/GPT_PROMPT_TEMPLATE.mdfor recommendation generation questions
Last Updated: December 2025
Version: 1.1.0