15.04.2018 Views

programming-for-dummies

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

650<br />

Problem Solving<br />

ELIZA doesn’t actually understand the meaning of words. Instead, ELIZA just<br />

knows how to arrange words in their proper position to mimic an intelligent<br />

conversation. When ELIZA spots a word, such as sister, brother, or father, it<br />

immediately searches its database <strong>for</strong> a list of canned replies related to<br />

asking the user questions about his or her family.<br />

By combining both canned phrases and parroted replies, ELIZA succeeded in<br />

mimicking an ordinary conversation. Although Joseph Weizenbaum originally<br />

created ELIZA to research natural language processing, he was astounded at<br />

how readily people accepted ELIZA and treated it as an intelligent computer<br />

even though they knew how it was programmed. When Weizenbaum found his<br />

secretary typing her problems into ELIZA and requested that he leave so she<br />

could have privacy, he became an advocate against artificial intelligence.<br />

One common application of natural language processing can be seen in the<br />

help system of many programs. If you type How do I print a document, the<br />

help system <strong>for</strong> your word processor might display a list of topics <strong>for</strong> printing<br />

files. The computer didn’t actually understand the sentence. Instead, the<br />

computer, like ELIZA, just scanned the sentence, looking <strong>for</strong> keywords that it<br />

could recognize and then responded based on the keywords that it found.<br />

To poke fun at ELIZA, Kenneth Colby, a psychiatrist at Stan<strong>for</strong>d University,<br />

wrote a similar program dubbed PARRY. Whereas ELIZA mimicked a therapist,<br />

PARRY mimicked a paranoid, schizophrenic patient. Computer scientists often<br />

connect ELIZA with PARRY to see what amusing conversation these two<br />

programs could create from each other.<br />

Speech recognition<br />

Similar to natural language processing is speech recognition. Like NLP, speech<br />

recognition must identify a word and deduce its meaning. But unlike NLP,<br />

speech recognition has the added burden of trying to do all this in real-time.<br />

The moment someone says a word, the speech recognition computer must<br />

quickly understand that word because the speaker won’t likely pause <strong>for</strong> long<br />

be<strong>for</strong>e saying the next word.<br />

The simplest <strong>for</strong>m of speech recognition involves choosing from a limited<br />

selection of distinctly different sounding words. Many voicemail systems offer<br />

this feature by asking a question such as, “Do you want to leave a message?” At<br />

this point, the speech recognition computer listens <strong>for</strong> any sound that resembles<br />

either Yes or No. Because the speech recognition computer has such a limited<br />

selection to choose from, its accuracy rate can be almost perfect.<br />

A second way to understand speech is to <strong>for</strong>ce users to train the computer<br />

first by saying a limited selection of words. The computer then stores these<br />

spoken sounds in a database so the next time the user talks, the speech recognition<br />

matches every spoken word with the closest match in its database.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!