purifier

The Unseen War – Purifiers, NCPs, and Open Source Development

    Over the past few months, I’ve been following a rather divisive topic in the world of Screeps- the matter of NCPs, or Non-Coding-Players. To understand the matter I’m to bring forward today, it’s important to understand the history and context of the idea of NCPs in Screeps (a separate article about the full history is in progress).

A Brief History of Bots

As many are aware, open source code is often more than a legal or financial decision- the decision to release code as open source can often be a philosophical one or one made out of a sense of moral obligation or wanting to give back to the community. To that end, a number of prominent players have released their codebases online. The earliest of these was TooAngel, who for a time endeavored to make his released bot interesting to interact with but has since discontinued development. At the time, TooAngel’s bot was considered a minor curiosity, but its extremely poor combat capability, bad economy, and predictable behavior meant that it was often treated similarly to a “Zombie”, or inactive player.  

    As time passed, further bots were made open source. One of the first major turning points was when the powerhouse player Bonzaiferroni released his codebase to the public with the hope to inspire other players and provide ideas for further development. Unfortunately, new players then took his code and used them to rampage through undeveloped novice areas, decimating players attempting to develop their own code and considerably threatening established players.

    In a decision that took no small amount of effort to accomplish, Bonzaiferroni not only stripped his open source bot of any and all offensive combat capability, but retroactively deleted all references throughout the public repository in which the code was stored. While concerns about the risks of un-defanged copies of BonzAI floating around persisted, the matter was largely resolved.

    Nevertheless, BonzAI was the first known instance of open source AIs collaborating together, albeit in a relatively passive way. BonzAI was listed as being the AI that bonzaiferroni ran on shard0, and therefore it came preloaded with Bonzai’s preferred trading partner defaults. During an unannounced brushwar between ThunderKittens and The Culture, The Culture member Tedivm discovered this. While the BonzAI repo clearly stated that unintended behavior would result from attempting to run it unmodified on live and advised against it, Tedivm felt that Bonzai hadn’t gone far enough to clarify that this would result in BonzAI players sending Thunderkittens resources. (For anyone interested in reading the raw, unfiltered drama, check out the GitHub repo here https://github.com/bonzaiferroni/bonzAI/issues/14 )

    Other open or collective bots came and went. The OCS(Open Code Society) tried developing a bot collectively, but they soon fractured into no less than three different subgroups and further progress was somewhat limited. Furthermore, in at least one iteration of OCS military code was in a repo limited purely to contributors, differentiating between those that contributed to the codebase and those that simply ran it. This split further enforced an idea that had existed for some time that open source code in the hands of noobs was fine, but giving them combat code was crossing a line.

    Other majors bots included:

  • Kasami made the popular K-Bot, for a time earning the award of “Most Annoying Bot” due to it’s highly aggressive behavior before Kasami stopped development for similar reasons as Bonzai. Shortly thereafter, it was discovered that an optimization introduced for the Screeps Warfare Championship caused K-Bots running on live to abandon threatened rooms. This can be easily exploited and has reduced its’ popularity.
  • Andromeda, closed source but distributed among the SUN alliance, made a devastating showing against Ypsilon Pact in the Poacher’s War.
  • Quorum, another open source bot developed largely by Tedivm but with support from several others and utilizing a novel system of voting for PRs based on contributions, took the place of K-Bot as the “Most Annoying Bot” for a brief time. Unfortunately for Quorum, its combined habits of putting signs everywhere it could reach and sending single MOVE creeps to step on construction sites and generally get in the way resulted in it being nearly wiped out.

    Suffice to say, open source bots, and by extension non-coding players, have been around since nearly the beginning of Screeps and are nothing new. Neither, by extension, are the extents some players will go to flush them out; Many players will go out of their way to seek out and destroy NCPs for various reasons. Some players see them as easy targets, some abhor what they represent, some dislike the fact that players benefit without work, and so on. On the other hand, many modern codebases are based on fragments of open source code. Warinternal, ever active in slack’s help channel, is sometimes joked to have a line in every codebase, and modified snippets from #share-thy-code have been found in public codebases. BonzAI’s mission system and quorums OS model have both become standards used by many an AI, and I among many others have taken advantage of open source codebases to, when faced with a seemingly unsolvable problem, see how others might have gone about it.

For many, their battle against NCPs shifted when Tedivm, developer of Quorum, released LOAN’s clone map. Deliberately closed source to prevent spoofing, LOAN’s clone map was able to identify and highlight NCPs and make that information available in public segment 98 of the “LeagueOfAutomatedNations” user in-game.

Many users, and indeed entire alliances, used this information to great extent. The (then) newbie alliance Spawn More Overlords banned any members from running open-source bots without being active developers, and alliances like SemperRexOfficia went to far as to automatically nuke and assault bots detected within range.

On the other end of the spectrum, a new bot was being developed by a player called Muon: Overmind. Overmind is unlike any bot previously developed. It’s highly intelligent, has very few real weaknesses, expands effectively, and holds its own in the face of aggression. However, it is notable for being the first networked bot to become popular. Called the “Assimilator”, Overmind has a module designed with the intention to allow all Overmind bots to act in unison.

New Developments

It was in the process of research and interviews for an article over the history, community, and future of NCPs (some small portion of which is covered above) that I became aware of a shadowy war taking place against the backdrop of shard2. A war unannounced, undeclared, and yet waged with a ferocity that exceeds anything I’ve seen in the last year or more.  I speak of a group that extends beyond alliances, yet without organization. With massive resources, yet very limited cohesion. I speak of a group calling itself “The Purifiers”.

I’ll be honest, reader- My information on the group of players calling themselves the Purifiers is extremely limited. From what I can tell, they grew in an unorganized, sporadic way as players with NCP neighbors began to organize with each other, and then reached out to others who also were attacking their NCP neighbors. Similar to a grassroots movement (or insurgency, depending on your point of view), this group has expanded over much of the game. When they started calling themselves Purifiers is inconsistent (In my interviews I got at least three different conflicting stories).

This war raged against Overmind bots on shard2 seems to have largely been an action of various people calling themselves Purifiers, though muddying the waters somewhat- not all. I spoke to one player, mistakenly thinking them to have been a part of this group, and they instead told me of their own personal crusade against one specific overmind. They only discovered the presence of these “Purifiers” when almost certainly about to die, as a hitherto unknown Purifier sent a large strike force against the NCP they were fighting, turning the battles in their favor. It was only then that, somewhat to their alarm, they realized they were in the middle of a war between the Purifiers and Overmind.

On the other end of the spectrum, Muon has accelerated his development, adding remote diagnostics (read: remote code execution using `eval()`), improved use code for users, smarter spawn behavior, and better intelligence gathering. He’s also made considerable advances in inter-bot coordination, and smarter combat code is reportedly underway. Unfortunately, at least on shard2, this hasn’t been enough to stem the tide of assaults against Overmind made by the Purifiers and others. Nevertheless, Muon continues to strive forward with ever more coordinated copies of Overmind. As someone following his progress over time, the steps forward made by Overmind have been particularly impressive.

On a personal note, however, I’m not certain it will matter. Muon’s Overminds are heavily outnumbered, facing some of the most experienced veterans Screeps has to offer, and the ratio of development-hours simply aren’t in his favor. Further, Purifiers have been coming out of the woodwork- shard2, once populated heavily with Overmind NCPs, has now only a small pocket of holdouts in the southeast. Shards 0 and 1 have also experienced a severe downtick in the number of Overmind players, possibly due to other members of these Purifiers.

The Purifiers Come Forward

NOTE: My original conclusion here has been removed- as I was preparing to post this on ScreepsWorld, a player claiming to represent the Purifiers reached out to me. While I have reservations about the ability of any single player to claim to represent the group, what they said was relevant and I think it better the place of you, the reader, to have all the information as to better draw your own conclusions.

P: “Hey, so I heard you were looking into the NCP thing, been asking around about the Overmind thing?”

K: “Mhmm.”

P: “Doing an article on it?”

K: “Maybe.”

P: “Just wanted to leave this here. i.imgur.com/mDSXsqw.png  – this is what I’m after. That’s it.”

K: “You realize though that there’s a problem right? Your group seems to hate NCPs with a passion, to the point of wiping out Muon who, I think we can both agree, writes his own code.”

P: “That isn’t representative of all of us though. Sure, a few want to kill him, but not all of us.”

K: “And the rest of you?”

P: “Some want to kill him, sure, but that’s their decision. We [The Purifiers] are together to stop the spread of NCPs and get people to run their own code. You’re a math guy, right?”

K: “Somewhat.”

P: “Muon introduced an attractor to an unstable system. New players are pushed into running open source bots, and when all the bots cooperate, that results in a meta where the only smart thing to do is to run an open source bot that cooperates. Anything else is suicide.”

K: “And you think that’s a risk?”

P: “Thanks to us, no.”

K: “So what, you expect everyone to thank you for saving us from the bot-pocalypse? A little narcissistic, don’t you think?”

P: “I could give a shit what you (or anyone else) think. It’s about people writing their own code, and we won’t stop until there isn’t a single NCP left.”

K: “And you think you can pull that off?”

P: “We have so far.”

K: “And you think that’s your call to make?”

At this point they refused to answer further questions, and I will admit to some annoyance at someone taking the opportunity to have a pithy one-liner instead of answering questions to the point where I had some reservations about including it in the article at all, but I feel like it’s necessary for analysis.

Now, to go over what this Purifier seems to have implied-

    Firstly, there’s the bit about targeting NCPs, not actively writing players. This would somewhat explain why Muon, the developer of Overmind, is still alive on shard2 despite being surrounded by Overmind bots that have thus far been under heavy attack.  The cynic in me wonders if this wasn’t deliberate to make it harder to design defense code. Realistically, however, other Overmind players have been wiped out relatively quickly, so I’m not sure having an easier time writing defense code could have mattered much. I rank this one as Probably accurate, but time will tell for sure, especially if these Purifiers end up going after NCPs other than just Overmind. (Authors Note: It’s also possible they have been going after non-Overmind bots. They don’t tend to announce themselves, so it’s hard to tell if someone killing a bot was personal, opportunistic, or part of a larger movement. Given the ad-hoc nature of the group, there are also questions if someone acting as a Purifier against NCPs without knowledge of the group counts as a Purifier regardless).

    Secondly, there’s the bit about bots driving people to use bots. While the number of active bots has gone back and forth a bit, it’s pretty well understood that bots in novice zones frustrate novice players into running more bots. As to if that’s a shard-wide risk I’d say… maybe? It’s hard to say. Such bots could dominate a shard, certainly, but the ratio of man-hours would imply otherwise. The OCS  never achieved that much, and they had far more in the way of development assets. Overall, I’d rank that as Probably technically true, but I mean, c’mon, and overall I’m not sure how valid that argument is. It’s also built on the assumption not just that Muon could take over the shard, but that he’d actually want to.

    Thirdly, there’s the matter of the organization of the group. The fact that this person reached out to me implies that there’s some level of organization, or at least communication, between purifiers. That said, even if it’s meant to be a top-down group, if no one on the bottom knows they’re on the bottom, then that person won’t know to follow orders from above. I’d rank this as Probably True, regardless of if someone thinks they’re in charge of the Purifiers or not if no one else knows then it doesn’t matter.

    There’s also the matter of why the Purifiers do what they do. The player I spoke to stated that their goal was to convince NCPs to run their own code. Notably, this is not the case for all the purifiers I spoke to. Some simply took issue with the unfairness of someone getting benefits from code they didn’t write. Others see networked code like Muon’s Assimilator as an existential threat. Some think they’re turning NCPs straight. One also claimed that an NCP killed their family, a claim of which I am highly skeptical.

    Lastly, there’s the issue of it not being the group’s responsibility if a chunk of it wants to attack Muon or other bot developers. This is a tricky one, and an issue that Anonymous has faced in the past- if anyone can be a Purifier (which seems to be the implication), then can Purifiers act outside the ideals of the Group? Is there a line that can be crossed? If everyone in a group decides to do a thing, is that not a factor for the group, even if they claim they’re all doing it individually? I rank this one as I’ve got no goddamn idea.  

Further Analysis

    An interesting note here, between the communication, the inconsistent organization, and so on, is that there seems to be an idea that all it takes to be a Purifier is for the player to decide to be a Purifier. This also makes a bit of sense given the group’s grassroots origins. That being said, I also wonder about this conversation overall, because it reeks of some sort of prepared statement. It is also worth noting that I interviewed a number of non-coding players and bot developers. Several common themes appeared:

    First, most NCPs tend to fall into one of  three broad categories. That is to say, they tend to be players who feel like they have no choice but to run a public codebase to remain competitive, players who want to have the benefits of a fully functional codebase while they dismantle it and learn from better programmers, and players who are going to contribute to the codebase, but haven’t done so yet.

    I actually strongly empathize with the first type. Real life can be brutal and make it very difficult to focus on programming for Screeps. It can be extremely frustrating to see a colony die over the course of a week or so while you’re unable to take the time out to save it. On the other hand, I’ve very rarely spoken to players that have transitioned from running an open source bot to running their own code and it seems to be a somewhat rare case. In this case, I feel that the open-source code is being used as a crutch that in the end simply hinders the player, though I understand the desire to not fall behind. The third group is a tricky one. Players contributing to codebases they run is a laudable goal, and I personally like the idea of tracking not just who’s running a public codebase, but who has contributed to it as I feel there’s a difference between killing a random noob for running Overmind and killing, say, Muon, for running overmind.

That being said, it’s an unfortunate truth that the majority of open codebases are single developer. Muon has made over ninety-five percent of Overmind contributions. Tedivm did more work on Quorum than every other user combined, and Ags131, the second greatest contributor, committed almost twenty times the code of the next greatest contributor. TooAngel, the oldest open-source bot and once run all over shard0, only ever had six players that contributed more than a thousand lines of code and again, the lion’s share of the work was done by TooAngel and the rest of the contributors combined making up for less than ten percent of all work done on the TA Bot. While I don’t know of any open copies of Andromeda it was for a long period of time the flagship codebase of the SUN alliance, and I’ve been informed that the code not written by Atavus is so limited that it is within a statistical rounding error of being a single-user developed codebase. Incidentally, BonzAI and K-Bot were both single-user developed.

As a result of this, I have a hard time buying into the idea that a player is going to contribute to an open source codebase in any meaningful way, and many of Quorum’s (still remarkably few) contributors make very limited changes- correcting spelling errors, changing config values, and so on. The typical change made to an open codebase by a player not the primary developer is less than ten lines of code.

Of course, we can’t focus on the NCPs without focus on the people designing the code that they run: the bot developers themselves. These too found a common theme: none of the developers I spoke to had really considered themselves to be writing a bot. Bonzai, Muon, and Kasami all made their codebases open as a matter of principle, and then later found that others were taking the code and running it wholesale. Others intended their code to be used as a bot to play against on private servers, to replace the default simple-bot, going so far as to publish to NPM to make it easier to install as a mod. Quorum was designed to be community developed (as evidenced by the voting system used for handling pull requests), and Tedivm and the other developers deliberately prevented Quorum from either collaborating or hiding its presence. TooAngel too simply made his code open and then later found that other users were running it. In the cases of Muon, Bonzai, and TooAngel, the response by the bot developer was often to try to get some benefit out of everyone running their code. Actual opinions on NCPs themselves varied, but the consensus was often that they weren’t a major factor in development and that the bot was open source for open source’s sake.

    Savvy readers will no doubt notice parallels between bot developers considering themselves not responsible for their NCPs and Purifiers considering themselves not responsible for the behavior of their individual members. As a result, I can’t help but feel that the main conflict here is between the NCPs and the Purifiers.

In any case, the battle between Purifiers, NCPs, and Open Source developers will continue, if not on shard2 then elsewhere, and I for one look forward to seeing the end result of this, wherever it may be.

For ScreepsWorld, this is Knightshade.

Note: An early version of this post included references to Tigga that have been removed. Though I wouldn’t rule out Tigga being one of these “Purifiers”, I suspect the initial connection made during my investigation was purely coincidental (and possibly someone trying to talk big). Further investigation is required, though I expect things will become clear in the coming weeks.

Share this post

Share on facebook
Share on google
Share on twitter
Share on linkedin
Share on pinterest
Share on print
Share on email