Designing a Feed Recommendation and Display Architecture for a Video Community Homepage

    A video community homepage feed is often the first screen users see when they enter a content platform. This article presents an engineering-oriented breakdown of how to design such a feed, covering metadata modeling, multi-stage ranking, real-time status handling, caching and degradation, content safety, and observability, with practical architecture guidance and pseudocode examples.

    Designing a Feed Recommendation and Display Architecture for a Video Community Homepage

    The homepage feed of a video community is usually the first screen users see after entering a content platform, and it is the combined result of the recommendation system, content understanding, content safety, frontend rendering, and operational strategy. A typical homepage feed is not simply a “video list”—it is a mixed arrangement of short videos, long videos, live streams, collections, partition content, leaderboards, and feature entries. Each card must carry metadata such as title, cover, duration, play count, interaction count, author, publish time, and status labels, while also delivering low latency under high concurrency, content diversity, accurate status, explainability, and operability.

    This article breaks down the key design decisions of a homepage feed from an engineering perspective and provides a practical architecture with pseudocode examples, focusing on metadata modeling, recommendation blending, real-time status, caching and degradation, safety review, observability, and experimentation.

    1. Requirements and Core Challenges

    The technical goals of a homepage feed can be summarized in four dimensions.

    First, low latency and high concurrency. Homepage traffic is large with pronounced peaks, and users are sensitive to first-screen load time. The system must complete candidate recall, ranking, reranking, card assembly, and safety checks within a tight time budget while minimizing redundant computation.

    Second, mixing multiple content types. Short videos emphasize completion and interaction, long videos emphasize consumption depth, live streams emphasize real-time status, and collections emphasize continuous viewing. Different content types have different ranking objectives, display fields, freshness requirements, and state machines, so they cannot simply be concatenated.

    Third, accurate and readable display information. Fields such as play count, interaction count, duration, and publish time need formatted display; live status needs frequent refreshes; content under review or already taken down must not enter the feed; count fields may be approximate but must deliver a consistent experience.

    Fourth, safety, explainability, and evolvability. Homepage content must pass content safety and quality filters; ranking results should retain strategy provenance and score composition to support troubleshooting and iteration; the system must also support operational interventions, partition quotas, diversity constraints, and gradual rollouts.

    2. Overall Architecture Layers

    The homepage feed should be split into the following service layers:

    1. Access layer: handles authentication, rate limiting, request parameter validation, pagination token parsing, and response trimming.
    2. Content aggregation service: assembles the recommendation feed, live entries, partition content, leaderboards, and operational slots into a unified card list.
    3. Recommendation and ranking service: performs recall, coarse ranking, fine ranking, and reranking, outputting content IDs and ranking scores.
    4. Metadata service: provides content title, cover, duration, author, publish time, tags, partition, status, and other fields.
    5. Real-time status service: maintains live stream status, content review status, takedown status, and approximate counters.
    6. Caching and storage layer: uses general-purpose cache components, object storage, message queues, and logging services to hold hot snapshots, media assets, asynchronous events, and observability data.
    7. Safety and quality service: provides moderation results across text, image, and audio, plus strategy inputs such as creator reputation, report risk, and quality scores.
    8. Experimentation and monitoring platform: handles metric instrumentation, experiment layering, alerting rules, and distributed tracing.

    The request path can be summarized as follows: the access layer parses the user and pagination context, then first attempts to read a cached homepage snapshot. On a cache miss, it calls the recommendation and ranking service to fetch candidates, then batch-fills fields from the metadata and real-time status services, applies safety filtering and card trimming, writes a short-lived snapshot, and returns. Strongly real-time fields such as live status use a shorter TTL or an independent refresh strategy.

    3. Content Card Metadata Modeling

    The content card is where frontend display and backend strategy intersect. A unified structure is recommended, so that different content types do not each maintain their own field set and complicate aggregation. An example:

    1. ContentCard {
    2. contentId: string
    3. contentType: "short_video" | "long_video" | "live" | "collection"
    4. title: string
    5. coverRef: string
    6. durationMs: number
    7. author: { id: string, name: string }
    8. publishTime: number
    9. playCount: number
    10. interactionCount: number
    11. tags: string[]
    12. partition: string
    13. status: "online" | "auditing" | "offline"
    14. liveStatus?: "living" | "not_living"
    15. qualityScore: number
    16. safetyScore: number
    17. rankInfo: { source: string, score: number, reasons: string[] }
    18. }

    Several engineering details matter in field design. First, separate display fields from strategy fields. The frontend only needs title, cover, duration, author, counters, and status labels; ranking scores, safety scores, and strategy provenance should stay in server-side context to avoid leaking internal strategies. Second, status fields must be decisive. Only content with status=online and a passing safety score may enter the feed; live content must also satisfy liveStatus=living. Third, count fields may be updated asynchronously. Play and interaction counts can use near-real-time aggregated values, but consistency must be maintained within the same pagination snapshot so numbers do not jump around as the user scrolls. Fourth, duration and time must be formatted. Long videos show full duration, short videos show minutes-and-seconds format, and publish time can be converted to relative time; formatting should be done during card assembly or handled by the frontend under a unified rule.

    4. Recommendation Blending: Recall, Ranking, and Reranking

    A homepage feed typically uses a multi-stage pipeline of “recall — coarse ranking — fine ranking — reranking.” In the recall stage, candidates are fetched separately per content type—for example, a fixed quota each for short videos, long videos, live streams, and collections—to ensure baseline supply. The coarse ranking stage uses lightweight models or rules to quickly trim the candidate set. The fine ranking stage scores candidates by combining user interest, content quality, interaction estimates, freshness, and safety scores. The reranking stage handles diversity, partition quotas, live freshness, operational slot insertion, and final truncation.

    A practical scoring formula might look like:

    1. finalScore =
    2. w1 * interestScore +
    3. w2 * qualityScore +
    4. w3 * freshnessScore +
    5. w4 * interactionScore -
    6. w5 * riskPenalty

    Weights should be tuned through experimentation rather than hardcoded. Reranking must handle three specific problems. First, content homogeneity: consecutive items from the same author, tag, or partition degrade the browsing experience; this can be mitigated with spread-out windows and frequency capping rules. Second, live status freshness: live candidates that pass fine ranking still need a second status check right before display, to avoid recommending streams that have already ended. Third, cold-start exploration: reserve some exploration quota for new content or new creators, but only after they pass safety and quality thresholds.

    Pseudocode example:

    1. function buildHomeFeed(userId, pageToken, limit) {
    2. snapshot = feedSnapshotCache.get(userId, pageToken)
    3. if (snapshot != null) return snapshot
    4. candidates = recall(userId, {
    5. shortVideo: 300,
    6. longVideo: 120,
    7. live: 60,
    8. collection: 40
    9. })
    10. coarse = coarseRank(userId, candidates)
    11. fine = fineRank(userId, coarse.slice(0, 300))
    12. reranked = rerank(userId, fine, {
    13. diversity: true,
    14. partitionQuota: true,
    15. liveFreshness: true,
    16. safetyFilter: true
    17. })
    18. cards = renderCards(reranked.slice(0, limit))
    19. feedSnapshotCache.put(userId, pageToken, cards, ttlByPageToken(pageToken))
    20. return cards
    21. }

    5. Real-Time Status, Caching, and Degradation

    A homepage feed is a read-heavy, write-light workload, so cache design directly affects latency and stability. A multi-level cache is recommended: the access or aggregation layer caches homepage snapshots, the metadata service caches base content fields, and the real-time status service applies a shorter TTL to live status. Pagination requests should be bound to a pagination token and snapshot version, so users do not see duplicates or gaps caused by changes in the underlying ranking while scrolling.

    Cache invalidation should be differentiated by field. Low-churn fields such as title, cover, and author can use longer TTLs; play and interaction counts can be refreshed asynchronously; live status, review status, and takedown status must be validated on short cycles. For hot content, combining local cache with distributed cache reduces concentrated access pressure.

    Degradation strategy is equally important. When the ranking service times out or fails, fall back to popular content, followed content, or partition leaderboards. When the metadata service partially fails, return cached base cards and hide non-critical fields. When the safety service is unavailable, default to narrowing the display scope rather than bypassing moderation. Degradation events should record the reason and proportion, enabling later alerting and postmortems.

    6. Content Safety and Quality Governance

    Content safety for the homepage feed should be enforced upstream, at the recall pool. Content that failed review, is under review, has been taken down, or is high-risk must not enter the candidate set; for live content, stream status and real-time risk must also be validated. Quality governance can build a quality score from creator reputation, report rate, content duplication, clickbait risk, and cover quality, then apply it as a constraint or penalty in fine ranking and reranking.

    Safety filtering should use a layered approach of “rules + models + human review”: the rule layer handles clear violations and status filtering; the model layer outputs risk probabilities; high-risk results enter a human or secondary review queue. All filtering actions should keep audit logs recording content ID, strategy version, hit reason, and outcome, ensuring traceability.

    7. Observability and Experimentation

    A homepage feed needs a complete metric feedback loop. Core metrics include first-screen latency, P99 latency, cache hit rate, degradation rate, empty-feed rate, impression click-through rate, play rate, effective watch time, interaction rate, negative feedback rate, content duplication rate, and diversity metrics. Monitoring and alerting should cover API error rates, ranking service timeouts, cache stampedes, abnormal moderation interception, and live status inconsistencies.

    For experimentation, layer experiments by user so that a given user sees a consistent strategy version within an experiment period. Experiment metrics should not focus only on click-through rate; consumption depth, negative feedback, and diversity matter too, to avoid short-term metric gains that hurt long-term experience. Operational slots and partition quotas should also go through experiments or gradual rollouts, ensuring strategy changes can be rolled back.

    8. Conclusion

    A video community homepage feed is a typical multi-source content aggregation and multi-stage ranking system. The engineering focus is not on a single recommendation model, but on the coordination of unified metadata modeling, multi-type content blending, real-time status validation, caching and degradation, safety and quality governance, and an observable experimentation system. With a unified card structure, staged ranking, pagination snapshots, and layered caching, low-latency display can be achieved under high concurrency; with upstream safety enforcement, quality constraints, and strategy auditing, content remains controllable and explainable; with a metric feedback loop and gradual experiments, ranking strategies and display formats can be continuously iterated. These approaches apply to general content community homepage feeds and can be trimmed or extended based on business scale and content types.