X Open-Sources Its Grok-Based Recommendation Algorithm

X has open-sourced its Grok-based recommendation algorithm, marking a significant shift in social media transparency and architecture.

X Open-Sources Its Grok-Based Recommendation Algorithm
X logo with an AI algorithm icon

On January 20, 2026, X (formerly known as Twitter) open-sourced its core recommendation algorithm, which uses a transformer model based on Grok. This step represents a significant shift in social media transparency and architecture, giving the public unprecedented access to the platform's inner workings.

System Architecture: Thunder and Phoenix

The source code available on GitHub reveals a four-stage ranking pipeline, designed to evaluate thousands of posts in under 200 milliseconds. The two main components are:

  • Thunder: Handles in-network content, ensuring immediate visibility of posts from followed accounts without requiring expensive database queries.
  • Phoenix: Handles the discovery of out-of-network content, using a two-tower retrieval model that encodes user interests and candidate posts into vectors, selecting matches through dot-product similarity.

Engagement Signals That Shape the Feed

Each post receives a final score, calculated as the probability of an action multiplied by a weighted importance factor. Positive signals include replies, profile clicks, video watch time and direct shares, while negative signals include "Not Interested" feedback, muting or blocking the author, content reports and low account reputation.

Transparency and Implications for the Industry

The source code release came amid growing regulatory pressure. In December 2025, the European Union fined X 120 million euros under the Digital Services Act for insufficient algorithmic transparency. With this move, X aims to demonstrate political neutrality and invites external scrutiny and ongoing improvements. The repository will be updated every four weeks, allowing regulators, researchers and developers to watch how the algorithm evolves in near real time.

Conclusion

The open-source release of X's recommendation algorithm marks an important step toward greater transparency in the social media industry. The implications include:

  • Collaborative Innovation: The community can contribute to the algorithm's continuous improvement, leading to more effective and personalized solutions.
  • Increased Accountability: The visibility of the code increases X's accountability for algorithmic decisions and the handling of user data.
  • Impact on the Industry: Other platforms might follow suit, promoting a culture of transparency and collaboration in the social media industry.

This initiative represents a significant change in how social platforms manage and share their technologies, with potential benefits for users, developers and the entire digital ecosystem.