Calendar AI is a smart calendar that uses AI to help you manage your calendar. It's like magic, and it's free forever.
Calendar AI is a Next.js application that leverages artificial intelligence to help you manage your schedule intelligently and efficiently. With Calendar AI, you can create and manage events using natural language, automatically reschedule events, and share your calendar with others.
Follow the steps below to set up the project locally.
Clone the repository:
git clone https://github.com/typper-io/calendar-ai.git
cd calendar-ai
Install dependencies:
pnpm install
Start the development server:
pnpm run dev
The server will start at http://localhost:3000.
To run this application, you need to configure several environment variables. You can do this by creating a .env.local
file in the root directory of the project or by using the provided .env.example
as a template.
OPENAI_API_KEY
: Your OpenAI API key, used for integrating GPT features.GOOGLE_CLIENT_ID
: The Client ID for Google OAuth, used for authenticating users.GOOGLE_CLIENT_SECRET
: The Client Secret for Google OAuth.NEXTAUTH_SECRET
: A secret key used by NextAuth.js to encrypt session data.ASSISTANT_ID
: The unique ID of your OpenAI assistant.NEXTAUTH_URL
: The URL of your Next.js application, used by NextAuth.js.Create a .env.local
File:
Copy the .env.example
file to a new file named .env.local
:
cp .env.example .env.local
Add Your Credentials:
Open the .env.local
file and fill in the values for each variable. You need to obtain these values from the respective service providers (OpenAI, Google, etc.).
Run the Application: After setting up the environment variables, you can start the development server:
pnpm run dev
This project includes an OpenAI Assistant that helps automate and manage your calendar through natural language. Follow the steps below to create and integrate the assistant:
Create an Assistant on the OpenAI Platform:
ASSISTANT_ID
.Add the Assistant ID to Environment Variables:
.env.local
file.ASSISTANT_ID
you just copied.ASSISTANT_ID=your-assistant-id
Configure the Assistant with Functions and Instructions:
The JSON files and the instruction file you need to use for configuring the assistant are located in the assistant/functions/
directory and in the assistant/instruction.txt
file. Follow these steps to set them up:
Load Functions:
edit_event.json
, get_calendar.json
, and schedule_event.json
files located in the functions/
directory. These functions will be used by the assistant to edit events, retrieve the calendar, and schedule new events, respectively.Add Instructions:
instruction.txt
file and paste it into the instruction area. These instructions will guide the assistant's behavior and how it should use the available functions.Test the Integration:
Run the development server and interact with the assistant to ensure everything is set up correctly.
pnpm run dev
You should now be able to schedule events and manage your calendar using natural language.
This project is licensed under the MIT License.
Contributions are welcome! Feel free to open issues or pull requests to suggest improvements or fix issues.
For more information or support, contact [email protected].