- Fix Twenty CRM filter syntax (dot notation for composite fields)
- Fix noteTargets/taskTargets to use targetPerson instead of personId
- Handle duplicate person creation gracefully (find existing on 400)
- Add task creation for new leads (follow-up TODO)
- Save conversation transcript to CRM on escalation and rate limit
- Strengthen system prompt to make Claude call update_lead proactively
- Tell Claude that form-submitted leads are already in CRM
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Bot now acts as sales consultant: identifies needs, proposes services, pushes for booking
- escalate_to_human tool: triggers on user request, bot stuck, or hot lead
- Escalation notifies RC with reason + conversation summary
- Contact form and quote form now create leads in Twenty CRM
- Fix RC webhook to use correct payload format (visitor.token as session_id)
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Store lead info in Redis session meta so bot remembers name across messages
- Create Twenty CRM lead immediately from form data (bypass tool-call flow)
- Store room→session reverse mapping in Redis for RC webhook delivery
- Update system prompt: don't re-ask for form-provided info
- Fix "Most Popular" badge clipped on mobile (overflow: visible)
- Fix contact form inputs overflowing on small screens (box-sizing)
- Reduce chat tooltip size on mobile to avoid overlapping content
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- New twenty_crm.py: full CRUD for people, companies, notes via Twenty REST API
- Lead capture now creates person + company in Twenty CRM automatically
- New update_lead tool: enriches CRM profile as conversation progresses
(job title, phone, city, budget, requirements)
- Session meta stored in Redis to track Twenty person ID across messages
- Docker-compose updated with TWENTY_CRM env vars
- Chat bubble: pulsating ring animation with gradient background
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
When Claude returns text + tool_use together, the bot was not sending the tool_result
back, so no follow-up message reached the user. Now always sends tool_result to get
a proper response. Also added Cal.com booking link to system prompt so bot offers
consultation scheduling after capturing lead data.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>