RSS

Monthly Archives: June 2019

Are Algorithms really non-bias?

You hear it all the time, “the search algorithm is unbiased in the results.” The program uses algorithms to do whatever tasks are needed. But, the big question should be: do algorithms have a bias? 

Well, the answer is YES! The algorithm is as bias as the programmer programming it. At this point, most people reading are going to ask, what is an algorithm?

Definition: A process or set of rules to be followed in calculations or other problem-solving operations, especially by a computer. (Google)

Let’s put this into practice, and look at some pseudo code:

1.     Flip Coin

2.     Is it heads or is it tails?

This is the classic flip-a-coin problem and because the coin is two-sided, it should flip heads 50% and tails 50%. However, if flipping the coin 10 times, you may get more of one side than the other, but if you continue to flip the coin, say 100 times, most likely it will become almost 50% heads and 50% tails. Now, that is assuming the coin is not weighted or tampered with… which, does that not sound like a bias, but what if someone took the time to weight a coin so that when it flipped it would come up a certain way more often?

In computer science we would use the Random function to return a random number based off a seed number; the closer to 1 means heads and the closer to 0 means tails. Let me state this before someone who programs for a living — yes, I know Random is not always Random, but for this simple example, it will do the trick. As an aside, it turns out writing a truly Random number generator is not as easy as one might think! 

Sorry, back to our example. If the random number is closer to 1 it is heads, and closer to 0 then it is tails. In most cases, if you executed the program as stated above it would eventually come out as 50% for each side.

What if, we want the flip of the coin to come up tails more often? For example, we found out that if a customer flips the coin and it comes up tails before shopping that they will buy 20% more goods at our online store. Therefore, I could just simply add a round process and depending on the round strategy I pick, I could make it so the tails side comes up more often… but this is way random (pun intended). I need more control and I have to make the coin flip look more random because if you come to the store and each time flip the coin and 90 times out of 100 you got tails, you might start asking questions or thinking the system is rigged. Thus, we need to increase the tails outcome by only 30% so now I add a quick calculation to see if the result is within my bias of 30% of the time it is more likely the flip will be tails.

What have we just done? We have made the Algorithm bias! So, as you can see, programming a bias into an algorithm is rather easy. However, let me give one more concrete example of how this works every day in Las Vegas! The gaming regulators basically state the machines must give out X amounts of wins over a period of time. The casino can manipulate the slots algorithm to not pay out any wins for 10 hours and then allow a streak to happen… thus, gaining more attention and people passing by see it and start playing because the machines are hot! However, they may not be, it may be that the slot machine has not been played for 10 hours and must pay out and is trying to get to the defined 30% win ratio! This is a complete bias algorithm. If the casinos wanted to and could get away with it, they would manipulate the machine’s algorithm to hardly ever pay! This does actually occur in some bars where they have a one-off slot machine and may not be regulated as the regular casinos are.

I hope this helps to better understand what you hear on the news and why it is important to understand as we get further down the road with Artificial Intelligence (AI) and systems doing things for us, that all these capabilities are based on algorithms and they are as bias as the programmer who writes them. Therefore, Yes, the algorithms can have a bias!

 
Leave a comment

Posted by on June 29, 2019 in Opinion

 

Tags: ,

Will Robots End Work As We Know It?

It seems this is the question of the day; will robots change or end work as we know it? The quick and simple answer is Yes!  However, we know that nothing is ever that simple and the answer to this question is very complicated. It starts with the concept of work, which is ever-changing since the beginning of time. Having something to trade with another person established the concept of work, and since that time, work has been changing to meet the needs of the world. Living together in groups, building shelters, gathering food, and protecting resources continue to evolve the concept of work.

However, this does not mean that work will stop or there will be no work for anybody and robots will do everything. Historically speaking this has not been the way it works throughout history. Every time an innovation or automation occur, the concept of work changes. As a quick example, do you remember in the 80’s how the robots were going to put everybody out of work? One robot would put 100s of people out of work. These new robots could assemble repetitive tasks over and over, with higher quality and better workmanship.

These things were true, but what was not expected by the masses was the U.S. moving away from industrial revolution towards the information age. Therefore, work evolved from 5 strong guys lifting a motor into a car manually and with brute strength, to having a motorized hoist that one person manipulates to do the job, to the factory floor being manned by task robots that could lift and place the motor into the car, bolt it in, and send it to the next station.

That example shows how over 100 years the task of putting an engine into a car went from 5 people to no people, therefore we had a loss of 5 jobs, right? Well not so fast, the factory had to be upgraded and reconfigured to allow task robots to work. The company providing the task robots hired sales, engineers, programmers, QA people, installers, and then there are the maintainers at the factory itself. Thus, it could be said that the elimination of 5 workers allowed 20 or more workers to be hired. Now, that stinks for the 5 people who got displaced, but overall it was good for the economy and over time lowered the cost of producing a car, which kept the car company in business and allowed the company to compete.

The same story has played out over history as we have moved from a farming society to an industrial society, to a services society, to an informational society, and now starting a mass-automation society period. Think of the time-savings in the past 20 years with “smartphones” and how the world has adapted to having a computer in your hand for much of the day, every day, 24×7. Did having the smartphone take your job or did it create a whole new level of programmers building mobile applications? Again, it did not take the regular application and web developers away from their jobs, it added to the amount of programmers needed for the marketplace.

It is important to remember that every generation has, or takes, a huge step forward in productivity. Once those steps are taken, the productivity is normalized and that is the new base standard of doing the job. This new standard is then built-upon to established even more productivity gains and the process continues to repeat.

One of the best examples of this is one of mankind’s greatest failures, which is slavery. You can pick the time and location and as we know slavery continues to this day. However, let us look at Egypt and the building of the pyramids, which it is estimated that there were over 100,000 slaves used to build and construct the pyramids. While the slave labor was used to build and construct, this did not stop commerce in the region, it actually continued as people provided farms, livestock, textiles and all the things that made the society work. It could be said that these 100,000 people took the hard work, which they did, that allowed the general Egyptian to focus on other things than building pyramids. Thus, the majority of Egyptian people did not stop working and just sit and think about the world, they continued in their line of business and continued moving forward.

So, here we are today, with the concept that a majority of jobs are being lost due to automation and in some cases, there will be displacement as machines continue to grow in capabilities. There are signs that even some “thinking” jobs could be in the crosshairs in this go around. That is definitely possible, since the 80s we have been talking about ESS (Executive Support Systems), Artificial Intelligence, and building analytics into the DSS (Decision Support System) that can take “real knowledge” and allow constraints to be applied to formulate the “coded” expertise into useful information, or actionable knowledge.

In some cases, we are there today, but it still relies on old technology. Some could argue that we are still in the 3rd generation programming languages (see my other posts about that) when we thought in the old days 70s/80s/90s that we would be working on 5th generation languages and would be doing all the really, really, high-level constraints and logic programming.

However, that is still not the case, and one of my favorite statements from Wikipedia on 5GL programming languages is: “It turns out that, given a set of constraints defining a particular problem, deriving an efficient algorithm to solve it is a very difficult problem in itself. This crucial step cannot yet be automated and still requires the insight of a human programmer.” (Wikipedia – https://en.wikipedia.org/wiki/Fifth-generation_programming_language )

Finally, this leads to the concept that is if there is this much automation and that correlates into massive amounts of displacement, do we need to start now in establishing a “Basic Income” for all, since the machines are going to be doing all the jobs? Again, as explained above, automation could be huge and in this go-around, the displacement of workers could be huge as well, but historically speaking, any time labor becomes obsolete, or replaced by productivity, or a machine, the market has responded by adding more “things” to do. Or we have the ability to take advantage of the “new labor” and work to go beyond that labor, because as we know… once you release the first version of anything, the idea for the next version is right around the corner. Just one more example of how automation on the surface appears to kill jobs, but in reality, it expands jobs.

Take for example the Pony Express, which only operated for 19 months, but it is likely known by most kids in school. What did it do? It would deliver a piece of mail from east coast to west coast in about 10 days in the U.S. Prior to the Pony Express being set up the process of sending a letter could be months and then, an answer could take months coming back. Think if you had a contract, you sign it, send it, a month later it is received, it had a spelling error, so it could not be signed, it was sent back, another month, spelling fixed, sent back to the west coast another month, signed and sent back, another month, so in about 6 months you could have a signed contract.

Picture: https://s-media-cache-ak0.pinimg.com/236x/24/92/33/2492331986727f7e7d426f2902857637.jpg

By the by, the cost was not cheap, it was about $5 dollars per ½ ounce and in 1860 that was a lot of cash. This was revolutionary, but it was quickly replaced and put out of business by October of 1861. It was no small operation with over 120 riders, 184 stations, 400 horses, and 100s of people working there and delivered over 35,000 letters in its short time. However, Western Union showed that they could send a telegraph from east coast to west coast in a matter of minutes, thus the Pony Express shut down 2-days later. An estimated 300 people were displaced by the telegraph, but Western Union is still around today employing thousands.

Again, the example of poor competitive analysis by the Pony Express people is another story, but the fact is there was something exponentially faster and it displaced all those people for a new system. Before the Pony Express, it was unheard of to deliver a letter in 10 days. With the telegraph, it was unheard of to do the same thing in minutes. This productivity did not stop people from working, they devised new ways to work with faster communications and thus the story continues.

Do we need a “basic income?” No! Will there be automation in the future that will displace a lot of people, Yes! Does this mean all ideas and work will stop, No! It does mean we will learn how to take advantage of the new “labor” and exploit it for more gains and profit as it has always been done since people starting doing commerce.

 
Leave a comment

Posted by on June 28, 2019 in History, Opinion, Technology, Uncategorized