Elon Musk’s car is literally cruising through space right now and it could stay up there mostly intact for over 10 million years.
One day, an alien civilization is going to argue for centuries over why a planet launched a sports car into space.
We know the algorithm is dumb and needs massive improvements, but at least you can see us struggle to make it better in real-time and with transparency.
No other social media companies do this.
BREAKING: 𝕏 has open sourced its For You feed algorithm, the same production system running today and powered by Grok from xAI. The full code is live on GitHub and will be refreshed every 4 weeks.
Your feed blends posts from accounts you follow with posts discovered across all of 𝕏, then ranks them using a Grok based transformer that predicts how likely you are to like, reply, repost, click, or watch. Instead of one simple score, the model predicts many actions and combines them for a more nuanced ranking.
Everything learns directly from user behavior. Intelligence lives inside the model, not scattered pipelines. The system is modular, transparent, and stable, with each post scored independently so results are cacheable and consistent.
This is one of the most open looks ever at a large scale social feed ranking system.
Grok explained the newly open sourced X algorithm in 10 clear and easy points:
1) When you open the "For You" feed on X, it starts by gathering your personal info, like who you follow and what posts you've liked, replied to, or shared in the past—this helps customize what you see.
2) Next, it collects potential posts from two main places: ones from people you already follow (called in-network) and new discoveries from across all of X (called out-of-network) that might interest you.
3) The in-network posts come from a fast system that stores recent updates from your followed accounts in memory, making it quick to grab without delays.
4) For out-of-network posts, it uses smart AI to compare your interests (based on your history) with all posts on X, picking ones that seem similar or relevant through a matching process.
5) Once it has these candidate posts, it adds extra details to each, like the post's text, images, videos, author's name, and whether they're verified or if it's behind a paywall.
6) Then, it cleans up the list by removing duplicates, old posts, your own stuff, anything from blocked or muted people, keywords you don't like, or things you've already seen.
7) Now, a powerful AI model (based on Grok) looks at your past interactions and predicts how likely you are to like, reply, repost, click, or even dislike each post—giving each a score.
8) It combines these predictions into one final score per post, boosting good actions (like likes) and lowering bad ones (like blocks), while adjusting to mix in variety so one person doesn't dominate your feed.
9) The posts are sorted by these scores, and the top ones are selected to create your feed, ensuring a balanced mix of familiar and new content.
10) Finally, it does one last check to remove any deleted, spammy, violent, or inappropriate posts, then serves up the ranked feed for you to scroll through.