Disclaimer: I am not a doctor nor medical researcher. I'm not giving advice nor diagnosing anything and my only experience is myself.
About two months ago, I built a little tool to measure my panic attacks. Before you get concerned this is a coming-out-to-dev type story; this isn’t a secret. I tell most people in my dev circles about panic because panic is the reason I started programming.
I'm not here to shame you against stigma, tell you it's illegal to say "crazy" or make a case for better working hours. I'm here to show you something I'm working on.
Here’s a graph of the attacks I’ve had over a roughly 2 month period.
This graph comes from that tool I built, affectionately called
freak. It's a simple command line tool that records a timestamp and an intensity:
$ freak 8
Episodic disorders like panic are easy to forget about. When it's bad, it's easy to forget that it could ever be good, and when it's good, you forget how bad it ever got.
It's easy to "forget" which treatments are effective and which are hogwash.
freak is simple way for me to record hard data about when they occur and when they stop. That way no armchair psychologist can claim that my attacks are just "caused by the moon's orbits" or whatnot.
I can point to any treatment and definitively say "yeah that seems to work for me."
Lots of people describe this differently, so I'm not able to give you a one-size-fits-all description. I can tell you what my attacks are.
For me, panic is not stress, it's fear.
A panic attack is an intense physiological experience of fear in response to something that isn't dangerous. It's that shot of adrenaline you get in your belly when you're almost in a car wreck. It's knowing there's a murderer in your basement after having watched a scary movie. It's the "flight" in fight or flight; it's running from the tiger but without the tiger.
Panic is your body putting the foot to the floor, pedal to the metal, balls to the wall in your driver's ed parking lot.
It lasts about an hour or two and can sometimes happen in "clusters." It's not generalized anxiety because generally, you're happy and healthy.
I've had these attacks for as long as I can remember and for as long as I can remember people have suggested dumb, back-of-the-internet, armchair treatments to me. After trying a lot of them, it's really easy to become skeptical.
After a particularly bad episode when I was in high school, I started seeing a doctor who recommended CBT.
I passed on the offer.
At the time, I had no idea what therapy might mean. When everyone around you suggests treatments, you tend to associate them in to hard treatments and soft treatments.
Since many lay people have an unfortunate moral objection to medication, they tend to provide soft treatments. And since they generally don't know what they're talking about, their "treatments" don't work.
You become biased against soft treatments, even when a doctor suggests them.
For several years, I ignored the concept of any form of therapy. It wasn't until this past year that I explored Cognitive Behavioral Therapy (CBT), the gold-standard of "soft" treatment options.
Not only has it reduced the overall amount of attacks, but reapplication during clusters dramatically reduces their intensity and duration.
In my most recent cluster, captured by
freak, it halted the attacks.
And I'm not the only one to suggest that CBT is effective, plenty of studies have shown it to be at least as good as treatment with SSRIs. It's been around since the 80s and is often the first treatment attempted when you see a psychologist.
There are a lot of formats of CBT since it's popularization in the 1980s. CBT encompasses many different exercises; my explanation will focus on the "simplified" versions of the treatment.
CBT asks you to recognize that your thoughts cause feelings, not the other way around. While it's certainly true that your existing moods can make some thoughts easier, generally destructive and unhealthy moods are caused by illogical and "distorted" thoughts. It also suggests that many of these thoughts are "automatic" and self-fulfilling prophecies.
For example, often my attacks will start because I think they're going to start. Something small and brief will frighten me, I'll pick up on it, and I'll automatically think:
I felt a bit of panic, therefore I'm about to have a panic attack.
The image of past attacks flashes in my head and I start to think about how bad it would be if I actually did have an attack. Maybe I'm at work and about to give a super important demo. What if I got hit on a performance review? What if I had to run out in the middle of the demo?
CBT would ask me to notice the cognitive distortions (effectively the psychological words for logical fallacies) in the original thought.
In this example, I'm catastrophizing. Would really anyone care if I screwed up a demo? Most people know that I have these attacks. I would just explain what was going on. Plus any of my teammates could have taken that demo; they're all fantastically smart.
Would it really be a big deal if I had to run out in the middle of the demo? Surely that's happened before. Plenty of folks have gotten sick before a big event.
CBT would then ask me to record these logical arguments. Writing them down helps solidify the concepts so they come more naturally before your brain has jumped from one terrifying thought to the next.
Finally, CBT would ask you to find a logical way to interpret the situation. For example:
I felt a bit of panic, but that doesn't mean it'll lead to more panic nor an attack.
You record your thought, you challenge it, and you find an alternative thought. And you do it for every illogical, unreasonable, and terrifying thought you might have.
In the 80s when treatment was formalized, they suggested patients do this in three columns:
But anyone who's ever done this in the modern world has likely noticed that it's much easier with a device. Software gives you two major advantages:
- discrete recording
- cumulative metrics
Having it on your phone means you'll always have a way to record.
There's a few apps that currently exist, namely "Thought Diary" and "MoodNotes." ThoughtDiary is free but it's quite fugly.
MoodNotes is 5 dollars but much better looking.
Both suffer from an intense focus on mood. They assume that the user is using CBT for depression and therefore strongly couple "mood" therapy to cognitive change.
The very first thing you have to do when you record something is tell the app how you're doing. If you're happy, it will not let you record and challenge a thought.
Which means if you're having a fine day, but notice yourself thinking something illogical that could bring you down, you have to either wait for that thought to spiral out of control or lie to the app and tell it that you're unhappy.
That's a pretty bad flaw in an app that's trying to help you disassociate your illogical thoughts from catastrophic moods.
Because they're so focused on mood therapy, they add plenty of diverging steps which mean more taps and more fields to fill out.
If it takes you 30 seconds to fill something out, you can easily sneak that in, even if you're in a meeting. If it takes you 2 minutes, it's much harder.
More importantly, we could do a lot less. Many of these apps suffer from feature creep. They're trying to make a very specific solution with all the bells and whistles but marketing it to everyone.
Instead, we could trim down the features and make something more focused.
For the past few weeks, I've been prototyping a CBT app. It's still in really early stages, but here's the general gist of what it could/will be:
- Licensed under aGPL with a repo on Github
- Stores data on device for privacy
- Non commercial
Note that non commercial and open source does not mean "free," just that the purpose of this endeavor is not to make money. There's no business being created; this is just a project I'm doing on my weekends. That said, it's not cheap to put or keep an app on the various stores.
All the mockups below are done really quickly and are in a very malleable state. They're not final and may not even be remotely close to the finished state.
From a code perspective, this app is really small and I already have a solid but ugly prototype of it working. So this write-up is much more about how we can make a great product.
The code's written in React Native, so I plan to publish it on both the Google Play store and the Apple App Store.
That said, I currently don't own an Android device and haven't worked on Android for awhile. Your Mileage May Vary.
To limit the scope as much as possible, there's only really two main screens. One for recording and one for later viewing. The transitions between these screens will be swipes, so you can think of the recording screen as "on the left" and the listing screen as "on the right."
To help highlight that, we'll put the transition buttons on opposite sides and even change the place of the period in
quirk. to really sell the effect.
When the user hops on, we'll give them a crash course on CBT. This has to be really minimal otherwise they won't remember it, so we'll add some illustrations to make it more memorable.
Then let me know. I'm building this first and foremost for myself. But I'm planning on releasing it because I doubt I'm the only one who needs it.
So if you're interested in either helping build this or using it let me know! And if you could, fill out this 4 question survey.
There's about three iterations of this project so far, all of them prototypes. It's currently not released nor on Github. It will be in the future once I can properly clean it up and have reasonable entry points.
I'd love critique on this app. I can't guarantee that I can do everything; the scope of this app is very small for a reason. But there's certainly ways to improve this product.