Quirk is a new GPL-licensed Cognitive Behavioral Therapy (CBT) app for iOS and Android built in React Native/Expo. The app helps users challenge their “automatic thoughts,” a term that refers to thoughts that come to a person spontaneously in response to a trigger, which can often be negative.
Quirk lets users record a quick thought and will automatically narrow down a list of potential ways these thoughts are distorted. The distortions were inspired by the ones popularized in Feeling Good: The New Mood Therapy. The user is then invited to challenge those distortions and write an alternative thought.
Evan Conrad, a software engineer at Segment, created Quirk as a non-commercial, personal project to make it easy for people to take control of their irrational thoughts using a common CBT technique. Quirk is not a substitute for a trained therapist but rather a tool for people to use on their own. Left unchecked, negative automatic thoughts can become emotional weights and lead to distorted thinking. Quirk is a simple app that helps people experience the world in a less negative way and develop more rational thinking patterns.
“It’s super useful for day-to-day stuff,” Conrad said in response to comments on Hacker News. “Take a thought like ‘I took too many hints in that interview question.’
“That thought might lead to ‘I must have failed that interview,’ which leads to ‘I’ll fail all the rest of my interviews,’ which leads to ‘I’ll never get another job,’ which leads to ‘I must be really bad at this, I should just give up.’
“Each step seemed kind of logical at the time, but one thought led to the next and now you feel awful.
“CBT is a counter measure to this; it stops you at that first point and gives you a bunch of common logical fallacies that help you recognize why your thought is overreaching. You don’t know if you really flunked that interview, besides flunking one is good practice to pass the next one.”
Conrad said these types of thought processes aren’t exactly a mental health issue but are common struggles for many people. Quirk can be a useful tool for anyone looking to recognize and remove their own cognitive biases.
The iOS version of the app currently works better than the Android one, as the author said he doesn’t have an Android phone and finds it difficult to support the app on that platform. However, fixes are being pushed out regularly and many of the issues with crashing are getting resolved.
How the GPL Protects Users in Mental Health Tech
The code for Quirk can be found on GitHub and is open source under the GPL-3.0, which is not a popular choice for licensing mobile apps. I asked Conrad why he opted for the GPL license, as opposed to other popular open source licenses.
“Mental Health tech is a really weird world,” Conrad said. “There’s a lot of folks who want to do the right thing, but end up doing really sketchy stuff.
“For example, a lot of apps collect the thoughts you’re recording for ML (Machine Learning) or NLP (Natural Language Processing). The stated purpose of this is to help better identify suicide, depression, etc. Partially because of the subject matter, many apps aren’t clearly telling their users that this is happening.
“So what ends up happening is a bunch of well intended researchers get access to your most sensitive thoughts. Which is fine, but they frequently aren’t aware of how valuable of a target they’re holding to a nefarious actor. Because it’s not like a database of passwords or credit card numbers, they tend to not think about security.
“But thoughts are super valuable and dangerous for abusers and blackmailers; plus most people would rather give you their password in plaintext than show you their mental health thoughts.
“So if I made Quirk MIT, I would worry that someone would take Quirk and launch their own version for research that tracks and stores user thoughts. Because the license doesn’t follow them, they could do it without telling a user and there would be little way for an average person to /know/ that this is happening.”
Conrad has taken an inspiring, user-centric approach to licensing and privacy that ensures users of his app (and any derivatives) will have access to the code and a better understanding of where their data is being stored. In a recent Twitter thread, he outlined the privacy principles that underpin Quirk’s architecture:
In Quirk, FOSS and privacy isn’t a focus, it’s a given. Outside the tech world, Quirk is not trying to be a FOSS CBT app, it’s trying to be a really good CBT app that happens to be FOSS. It’s not coming out and saying “hey we don’t store your deepest darkest secrets on some server somewhere.” User’s don’t care. It’s a given. It doesn’t store things on the device because it’s trying to sell you on privacy, it does it because it’s the correct engineering decision.
Regular people don’t look at the Golden Gate bridge and think about the structural quality of the bolts. They pull out their phones and take a picture. The responsibility of software is to make things frictionless and reduce the stuff someone has to think about before buying in.
Conrad said he would like to see other developers build things using the app and conduct research, as long as they do so ethically. The project’s GitHub repo has a detailed writeup of its design and engineering logic. It includes specific goals the code was built around in order to respect users’ privacy and mental health, such as:
- Thoughts are more valuable than passwords, treat them that way.
- Be extremely cautious about making engagement your core metric.
- But be clear and obvious within the app about what’s going on with the user’s data.
“I really do want to see people use Quirk for research,” he said. “I just want it to follow more ethical practices of consent and data security. Someone should willingly give a researcher their thoughts and as little information should be given about the person as possible. When it’s stored, it should be stored safely and not on a publicly exposed DB for example. But for that to happen, it has to be open.”
Beyond GPL-specific licensing, making the app open source has many other benefits. Quirk has already been translated into six different languages. One of the byproducts of making a useful app open source is that it energizes contributors and speeds up the process of bringing the app to new audiences.
I cannot express how absolutely amazing it is that Quirk was translated into 6 languages in just a few days. 🔥🙌♥👏
— Evan Conrad (@evanjconrad) April 10, 2019
Feedback on the app so far has been mostly positive. One commenter on Hacker News thanked Conrad for open sourcing the app because he wasn’t able to continue in-person CBT due to the cost:
I’ve been through CBT and stopped because of the cost. I feel that an app like this can complement those of us that have had face to face time but stopped for whatever reason.
Quirk is an inspiring example of how open source software can help people with every day problems. Its carefully-considered implementation respects users’ sensitive information and doesn’t encourage an unhealthy attachment to the app.
If you like Quirk and want to contribute, you can find the app on GitHub, including directions for translating it into different languages. Mental health professionals who want to contribute are encouraged to audit the descriptions of the cognitive distortions. Users can report bugs as GitHub issues or directly to the app’s creator via email to Humans @ usequirk.com.