Design a ranking system for comments inside a single Reddit post. Popular posts may contain tens of thousands of comments nested across many levels, so the system should surface the most relevant top-level comments first and independently rank the replies under each expanded branch. Home feed ranking, cross-post recommendation, full-text comment search, and other global retrieval problems are out of scope.
Raw upvotes alone are not…