Week 6 had us introduced to the world of artificial intelligence.
I researched the history of AI and the different intelligences.
But first, how do we define AI?
According to Google, AI is "the theory and development of computer systems able to perform tasks that normally require human intelligence, such as visual perception, speech recognition, decision-making, and translation between languages."
Also in accordance with research by Howard Gardner, there are multiple intelligences.
There are nine of them. They are:
Musical: Knowledge of tone, harmony, rhythm, and sound in general. People with this intelligence can play musical instruments, compose music, and sing.
Spatial-Visual: The ability to visualize with the eye of the mind.
Verbal-Linguistic: Knowledge of words and languages. People with this intelligence are adept readers, writers, storytellers, and memorizers.
Logical-Mathematical: Knowledge of logic and mathematics. People with this intelligence are good at reasoning.
Bodily-Kinesthetic: The ability to control motion of oneself and use it to perform tasks. It also implies having great timing and training responses.
Interpersonal: Knowledge of others.
Intrapersonal: Knowledge of oneself.
Naturalistic: Knowledge of natural surroundings. This includes the ability to identify aspects of nature (plants and animals).
The History of AI and its Pioneers: Alan Turing
Alan Turing was a computer scientist, war hero, and a genius. He is best known for cracking the Enigma code the Nazis used in World War Two.
He was, therefore, critical in aiding Allied intelligence because coded messages revealed Nazi plans.
Alan Turing was a computer science student at King's College and proved many logical and mathematical theorems, including one which
states that one computation machine can perform the same tasks as another and therefore compute anything that is computable. Today,
these machines are known as Turing Machines, but we simply call them computers.
An example of artificial intelligence is this chat bot called Jabberwacky that I interacted with. Notice how some of the answers the bot has don't make sense. Sounding human is not an easy feat for a Turing Machine like this. To respond to input, the computer decides the output by searching for keywords from the input, and in this case, also responds to emotion.
Further along the week we experimented with interacting with our own computer programs. I was not present during these two days, however my friend offered to show his work. He was able to get his computer to read aloud the Old Testament of the bible for two hours. Quite a feat, I'll say.
When I came back from my absences due to sickness, we once again used Python for programming, but this time we would make the computer answer factual-answer questions. I got it to tell me about Monty Python references, as seen in the picture below. For the picture, note the computer output is in blue and human input is black and orange.
So where did the computer learn the screenplay for Holy Grail? Wolfram Alpha, mathematical and factual encyclopedia, has it all. Read the red comments in the picture below.
A final thing we learned on that day was how computers learn. We watched a video on the development of Jeopardy contestant Watson, a supercomputer developed by IBM. The idea behind machine learning is that a machine learns when examples are attributed to their indentities and the machine searches for patterns in these attributions of the same entity. This is what IBM programmers largely credit Watson with qualifying for the show. This was a breakthrough considering the difficulties posed to the developers initially, including the problem of recognizing language, something we humans do very well, however computers do not.
The day after, end of week 6, presented us the final challenge of getting the computer to play games with us.
The day began with rock paper scissors. Above is the working code. Notice how I used "import random". This command allows the computer to select random values from a set of given numbers or strings. Also I learned that I could infinitely loop the process of the computer asking if the player wants to continue playing. At the beginning of the week I speculated it would be hard to do this, however I found an easy method to doing it. Simply create the game, define it, then create another variable for looping. Put the game variable in the loop. Then put the loop variable at the end of the game. Voila. In the code above the variable is listed as "playagain".
The day ended with programming Hangman. It was difficult because I had to learn how to integrate the random word generator with the hangman diagram and missing letters diagram. This concluded week 6 of computer science.
My teacher had a great idea about programming computers presented to us. He said, "It can't be that hard to program a game of tic-tac-toe, can it?" And then he let us work and figure out how tough it really was. Now, that's not to imply he is a mean person, but I learned that I need to lower my expectations. Below is my unfinished code for hangman. Red comments guide the way.
What did I learn?
1. Arrays are necessary for variables representing more than 1 string.
2. Variables such as "move" can have more than one value; for instance, they can be changed from numeric input to letter output.
3. It is more efficient to identify all the necessary functions for a program before coding in Python.
The next challenge of the week was to create a 1-player tic tac toe game. This was tricky because we need to make the computer move, right? Well, we have to program it to make its own decisions of playing tic tac toe and HOW. I built my own denomination of computer functions building off of a technique my instructor used. It's called "bestmoves". Not much changed to my tic tac toe program besides the addition of the computer brain and disabling ("commenting out") the code for player 2 of the two-player game. Below is the experimental code I created for the computer.