Category: AI and Life

Should Cecilia have said “insecure” instead of “unsecure”?

In this funny PhD Comic, the main character – Cecilia (the girl in red) – says:

“Do you realize how unsecure your coffee distribution system is?”

That made me wonder – should she have said ‘insecure’?

Even the WordPress spell-checker has a problem with “unsecure”.

It thinks that “unsecure” is a spelling error.

However, the word “insecure” doesn’t sound as if it were the right term to use in the context of computer security.

That is because the word “insecure” is usually used in the context of a person to mean a person who is not confident and self-assured.

To call a computer “insecure” would be a bit like saying that the computer had self-image issues.

Others have written about this cognitive dissonance as well (see for a nice discussion).

Given the problem, the author of the cartoon seems to be justified in using a newly-minted word (one not found in any dictionary) in order to describe the lack of security.

This is also very interesting because it throws some light on how words are born.

Before I can explain what I mean, I’ll need you to take a look the Oxford dictionary’s definitions of the word “insecure” (from the Oxford English Dictionary online search at



  • 1   uncertain or anxious about oneself; not confident:  a rather gauche, insecure young man,  a top model who is notoriously insecure about her looks
  • 2   (of a thing) not firm or fixed; liable to give way or break:  an insecure footbridge 

                 not sufficiently protected; easily broken into:  an insecure computer system

  • 3   (of a job or situation) liable to change for the worse; not permanent or settled:  badly paid and insecure jobsa financially insecure period

There are three ways in which the word “insecure” can be used.

The second usage would have been perfect for the context of computer security.

But the first usage might be conflated with the second in that context.

And that is because (sorry, I no longer recall the references to support this claim) computers appear to the human mind to have human-like characteristics (we say things like “Google tells me that …” or “my computer has gone to sleep”).

So, the only word in the dictionary that can do the job – the word “insecure” – has a conflict of interest.

And therefore, a new word needs to be coined that is not susceptible to the same sort of ambiguity.

And if the new word “unsecure” catches on, then one day, the second sense of the word “insecure” could become extinct in the context of computers.

Oh well, “it’s only words!”


A friend pointed out that the Google NGram Viewer shows a history of the use of the word “unsecure”:

The word seems to have been in use between 1650 and 1850 (there is evidence of use in literature), and has in more recent times simply fallen out of circulation (being eclipsed by “insecure” in around 1750).  Thanks, Prashant.

(You can also search for those early usages in books –

How algorithms can ‘shape’ our world – Kevin Slavin

In our first blog post of the year, we’d like to share a talk by Kevin Slavin.

It is about how math (especially algorithms) has ‘transitioned from being something that we extract and derive from the world to something that actually starts to shape it.’

One of the posts we most enjoyed writing last year was related to this:

It was about algorithms to combat poverty.

We also wrote about how math might someday shape our values.

Frameworks for evaluating values

I recently came across a very interesting 2001 paper by Daphne Koller that dealt with influence diagrams and how they could be applied to game theory.  I came across the paper while doing some background reading on a talk on decision making in accordance with our core values by a friend of mine, Somik Raha.

Influence diagrams are a formalism (very similar to probabilistic graphical models) that are used for making decisions.

What Somik Raha has attempted to do is come up with a framework for making decisions while also taking one’s values into account (either as constraints or as inputs into the decision model).  To do that he proposes extensions to influence diagrams.

What I found interesting when I thought about Daphne Koller’s work and Somik’s together, is that they could possibly give you a framework to evaluate your values.

Koller’s formalism reduces to a game theoretic model, which can be evaluated to determine the outcome of the decisions made by a group of people.

Plug in a formalism based on Somik’s ideas and you just might be able to create a way to quantity the benefits of values.

The Importance of Values?

I have been thinking a bit about values these days because there has been a horrific gang rape in Delhi, and there have recently been numerous incidents of bad driving where friends of mine have been injured in Bangalore.  Then there is corruption.  Our society seems to be quite happy with inequality and vast differences in the distribution of wealth.  It make me wonder if our values are to blame.

I have often wondered whether some of our problems originate in our value systems and whether the value systems that we consider sacrosanct in India are really very good ones.

Let me take just a couple of values that most Indians would consider to be very good values

  1. Non-violence
  2. Obedience

and let’s discuss them in more detail.

  1.  Non-violence

This value appeals not just to people in India.  You see variants of the value of non-violence appear in Tolstoy’s writings and in Semitic religions, as you can see from the Bible (“turn the other cheek”) and the Quran (“give alms to one who begs from you, even if he comes on the back of a horse”).

The issue with this sort of value is that it makes a person (and those around him/her) extremely vulnerable to injustice.

In India, we restrict the liberty of women – in their choice of clothing, company and lifestyle – for fear that they could be in danger if they violated societal norms.  This shows that none of us want to fight society or cross swords with someone who might make disparaging comments about personal choices.

Moreover, possibly as a result of the value of non-violence, very few Indians if any are taught fighting skills in school.  So, even if a person really wanted to act, say to protect a friend, he or she might not really have the skills to take down an aggressor.

So, instead of protecting and standing up for people who might be vulnerable, we become their tormentors and make their lives more miserable, just so we don’t have to get our hands dirty, or because we don’t have the skills and strength to do squat.

I’ve written about how bribes are openly collected by traffic policemen.  It should be very easy to put a stop to such behavior if you’re willing to fight.

If non-violence is not a core value, then how do we protect people from tearing each other to bits?

We could start with a question like:  non-violence for what purpose?  (turning it into an extrinsic value)

If the answer is something like, “so that the weak feel protected”, why not make protecting the weak our core value?

I’d prefer teaching kids values like “Don’t ever turn your back on a bully” rather than values like “Don’t fight anybody, and just come home safe, child!”

2.  Obedience

Indian parents love to boast that their child is “such an obedient child!”

Is that a good thing?

Obedience is different from politeness or respect.  The latter are mutual but the former is one way.

So, the politics of obedience creates a hierarchy of subservience.

In India, Parents expect complete obedience from Children.

The Police expect complete obedience from People.

The Politicians expect complete obedience from Police.

Teachers expect complete obedience from Students.

Managers expect complete obedience from Employees.

The creation of the hierarchy (through expectations of obedience) can be very dangerous in many ways.

1.  It can stifle creativity and problem-solving ability.  There is a bias against ideas flowing up a hierarchy because those higher up the hierarchy claim their place above those required to be obedient to them on the premise that they are somehow superior to those below them.  A good example is how parliament will not accept that people have a right to demand a bill against corruption (members of the Indian parliament claim that parliament is supreme in a parliamentary democracy – not the citizens that the parliamentarians represent).

2.  It can leave young people ill-equipped to defend their personal spaces.  I read in a paper on rape that many rapists approach victims by testing their boundaries.  They make comments and otherwise violate the intended victim’s personal boundaries.  If these are not strongly resisted, the probability of an assault becomes greater.  Another strategy used by rapists is to move their intended victim to a new location where they are more vulnerable. It is very important for people to be conditioned so that they do not obey an order by an attacker to relocate under any circumstances.

3.  The hierarchies perpetuate the power of stronger (bigger, older or richer) parties by providing social sanction to their dominant position, and so hinder social mobility.

4.  The obedience hierarchy could allow a few people at the top to amass too much power. It might have, for example, prevented cops from disobeying those in power during the Gujarat riots.

5.  Obedience means valuing rules above truth.  Obedience implies not challenging the rules or the status quo.  So there is little scope for discovering if the rules really are good ones for everybody.  People often defend something they assert with a “because I said so.” – that is, you are expected to believe them because of their authority, and not because they can substantiate their assertion.

Obedience as an absolute value is not entirely harmless.  It could be dangerous to us as a society because corrupt politicians can use the pliability and obedience of people around them to get away with evil (remember the activist who was hacked to death on the orders of a corporator from Bangalore, the journalist who was burnt to death in Uttar Pradesh, or the shutdown that the former Chief Minister of Karnataka State ordered when he was about to be investigated for corrupt dealings?).

I’d love to replace “obedience” with something else, perhaps “honesty” and “trustworthiness” and “pride”.


I understand that we as Indians are very proud of our values but I’ve tried to argue that our values need to be re-examined.

Personally, I’d love to see the day when we replace all our values with just the value of trustworthiness.

Trustworthiness as a value would mean we’d fight for each other.  It would mean we’d protect the weak.  It would mean we’d be on time.  It would mean we’d be honest.  It would mean we’d be capable and skilled and strong.  It would mean we’d be proud of each other.  It might mean we’d never lose another war.

Reading Koller’s and Somik’s work you get the feeling that one day you might be able to evaluate the comparative benefits of two sets of values, and pick the better one, using plain math.

And hopefully, by showing them mathematical proofs, you can convince people to change their values and pick better ones for themselves.

How far is 5 from 4? Does art take you from 4 to 5? Does MAGIC happen between 4 and 5?

I was intrigued, not long ago, to see a tweet by Dr. Prabhakar Raghavan that went “Berkeley Study: Half-Star Change In Yelp Rating Can Make Or Break A Restaurant  nonlinear outcomes from linear(?) inputs“.

Anderson and Magruder at Berkeley observed Yelp ratings and tried to see if they impacted the likelihood of a restaurant being fully booked at peak dinner time (between the hours of 6 and 8 pm).

What they found was that:

An extra half-star rating causes restaurants to sell out 19 percentage points (49%) more frequently, with larger impacts when alternate information is more scarce

Moving from 3 to 3.5 stars reduces the likelihood of availability from about 90% to 70%. A fourth star reduces the likelihood of  availability further to 45%, and that possibility drops to 20% at 4.5 stars

So, the answer to the first question seems to be “A lot farther than you’d think” or “About as far as 4 is from 1” !

Now I am going to show you something else that is equally amazing!

The above economics result is very similar to what is being talked about in this XKCD cartoon on online star ratings!

Take a close look at the cartoon and you will see that the cartoonist is saying much the same thing as the economics researchers.

How did the artist hit it right on the head?

Just how did he do it?  (maybe the cartoonist read the research paper – the guy’s a scientist so it could have happened).

But could it just be that good artists are also incredibly perceptive and intelligent people?

Does art take you from 4 to 5?

I don’t have the answer to that, but I am going to point you to an intriguing paragraph in the book “Transforming Education through the Arts”.

“We found that compared with typical scientists, Nobel laureates are at least 2 times more likely to be photographers; 4 times more likely to be musicians; 17 times more likely to be artists; 15 times more likely to be craftsmen; 25 times more likely to be writers of non-professional writing, such as poetry or fiction; and 22 times more likely to be performers, such as actors, dancers or magicians.”

(From Page 7 of “Transforming Education through the Arts” in the article “The social and educational costs of neglecting the arts”, citing as the source: “Root-Bernstein and Root-Bernstein 2010: 4”).

So, maybe the answer to the second question is ‘maybe‘.

I say ‘maybe’ because there is another explanation.

In software, we have a saying that goes:

80 percent of the features take 20 percent of the time.  The last 20% of the features take 80% of the time.

However, this 80/20 rule seems to apply to many things in life.

You can be a better singer than 80% of the world quite easily.  It might even be possible to become a better singer than 97% of the world with a bit more work.  But it takes infinitely more effort to get from 97% to 99%.  To reach those levels of perfection takes enormous dedication and persistence.

This is the case in every art, and in every craft, and in every area of science, and in every area of technology.

Products become magical when you put in that enormous effort that takes it from 97% to 99% of perfection.

Dancers become magical when they go from 97% to 99%.

We all heard the story of Steve Jobs obsessing over the details of the iPhone even during sessions of chemotherapy.

Cartoonists become magical when …

You get the idea.

So maybe it’s not about art …

Or about science …

Or about technology …

Maybe it’s about having the strength, resilience and stamina to get you to the very top of the mountain and the obsession to keep going …

Maybe that’s what makes all the difference in any area of human endeavour – the intense effort and drive that only very obsessed people are capable of putting in is the magic (or madness) that takes something from 4 to 5.

Maybe that’s why 5 is so far from 4.

Statistics for Linguistics

I recently wrote an article on how machine learning algorithms can be considered extensions of linguistic rules.

The article I am currently sharing with you is also related to linguistics.

It is in the form of a set of slides and describes statistical concepts and tools that might come in handy for linguists.

Here are the slides:

The goal of these slides was to teach a team of linguists about statistics and machine learning.

The main sections are:

  1. Motivation for learning new tools using examples from algorithms and their application to education and poverty elimination.
  2. What to annotate
  3. How to develop insights
  4. How to annotate
  5. How much data to annotate
  6. How to avoid mistakes in using the corpus

What life lessons can you learn from ‘precision’ and ‘recall’?

A few weeks ago, I was invited to Mysore to give a talk.  I wanted to leave the audience with a good idea of quality measurement in Machine Learning.  After talking about Accuracy as a measure of quality and listing some of its drawbacks, I began to talk about Precision and Recall, two very important measures of quality of an AI system.

The slides were really complicated, so I had to simplify the explanation and translate it into layman’s terms:

The Life Lessons Explanation

The explanation went something like this:

You are here listening to me talk today.  But there are so many other events taking place in the city of Mysore right now.

Some of them may be events worth going to (opportunities).  Some may not.

If you attended 10 events out of a possible 200 events taking place, and 5 of them were worth it, your precision would be 50%.

A precision score of 50% indicates that you’re right 50% of the time.

Let’s say there were 200 events around Mysore that you could have attended, and 20 of them were really worth attending.

Since you attended 5 of the 20 events worth attending, your recall was 5/20, that is, 25%.

There are many opportunities for positive experiences out there waiting for you right now.

How many of them did you actually go out and make use of?

That’s what Recall tells you.

Precision is a measure of how well you chose those experiences.

You can aim to experience as many things as you possibly can.  Or you could be very careful about what you expose yourself to.

Recall is about quantity.

Precision is about quality.

The Complicated Version

Now, I’ll try the formal version of the explanation on you to see if you like it.

The slide on Precision and Recall looked like this:

The terms True Positive (TP), True Negative (TN), False Positive (FP) and False Negative (FN), are the key concepts one needs to understand to get a good grasp of what precision and recall are all about.

To understand TP, TN, FP and FN, you need to pick a point of view – a category that you are interested in.

Then, TP is the number of times that someone (or something) picks that category when the data is really of that category.

TN is the number of times that someone says that the data does not fall into the category when the data really does not.

Note that TP + TN represents the number of times they got it right.

FP is the number of times that someone picks the category when the data is really not of that category.

FN is the number of times that someone does not pick the category when the data falls into the category of interest.

Note that FP + FN is the number of times they got it wrong.

Note moreover that TP + FP is the number of times the person thought the data fell into the category of interest.

Also, TN + FN is the number of times the person thought the data did not fall into the category of interest.

There are two more interesting combinations.

TP + FN is the number of data items in the category of interest.

TN + FP is the number of data items not in the category of interest.

Precision is calculated as TP divided by TP + FP.

That is, precision is the fraction of the time someone is right when they claim that some data belongs to a certain category.

Recall is calculated as TP divided by TP + FN.

Recall is the number of data items belonging to the category of interest that the system being measured is able to identify.

In this explanation, you not only have truth being split into perceived truth and real truth, but also have perceived truth being split into two, and real truth also being split into two.

People have thought deeply about truth since times immemorial.  According to the Wikipedia article on Dialectics, “The Sophists taught arête (Greek: ἀρετή, qualityexcellence) as the highest value, and the determinant of one’s actions in life.”

But there lived in Greece a man who disagreed with that notion:  “Socrates favoured truth as the highest value, proposing that it could be discovered through reason and logic in discussion: ergo, dialectic.”

It is surprising that it took till the late 1900s for that conception of truth to be advanced to where you split truth.  Once you began to think of categorisation as a machine learning thing, you suddenly discover how truth has many sides to it.