Hello, Computer Final

As a person with no inherent self-preservation instinct, nor the self-discipline to enact a learned one, it’s been a tough transition to independent adult life. I nearly immediately fell into an acute depression after moving to NYC in 2012 for my first job, shortly after completing my BFA. Since then, I’ve learned the hard way to take care of myself physically, mentally, and emotionally, and while I’ve skimmed countless research papers, books, and MOOCs about psychology over the years, making a regular practice of what I’ve learned still proves a challenge.

So for my Hello, Computer final project, I created a self-care assistant. Named Life Support, it’s a relatively sprawling/unfocused endeavor that attempts to intervene generally on common/modern emotional discomforts. While I plan to build this out even more as part of my thesis, Life Support presently consists of the following features:

  1. A guided breathing exercise. When you tell Life Support that you’re feeling some variety of agitated (anxious, nervous, etc), it will guide you through a breathing exercise: five counts in, five counts out. When a body is stressed, the fight or flight response (ie the sympathetic nervous system) kicks in; breathing exercises promote the opposite response (ie the parasympathetic nervous system) and indicate to the body that there is no threat. Breathing exercises/mindfulness practices in general have also been shown to reduce mild depressive symptoms. Since the assistant’s response seems to be capped at about 30-40 seconds, Life Support will ask whether to continue the exercise every six breaths.
  2. A guided physical exercise. When you indicate that you’re feeling some variety of burnt out (sluggish, unfocused, foggy, etc), Life Support will guide you through NYT’s Scientific Seven Minute Workout. As a person who naturally loathes exercise from the depths of my being, this is the rare workout that’s actually within my tolerance threshold, and since their interactive guide stopped working I’ve definitely become even lazier. Luckily, it was quite easy to recreate using SSML. Similar to the breathing exercise, Life Support will ask after each exercise whether or not the user wants to continue. Physical exercise has been shown to have countless benefits on a person’s mental and physical health, and is particularly helpful to prevent burn out.

  3. Guided cognitive behavioral therapy. When you tell Life Support that something is bothering you, it will help you CBT. CBT makes good on the belief that affect, behavior, and cognition directly influence (and therefore, exacerbate) each other by empowering the individual to targeting self-defeating cognitive distortions. Because cognitive distortions are based on fears and not facts, they can be effectively abated by gathering evidence for and against them. The individual then reassesses their beliefs based on these facts. While easily executed with the help of a therapist and some distance from the triggering event, it’s much more difficult to practice CBT in the moment, by oneself, while emotionally agitated. Life Support can help you challenge your triggering thoughts in the moment, thereby de-escalating emotional turmoil.There’s another branch in the conversation that the user can go to if they’re catastrophizing, which helps them challenge the extreme belief that is triggering them. Life Support asks them to consider 1) the worst case scenario, 2) the best case scenario, 3) the most probable case scenario, and 4) a purposeful action based on that probable scenario.

  4. Gratitude and good things log. In addition to helping users with their unpleasant emotions, Life Support also helps them prioritize positive emotions by keeping a log for good things that happen, as well as a log for things that the user is grateful for. According to positive psychology, a bias towards optimism and the refocusing on positive emotions allows people to change their subjective reality, and eventually their objective reality when their behavior changes as a result.Another benefit of keeping track of such things is the ability to revisit them; apparently, merely recounting positive moments from one’s past is enough to elicit those positive emotions in the present. When the user tells Life Support that they are feeling sad, Life Support will respond with something from their log, which is stored on a Firebase database.
  5. Knowledge base fallback. In addition to the foregoing intents, I also trained Dialog Flow’s Knowledge base on the transcripts of UPenn’s positive psychology MOOCs, as well as Barbara Oakley’s Learning How to Learn MOOC. As a result, Life Support will attempt to give advice when the user asks about anything related to positive psychology (coping/resilience skills, how to feel better about life, etc) or learning.

hello computer w6 hw

!!!!!!

 


Notes from the reading  (actually, it was so well-written that I just copy/pasted excerpts that I particularly wanted to remember)

Effectiveness of Alexa’s responses is inferred by these metrics:

  • Is the same question uttered again? (Did the user feel heard?)
  • Was the question reworded? (Did the user feel the question was understood?)
  • Was there an action following the question? (Did the interaction result in a tracked response: a light turned on, a product purchased, a track played?)
“With each interaction, Alexa is training to hear better, to interpret more precisely, to trigger actions that map to the user’s commands more accurately, and to build a more complete model of their preferences, habits and desires. What is required to make this possible? Put simply: each small moment of convenience – be it answering a question, turning on a light, or playing a song – requires a vast planetary network, fueled by the extraction of non-renewable materials, labor, and data.”
Extractive system of AI:
  • As Liam Young and Kate Davies observe, “your smart-phone runs on the tears and breast milk of a volcano. This landscape is connected to everywhere on the planet via the phones in our pockets; linked to each of us by invisible threads of commerce, science, politics and power.” 8
  • Our exploded view diagram combines and visualizes three central, extractive processes that are required to run a large-scale artificial intelligence system: material resources, human labor, and data… 
  • Vincent Mosco has shown how the ethereal metaphor of ‘the cloud’ for offsite data management and processing is in complete contradiction with the physical realities of the extraction of minerals from the Earth’s crust and dispossession of human populations that sustain its existence. 
  • Sandro Mezzadra and Brett Nielson use the term ‘extractivism’ to name the relationship between different forms of extractive operations in contemporary capitalism, which we see repeated in the context of the AI industry. 10
  • Thinking about extraction requires thinking about labor, resources, and data together.
  • The Echo user is simultaneously a consumer, a resource, a worker, and a product.
Statua citofonicaStatua citofonica by Athanasius Kircher (1673)

On environmental resource extraction:
  • Reflecting upon media and technology as geological processes enables us to consider the profound depletion of non-renewable resources required to drive the technologies of the present moment. Each object in the extended network of an AI system, from network routers to batteries to microphones, is built using elements that required billions of years to be produced. Looking from the perspective of deep time, we are extracting Earth’s history to serve a split second of technological time, in order to build devices than are often designed to be used for no more than a few years.
On human labor extraction:
  • Amazon CEO Jeff Bezos, at the top of our fractal pyramid, made an average of $275 million a day during the first five months of 2018, according to the Bloomberg Billionaires Index. 17 A child working in a mine in the Congo would need more than 700,000 years of non-stop work to earn the same amount as a single day of Bezos’ income
On the immensity of the supply chain:
  • As a semiconductor chip manufacturer, Intel supplies Apple with processors. In order to do so, Intel has its own multi-tiered supply chain of more than 19,000 suppliers in over 100 countries providing direct materials for their production processes, tools and machines for their factories, and logistics and packaging services. 20
  • Dutch-based technology company Philips has also claimed that it was working to make its supply chain ‘conflict-free’. Philips, for example, has tens of thousands of different suppliers, each of which provides different components for their manufacturing processes. 21 Those suppliers are themselves linked downstream to tens of thousands of component manufacturers that acquire materials from hundreds of refineries that buy ingredients from different smelters, which are supplied by unknown numbers of traders that deal directly with both legal and illegal mining operations.
  • Apple’s supplier program reveals there are tens of thousands of individual components embedded in their devices, which are in turn supplied by hundreds of different companies. In order for each of those components to arrive on the final assembly line where it will be assembled by workers in Foxconn facilities, different components need to be physically transferred from more than 750 supplier sites across 30 different countries. 24This becomes a complex structure of supply chains within supply chains, a zooming fractal of tens of thousands of suppliers, millions of kilometers of shipped materials and hundreds of thousands of workers included within the process even before the product is assembled on the line.

On environmental damage/effects on human health:

  • In recent years, shipping boats produce 3.1% of global yearly CO2 emissions, more than the entire country of Germany. 27 In order to minimize their internal costs, most of the container shipping companies use very low grade fuel in enormous quantities, which leads to increased amounts of sulphur in the air, among other toxic substances. It has been estimated that one container ship can emit as much pollution as 50 million cars, and 60,000 deaths worldwide are attributed indirectly to cargo ship industry pollution related issues annually. 28Typically, workers spend 9 to 10 months in the sea, often with long working shifts and without access to external communications. The most severe costs of global logistics are born by the atmosphere, the oceanic ecosystem and all it contains, and the lowest paid workers.
  • David Abraham describes the mining of dysprosium and Terbium used in a variety of high-tech devices in Jianxi, China. He writes, “Only 0.2 percent of the mined clay contains the valuable rare earth elements. This means that 99.8 percent of earth removed in rare earth mining is discarded as waste called “tailings” that are dumped back into the hills and streams,” creating new pollutants like ammonium. 31 In order to refine one ton of rare earth elements, “the Chinese Society of Rare Earths estimates that the process produces 75,000 liters of acidic water and one ton of radioactive residue.” 32Furthermore, mining and refining activities consume vast amount of water and generate large quantities of CO2 emissions.

AI Extractivism:

  • Availability of open-source tools for doing so in combination with rentable computation power through cloud superpowers such as Amazon (AWS), Microsoft (Azure), or Google (Google Cloud) is giving rise to a false idea of the ‘democratization’ of AI. While ‘off the shelf’ machine learning tools, like TensorFlow, are becoming more accessible from the point of view of setting up your own system, the underlying logics of those systems, and the datasets for training them are accessible to and controlled by very few entities. In the dynamic of dataset collection through platforms like Facebook, users are feeding and training the neural networks with behavioral data, voice, tagged pictures and videos or medical data. In an era of extractivism, the real value of that data is controlled and exploited by the very few at the top of the pyramid.
  • Every form of biodata – including forensic, biometric, sociometric, and psychometric – are being captured and logged into databases for AI training. That quantification often runs on very limited foundations: datasets like AVA which primarily shows women in the ‘playing with children’ action category, and men in the ‘kicking a person’ category. The training sets for AI systems claim to be reaching into the fine-grained nature of everyday life, but they repeat the most stereotypical and restricted social patterns, re-inscribing a normative vision of the human past and projecting it into the human future.

  • While Shiva is referring to enclosure of nature by intellectual property rights, the same process is now occurring with machine learning – an intensification of quantified nature. The new gold rush in the context of artificial intelligence is to enclose different fields of human knowing, feeling, and action, in order to capture and privatize those fields. When in November 2015 DeepMind Technologies Ltd. got access to the health records of 1.6 million identifiable patients of Royal Free hospital, we witnessed a particular form of privatization: the extraction of knowledge value. 53 A dataset may still be publicly owned, but the meta-value of the data – the model created by it – is privately owned.

 


Response to the reading:
So I had been the president of my high school’s Environmental Club, obsessively sorting the building’s recycling bins, running e-waste collection drives, and begging my parents to buy low-flow shower heads and compact fluorescent lightbulbs. To their despair, I applied to colleges with the intent of majoring in Environmental Science, and spent the first semester at UMich loading up on such courses and joining every environmentally-themed club I could find. All this led to nothing but my rapid disillusionment—most people just don’t care. Like, at all. And just like that, I completely lost hope that humanity could ever curb its materialism for the sake of our planet’s health, and transferred to art school the next year.

Like the article pointed out, not just economies but even early forms of trade are based on the extraction of resources for gain. Capitalism fundamentally depends on the pillaging of the planet and exploitation of large swaths of society. The tech industry may seem relatively innocuous, providing mostly intangible services rather than physical products, but they still pillage resources—namely, our time, attention, and data, as well as the materials necessary for the server farms and physical products they do sell—and profit to a degree that is astronomical.

Unfortunately, all of it is here to stay, and it’s still painful for me to be complicit in such an extravagantly wasteful system when I was so sensitive to it before, but the reality is that opting out would effectively disable me from engaging and participating in society in any meaningful way—technology is the platform on which our society organizes itself nowadays. Even in 2013, before I finally acquiesced to buying my first smart phone, I already had the feeling that I slipping to the margins. To even attempt to opt out is to render yourself irrelevant.

Hello, Computer W4 HW

Using Fulfillments, I was able to implement two guided exercises: the first was a remake of NYT’s seven minute workout (which always seems to be broken on their website), meant to trigger if the user’s input entity value is “burn out”; the second was a breathing exercise, which triggers if the entity value is “anxiety”.

I had tried to add a Fulfillment that played audio for another yet another entity, but it seems that Firebase won’t make http requests unless I have a payment method on file. I might look into a Spotify API instead.

Here’s the result:

 

I cleaned up the corpora I used to train the bot a little more as well, so it can now field questions about positive psychology and uh, learning effectively, slightly better. Chat with it here, although the web demo doesn’t speak, so you’ll only get the abbreviated “text” version of the Fulfillments.

It’s very confusing for me to have Dialogflow’s entity/intents, and some responses, removed from the responses in my nodejs code, so I may look into coding the entire thing at a later date.

Hello, Computer w3 hw

So I made my first foray into my life support project this week, using Dialogflow. Initially, I had little faith in its flexibility and anticipated having to train a word2vec model to facilitate the self-care/positive psychology “understanding” it would need, but upon further investigation the platform seems to be sufficient, although I haven’t tried Fulfillments yet, which will be the real test.

While I haven’t finished my plans for interventions yet, I translated what I do have into broad intents and entities in the console. Eventually, I will have to connect these to web hooks in order to serve up the actual interventions. I also had a lot of fun training its Knowledge Bases with transcripts from various relevant MOOCs, then testing how much it learned afterward (admittedly, probably more than I have). Some of the responses were wonky, or ended abruptly—which is consistent with what you’d normally get if you asked Google Home a random question—so I had to go back into the training data and remove anecdotes, etc. The feature is in beta right now anyway, so I’ll withhold criticism until it’s official, but overall it’s pretty cool to be able to control your sources of information to what you know is credible.

Although I had the Knowledge results preference at maximum strength, I was still surprised to see it override follow-up intents even when I responded verbatim with training phrases:

 

The knowledge results the bot returned weren’t very helpful, but it would be nice to have them in addition to the follow-up intent response, but I couldn’t find a combination option in the console.

Interact with the bot here.

 


 

The faux-AI in the Sandra podcast reminds me of Lauren McCarthy’s project, Get Lauren, where she performs the role of a smart home speaker, readily available to the user’s whims 24/7. I personally prefer narratives where the AI hype fails to live up to its potential and humans have to go back to connecting with other humans, rather than the sci-fi fantasy where robots integrate seamlessly into society and fulfill all our needs. In the context of modern day Western society, where we are feeling more isolated, lonely, and depressed at an increasingly greater scale than ever before, it’s truly grim to think about how we’re still pouring all our resources into swapping human interaction with artificial intelligence—technology has done quite enough to separate us already.

In both the fictional Sandra and the actual Get Lauren project, users turn to these interfaces ostensibly for help, but they sometimes end up bearing witness to and sharing in small, intimate moments in their users’ life. For the users of Get Lauren, clearly this dynamic was the entire appeal of the project, something that they willingly paid for with their privacy and partial control over their households. For the users of Sandra, this was a concomitant result of a natural inclination for humans to connect with other humans/convincing human-like interfaces (see: people like me who thank voice assistants after they complete a task).

Hello, Computer Week 1 / A2Z Week 2 Homework

https://xujenna.github.io/a2z/wk2/index.html

For this week’s homework, I decided to rebuild a markov model with RiTa.js that I had previously created in python with markovify and NLTK. This time, it would respond (loosely) to a user’s input, and with a voice via the Web Speech API.

I had initially experimented with markov models in python because I had the idea to create a sort of self-care assistant as the final phase of my mood prediction project, and had dreams of it being this omnipotent and omnipresent keeper. While I have yet to figure out how to implement such a presence, I did have an idea of what I wanted it to sound like: a mixture of the exercises in Berkeley’s Greater Good in Action, NY Mag’s Madame Clairevoyant, and Oprah. I had assembled corpuses for each of these personalities manually.

It was incredibly easy to build this markov model with RiTa, and the results were surprisingly coherent—with markovify, it was necessary to POS-ify the text with NLTK in order to force some semblance of grammar into a model. However, there didn’t seem to be a native option to provide seed text, so in order to make the model responsive to a user’s input, I utilized RiTa’s KWIC model to gather all of the sentences from the source text that contain each stemmed word from the input, and loaded what the KWIC returned back into the markov model as an additional source with a high weight. The resulting generated text was consistent enough in making subtle reference to the user’s input.

The last step was to feed the markov’s response into the speech synthesizer, which was pretty straightforward, but the creepy, male, pixelated voice gives this experience the uncanny feeling which every divine being deserves.