Requirements
What this lesson covers
This lesson defines the requirements for designing Instagram in a system design interview. Storing and retrieving images can be assumed in any Instagram interview, but other features should not be assumed. Candidates are advised to ask the interviewer what they expect, since time constraints rarely allow every feature to be designed in depth. The video settles on four key features: storing and getting images, liking and commenting on posts, following other users, where every account is treated as a user rather than a page as on Facebook, and publishing a news feed. Image storage is noted as already covered in the course's Tinder design. The lesson then looks more closely at likes and comments by raising questions to ask, such as whether a comment can have its own comments, making the structure recursive, and whether a comment can be liked. It notes that Instagram allows one level of replies to a comment but not replies to replies, which keeps complexity bounded, even though nothing technically prevents deeper nesting. For the interview, the design is simplified further: there are no replies to comments, but comments can be liked.
- Ask the interviewer which features they expect instead of assuming everything Instagram offers
- The design covers four features: images, likes and comments, following, and a news feed
- Whether comments can be nested or liked is an important question to settle early
- The interview design allows likes on comments but no replies to comments