Spaces:
Sleeping
Sleeping
FEATURE: Add phone call meeting type (no Google Meet)
Browse files- Phone calls detected by: "phone call", "phone meeting", "call me", "telephone"
- Phone calls do NOT create Google Meet links
- Removed "conference call" from Google Meet triggers
- Phone call detection takes precedence over Google Meet
- Meeting types: In-Person (default), Phone Call, Google Meet
- Bump version to 1.2.8
π€ Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
- app/core/agent.py +30 -13
- app/personality/prompts.py +3 -2
- pyproject.toml +1 -1
- version.txt +1 -1
app/core/agent.py
CHANGED
|
@@ -1174,20 +1174,30 @@ When user provides all info upfront (name, contact, time, topic):
|
|
| 1174 |
print(f"π Context updated: {context_updated}")
|
| 1175 |
|
| 1176 |
# Check if we have complete info for Google Meet (check current message AND conversation history)
|
| 1177 |
-
|
| 1178 |
-
|
| 1179 |
-
|
| 1180 |
-
|
| 1181 |
-
|
| 1182 |
-
|
| 1183 |
-
|
| 1184 |
-
|
| 1185 |
-
|
| 1186 |
-
|
| 1187 |
-
|
| 1188 |
-
|
| 1189 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1190 |
|
|
|
|
| 1191 |
print(f"π Is Google Meet request: {is_google_meet}")
|
| 1192 |
|
| 1193 |
# Store Google Meet preference in user info if detected
|
|
@@ -1197,6 +1207,13 @@ When user provides all info upfront (name, contact, time, topic):
|
|
| 1197 |
self.user_info['preferences']['google_meet'] = True
|
| 1198 |
print("π Stored Google Meet preference in user info")
|
| 1199 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1200 |
# Recreate agent if it doesn't exist yet OR if context was updated (time slot selection, etc.)
|
| 1201 |
if self.agent is None:
|
| 1202 |
print("π Creating agent for first time")
|
|
|
|
| 1174 |
print(f"π Context updated: {context_updated}")
|
| 1175 |
|
| 1176 |
# Check if we have complete info for Google Meet (check current message AND conversation history)
|
| 1177 |
+
# IMPORTANT: "phone call" should NOT trigger Google Meet - only video-specific phrases
|
| 1178 |
+
google_meet_phrases = ['google meet', 'googlemeet', 'meet.google', 'video call', 'video conference', 'online meeting']
|
| 1179 |
+
phone_call_phrases = ['phone call', 'phone meeting', 'call me', 'telephone']
|
| 1180 |
+
|
| 1181 |
+
# Check for phone call request FIRST (takes precedence)
|
| 1182 |
+
is_phone_call = any(phrase in message.lower() for phrase in phone_call_phrases)
|
| 1183 |
+
|
| 1184 |
+
# Only check for Google Meet if NOT a phone call request
|
| 1185 |
+
is_google_meet = False
|
| 1186 |
+
if not is_phone_call:
|
| 1187 |
+
is_google_meet = any(phrase in message.lower() for phrase in google_meet_phrases)
|
| 1188 |
+
|
| 1189 |
+
# Also check conversation history for Google Meet requests
|
| 1190 |
+
if not is_google_meet and hasattr(self, 'conversation_history'):
|
| 1191 |
+
recent_messages = self.conversation_history[-5:] # Check last 5 messages
|
| 1192 |
+
for msg in recent_messages:
|
| 1193 |
+
if isinstance(msg, dict) and 'content' in msg:
|
| 1194 |
+
msg_content = msg['content'].lower()
|
| 1195 |
+
if any(phrase in msg_content for phrase in google_meet_phrases):
|
| 1196 |
+
is_google_meet = True
|
| 1197 |
+
print(f"π Found Google Meet request in conversation history: {msg_content[:50]}...")
|
| 1198 |
+
break
|
| 1199 |
|
| 1200 |
+
print(f"π Is phone call request: {is_phone_call}")
|
| 1201 |
print(f"π Is Google Meet request: {is_google_meet}")
|
| 1202 |
|
| 1203 |
# Store Google Meet preference in user info if detected
|
|
|
|
| 1207 |
self.user_info['preferences']['google_meet'] = True
|
| 1208 |
print("π Stored Google Meet preference in user info")
|
| 1209 |
|
| 1210 |
+
# Store phone call preference if detected
|
| 1211 |
+
if is_phone_call:
|
| 1212 |
+
if 'preferences' not in self.user_info:
|
| 1213 |
+
self.user_info['preferences'] = {}
|
| 1214 |
+
self.user_info['preferences']['phone_call'] = True
|
| 1215 |
+
print("π Stored phone call preference in user info")
|
| 1216 |
+
|
| 1217 |
# Recreate agent if it doesn't exist yet OR if context was updated (time slot selection, etc.)
|
| 1218 |
if self.agent is None:
|
| 1219 |
print("π Creating agent for first time")
|
app/personality/prompts.py
CHANGED
|
@@ -138,8 +138,9 @@ Meeting topics - YOU CAN SCHEDULE ANY TOPIC the user requests:
|
|
| 138 |
- Duration: Accept any duration from 15 minutes to 8 hours (480 minutes)
|
| 139 |
|
| 140 |
**Meeting Format Options:**
|
| 141 |
-
- **In-Person**: Traditional face-to-face meeting
|
| 142 |
-
- **
|
|
|
|
| 143 |
|
| 144 |
**CRITICAL: ONE MEETING PER SESSION**:
|
| 145 |
- ONLY book ONE meeting per conversation session
|
|
|
|
| 138 |
- Duration: Accept any duration from 15 minutes to 8 hours (480 minutes)
|
| 139 |
|
| 140 |
**Meeting Format Options:**
|
| 141 |
+
- **In-Person**: Traditional face-to-face meeting (default if not specified)
|
| 142 |
+
- **Phone Call**: Audio-only telephone meeting (use when user says "phone call", "call me", "telephone")
|
| 143 |
+
- **Google Meet**: Video conference call with automatic Meet link generation (use when user says "google meet", "video call", "video conference")
|
| 144 |
|
| 145 |
**CRITICAL: ONE MEETING PER SESSION**:
|
| 146 |
- ONLY book ONE meeting per conversation session
|
pyproject.toml
CHANGED
|
@@ -1,6 +1,6 @@
|
|
| 1 |
[tool.poetry]
|
| 2 |
name = "voicecal-ai"
|
| 3 |
-
version = "1.2.
|
| 4 |
description = "A friendly interactive AI speechbot for booking Google Calendar appointments"
|
| 5 |
authors = ["Peter <pgits.job@gmail.com>"]
|
| 6 |
|
|
|
|
| 1 |
[tool.poetry]
|
| 2 |
name = "voicecal-ai"
|
| 3 |
+
version = "1.2.8"
|
| 4 |
description = "A friendly interactive AI speechbot for booking Google Calendar appointments"
|
| 5 |
authors = ["Peter <pgits.job@gmail.com>"]
|
| 6 |
|
version.txt
CHANGED
|
@@ -1 +1 @@
|
|
| 1 |
-
1.2.
|
|
|
|
| 1 |
+
1.2.8
|