Design a Windows App Notification System While Working With an AI Assistant
Company: Microsoft
Role: Software Engineer
Category: System Design
Difficulty: medium
Interview Round: Onsite
Design the notification system for the Windows operating system: the platform component that lets many different applications generate notifications and have them displayed to the user.
This round is AI-assisted. You are allowed, and expected, to use an AI assistant while you work. The interviewer is less interested in whether you can take the code the assistant produces and use it directly than in how you write prompts for it, how you refine those prompts, and how you judge whether its answers are right.
### Clarifying Questions
- Do notifications come only from applications running on the device, or must they also arrive from an application's cloud service while the application is not running?
- Which user controls are in scope: turning notifications off per application, a quiet or do-not-disturb mode, priority levels, hiding content on the lock screen?
- Must notifications stay in a history the user can revisit, and must that history survive a reboot?
- Can an application update or withdraw a notification it has already posted?
- Which parts of the design should the AI assistant help with, and may its output be pasted into the solution as is?
### Part 1 — Design the notification platform
Design the system that sits between applications and the user: how an application submits a notification, how the system decides whether and how to show it, how it is displayed, and what happens when the user clicks it, dismisses it, or ignores it.
```hint Start from the trust boundary
Many applications run at once and none of them can be trusted. Decide which process owns notification state and what each application is allowed to see or change.
```
```hint Follow one notification end to end
Trace a single notification from the application's call to the moment it disappears, and note every decision point on the way.
```
#### What This Part Should Cover
- Components and their responsibilities: the application-facing API, a central notification service, storage, and display
- The full lifecycle of one notification, including user interaction, update, withdrawal and expiry
- Isolation between applications, and how user settings are enforced
- Behavior under load and failure, such as a noisy application or the service restarting
### Part 2 — Build it with the AI assistant
Use the AI assistant to help produce a concrete piece of your design, such as the service's request-handling logic or its API. Show the prompt you would write first, how you would refine it after seeing the first answer, and how you would decide whether the assistant's output is correct and safe to adopt.
```hint Give the assistant what only you know
List the requirements and decisions from Part 1 that the assistant cannot guess, and decide what form you want its answer in.
```
```hint Decide how you will check it before you ask
Work out in advance which properties of the answer you can verify, and how you will verify each one.
```
#### What This Part Should Cover
- A first prompt that carries the context, the constraints and the expected shape of the output
- Refinement steps driven by specific gaps or errors in the previous answer
- A method for verifying the output against the requirements, including invented APIs or facts
- Clear decisions on what to keep, change or reject, with ownership of the final result
### What a Strong Answer Covers
- A design in which applications never block on display and the service never blocks on an application
- One owner of notification state, with a consistent model for posting, updating, withdrawing and expiring
- User control and privacy treated as requirements, not afterthoughts
- Deliberate, verifiable use of the AI assistant rather than copying its output
- Explicit trade-offs with reasons
### Follow-up Questions
- One application posts hundreds of notifications per second. How does the system protect the user and itself?
- How would you deliver a notification to an application that is not running, or to a device that has been offline for a day?
- How do you keep the history consistent if the service crashes between accepting a notification and displaying it?
- The assistant proposes an operating-system API that looks plausible but that you cannot confirm exists. What do you do?
Overview: A system design exercise to design the Windows notification platform that lets many applications post, update and display notifications, completed with an AI assistant. It tests component design, isolation between apps, user controls and load handling, plus how well the candidate prompts, refines and critically evaluates AI output.