Keyboard shortcuts

Press โ† or โ†’ to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

RecSys Auto Research KB

A knowledge base for recommender-system auto research ยท from cascading architectures to the generative paradigm

mdBookLanguageTopicStatusRead Online

A knowledge base for recommender systems and computational advertising: discriminative recommendation, generative recommendation, and the advertising stack โ€” structured, citable technical knowledge for auto research by humans and AI agents.

๐Ÿ“– Read Online ยท GitHub Repository


What Is This?

RecSys Auto Research KB is a knowledge base for recommender-system auto research, rewritten and expanded from the Datawhale open-source project fun-rec.

๐Ÿ“– Read online: visit https://haozhe-xing.github.io/fun-rec-mdbook/ for the latest version.

The book follows two main threads:

  • Discriminative recommendation: retrieval, ranking, re-ranking, multi-task learning, multi-scenario modeling, debiasing, cold start, and other foundational capabilities of industrial recommender systems.
  • Generative recommendation: semantic IDs, generative ranking, end-to-end recommendation, recommendation reasoning, diffusion models, and hands-on practice building a generative recommender.

If you want to move from "algorithm principles" to "system practice" and understand the full arc from the classic architecture to the generative paradigm, this book is for you.


Content Map

The book has 11 Parts, best read in order; if you already know the basics of recommender systems, feel free to jump straight to the topics you care about.

PartThemeWhat You Will Learn
Part 1Recommender Systems at a GlanceThe basic problems of recommendation, a technical map, and feature & embedding fundamentals
Part 2Fast Candidate RetrievalCollaborative filtering, vector retrieval, two-tower models, sequential retrieval, streaming indexes
Part 3Accurate Preference PredictionWide&Deep, feature crossing, sequence modeling, multi-task learning, multi-scenario modeling
Part 4Re-ranking for DiversityMMR, DPP, personalized re-ranking, and list-level optimization
Part 5Frontier TrendsDebiasing, cold start, and the evolution toward generative recommendation
Part 6Foundations of Generative RecommendationThe generative paradigm, LLM basics, codebooks, semantic IDs
Part 7Scaling Generative RankingHSTU, generative ranking, MTGR, RankMixer, OneTrans
Part 8End-to-End Generative ApplicationsEnd-to-end generative modeling in recommendation, search, and advertising
Part 9Thinking and Reasoning in RecommendationSemantic alignment, reasoning frameworks, autonomous reasoning exploration
Part 10Diffusion Models for RecommendationDiffusion basics, data augmentation, recommendation applications
Part 11Building a Generative RecommenderSystem architecture, offline pipeline, online pipeline, frontend, and deployment

See SUMMARY.md for the full table of contents.


1. Install dependencies

cargo install mdbook
cargo install mdbook-katex

2. Local preview

./serve.sh

./serve.sh builds both language editions and starts a local preview server. Open the URL printed in the terminal to read the book โ€” the language is auto-selected at the site root based on your browser settings.

3. Build static sites

mdbook build

Build artifacts are written to the book/ directory (book/zh/ and book/en/, one per edition; ./serve.sh wraps the same build for both configs).


Project Structure

This is a bilingual project: the Chinese and English editions share the same structure and are built separately.

.
โ”œโ”€โ”€ README.md                 # Home page and project intro
โ”œโ”€โ”€ SUMMARY.md                # mdBook table of contents
โ”œโ”€โ”€ book.toml                 # mdBook config (Chinese edition)
โ”œโ”€โ”€ book-en.toml              # mdBook config (English edition)
โ”œโ”€โ”€ serve.sh                  # Build/serve script for both editions
โ”œโ”€โ”€ GLOSSARY.md               # Glossary
โ”œโ”€โ”€ src/
โ”‚   โ”œโ”€โ”€ zh/                   # Chinese source (chapter sources + appendix)
โ”‚   โ”œโ”€โ”€ en/                   # English source (chapter sources + appendix)
โ”‚   โ”œโ”€โ”€ zh/images/            # SVG figures (Chinese edition)
โ”‚   โ”œโ”€โ”€ en/images/            # SVG figures (English edition)
โ”‚   โ”œโ”€โ”€ zh/viz/               # Interactive visualizations (Chinese edition)
โ”‚   โ””โ”€โ”€ en/viz/               # Interactive visualizations (English edition)
โ””โ”€โ”€ book/
    โ”œโ”€โ”€ zh/                   # Build output (Chinese edition)
    โ””โ”€โ”€ en/                   # Build output (English edition)

Beginner path

For readers new to recommender systems who want to build a complete knowledge framework:

Part 1 โ†’ Part 2 โ†’ Part 3 โ†’ Part 4 โ†’ Part 5

You will first master the classic cascading architecture of recommender systems, then understand how retrieval, ranking, and re-ranking work together.

Advanced engineering path

For readers who have already worked on recommendation algorithms or recommendation engineering and want to strengthen their system-design skills:

Part 2 โ†’ Part 3 โ†’ Part 4 โ†’ Part 11

You will focus on candidate generation, preference prediction, list-level optimization, and online serving architecture in the industrial recommendation pipeline.

Generative recommendation path

For readers interested in LLMs, generative ranking, semantic IDs, and next-generation recommender systems:

Part 5 โ†’ Part 6 โ†’ Part 7 โ†’ Part 8 โ†’ Part 9 โ†’ Part 10 โ†’ Part 11

You will start from the paradigm shift and work through the modeling, inference, and system deployment of generative recommendation step by step.


Who Is This Book For?

  • Recommendation algorithm learners: build a systematic grounding in the core models and technical roadmaps of recommender systems.
  • Machine learning engineers: understand the full engineering loop of a recommender system, from offline training to online serving.
  • Recommender system practitioners: catch up on new directions such as generative recommendation, semantic IDs, and end-to-end recommendation.
  • Interview candidates: build a clear mental map and vocabulary for recommender-system topics.

Writing Conventions

  • Each chapter opens with badges for the chapter number, estimated reading time, and difficulty level.
  • Math uses $inline$ and $$display$$ notation, rendered by mdbook-katex.
  • Figures live in images/, and interactive visualizations live in viz/.
  • Wherever possible, each chapter includes common mistakes, key takeaways, an FAQ, chapter connections, and tiered practice problems.

Contributing

Issues and pull requests are welcome:

  • Fix typos, formulas, figures, or broken links.
  • Add recommender-system papers, industrial case studies, or engineering lessons.
  • Improve chapter structure, example code, exercises, or visualizations.
  • Propose new recommender-system topics you would like to see covered.

When submitting, please keep:

  • Consistent terminology: follow GLOSSARY.md first.
  • Consistent structure: mirror the organization of existing chapters.
  • Clear explanations: favor intuition, boundary conditions, and engineering trade-offs.

Acknowledgments

This book is rewritten from the Datawhale open-source project fun-rec. Thanks to the original authors and community contributors for building open learning materials on recommender systems.

Thanks also to the researchers and engineers in the recommender-system, information-retrieval, machine-learning, and LLM communities. Much of this book draws on public papers, industrial experience sharing, and open-source community discussions.


If this book helps you, consider starring the repository, sharing it, or contributing.