Challenges facing Artificial Intelligence

Technology is changing quickly, especially in the area of artificial intelligence. In 1985, Garry Kasparov defeated 32 different chess computers simultaneously. In 1997, Garry Kasparov lost to IBM's chess computer Deep Blue in Game 6. This could be considered the tipping point, where computer programs became better than humans at some difficult tasks. By 2011, IBM once again shocked the world, when their Watson computer defeated former champions Brad Rutter and Ken Jennings on Jeopardy! in two televised matches.

Fast forward once again to 2016, where Google's DeepMind AlphaGo artificial intelligence program defeated 18-time world champion 9-dan Go master Lee Sedol, by winning 4 of 5 games, a feat previously judged to be at least a decade away.

Lee Sedol plays game three in his match against Google's AlphaGo artificial intelligence program
Lee Sedol plays game three in his match against Google's AlphaGo artificial intelligence program

Tay's failure in artificial intelligence

Then there was Microsoft's Tay artificial intelligence. Microsoft launched a chat bot, which would respond to input from users on Twitter. They shut down Tay within 24 hours, having become as The Verge reports "a racist asshole". Why did this experiment go so badly?

The Tay AI chatbot artificial intelligence was quickly shut down
The Tay AI chatbot artificial intelligence was quickly shut down

The earlier examples of artificial intelligence all involve controlled environments. Deep Blue and AlphaGo work entirely within the rules of the game board, and contain virtually no social interaction. Watson was able to respond to input through a rule-based system that created a question by mining data from static data sets. As for Tay, this artificial intelligence was released not just to the internet at large, but to Twitter in particular. Tay was unprepared for a completely unstructured and uncontrolled environment.

Twitter as an uncontrolled environment

I use Twitter myself ( @maplemuse ). While twitter can be good for sharing information, it's also home to considerably darker elements. Twitter is a free exchange marketplace for ideas, but as noble an idea as that sounds, not all the ideas are... appropriate for polite company. Microsoft claims that this was a "a coordinated attack by a subset of people". They just don't understand Twitter.

There are a few fundamental problems with Microsoft's approach. They completely failed to impose rudimentary controls over the environment, and take into account "rogue actors" who would find this a fun challenge. Secondly, this seems to have been an open-ended project without a clear product goal. The earlier programs tested progress against clearly defined and measurable goals.

It seems like the answer to Microsoft's classic slogan "Where do you want to go today?" was something Hunter S. Thompson wrote.

Twitter is bat country!
Twitter is bat country!

The Turing Test and Eliza

Clearly, Microsoft was reaching towards passing the classic Turing test, whereby a human conversing with an artificial intelligence or computer program would be unable to determine whether they were talking to a program, or to another human. Having a conversational program hearkens back to Eliza, a software chat program written at the MIT Artificial Intelligence lab back in the mid 1960s. Eliza parrots back statements as questions, mimicking the style of  psychotherapy.

While it remains unclear how much of Tay was mimicry, and how much was artificial intelligence and rule processing, it is quite clear that no company will release a conversation AI directly onto Twitter ever again.

Joining Google


A few weeks ago, I received an offer of employment from Google. I'll be working in the Google Waterloo office, currently located in the Tannery building in downtown Kitchener. It's a pretty cool office, which I've visited several times now for various interviews and meetings. I've worked for small and medium-sized companies before, but before this, the largest company I've worked for was Research in Motion (since renamed to BlackBerry), although they're not as big as they were at their zenith. Google will easily surpass that, but it seems that the culture is in many ways, more like some of the smaller companies that I've worked for.

Yesterday was the last day at my current job. While it's sad to see it go, new opportunities await. Automation control software can be quite challenging, but there isn't as much emphasis on user interface and user experience as I would like. Still, in the end, it's a big change.

Here's to the next chapter! I'm rather excited.

A LEGO android

On Passion in Sales and Customer Disservice

The other day, I willingly walked into a Future Shop. I had a particular need, a new BluRay player that was smaller than my 10 year old DVD player that had been in the basement. It needed to fit on a much smaller shelf, and the old unit was a behemoth. Upgrading to a device that used HDMI would also free up the only component input, so I could connect the Gamecube for the kids.


Another family was looking at the BluRay players, being "helped" by their sales vulture. Apparently, they had just bought a $3000 television, and needed a player as well. I don't know why, but he directed them to the cheaper Sony model on the shelf. Maybe because he could offer it on a greater discount for them. The confusing thing for me was that he wasn't talking about any of the features any of these players had. The model he was recommending did not have built in WIFI, requiring an ethernet cable to the television location. When he explained why the Sony was so great, he essentially said

When we have televisions out on the floor, we always choose Sony models, because they're super reliable. Unless it's for a Samsung television, when we use the Samsung player.

Excuse me? They're "super-reliable"? At this price point, it's commodity hardware. You're not going to get a more "reliable" model by brand. I was of course standing there, holding a non-Sony device.

Was he trying to shame me into changing brands? Unlikely, as his name wasn't going to find itself attached to my receipt.

Why didn't he ask more questions about what they wanted? Maybe he asked the questions while in the television section of the store, but I doubt it. Why didn't he try to upsell to a model with better features. In his own words

"You already spent $3000 on the television"

So what's the difference between a $69 and $89 model? $20. If you have a $3000 television, are you really going to quibble on 0.67% of your cost, if it gets you useful features? Maybe some might. But this sales guy didn't even try to match features (benefit to the customer). The only reason I can come up with is that there's a higher store margin (or personal bonus) for this particular model.

Retail is a very strange business. It's been we'll over a decade since I did my time, and I'm reasonably certain that I had slightly more integrity at the time.

I used to try and see if I could get to the far side of the home theatre section without being accosted by a "sales associate". In the high end area of the store, they usually want to see if you want to buy something. I asked on where the BluRay players were (the other side of the store? Really?) Once he realized that I wasn't going to be buying a TV, he lost interest fast.

This isn't the case for all stores, but I've found that employees at Best Buy, Future Shop, and other big box stores are in general, don't really provide that great of service. They can direct you to where things are in the store, and can answer questions about what's on sale, but often aren't very good at answering even basic product knowledge questions. Ask them to compare two products? Good luck getting a useful answer! There are obviously exceptions to this rule, and I've likely avoided any chance of discovering those valuable salespeople, mainly due to my disgust with those who don't try. Show some passion about the products!

Why CAPTCHAs are evil

Have you ever signed up for an internet forum or web app? Chances are, you've seen a CAPTCHA: a little image with distorted letters demanding that you prove that you are human. Or is that what it is really asking? Perhaps instead, it's asking that you prove that you're sighted.

Phoney Security

CAPTCHAs (Completely Automated Public Turing test to tell Computers and Humans Apart), are supposed to prevent automated computer programs from posting spam messages on public forums. It's a kind of Turing test that assumes that computers cannot pass.

Advantage: OCR

This is far from the truth. Optical character recognition (OCR) is getting pretty good at this, and the various attempts at making this more difficult usually cause more problems for humans than computers. Adding noise to the image can be filtered out, and colours can be scanned.

Let's assume that the standard "what letters do you see?" CAPTCHAS can be broken by computers, with a little work. As can be seen from an article in WIRED discussing Ticketmaster's CAPTCHAs, large scale, automated circumvention has been lucrative for years now.

How easy is it for humans?

There are a number of cases where CAPTCHAs actively discriminate. Are you blind? Tough luck. We can forward you to an audio version, which is even worse. Are you dyslexic? If you have trouble reading words in a consistent font face, how easy is it to read deformed letters? Not so easy. What about people with poor motor control? They may need to use a toggle switch to manually type in your letters. This is a major inconvenience to sign up for an account.

The Arms Race

The next step in the arms race is to present the user with some images, and ask them to categorize them. This steps out of the realm of OCR, a mapping of image to characters, and into knowledge systems. This requires some domain specific knowledge, and potentially culture specific knowledge.

This adds additional problems, like when users are asked to select all the phone images. Telephones from the 1980s and earlier, especially early cordless and mobiles, look nothing like telephones today. Iconography relies heavily on cultural knowledge, and can easily lead to problems.

The Mechanical Turk

The other problem of course, is that there may be little distinction between malicious computer programs, and systems that employ a human factor. An automated system could serve up these CAPTCHA images in real time to human agents, who can solve them and pass them back to the system. Perhaps this doesn't scale as fast as a purely automated solution, but the fundamental issue is still there.

The Recommended Solutions

The W3 Web Content Accessibility Guidelines recommend, very broadly, a text-based cognitive test, to be offered as an alternative to either a visual or audio test. I've tried using an audio captcha once, but it was interfering with the JAWS screen reader I was testing at the time.

Oh, the irony!

The irony is that many users who rely on assistive technologies also use browser plugins to help bypass captchas. They take advantage of the fact that captchas don't work in order to gain access.

I would argue that the concept of captchas is fundamentally flawed. As the captcha technology becomes more sophisticated, so do the attacks. The problem is that with each stage of the arms race, successfully completing these tasks becomes more difficult for humans. CAPTCHAs don't address the real problem. The problem isn't determining whether a human is physically present on the end of a web browser. The problem is behavior based. What particular behaviour is a captcha intended to prevent? Spam messages on a forum? Unsolicited bulk email? Why not address these issues directly, rather than with a CAPTCHA?

Solving the Real Problem

There is existing technology to grade messages with heuristics. Spam filters have gotten quite good. If messages from a new member of your site are also held in a moderation queue, there can be an additional check for appropriate content.

You can also analyze the browsing behaviour. What patterns emerge? For a social site, how much time is spent on existing content? For an auction site, how much time has been spent looking at different items? For certain types of sites, such as local auction sites, there may not be enough behaviour to adequately analyze, especially if a user does not need to create an account in order to participate.

Why are CAPTCHAs so prevalent? They're available as third-party developer libraries, and don't require any changes to system architecture. It's a band aid solution to the wrong problem.

7 Steps to Solving Technical Problems

When I started a new job a few months ago, I entered an unfamiliar technology stack. Being the new guy on a project isn't always easy. While a great team will make it easy to ask questions and learn, there seems to always be another problem to solve, or figure out how something works. This isn't always solving a software bug, but instead often deals with coming to a greater understanding of how something works, to change the behaviour, or to duplicate it. Puzzle

I have a great mentor, who knows many aspects of the code base. While he's always willing to help, I like to reserve my questions for the tough questions. I've often found that when asking a colleague about a problem directly, I often wait until they're at my desk before I rephrase the problem, and make that elusive link between what I think I know, and what the code is hiding. In other words, I can usually figure it out on my own, but I end up explaining it to someone else first.

While this is good, as I've solved the problem, and I've shown how my thinking works, this isn't an interview situation where explaining how I think is important. Sometimes, the person I want to ask is away from their desk. They could be in a meeting, or out for lunch. These questions never seem to come at convenient times.

Here are a few techniques you can use to solve these kinds of problems before you pull a colleague over for a talk.

  1. Summarize the problem in writing. Be specific. This should be a careful analysis of the problem, clearly showing the state of the system, what you're expecting to see, and what you are seeing. Extrapolate if needed.
  2. Search the code history. Have any recent changes in the system affected this? Use the blame annotations provided by your version control tool. Perhaps you're hitting an edge case that wasn't properly accounted for in recent changes. Watch and see how the function has changed over time. Are all the assumptions still valid?
  3. From this summary, search the web with any key terms. With some luck, someone else has experienced this problem before, and you can learn what they tried.
  4. Search Stack Overflow. Many companies now host an internal version, which has information on internal software. These obviously won't be indexed by Google, and they're often rebranded. Hopefully there's something relevant.
  5. Post your problem to your Stack Overflow site if appropriate. Ensure that you include the written summary from step 1, as well as the results from steps 2-4.
  6. Send your mentor an email with the link to the Stack Overflow post.
  7. Finally, it's best to follow-up with your question, marking the best answer as accepted. Follow up with a comment for anyone who was particularly helpful. Ensure that others who find your question at a later date can also solve the problem.

There's a set of clear benefits to following a path such as this to solving your problem.

  • Help others solve the same problem at a later date.
  • Showcase your thinking process for your peers.
  • Highlight inefficiencies in the code base. Pain points like this can help target debt reduction strategies.

There are other ways to solve problems like these, but this is an effective strategy in helping not only yourself, but also your organization.

Why is Windows XP stuck with IE 8?

For all web developers and designers, Internet Explorer 8 support is likely the least enjoyable part of your work, and it's unlikely to go away any time soon. As much as Microsoft would like for everyone to upgrade to Windows 8 this fall, the simple truth is that many home and school PCs are still running Windows XP. These systems are for the most part under powered to run Windows 7, and may have software that is incompatible with the newer versions of Windows. After all, from XP there is Vista, 7, and very soon, Windows 8. Just think about all the driver incompatibilities introduced by each successive operating system upgrade.

Browser Wars image: Firefox and Chrome fight while IE eats glue

For large organizations, such as academic institutions, an en masse upgrade from XP is unlikely, not only for the hardware and licensing costs, but also through the IT management work required to vet any software upgrades. The upgrades happen, albeit slowly. There just isn't a compelling enough reason to upgrade.

Why doesn't Microsoft just upgrade the version of Internet Explorer running on XP? Why can't they put IE 9, and soon IE 10, on their older operating system? The latest versions of Mozilla Firefox, Google Chrome, and Apple's Safari are all available for Windows XP.

But all those browsers are cross-platform, one might argue. They don't have the deep integration with the operating system, like IE has. So what? Why should that matter? Safari is a web browser installed by default with Mac OS X, which presumably has as much opportunity for deep OS integration as IE. Apple took a different route. Rather than seeking deep integration with the OS, Apple open sourced the WebKit rendering engine, which is now not only used by Google Chrome, but also in most smartphone browsers as well, including those of BlackBerry, Android, and iOS.

One could argue that this kind of entrenchment, where Microsoft is unwilling or unable to upgrade the browser in earlier versions of Windows, is exactly the kind of problems the Department of Justice antitrust case should have solved. Certainly, the arguments raised by Microsoft suggested that the operating system was strongly coupled with the web browser, such that they could not be separated. But the antitrust trial focused on competitor access to Microsoft APIs. If the sanctions against Microsoft had been stronger, we might have seen IE9 on Windows XP today.

Microsoft is clearly capable of writing a rendering engine separate from the OS. From 1998 to 2003, Microsoft released versions of Internet Explorer for the Mac, dropping support in December of 2005. These versions were supported on Mac OS 7, the "Classic" OS, through to OS X Tiger, and supported two different system architectures, the old Motorola 68k systems, as well as the PPC systems. They have experience in writing cross-platform rendering engines, but clearly feel hat one closely tied to a particular operating system version is somehow beneficial.

How exactly does a tightly coupled system help them? It could be an added enticement to upgrade to a newer version of Windows, but if so, it's not really very effective. Perhaps it makes development easier? I fail to see how that might be the case. Other browsers seem to have no problems with a more portable architecture, so unless Microsoft is making extensive use of internal APIs again (once again, reference the antitrust suit),I fail to see how this makes sense.

One of the most convincing arguments is that it could cut the number of possible OS/browser configurations for testing, either internally, or by organizations with more extensive upgrade trials. Supporting IE9 on Windows XP would need extensive testing not inly of the browser itself, but all the different extensions and integrations, all on an operating system that is several generations old. After all, XP is in extended support mode, with that final stage set to expire in April 2014. Spending large amounts of money on testing IE9 support on Windows XP clearly isn't in Microsoft's best interests.

So where does that leave web developers today? Are we doomed to support IE until 2014? Sadly, I suspect it will live on longer, the browser zombie of the net. Aside from promoting the use of Firefox or Chrome on Windows XP, there is little we can do. Like classic Romero zombies, it's not going anywhere very fast.


The High Tech Job Sector in Waterloo Region

As dire as news coming from Research in Motion is these days, Waterloo Region has a large number of technology companies actively hiring. We're really fortunate to have such a variety of local companies here in the Region, and the support of Communitech.

Tech Leadership Conference 2012

Communitech also has a tech jobs website, This past month, I attended the Waterloo TechVibe Recruitment Event, where a number of local companies were recruiting. How did that work out? After the event, I was in different stages of the interview process with six companies, before accepting a position at Desire2Learn.

I was really impressed by the variety and quality of companies we have in Waterloo Region. We are far more than just the headquarters of RIM. From radiology workflow solutions at Medicalis, to financial account management at Arius Software, to cross-platform mobile voice solutions such as Fongo, the market is definitely hopping.

While it's true that when people think of Waterloo Region technology companies, RIM is often the first company that comes to mind, there are also local Google offices, as well as OpenText.

While many companies in the region are in the mobile space, such as Kik and enflick, we also have good representation in the medical and financial services fields.

So while the wind may be out of the sails at RIM, the economic outlook for Waterloo Region is still very good, as noted in a recent article in the Waterloo Region Record on a report by the Conference Board of Canada. Will job cuts at RIM hurt? Without a doubt. But the benefit is a more diverse region, where smaller companies are not struggling to find the talent that in the past several years has been going to RIM.

Waterloo Region also has great support for technology startups. Communitech has their Hyperdrive program, Waterloo has the Accelerator Centre, and the University of Waterloo has a Velocity incubator. All of these programs offer entrepreneurs with space and access to established mentors, to help build their businesses. While these don't provide large employment numbers now, they do provide opportunities for those in the region.


Supporting Local in a Global Marketplace

While listening to 570 News the other day, one of the hosts of "Your Money Matters" assured the audience that although he likes Apple stock, that he wears a BlackBerry on his hip. I know that I'm not the only person in Waterloo Region with an iPhone, and there are a number of folks with Android devices as well. After all, Google has a local presence here as well.

The fact remains that there appears to be a blind devotion to supporting Research in Motion's handheld devices, without a critical comparison to competitors. "BlackBerrys have a physical keyboard" is one quick defense, with the strong implication that a touch screen device is useless for typing. Guess what? This post was typed entirely on my iPhone.

Before someone suggests that I don't know enough about BlackBerry, let me assure you that I do. During my four and a half years working there, I used the Pearl, Bold, Storm, Torch, and all the variants. I even used a Pearl Flip for awhile. Some were better than others, but when it was time to leave RIM, I didn't hesitate, and bought an iPhone.

I'm not suggesting that everyone should buy an iPhone, but rather that they should acknowledge that they may not have the best, most competitive device. In fact, they should realize that this blind devotion to RIM, and lack of local criticism may in fact have contributed to the lack of true innovation in the last several years.

While I understand the desire to support local businesses, the lack of critical dialogue in the community makes things seem like a case of the Emperor's New Clothes. I think we need members of the community to be critical of local businesses which are attempting to compete globally. It leaves the perception of being a market leader, where outside the region, the ship has long since sailed.

This increased isolation from competitive devices has no doubt affected RIM staff as well. How many developers at RIM have had much experience using an iPhone or Android? How many know areas in which one is better than another?

Now I'm sure that their situation is abundantly clear by now. The new CEO does not have rose colored glasses. Other recent departures on the executive hopefully reveal a shift in vision, to address the challenges facing them today.

We in Waterloo Region have benefited from RIM's past success. Does this require seemingly sycophantic praise for their current devices? While I wish my former coworkers the best of luck in the current transition to BlackBerry 10, I can only hope that their new devices meet the demands of the wider international market, and not just those of Waterloo Region.

We should also remember that as a corporation, RIM's first duty is to its shareholders. The corporation doesn't "owe" the community anything, outside any possible contracts with the municipalities. However unlikely it may seem, some high level deal could see RIM walk away from the region, to set up shop elsewhere. Don't think that could happen? Just ask the folks in Salo, Finland, about ailing Nokia. While I don't see this happening, RIM has significant investment in the region, it is within the realm of possibilities, especially if RIM enters certain partnerships or is otherwise acquired.

What do you think? Am I missing something here? Is there a reason to praise the current BlackBerrys? Does the Be Bold marketing campaign mean anything to you? Should I cut RIM a little more slack as they negotiate their transition to a new platform, or do you, like me, hope that people stop trying to defend their mobile choices by saying that they are "supporting the local guy"?