Hacker News new | past | comments | ask | show | jobs | submit login
I wrote a program that sends cats to my phone when I'm sad at the computer (healeycodes.com)
307 points by steventey on Feb 22, 2022 | hide | past | favorite | 80 comments



Would be interesting to use this to track your facial emotion in relation to what you are doing at your computer; e.g. facebooking, reading news, working, etc.

If you're a developer, what kind of programming you're doing, language, platform, etc. Could scientifically prove once and for all whether or not Ruby is optimized for programmer happiness.


In the quantified self heyday I created an app that takes a webcam pic every half hour which was popular in the Bay Area QS community. I’ve had it running almost 10 years now.

Bottom line: people don’t show much emotion while looking at screens. The only exception was video calls.

Project site: http://wanderingstan.github.io/Lifeslice/

Early talk: https://vimeo.com/42239564


You can use ActivityWatch to gather the data.


Maker of the Cat API the author uses here - love his use-case, and a wonderfully useful & concise write-up to boot.


How do you moderate what is uploaded and check for copyright for example. I am always confused how solo developers make sure that nothing malicious is uploaded. Surely you don't have time to moderate everything yourself.


We layer AWS Rekognition and GCP Vision to check if it's safe, does not contain a human, and actually contains a Cat. The ones that make it through are then manually reviewed to be included in the public results.

We also make the results available for each safe image via the API so anyone can create their own ML model on top.

Both theCatAPI.com and its sister theDogAPI.com are used in a lot of schools, colleges, bootcamps, and even coding interviews so we try and make them as clean as possible.


I was first thinking that the author has a real cat and uses a remotely controlled laser pointer...well, it may be version 2


Version 1: software cat, v2: real cat, v3: tiger

---

I also thought it was a real cat, already (not only in v2). They aren't too impossible to attract with some nice sounds of food for example? At least not the ones I've known


Does anyone else find this mildly dystopian? I mean, it's a cool and really fun project, but it doesn't take much imagination to envision a service like this actually taking off.

"We monitor your mood 24/7 and automatically send you 'happy thoughts' on demand! Contemplating your feelings? Why bother! Here's a cute cat video! Never feel uncomfortable, pensive, or existential again!"


This was a scene in the movie Don't Look Up. A cellphone company CEO (a Zukerburg type character) introduces the 9.5 update, which includes emotion sensors. When you are sad, it automatically shows you pictures of cats.

So yes, I do.

Edit: Here is the video - https://www.youtube.com/watch?v=1jTHBBkillM&t=96s

(My bad it was the 14.3 update and dogs riding chickens)


Another exploration of this theme was in an episode of Doctor Who (Smile) which features a colony with nanobots that are optimized for happiness, with disastrous results: https://en.wikipedia.org/wiki/Smile_(Doctor_Who) - "The Vardy were programmed to help construct and operate the colony and make the colonists happy, monitoring the emotional state of the colonists through the emotion badges and avatars. When one of the flight crew died of natural causes, it created grief among the crew, something the avatars were not programmed to register. The Vardy took this as a sign of disease and killed those who displayed unhappiness. This created a "grief tsunami" which rapidly wiped out the flight crew, and will likely wipe out the waking colonists when they discover what happened."


Huh, I was going to wonder if this inspired the AI safety concept about how you shouldn't program a superintelligent AI to optimize the number of things it can see that look like human smiles, since unfortunately there are many ways to maximize that other than making real people genuinely happy.

But it seems like the Doctor Who episode is from 2017 and so it could potentially have been inspired the other way around.


> Zukerburg type character

I was trying to put my finger on who he was emulating (besides the same actor’s character in Ready Player One), I was very pleased to hear Duncan Trussel’s take in his last podcast (493), he thinks the character is lifted from the head of the suicide cult “Heavens Gate”, note the pauses in speech and the ever-lifted eyebrows [0]. Basically framing the geo-engineering/tech-will-save-us crowd as a suicide cult.

[0] https://youtu.be/AqSZhwu1Rwo


Ohhhhh yeah! I couldn't quite put my finger on that but it's definitely there.


I agree that this could absolutely be an awful service. However, if someone is just now hacking this for fun, then odds are someone else is already hacking it for profit.

I'm always glad to see people experimenting with technology at a human level and writing about it. That feels like the best that we can do, as opposed to not writing about it or pretending that it doesn't exist.


An awful service, but an amazing concept for a novel.


Maybe a Black Mirror episode.


The dystopia is already upon us. Facial recognition was apparently deployed in a school in China to track students' emotions and actions. [0].

[0] https://www.businessinsider.com/china-school-facial-recognit...


China has been dystopian for decades.

The real bummer is that even free countries are starting to embrace the same methodologies. When Australia, Canada and the US start heading toward the abyss of surveillance/lock-down states you know things are not looking good for the planet.


Settler-colonial states were never symbols of peace and egalitarianism.


Was done in (NZ) Auckland University too if I recall correctly.


I really want a machine that monitors me and tells me "yo dude, you're Hella depressed. Don't take any of your thoughts too seriously" or "you're super happy. Don't make any big choices without asking your Wife about them".


It's a fun story, but yeah continuing the thought it is a little dark.

But the truth is any dystopian future we create ... it's not Evil Google taking over, it's us accepting it happily in exchange for instant cat messaging and Marilyn Monroe bots.


I'd rather have it above-board and open than be part of some giant machine learning algorithm at Meta somewhere - "we want our customers to be a bit depressed but not too much or they stop spending ..."


I would gladly accept the insane intrusion and surveillance if the service sent actual cats, as the headline led me to believe for a moment.


In a year, on a Show HN thread there will be a comment referencing this news entry as another "Dropbox" moment.

Only half joking, wouldn't be surprised at all


Oh, just got why: in western cultures it's considered dystopian, but I can imagine Japanese market being open to that (just like with robot dogs that are getting their own cemetery spots)


I did. Not that hard to move from injecting cats to inject chemicals or newest novel research chemical to formulate happiness. Imagine if a business can jump on that as a subscription service.

"Sign up Today, never be sad again." Sort of a opposite to the dopamine feedback addiction loop that powers social media and cell phones.

Actually, wait, ycombinator is open for startups...

Can just replace a timed morphine drip with a non-scheduled analog, make it an inhalant that ties into the HVAC and measures ppm so it's non-invasive.

It does have potential.


My personal machine has a python script in the bacground and in addition to a host of other things (un-tarring downloaded files etc) it tries to take a photo of my face once an hour. I use some CV to detect the face & take 10 frames of video, throwing them out if there is noticeable jitter. The closest 6 face fragment frames then get merged together and saved with a timestamp, for my future use doing dumb projects (face authentication, I've created fun timelapses by sorting ~6 months of photos by similarity).

If I were doing this to someone else without their knowledge it would be dystopian, if I'm doing it to myself or with a group of friends also interested in it then it becomes no wierder than taking your temperature every hour for dumb project reasons (biological clock fourier nonsense? whee~!)


To me, it only sounds dystopian if a distant, all-powerful big brother is running it. Not everything has to be like that.

If it's under your control, like it is here, it doesn't sound dystopian at all.

This person has noticed something in their life that they don't like, they get too sucked in into work and need to snap out of it a bit.

In the future, they could notice themselves watching too many memes, and they could add a new feature that sends them a though-provoking quote when their face is very relaxed for a long time in front of the computer.


There is already a product for employers that automatically monitors if and how long employee smiles while talking with customers (although masks probably slowed it down). Don’t remember the name though.


People trying to make themselves happy isn't something new or dystopian. A better description if you don't mind being slightly rude is that it's a bit pathetic.


After the protests in Canada I started seeing a bunch of recommended videos on YT themed around random acts of kindness. I mainly watch technical videos, nothing else.

I am convinced that someone did something to pump those videos up and get eyeballs on them. If my hypothesis is correct I would find it to be creepy and insulting. I do not want to be manipulated.

Sometimes the truth is hard, and that's ok. Pain is healthy in the right doses.



I don't know... on one hand... it will probably just be used to sell ads... but what if it actually worked? like, maybe some small dent in the rate of suicide?


Assuming that it works (and I don't think I'm emotive enough that it would) I don't think cat pictures (no mater how efficiently they're distributed) can put a meaningful dent in the kind of depression that would lead to an act of suicide or even genuine sadness.


You just described the dopamine microdosing that is social media and their algorithm backbones lol


Well thats the point of the tweet that is quoted right at the start of the article


yes lol, the title made me think "I'm bored, lets make my life more black-mirror-esque"


Why is cheering people up dystopian?


It can be. It isn't necessarily, but it can be.

Imagine a scenario in which you walk into an ER with a venomous demon chomping on your leg. The doctors give you pain killers and send you cat pics and a list of sitcoms to watch.

No one does anything to solve the real problem that has you in agony and is threatening to kill you. They just make sure you feel fine and that's it.

Now that you feel fine, the feedback loop is broken and you no longer realize you have a really dire problem that needs to be resolved or you will be maimed for life and/or soon dead. You feel fine! though the demon continues to gnaw on your leg.


It's the premise of Brave New World. It tells of a society subjugated through genetic-engineering and hedonistic entertainment. I think a quick dose of happiness is pretty akin to "soma", a drug the characters use to avoid bad feelings.


I actually tried launching that last year lol, I had a similar code to OP(except I was more thinking about sending jokes or meditation videos)

The conversion rate of the landing page were very low so I didn't go further


I feel that `thecatapi` and `placekitten` should get together and save the planet whilst providing various cats at a consistent size.


I solved this problem in a lower-tech way by simply configuring the area behind my workstation as a cat bed. Now, I can turn around and enjoy looking at my cat at any time, as she loves her bed and rarely leaves it. Stress eliminated!

Yes, she is taking Series A funding in the form of wet food, if anyone is interested.


There is a wide gap between my screens and keyboard. Enough for 2 out of my 4 cats to accommodate themselves.

At first, I thought it was for me, they did it to keep me happy, but then quickly realized they somehow can understand when it's chow time and simply get up, start stretching and sit up in front of my screen around that time.


Did the same with a dog (shiba inu) this past year.

I think we're all the way at Series C funding at this point with the biweekly trips to the store for goodies.


Isn't any warm spot essentially pre-configured as a cat bed?


Any place is pre-configured as a cat bed. "If I fits, I sits" does not just apply to boxes... cats will, in my experience, sit wherever the f..k they want whenever the f..k they want.


Preferably on your chest at 5 am. At least that's what mine like to do, because they feel a little bit hungry or have seen a bird and want to get out on the balcony for further inspection.


That's what makes it so easy!


If you can get some to give you $1 for 0.000000000001% of your cat then you can upgrade your cat to a unicorn.


All at once, it fills up my feed

More bad news that I didn't need

I can't stop reading but I wish that I didn't know

Still too soon, there's not much to say

They don't know, but talk anyway

All of the pieces, and none of the places they go

So I am looking at pictures of cats

https://youtu.be/4JO-KRT0Vf0


This exact thing was a dystopian little vignette in the movie Don't Look Up. Funny and scary that it's real now.


Now this sounds like fun, when Peter Isherwell [0] proposed it, it was a bit more scary.

[0]: https://m.imdb.com/title/tt11286314/characters/nm0753314


Since working from home I have between 3 and 6 coworkers. The stress relief tends to depend on the fact that some are better behaved/trained than others.

My SO and me are a foster home for stray cats that were found to need special care during neutering campaigns for stray cats. While most strays in these campaigns return to their spots after being neutered some (like kittens found in trash bins or cats with injuries that need longer treatment) are being put up for adoption.

Especially with newly arrived foster cats they need to be taught what the are allowed and especially what not (let the plants live, not jumping onto the table). After that they are the most lovely coworkers lying on the chairs next to me.


How do you train cats? I thought they are the king of the house!


Are people always smiling at the computer? My face rests with a frown.

The more intent I'm thinking, the more likely I'm frowning, then CAT! Which is realistic at least.

Inverse it and you can tell when you're probably not working, for task reminders, upcoming meetings.


For the record - the author considered these two libraries for face detection: https://github.com/vladmandic/human & https://github.com/justadudewhohacks/face-api.js, he chose "vladmandic/human".


It‘s important to make the distinction between facial expressions and emotions …

A while back we made some glasses with photoreflective sensors to detect facial expressions, got so many requests about using it for emotion detection.

https://m.youtube.com/watch?v=9PMzpsDg518

Yet, that’s not what it does … maybe I was just naive and it didn’t help we called it affectiveWear.


Shoutout to the Human library and it's creator vladmandic. The library is growing fast.


Curioulsy, how does one go from BA in creating writing to Msc in computer science?


By taking minors and extra courses in computer science. Ultimately grad schools care more on the courses you take plus recommendation letters and use GRE/GMAT as filters.


Cats. Lots and lots of cats.


Just being aware of the expression on your face might be very interesting.


Sometimes I wonder if I might buy into The Matrix / Colossus: The Forbin Project / our AI overlords if I felt it actually cared about me / was whimsical enough ...


Colossus/Guardian did exactly the thing it was built to do, and that humans claim to want: prevent war. I think that's a pretty good track record and Forbin overreacted a bit.


That was an amusing ending in that way. It is presented as a terrible outcome but ... really Forbin seems upset he isn't in control.


It sure feels like I'm eating steak...


This is fine for when you are a little down. It’s important though to honor real sadness vs trying to cover it up / distract.


Would love to see a macOS program version of this from the people who did the Christmas lights for the M1 screen notch.


What would be the advantage of using Pushover vs using notifications from a website via the browser app?


It’s rumored that it might be supported soon, but iOS still doesn’t support web notifications.


That’s awesome! Thanks for sharing. Makes me want to play around with these libraries.


I remember trying somewhat similar a long time ago(I think it was around 2016).I once paused for a bit and realized the long-term effects might be the opposite of the intended one, then I stopped.There are a lot of ways people can learn to both control and embrace their emotions, having a computer in this loop is not one of them.

And from what I recall, the actual thing that 'made me happy' (it was actually more like shortly lifting up the mood) was the fact that the thing worked for a bit, at least superficially.Sentiment analysis is very tricky and easily fooled especially if your (involuntarily) facial expressions are akin of smiling.[Which I believe I 'got' from my father, it's not that uncommon, something related to the need of oxygen] Tl;dr: Try it but don't rely on it, humans are one of the things AI won't beat nor understand nowhere near the future when it comes to inter-personal relations.


That should go into one of the virtual girlfriend apps in Japan.


But why are we okay with being sad at the computer?


I really like the idea of a native OSX app that takes your emotions into account and either plays music you like or shows your favorite photos that fade in and out. Something to snap you out of the crap zone.


[flagged]


It's also stitching several interesting APIs together in an unusual and whimsical way. Better yet, the article itself is well written. If you've done something better with your day that then feel free to tell us about it.


i've seen a fair number of HN posts with grown people sending spam (sorry, marketing emails to improve your conversion funnel!!!!) to other people and bragging about it on social media. i'll take sending cats to yourself any day.




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: