An AI-powered conversational assistant to manage your Google Calendar with natural language.
CalendarBot is a fully conversational AI assistant built using FastAPI, LangChain, and Gemini LLM APIs to handle your Google Calendar.
You can check the calendar bot live and see the publicly available calendar to see the schedulings reflected on the calendar or not. (Don't abuse the bot or give too many requests 🙏 I'm running on limited requests per day. (TailorTalk reviewers may try whatever they want))
It can:
- 🗓️ Book new events
- 🔍 Check availability
- ♻️ Reschedule existing events
- ❌ Cancel/delete events
- 📋 Summarize your schedule
- 🧠 Handle multiple tool calls in a single user request
All through natural back-and-forth conversations!
| Component | Stack |
|---|---|
| Backend | Python 3.12, FastAPI |
| Frontend | Streamlit |
| AI Model | Google Gemini API (gemini-2.5-flash) |
| Agent Framework | LangChain Tools (custom wrapper) |
| Calendar Integration | Google Calendar API (Service Account) |
| Deployment-ready | Yes (Railway, Render, etc.) |
💡 You can change the Gemini model (e.g., to
gemini-2.0-flash,gemini-2.5-pro, etc.) by modifying theGenerativeModel(...)name inagent.py.
tailortalk
├── backend
│ ├── main.py # FastAPI backend
│ ├── agent.py # Chat agent logic & Gemini tool integration
│ ├── calendar_tools.py # Google Calendar integration functions
│
├── frontend
│ ├── app.py # Streamlit UI interface
│
├── credentials
│ ├── <service_account>.json # Google service account file
│
├── .env # All environment variables
└── README.md
git clone https://github.com/your-username/calendarbot.git
cd calendarbotpython -m venv venvOpen two terminals:
- In both terminals, activate the virtual environment:
On Windows: venv\Scripts\activate # On mac/linux: source venv/bin/activate
pip install -r requirements.txtCreate a .env file in the root:
GOOGLE_API_KEY=your_google_gemini_api_key
GOOGLE_CREDENTIALS_PATH=credentials/your_service_account.json
CALENDAR_ID=your_calendar_id@group.calendar.google.com
✅ Make sure your calendar has editor access given to the service account. If not, create a cloud project on google cloud console and copy the service account id and add it in your calendar, and give it the 'make changes to event' permission.
In the first terminal (backend):
cd backend
uvicorn main:app --reloadIn the second terminal (frontend):
cd frontend
streamlit run app.py- "Book me a dentist appointment on July 10th at 10am."
- "Reschedule the meeting with Bob two hours later."
- "Delete the hospital appointment."
- "What do I have on July 9, 2025?"
Automatically detects multiple actions:
- Reschedules an event and books a new one in one go.
- Understands:
- "Move 2 hours ahead"
- "Postpone by 1 hour"
- "Back-to-back meetings"
- "Shift event 90 minutes earlier"
- Detects overlaps automatically
- Suggests alternatives
- Optionally reschedules conflicting events
- Asks for confirmation before deleting
- Handles missing event names/dates/times gracefully
- Booking overlapping events ➜ gets rejected or rescheduled
- Rescheduling with vague commands ➜ prompts clarification
- "Shift X meeting to 1 hour later" ➜ applies correct logic
- Deleting non-existent events ➜ handled gracefully
- Mixing booking and rescheduling in one command ➜ success
- Natural follow-up queries like "And now what's on my schedule?" ➜ accurate list
- Trying to book without time ➜ asks for missing time
- Trying to book with only partial date ➜ confirms year if missing
- ❌ Backend down ➜ "
⚠️ Backend is offline. Try again later." - ❌ API quota exhausted ➜ "😔 Sorry, we ran out of free messages today. Limit resets at 12:30 PM IST."
- ❌ General errors ➜ "
⚠️ Something unexpected happened. Please try again later."
You can host the app using platforms like:
- Railway
- Render
- Fly.io
Make sure to:
- Upload the service account
.jsonsecurely - Add all
.envvars in the hosting environment - Enable public access for Streamlit frontend
If you found this project helpful, feel free to ⭐ it or reach out! And TailorTalk may proceed me to the next round 😅


