Follow Slashdot blog updates by subscribing to our blog RSS feed

 



Forgot your password?
typodupeerror
×
Twitter Open Source

Twitter Opens Much of Its Source Code To the Global Community 70

Twitter blog: At Twitter 2.0, we believe that we have a responsibility, as the town square of the internet, to make our platform transparent. So today we are taking the first step in a new era of transparency and opening much of our source code to the global community.

On GitHub, you'll find two new repositories (main repo, ml repo) containing the source code for many parts of Twitter, including our recommendations algorithm, which controls the Tweets you see on the For You timeline. We're also sharing more information on our recommendation algorithm in this post on our Engineering Blog. For this release, we aimed for the highest possible degree of transparency, while excluding any code that would compromise user safety and privacy or the ability to protect our platform from bad actors, including undermining our efforts at combating child sexual exploitation and manipulation. Today's release also does not include the code that powers our ad recommendations.

We also took additional steps to ensure that user safety and privacy would be protected, including our decision not to release training data or model weights associated with the Twitter algorithm at this point. Ultimately, this is our first step to be more transparent in this way, and we plan to continue sharing more code that does not present a significant risk to Twitter or people on our platform.
This discussion has been archived. No new comments can be posted.

Twitter Opens Much of Its Source Code To the Global Community

Comments Filter:
  • Doesn't seem real useful then, since that's what would actually determine the results of using the model.
    • Of course not. It might validate the study that conservative views travel faster on Twitter. https://cdn.cms-twdigitalasset... [cms-twdigitalassets.com]

  • by drnb ( 2434720 ) on Friday March 31, 2023 @02:19PM (#63414972)
    A vey good first step, may others also do so. Transparency is necessary.
    • by grebke ( 2881557 )
      It doesn't appear to be complete transparency because TFA said "opening much of our source code". I'd like to also see the code that they are not sharing.
    • A vey good first step, may others also do so. Transparency is necessary.

      Assuming they actually opened the crucial parts of the recommendation algorithm, I expect the production code to quickly diverge. The problem is that there are too many people and organizations who will benefit from being able to game the system and thereby ensure that their tweets get widely recommended.

      Heck, if I were running Twitter, I might publish incorrect recommendation code simply to waste the effort of Tweet "optimizers", and make the actual code more effective. I don't think Musk has done that, though.

      • They left out the crucial 'weight' information which would allow you to do that. Anyone who doesn't already know getting more likes or retweets make it more likely to be recommended should go back to school.
        • Maybe. I'll bet you can still glean information that can help you game the system. Perhaps with a little experimentation you can even discover the weights, given knowledge of precisely how they are applied. (Note that I have not looked at the code.)
    • Re: (Score:2, Informative)

      by Anonymous Coward

      The biggest problem is that despite the headline of open sourcing their source code, this is literally just the recommendation algorithm.

      Specifically there's nothing here that tells us that this doesn't just provide base recommendation functionality, but that there's no other manipulation on top. It's perfectly plausible that whilst this does the basic recommendation, there's an entire layer of manipulation and boosting on top.

      Given the algorithm is changing too, the question is whether this is their master

      • "What he probably didn't want you to know" What??? You're showing code HE OPEN SOURCED!! Did the prior owners ever show how they were shadow banning anyone to the left of Mao?? "Either way, it's clear that under Musk Twitter is an incredibly biased misinformation platform designed to push people to Musk's world view over and above that of others." That is the most irrational thing I've heard in some time. He has done nothing of the sort, and you have zero evidence for that assertion. An "incredibly b
      • by tlhIngan ( 30335 )

        Now you may wish to give him the benefit of the doubt, and pretend he is naive to this, but, well, when he was questioned about it in a Twitter space he played dumb and immediately ended the Q&A. Besides; his brother openly was looking for engineers to rig his posts views too when he got salty about Biden's superbowl post getting more views than his.

        Elon Musk knows. He specifically requested this after Biden got more engagement than him during the Superbowl [businessinsider.com].

        Yes, it actually resulted in people seeing not [theverge.com]

    • by Reziac ( 43301 ) *

      A radical idea comes to mind:

      If you collect user data, you must publish the relevant code.

  • Really awesome (Score:5, Interesting)

    by Anonymous Coward on Friday March 31, 2023 @02:48PM (#63415052)
    This is huge for social media as a whole. I predict any social media company that does NOT open source their code in the near future will suffer from a lack of trust. This is a huge leap for transparency in social media, where people are being manipulated left and right by bad actors, governments, and special interests. At the very least people should know how the code works. I applaud this decision.
    • nah. Twitter is only for crazy people and has close to zero market share.
      • Re: (Score:3, Interesting)

        by Anonymous Coward
        450 million monthly active users. Not as big as Facebook, but Twitter definitely is #1 in marketshare when it comes to dictating ideas and policy.
  • by Comboman ( 895500 ) on Friday March 31, 2023 @02:48PM (#63415056)

    The recommendation code looks pretty simple:

    if (tweet_author=="elonmusk") {timeline_position = 1};

    • Re: (Score:3, Informative)

      by Anonymous Coward

      How did you guess? You were almost there, here's the actual code, you probably just needed to Scala-ify your attempt and you'd probably have nailed it:

      https://github.com/twitter/the... [github.com]

      "author_is_elon",
      candidate =>
      candidate .getOrElse(AuthorIdFeature, None).contains(candidate.getOrElse(DDGStatsElonFeature, 0L))),

    • You can have that privilege on my social network if you spend $44bn.

  • by henni16 ( 586412 ) on Friday March 31, 2023 @03:55PM (#63415194)

    Oh, voluntarily this time

  • Twitters gettin great
  • There aren't a lot of people that work with and contribute to a large project in Scala. A good chunk of them actually worked at Twitter of course. Not to mention all the Mesos hooks.

    I know there is a lot talk about how outdated and brittle the Twitter thing is, but they fact that the company could be decimated to the degree it was and still stay up shows how well that stack can work.

    In then end, best of luck replacing it with a hodgepodge of who knows what from Node, Java on top of some Kubernetes kludge.

  • Code doesn't matter *at all* for this sort of thing. Only data does.

    To greatly simplify: for any pair of speaker and listener in this scenario, you have a DB entry that holds how likely the listener is to "approve of" the tweet, based on past retweets, likes, etc etc. That base value is then adjusted by "friend of a friend" factors, and so on. The core algorithm itself can literally be implemented in ten lines as a simple MUL loop of fractional weights (or a MAD'ed polynomial, etc), optionally recursed out

  • Dear Musk. Twitter is not the Town square. You're a privately owned shopping mall with security and a nutjob for an owner who wants to push people out of the shop every time he takes the podium.

  • Today this seems to be some sort of joke.
  • Read through some of it. Quite interesting, Most of the code is as I expect however some of it looks quite innovative. Looks legit.
    I am fascinated that they used a case statement with some dot products and sine functions when running their algos. The rest looks like vanillar coding.

  • Producing the source code isn't one of them. All social media corps need to be doing this. However, since he still maintains Master Control, nothing much really changes.

To stay youthful, stay useful.

Working...