x-algorithm-wiki
Architecture wiki for the open-sourced X "For You" recommendation algorithm (xai-org/x-algorithm) — 21 source-anchored pages
Community wiki of 34 cross linked Markdown pages explaining the open source X (Twitter) For You recommendation system with file and line references back to the xai-org/x-algorithm source.
This repository is a documentation wiki, not running code, that explains the open-source X (Twitter) For You recommendation system in detail. The author read through the xai-org/x-algorithm source code at a specific commit and wrote up what each part does, with file and line-number references back to the original code so readers can check the claims themselves.
The wiki is organized as 34 cross-linked Markdown pages totalling over 6,800 lines. Eleven of them are a plain-language tour for readers who do not want to read code, covering questions like how a post is picked, what data the algorithm uses, what shadowbanning actually looks like in the source, how cold-start treats new accounts, and a list of popular myths held up against what the code actually says. The remaining pages go into technical depth on the five components that make up For You: an orchestration layer, the candidate pipeline framework, the in-network post store called Thunder, the machine-learning retrieval and ranking stack called Phoenix with a Grok-style transformer, and the content-understanding service Grox with classifiers and multimodal embedders.
It also includes five entity-reference pages that walk through specific Rust structs and Python scripts, such as the candidate pipeline executor, the Phoenix ranking and retrieval model constructors, the Thunder PostStore, and an end-to-end inference script.
The README points to a hosted preview site that renders the wiki with a sidebar, and notes that the files are designed to be opened directly in Obsidian using its wiki-link navigation. Pages include real code snippets, Mermaid diagrams, design-decision notes, and FAQs.
It is community-made, not official xAI documentation, and is based on a specific source-code snapshot tagged in the README.
Where it fits
- Read a plain language tour of how X picks the next post in the For You timeline
- Trace shadowban and cold start behaviour back to specific lines in the xai-org source
- Onboard to the Phoenix ranking model and Thunder post store before contributing to x-algorithm