gitmyhub

monolith

Python ★ 9.3k updated 8mo ago ▣ archived

A Lightweight Recommendation System

ByteDance's open-source deep learning framework for building large-scale recommendation systems, the same kind of engine that powers TikTok's video feed, with built-in support for real-time model updates.

PythonTensorFlowBazelLinuxsetup: hardcomplexity 5/5

Monolith is a deep learning framework from ByteDance, the company behind TikTok, designed specifically for building recommendation systems at large scale. A recommendation system is what decides which videos, products, or posts to show each user based on their past behavior. Building one that works well for millions of users requires solving some specific technical problems, and this framework addresses two of them.

The first is how to represent users and content as numerical values that a model can learn from. Monolith uses what the README calls collisionless embedding tables, meaning each unique identifier gets its own distinct numerical representation rather than potentially sharing one with something unrelated. The second is training speed: Monolith supports real-time training, so the model can update based on what users are doing right now rather than only on yesterday's data. This helps it surface newly trending content quickly.

The framework is built on top of TensorFlow, a widely used machine learning platform, so developers already familiar with TensorFlow can adopt Monolith's recommendation-specific features without learning an entirely different system. It supports both batch training, where you process large chunks of historical data at once, and real-time training that updates continuously.

The README is brief. Setup requires Linux, a specific version of the Bazel build tool, and a Python environment with a handful of libraries. The project links to a research paper for deeper technical background and includes some tutorial files in the repository. A Discord community exists for discussion.

Where it fits