第一轮系统设计,大早上的面试官迟到了,然后出了一个关于他们家自用的notification的系统的问题,一直在问我这个系统应该有什么特点。我也很懵逼啊,不知道啊,然后就各种猜,过了很久他给我提示说是时间,我说哦,那不能发太晚或者太早,比如一封邮件凌晨4点发出去的话,用户早上8点钟醒过来看收件箱可能已经被其他的邮件埋没了。他表示认可,“对,要在客户活跃的时候发。” 然后又问还有别的特点嘛?我实在不知道,继续各种瞎扯各种要提示。他说还是跟时间有关,但是跟系统的设计也相关,我实在想不出来,他就说是频率不能太高。哦,makes sense,最后瞎扯了几句什么message可以aggregate起来啊,用rate limiter啊之类的。我很懵逼的是我问他“我们要讨论rate limiting吗”他跟我说不是。基本没有时间设计这个系统,全部在讨论产品的特性了。这轮聊完就基本确定挂了。我自己没做过相关的东西,完全不懂产品该是什么样的,但是难道不是你告诉我产品的特性我来回答怎么设计满足这个特性吗?而且全程不管我说什么,他基本是在告诉我“不对”,大概是我偏得太离谱了吧,反正就是自己答得也烂觉得面试官问得也有问题。
What should pinterest notify?
- Personalized recommendations.
- Ideas people you know are saving and liking in the topics you care about most
- Who all's been following your boards, and liking and saving the same idea as you
- Which new boards people are creating, and finding to follow
Definition: A notification is the product communicating with you while you are not using it.
It is naturally interruptive and therefore could have signfiicant imapct on UX of the product.
Key considerations:
- Qaulity and persoanlization:
- Different features for power users and new users:
- new users might get follow suggestions
- Different features for power users and new users:
- Measuring success
- Know what engagement metrics leads to.
- e.g. a quick tap the notification link might be the user hurrying to turn off notification.
- Negative signal lags:
- App deletion or unsubcription could be triggered by something happend long time ago (consistently), hard to measure.
- Most companies use CTR and maintain some minimum required metric to justify the exitence of an indivdual notification.
- A better approach might be include a global measurement of the user's overall CTR to prevent volume burnout.
- Know what engagement metrics leads to.
Questions:
- How many users?
- Number of notifiers?
- One to One
- User A followed you, User B commendted on your pin, User C has repinned your pin.\
- One to Many
- User X's birthday.
- One to One
- Types of notifications?
- New pins, new friend, group requests, otc...
- Database schema should be flexible to support notifiocations for new entitries easily.
- Do notifications need to be grouped? E.g. If four different users liked some image, the owner should get one notification stating that four users heve liked the image and not four separate notifications.
Data Layer:http://blog.osmosys.asia/2017/04/26/design-notification-system/
4 key data types:
- Actor
- The user who is responsible for triggering a noitification. A user can be identifiied by userid (primary key) of user entity. We can also identify the user's activities using user_id.
- Notifier
- Entity
- Entity type
https://www.careercup.com/question?id=5167925411446784
https://www.linkedin.com/pulse/design-notification-system-osmosys-software-solutions-pvt-ltd/
https://medium.com/@engnews/building-our-own-push-notification-delivery-service-9e26232e8c9
Critieas for deciding what notification to send:
- Intent - what this person did?
Our desired action: what we want them to use?
Find the best hour of the day to send the email
- Metrics:
- How long it took the users the click the email
- Most clicks arrive at the first day, 50% of all clicks arrive at first few hours.
- Next is find the write time to send
- Optimized delivery time based on user's local time, send email at local hours that has the hightest click through rate.
- How long it took the users the click the email
- Goal: Predict the engagement probability to a given (userid, email_Type) pair
- If the engagement probability is too low, send those email less often, vice versa.
- metrics to track: country, gender, historical clickrate, open_rate.
- Metrics:
Use machine learning model and use business model to guide it.
John's Shopkick story about geofencing.