Paperclips, Thanos, and the Perils of Overfitting

Paperclips, Thanos, and the Perils of Overfitting

Some people have a lucky hat or a lucky pair of socks. I have a lucky paperclip. My freshman year of college, I would set it on my desk during exams to help me do well, and I passed every test that it was present for! 

In sports, athletes will sometimes have a lucky phrase they say or a routine such as adjusting their socks or taking a certain number of breaths before a critical play. Many athletes swear by them, claiming they’re an essential part of their success. But do any of these things actually work? Maybe these routines calm them down so they can focus on what they’re doing. Maybe my paperclip was a subconscious reminder to be organized and meticulous. Or maybe these are all examples of overfitting. 

Overfitting is when a machine learning model learns patterns from its training data that don’t generalize to the real world, often because those patterns are irrelevant, coincidental, or just noise. As a consequence, the model behaves in strange or irrational ways once it gets set loose in the real world. And this isn’t just a machine problem–people do it too! We sometimes latch onto the wrong cause-and-effect relationships, mistaking luck or ritual for actual influence, which is how you end up believing in the power of a paperclip during exams. Or adjusting your socks and saying a catchphrase as part of your bowling routine. Or, in a slightly more extreme example, attempting to destroy half of all life in the universe. 

Thanos probably failed his machine learning class

Movie villains often claim to be doing their evil acts for the greater good. But they’re really bad at identifying that greater good, and I think it’s an overfitting problem. In Marvel’s The Avengers movies, the villain Thanos saw his home planet collapse from overpopulation, and so he decided to dedicate his life to killing half of all living things in the universe to prevent overpopulation. That’s a textbook example of overfitting to a narrow data set. If Thanos had bothered to validate his solution by first testing it on one planet instead of the entire universe, or even performing any kind of simulation or sensitivity analysis, he would have seen that killing half of all living things doesn’t actually solve the problems he was worried about. 

Figure 1: Thanos has an overfitting problem. Image from https://imgflip.com/i/9gu8h4

Here are a few more examples of overfitting and related concepts that you might find interesting:

  1. Cramming for a test: You memorize all the answers on the practice test, but when you give the exact same answers in the exact same order on the actual test, your teacher fails you. What’s up with that? It turns out that instead of just memorizing the answers (i.e., overfitting), you were actually supposed to learn the material.

  2. Conspiracy theories: A conspiracy theory links together minor pieces of information to build a convoluted (i.e., overfit) story about how the people you don’t like are doing bad things, instead of only holding beliefs backed by sufficient evidence. 

  3. This coding problem: “Write a Python code to convert a written number in word form to numeric form. For example, given the string “Three hundred twelve”, return 312. Or, given the string “forty-two”, return 42.” See its overfit solution in Figure 2.

  4. Goodhart’s law [1]: “When you make a measurement into a target to optimize for, it stops being a good measurement.” This saying is known as Goodhart’s law, and it happens because of overfitting. My favorite example of Goodhart’s law is the story of a Soviet Union nail factory where the managers were rewarded based on the number of nails they produced, and so they made a bunch of tiny, useless nails. Then, when the target was shifted to weight, the factory made oversized, useless nails. In each case, the nail factory overfit to the specific metric they were trying to optimize for (number or weight) instead of keeping to the broader objective of producing useful nails. 

  5. Occam’s Razor: In philosophy there’s a problem-solving principle called Occam’s razor, which says that the simplest explanation that matches all your data is the most likely to be correct. This principle is also used in medicine, where doctors are taught “if you hear hoofbeats, think horses, not zebras”. In other words, don’t jump to rare or overly complex explanations when a common one will do. The core idea of Occam’s razor is that by choosing a simpler model, it will help you avoid overfitting. 

Figure 2: I saw this as a Reddit meme. I can’t find the original, so I reproduced it myself.

Overfitting makes it so that too much optimization can actually make things worse. And in machine learning we deal with that in the same way that teachers make sure their students learn the material: by hiding some of the questions so the answers can’t be memorized in advance. You set aside about 20% of your data as a test set, then you only run your optimization on the other 80% to fit a model to that data. If that model can answer the 20% of questions it hasn’t seen yet, then you know it’s learned the material, but if it can’t, then you’ve probably fallen victim to overfitting and you need to simplify your model. As a general rule, the solution to overfitting is to simplify. 

What does this have to do with engineering design? 

Here are a couple ways that understanding the concept of overfitting can help you get generalizable, robust solutions to your engineering design problems.

  1. Responding to feedback. There are two errors you can make when responding to feedback: not taking it seriously enough or taking it too seriously. I tend to suffer from the first problem more often, but I want to mention the fact that the second one exists and is an example of overfitting. Consider Microsoft’s “Clippy”, a very early paperclip-shaped AI assistant used in Microsoft Office 97. Clippy was designed to help users navigate Office features, but instead, it became an intrusive, over-engineered feature that frustrated users more than it helped [2]. Clippy was intended to make Office easier for beginners, but in trying to accommodate that group, they made the experience worse for the majority. 

  2. Fixing rare outlier cases. Computer science has a semi-joking technique called the “ostrich algorithm”: If a problem is very minor or exceedingly rare, then bury your head in the sand and ignore it. Sometimes responding to a minor problem has the potential to create more problems down the road, and so it’s better to just ignore it and keep your life simple. But please do not use this algorithm when there is a potential safety concern!

  3. Quality and robustness testing. When testing your design, it’s important to see how well it does in real world conditions. Otherwise, you might accidentally optimize it for idealized lab conditions and fail when you try to deploy it. There’s an interesting case study with the Mars Perseverance rover. They didn’t want to risk getting the actual rover damaged during testing, so they built a perfect twin, named OPTIMISM, which they tested on the type of terrain they expected to see on Mars. This allowed the NASA engineers to make sure the actual rover could safely execute the commands they sent it, and it also let them uncover any unexpected problems Perseverance might encounter [3].

  4. Design optimization. You rarely, if ever, only have a single design objective. Generally you will need to consider cost, time, performance, and manufacturing constraints, just to name a few. It’s common to simplify the problem and focus on a single objective such as cost or performance when optimizing your design. This is a good initial strategy, but it can sometimes lead you to overfit for that objective and lose out on the others. That’s why it’s useful to go back afterward and look for a design that meets your other goals better, or a simpler design that has less chance of unexpected problems.

Overfitting can rear its ugly head whenever you are trying to optimize something, but it can be mitigated by simplifying your design and validating it in the real world. Sometimes it is hard to recognize that you have an overfitting problem, so I hope some of the examples in this article have given you some practice. 

Conclusion

In conclusion, overfitting is all about paperclips. It caused me to keep a lucky paperclip on my desk during tests.  It caused Microsoft to create an annoying paperclip-shaped virtual assistant. And it might cause a future artificial intelligence to turn the world into paperclips. There is a thought experiment called the “paperclip maximizer” [4], where an AI is given the goal of making as many paperclips as possible, and it takes this goal too literally and tries to turn everything on Earth into paperclips. The paperclip maximizer is so overfit to the goal of maximizing paperclips that it neglects other goals that its creators would have preferred to account for, like human safety. So don’t be the engineer who’s responsible for releasing a paperclip maximizer on the world, make sure to properly test and validate your designs before deploying them!

Figure 3. Image from https://imgflip.com/i/9gu8vf

Sources:

[1] "Goodhart's Law." Model Thinkers, modelthinkers.com/mental-model/goodharts-law. Accessed 21 June 2025.

[2] Wulff, Jennifer. "The Tragic Life of Clippy, the World's Most Hated Virtual Assistant." Mental Floss, 19 Nov. 2017, www.mentalfloss.com/article/504767/tragic-life-clippy-worlds-most-hated-virtual-assistant. Accessed 21 June 2025.

[3] "Twin of NASA's Perseverance Mars Rover Begins Terrain Tests." JPL NASA, Jet Propulsion Laboratory, 10 Nov. 2020, www.jpl.nasa.gov/news/twin-of-nasas-perseverance-mars-rover-begins-terrain-tests/. Accessed 21 June 2025.

[4] "Instrumental convergence." Wikipedia, Wikimedia Foundation, 10 June 2025, en.wikipedia.org/wiki/Instrumental_convergence. Accessed 21 June 2025.

To cite this article:
McDonald, Mark. “Paperclips, Thanos, and the Perils of Overfitting.” The BYU Design Review, 14 July 2025, https://www.designreview.byu.edu/collections/paperclips-thanos-and-the-perils-of-overfitting.

America The Beautiful - How Ansel Adams Designed his Landmark Landscapes

America The Beautiful - How Ansel Adams Designed his Landmark Landscapes