AI-powered Google Calendar analysis tool for leaders and executives to gain insights into their time management.
TimeSherpa empowers executives and leaders to understand and optimize their time allocation by providing actionable insights based on their Google Calendar data. Using Google's Gemini AI, it analyzes past calendar events to categorize time spent and provides proactive suggestions for schedule optimization.
- π Google OAuth Integration - Secure authentication with Google Calendar access
- π AI-Powered Analysis - Leverages Google Gemini AI to categorize and analyze calendar events
- π Visual Analytics - Interactive charts showing time distribution across categories
- π‘ Smart Insights - Personalized recommendations based on calendar patterns
- π― Focus Time Tracking - Identifies and tracks dedicated focus/deep work time
- π₯ Collaboration Analytics - Shows top collaborators and meeting patterns
- π± Responsive Design - Works seamlessly across desktop and mobile devices
- React 18 with TypeScript
- Vite for fast development and building
- Tailwind CSS for styling
- Recharts for data visualization
- React Router for navigation
- Node.js with Express.js
- TypeScript for type safety
- Passport.js for OAuth authentication
- Google APIs (Calendar, OAuth2)
- Google Gemini AI for intelligent analysis
- Jest for unit testing
- React Testing Library for component testing
- ESLint & TypeScript for code quality
Before you begin, ensure you have:
- Node.js (v18 or higher)
- npm or yarn
- Google Cloud Project with:
- Google Calendar API enabled
- OAuth 2.0 credentials configured
- Google Gemini API key
git clone https://github.com/yourusername/time-sherpa.git
cd time-sherpacd app
./scripts/setup.shOr manually install dependencies:
cd app
npm install- Go to Google Cloud Console
- Create or select a project
- Enable the Google Calendar API
- Create OAuth 2.0 credentials:
- Application type: Web application
- Authorized redirect URI:
http://localhost:3001/api/auth/google/callback
- Download the credentials as
client_secret.jsonand place it in the/appdirectory
Create a .env file in the /app directory:
# Server Configuration
NODE_ENV=development
PORT=3001
SESSION_SECRET=your-session-secret-key-here
# Google Gemini AI
GEMINI_API_KEY=your-gemini-api-key-here
# Client URL (for production)
CLIENT_URL=http://localhost:3000Get your Gemini API key from Google AI Studio.
npm run devThis starts:
- Frontend: http://localhost:3000
- Backend API: http://localhost:3001
time-sherpa/
βββ app/ # Main application directory
β βββ src/
β β βββ client/ # React frontend
β β β βββ components/ # Reusable UI components
β β β βββ pages/ # Page components
β β β βββ hooks/ # Custom React hooks
β β β βββ App.tsx # Main app component
β β βββ server/ # Express backend
β β β βββ routes/ # API routes
β β β βββ services/ # Business logic
β β β βββ middleware/ # Express middleware
β β βββ server.ts # Server entry point
β βββ public/ # Static assets
β βββ package.json # Dependencies
β βββ tsconfig.json # TypeScript config
βββ docs/ # Documentation
βββ project-guide.md # Product requirements
Run the test suite:
# Run all tests
npm test
# Run tests in watch mode
npm run test:watch
# Generate coverage report
npm run test:coveragenpm run dev- Start both frontend and backend in development modenpm run build- Build for productionnpm start- Run production buildnpm test- Run testsnpm run lint- Run ESLintnpm run type-check- Run TypeScript type checking
The project uses:
- ESLint for code linting
- Prettier for code formatting (recommended)
- TypeScript strict mode
- Create a feature branch:
git checkout -b feature/your-feature-name - Make your changes
- Run tests:
npm test - Commit:
git commit -m "feat: add new feature" - Push:
git push origin feature/your-feature-name - Create a Pull Request
The project uses GitHub Actions for continuous integration and deployment.
Every push and pull request triggers:
- Multi-version testing - Tests run on Node.js 18.x and 20.x
- Type checking - TypeScript compilation checks
- Linting - ESLint code quality checks
- Unit tests - Jest test suite with coverage reporting
- Security audit - npm audit for vulnerability scanning
- Build verification - Production build testing
Additional PR-specific checks:
- PR size analysis and labeling
- Conventional commit title verification
- Branch naming convention checks
- Sensitive file detection
.github/workflows/ci.yml- Main CI pipeline.github/workflows/pr-checks.yml- Pull request validations
npm run buildThis creates:
- Optimized frontend bundle in
/app/dist/client - Compiled backend code in
/app/dist
Set these environment variables in your production environment:
NODE_ENV=productionPORT=3001SESSION_SECRET=<secure-random-string>GEMINI_API_KEY=<your-production-key>CLIENT_URL=<your-production-url>
We welcome contributions! Please see our contributing guidelines:
- Fork the repository
- Create your feature branch
- Follow the code style guidelines
- Write tests for new features
- Ensure all tests pass
- Submit a pull request
- π Additional visualization types
- π Internationalization support
- π± Mobile app development
- π Integration with other calendar services
- π¨ UI/UX improvements
- π Advanced analytics features
This project is licensed under the MIT License - see the LICENSE file for details.
- Built with Google Calendar API and Gemini AI
- UI inspired by modern productivity tools
- Color scheme:
#FF5B04,#075056,#233038,#FDF6E3,#D3DBDD,#F4D47C
- Create an issue for bug reports or feature requests
- Check existing issues before creating new ones
- For security vulnerabilities, please email directly
Made with β€οΈ by the Doug Rathbone