Symptom
Every customer message is treated as the start of a brand new conversation. The AI support agent has zero conversational memory — it never remembers what the customer said in previous messages.
What you know
Support Agent is an AI customer support platform. When a customer sends a message, the system loads their session from a key-value store, checks if it has expired (based on a 30-minute TTL), and either reuses the existing session or creates a new one.
Sessions store lastActivity as a Unix timestamp in seconds. The TTL is 1800 (seconds = 30 minutes).
Every single session is treated as expired, even ones created moments ago.
Pipeline Flow
Customer Message → Session Loader → Intent Classifier → Action Executor → Response Generator
Log excerpt
[session-loader] Session found in store
session_id=sess_f7a21
last_activity=1731677521 ← seconds
ttl_seconds=1800
current_time=1731677595201 ← milliseconds!
[session-loader] Session expired, creating new session
session_id=sess_f7a21
reason="TTL exceeded"
Hints
TypeScript
TypeScript ready
Test Output
▶
Click "Run Tests" to execute your code