MindGraph is an intelligent scheduling and time management system that uses AI to optimize task management based on individual preferences, workload perception, time constraints, and task interdependencies. The system learns from user behavior patterns to create more effective and personalized schedules.
- Intelligent Task Management: Create, manage, and track tasks with AI-powered scheduling suggestions
- Natural Language Interface: Interact with the system using a chatbot to create tasks, schedule events, and query free time
- Personalized Scheduling: AI learns from user preferences and behavior to optimize schedules
- Task Dependency Management: Handle complex task relationships and prerequisites
- Smart Reminders: Intelligent notifications based on urgency, priority, and user context
- Calendar Integration: Comprehensive calendar view with event management
- User Preferences: Customizable settings for work hours, energy levels, and scheduling preferences
- Analytics & Insights: Track productivity patterns and get insights into time usage
- Java 17 with Spring Boot 3.2.0
- Spring Security for authentication and authorization
- Spring Data JPA for data persistence
- PostgreSQL database
- JWT for secure authentication
- Maven for dependency management
- React 18 with functional components and hooks
- Material-UI (MUI) for component library
- React Router for navigation
- Axios for API communication
- React Query for state management and caching
- React Hook Form for form handling
- PostgreSQL 13+ with optimized indexes and triggers
mindgraph/
├── backend/ # Spring Boot backend
│ ├── src/main/java/com/mindgraph/
│ │ ├── entity/ # JPA entities
│ │ ├── repository/ # Data repositories
│ │ ├── service/ # Business logic
│ │ ├── controller/ # REST controllers
│ │ ├── dto/ # Data transfer objects
│ │ └── config/ # Configuration classes
│ ├── src/main/resources/
│ │ ├── application.properties
│ │ └── credentials.properties # API keys (create this file - not in git)
│ └── pom.xml
├── frontend/ # React frontend
│ ├── src/
│ │ ├── components/ # Reusable React components
│ │ ├── pages/ # Page components
│ │ ├── services/ # API service layer
│ │ ├── hooks/ # Custom React hooks
│ │ └── utils/ # Utility functions
│ ├── public/
│ └── package.json
└── database/
└── schema.sql # Database schema and sample data
- Java 17 or higher
- Node.js 16 or higher
- PostgreSQL 13 or higher
- Maven 3.6 or higher
- Install PostgreSQL and create a database:
CREATE DATABASE mindgraph;
CREATE USER mindgraph_user WITH PASSWORD 'your_password';
GRANT ALL PRIVILEGES ON DATABASE mindgraph TO mindgraph_user;- Run the schema script:
psql -U mindgraph_user -d mindgraph -f database/schema.sqlIf you get the following errors
ERROR: permission denied for schema publicThen run login as postgres
psql -U postgres -d mindgraphand run below three commands:
GRANT USAGE ON SCHEMA public TO mindgraph_user;
GRANT CREATE ON SCHEMA public TO mindgraph_user;
ALTER DEFAULT PRIVILEGES IN SCHEMA public GRANT ALL ON TABLES TO mindgraph_user;Exit by:
\qNow you should be able to run the schema.sql
The application uses Google's Gemini AI for the chatbot functionality. You need to obtain an API key to enable AI features.
- Visit Google AI Studio
- Sign in with your Google account
- Click "Get API Key" in the top right corner
- Create a new project or select an existing one
- Generate a new API key
- Copy the API key (it will look like:
AIzaSyC...)
- Navigate to the backend resources directory:
cd backend/src/main/resources/- Create a
credentials.propertiesfile:
touch credentials.properties- Add your API key to the
credentials.propertiesfile:
# Google Gemini API Key
gemini.api.key=AIzaSyC_your_actual_api_key_here⚠️ Never commit your API key to Git - Thecredentials.propertiesfile is already added to.gitignore- 🔒 Keep your API key secret - Don't share it publicly or in screenshots
- 📝 Use different keys for different environments (development, staging, production)
- 💰 Monitor your API usage - The free tier has usage limits
Option A: Environment Variable
# Set environment variable (Windows PowerShell)
$env:GEMINI_API_KEY="your_api_key_here"
# Then update application.properties to use:
gemini.api.key=${GEMINI_API_KEY:YOUR_GEMINI_API_KEY_HERE}Option B: Command Line Parameter
java -jar target/mindgraph-backend-0.0.1-SNAPSHOT.jar --gemini.api.key=your_api_key_here- If you see "API key not configured" errors, verify your
credentials.propertiesfile exists and contains the correct key - If requests fail, check your API key is valid and has sufficient quota
- The application will show detailed debug logs in the console when processing chatbot messages
- Navigate to the backend directory:
cd backend- Update
src/main/resources/application.propertieswith your database credentials:
spring.datasource.url=jdbc:postgresql://localhost:5432/mindgraph
spring.datasource.username=mindgraph_user
spring.datasource.password=your_password- Run the Spring Boot application:
mvn spring-boot:runThe backend will start on http://localhost:8081 (with context path /api)
- Navigate to the frontend directory:
cd frontend- Install dependencies:
npm install- Start the React development server:
npm startThe frontend will start on http://localhost:3000
POST /api/auth/login- User loginPOST /api/auth/register- User registrationPOST /api/auth/logout- User logout
GET /api/users/profile- Get user profilePUT /api/users/profile- Update user profileGET /api/users/preferences- Get user preferencesPUT /api/users/preferences- Update user preferences
GET /api/tasks- Get user tasksPOST /api/tasks- Create new taskGET /api/tasks/{id}- Get specific taskPUT /api/tasks/{id}- Update taskDELETE /api/tasks/{id}- Delete taskPATCH /api/tasks/{id}/complete- Mark task as complete
GET /api/events- Get user eventsPOST /api/events- Create new eventGET /api/events/{id}- Get specific eventPUT /api/events/{id}- Update eventDELETE /api/events/{id}- Delete event
POST /api/chatbot/message- Send message to AI assistantPOST /api/chatbot/create-task- Create task via chatbotPOST /api/chatbot/query-schedule- Query schedule information
POST /api/schedule/generate- Generate AI-optimized scheduleGET /api/schedule/conflicts- Check for scheduling conflictsGET /api/schedule/available- Get available time slots
- Users can have multiple Tasks and Events
- Tasks can have subtasks (self-referencing relationship)
- UserPreferences store personalized settings for AI scheduling
- Tasks and Events support categorization and tagging
The system will learn from:
- Task completion times vs. estimates
- User energy levels at different times
- Task difficulty ratings and actual effort required
- Preferred work patterns and break intervals
- JWT-based authentication
- Role-based access control
- Password encryption using BCrypt
- CORS configuration for frontend-backend communication
- Machine learning models for better schedule optimization
- Integration with external calendars (Google Calendar, Outlook)
- Mobile application
- Team collaboration features
- Advanced analytics and reporting
- Voice commands and natural language processing
- Third-party integrations (Slack, Microsoft Teams)
- Follow Spring Boot best practices
- Use DTOs for API communication
- Implement proper error handling and validation
- Write unit tests for services and controllers
- Use meaningful commit messages
- Follow React best practices and hooks pattern
- Use Material-UI components consistently
- Implement proper error boundaries
- Write reusable components
- Maintain consistent code formatting
- Use proper indexing for performance
- Implement soft deletes where appropriate
- Use database constraints for data integrity
- Regular backup procedures
- Fork the repository
- Create a feature branch
- Make your changes
- Write tests for new functionality
- Submit a pull request
This project is licensed under the MIT License - see the LICENSE file for details.
- Diganta Saha Tirtha
- H.M. Aktaruzzaman Mukdho