Design Conversation State for an Assistant Living in Slack and Teams
Last updated: November 29, 2026
Quick Overview
Design the service that stores and serves multi-turn conversation state (history, pending clarifying questions, partially filled slots, in-flight actions) for an employee assistant reached through Slack, Microsoft Teams and a web widget.
Moveworks
November 29, 20260
0
0 solved
Design the service that stores and serves multi-turn conversation state (history, pending clarifying questions, partially filled slots, in-flight actions) for an employee assistant reached through Slack, Microsoft Teams and a web widget.
An assistant inside chat platforms receives webhook events that can be duplicated, delayed or out of order, while the reasoning engine needs a consistent view of what was already asked and done. The interviewer checks data modeling, idempotent event handling, and latency within chat-platform acknowledgement limits.
What the Interviewer Expects
- Models conversation, turn and pending-action entities clearly
- Acknowledges platform webhooks quickly and processes asynchronously
- Deduplicates retried webhook deliveries by event id
- Serializes processing per conversation to avoid races
- Defines retention and PII handling for transcripts
Key Topics to Cover
How to Approach This
- Start by clarifying functional and non-functional requirements with the interviewer.
- Estimate the scale: QPS, storage, bandwidth. This drives your design decisions.
- Draw a high-level architecture first, then deep dive into 1-2 critical components.
- Discuss trade-offs explicitly (e.g., consistency vs availability, SQL vs NoSQL).
- Address failure scenarios, monitoring, and how the system handles 10x traffic spikes.
Possible Follow-up Questions
- An employee answers a clarifying question in Teams after starting in Slack; can the state carry over?
- How do you handle an employee sending three messages in two seconds while the first is still being processed?
- What do you keep in the hot store versus the long-term transcript store?
Sharpen Your Skills on Codemia
Practice similar problems with our interactive workspace, get AI feedback, and track your progress.
Practice System Design ProblemsSample Answer
Requirements
Functional: append user and bot turns, read the last N turns plus structured state (current plugin, filled slots, awaiting-confirmation flag), resume after hours, expire stale flows. Non-functional: a...
High-Level Design
Channel adapters (Slack, Teams, web) verify signatures, normalize events into a common message schema, write the event id to a dedupe set, enqueue to a partitioned queue keyed by conversation id, and ...