0% found this document useful (0 votes)
131 views38 pages

Unit-1 Ref

artificial intelligence

Uploaded by

Jyothi Pulikanti
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF or read online on Scribd
0% found this document useful (0 votes)
131 views38 pages

Unit-1 Ref

artificial intelligence

Uploaded by

Jyothi Pulikanti
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF or read online on Scribd
You are on page 1/ 38
Introduction to Artificial Intelligence Syllabus Introduction : What is Artificial Intelligence ? Foundation of Al, history, the state of, art Al today. - Intelligents Agents : Agents and environment, good behaviour, nature of. environment, the structure of agents. Syllabus Topic : Artificial Intelligence Introduction to Artificial Intelligence - John McCarthy who has coined the word “Artificial Intelligence” in 1956, has defined Al as “the science and engineering of making intelligent machines”, especially intelligent computer programs. ~ Artificial Intelligence (AI) is relevant to any intellectual task where the machine needs to take some decision or choose the next action based on the current State of the system, in short act intelligently or rationally. As it has a very wide range of applications, it is truly a universal field. ~ In simple words, Artificial Intelligent System works like a Human Brain, where a machine or software shows intelligence while performing given tasks; such systems are called intelligent systems or expert systems. You can say that these systems can “think” while generating output!!! AI is one of the newest fields in science and ‘engineering and has a wide variety of application fields, AI applications range from the general fiel and prediction to the specific field, such as writing sto Gly. 7 e ving a bus on’a crowded street, diagnosing disea: lds like learning, perception ries, proving mathematical ses, and playing chess. Of how to make machines do thing which at the moment people do better. fout approaches to define AI. : wiles sais en ~ For this test, the computer would need to possess the following capabilities : a a carey, 12 Introduction to Artificial int, | artificial ntetigence (MU B.S¢.1 3 —= TTabus Topic : Foundation of Al =—— Syl 1.2 Foundation of Al isthe study of how to make machines do things whic, In general, artificial intelligence the moment human do better. Fol yur approaches to define Al. Historically, all four approaches have been different methods. 4.2.1. Acting Humanly : The T! lowing are the fo! followed by different group of people wig uring Test Approach perational definition Of Al. Explain Turing test designed for satisfactory 2) ating machines th people.” (Kurzweil, 1990) Definition 1.: “The art of cre at perform functions that lligence when performed by Definition 2 : “The study of how to make computers do things at wl moment, people ae beter.” (Rich and Knight, 1991) S Sir Alan Turing had designed a te To judge whether the system can act like a human, known as Turing test. ‘As shown in Fig. 1.2.1, in Turing test, a computer needs to interact with a humn interrogator by answering his questions in written format. Computer passes the tes if human interrogator, cannot identify whether the written responses are from a person or a computer. Turing test is valid even after 60 year of research. Humen interrogator Fig. 1.2.1 : Turing Test Environment 1. Natural Language Processing (NLP) : Thi: rerprel 5 gua iB ) : This unit enables computer to int A English language and communicate successfully. 2, Knowledge Representation : This unit j thered : is used t ul om mech inp aie ‘0 store knowledge g@! 4 ictal Intaligence (MU Sem-V) 1-3 Introduction to Artitictal Intelligence 3. Automated Reasoning : This unit enables to analyze the knowledge stored in the system and makes new inferences to answer questions. 4. Machine Learning : This unit learns new knowledge by taking current input from the environment and adapts to new circumstances, thereby enhancing the knowledge base of the system. To pass total Turing test, the computer will also need to have computer vision, which is required to perceive objects from the environment and Robotics, to manipulate those objects. ities a Computer needs Fig. 1.2.2: Capabilities a Computer needs to possess - Fig. 1.2.2 lists all the capabilities a computer needs to have in order to exhibit artificial intelligence. Mentioned above are the six disciplines which implement most of the artificial intelligence. 1.2.2 Thinking Humanly : The Cognitive Modelling Approach Definition 1 : “The exciting new effort to make computers think ... machines with| ‘minds, in the full and literal sense”. (Haugeland, 1985) — a Definition 2 : “The automation of activities that we associate with human thinking, | activities such as decision making, problem solving, learning ...” (Hellman, 1978) DEFINITION Cognitive science : It is inter disciplinary field which combines computer models from Attificial Intelligence with the techniques from psychology in order to construct precise and testable theories for working of human mind. In order to make machines think like human, we need to first understand how human think, Research showed that there are three ways using which human's thinking pattern can be caught. 1. Introspection through which human can catch their own thoughts as they go by. 2. Psychological experiments can be carried out by observing a person in action. 3. Brain imaging can be done by observing the brain in action. BPP ariiciat into ence (MU B.Sc. IT- Sem-V)_1-4 Introduction to Artificial Intell ence | hing the human thinking pattern, it can be implemented in computer system ag a an ad if the program's input output matches with that of human, then it can be program an 's j claimed that the system can operate like humans: 1.2.3 Thinking Ratlonally : The “Laws of Thought” Approach cena | Definition 1 : ‘The study of mental faculties through the use of computational] [J] | modets”. (Charniak and MeDermott, 1985) ~ Definition 2 : “The study of the computations that make it possible to Perceive, reason, and act”, ~ The laws of thought are supposed to implement the operation of the mind and their study initiated the field called logic. It provides precise notations to express facts of the real world. - It also includes reasoning and “right thinking” that is irrefutable thinking process. Also computer programs based on those logic notations were developed to create intelligent systems There are two problems in this approach : 1. This approach is not suitable to use when 100% knowledge is not available for any problem. 2. As vast number of computations was required even to implement a simple human Teasoning process; practically, all problems were not solvable because even problems with just a few hundred facts can exhaust the computational resources of any computer, 1.2.4 Acting Rationally : The Rational Agent Approach Definition 1 : “Computational Intelligence is the stud LL | agents". (Poole et at, 1998) Definition 2 : “Al ... is concerned with intelligent behaviour in a ‘QNilsson, 1998) ly of the design of intelligent ifacts”. ® Rational Agent — Agents perceive their environment throu; adapt to change to create and pursue goal those goals. gh sensors over a prolonged time period and Is and take actions through actuators to achieve ~ Arational agent is the one that does “right” things and acts rationally so as to achieve the best outcome even when there is uncertainty in knowledge, Paniicia Intelligence (MU B.Sc. IT-Sem-V) 1-5 Introduction to Artificial Intelligence ee er = The rational-agent approach has two advantages over the other approaches 1 ‘As compared to other approaches this is the more general approach as, rationality can be achieved by selecting the correct inference from the several available. 2. Rationality has specific standards and is mathematically well defined and completely general and can be used to develop agent designs that achieve it. Human behavior, on the other hand, is very subjective and cannot be proved mathematically. — The two approaches namely, thinking humanly and thinking rationally are based on the reasoning expected from intelligent systems while; the other two acting humanly and acting rationally are based on the intelligent behaviour expected from them. =" In our syllabus we are going to study acting rationally approach 1.3 Categorization of Intelligent Systems As Al is a very broad concept, there aré different types or forms of Al. The critical categories of AI can be based on the capacity of intelligent program or what the program is able to do. Under this consideration there are three main categories: 1. Artificial Narrow Intelligence/ Weak Al = Weak AI is AI that specializes in one area. It is not a general purpose intelligence. An intelligent agent is built to solve a particular problem or to perform a specific task is termed as narrow intelligence or weak AI. — For example, it took years of AI development to be able to beat the chess grandmaster, and since then we have not been able to beat the machines at chess. But that is all it can do, which is does extremely well. 2. Artificial General Intelligence / Strong Al = Swong AI or general AI refers to intelligence demonstrated by machines in performing any intellectual task that human can perform. "Developing strong AI is much harder than developing weak AI. Using artificial general intelligence machines can demonstrate human abilities like reasoning, planning, problem solving, comprehending complex ideas, leatning from self experiences, etc. “L “Many companies, corporations’ aré working on developing ’a general intelligence but they are yet to complete it. i Introduction to Artifical inte Sc. IT - Ser’ | Super Intelligence intelli is an i 3. Artificial Super reading AI thinker Nick Bostrom, “Super intelligence is an intel iar name than the best human bres in practically every field including that is mucl scientific creativity, general wisdom and social skills. Super intelligence ranges from a machine which is just a little sinarter than a Puma to a machine that is trillion times smarter. Artificial super intelligence is the ultimate power of Al. 1.4 Components of Al Al is a vast field for research and it has got applications in almost all possible domains, By keeping this in mind, components of AI can be identified as follows : (Refer Fig. C1.1) Components of Al 1. Perception I 2. Knowledge representation| 3. Learning | 4. Reasoning 5. Problem Solving 6. Natural Language Processing (language- understanding) Fig. C11: Components of AI > 1... Perception > In order to work in the environi ‘ ment, intelligent agents need to scan the| environment and the various obj jects in it, Agent scans the environment using various sense organs like camera, temperature sensor, etc, This is called as perception, After the different objects in it and ext them. capturing various scenes, Perceiver analyses “ets their features and relationships amoné ix icial Intelligence (MU Sem-V) Introduction to Artificial Intelligence Knowledge representation - The information obtained from environment through sensors may not be in the bro format required by the system. - Hence, it need to be represented in standard formats for further processing like learning various patterns, deducing inference, comparing with past objects, etc. There are various knowledge representation techniques like Prepositional logic and first order logic. > 3. Learning = Learning is a very essential part of AI and it happens in various forms. The simplest form of learning is by trial and error. — In this form the program remembers the action that has given desired output and discards the other trial actions and learns by itself. It is also called as unsupervised learning. - In case of rote learning, the program simply remembers the problem solution pairs or individual items. — In other case, solution to few of the problems is given as input to the system, basis on which the system or program needs to generate solutions for new problems. This is known as supervised learning. > 4. Reasoning = _ Reasoning is also called as logic or generating inferences form the given set of facts. Reasoning is carried out based on strict rule of validity to perform a specified task. Reasoning can be of two types, deductive or inductive. — The deductive reasoning is in which the truth of the premises guarantees the truth ‘of the conclusion while, in case of inductive reasoning, the truth of the premises supports the conclusion, but it cannot be fully dependent on the premises. |= Am programming logic generally deductive inferences are used. Reasoning involves drawing inferences that are relevant to the given problem or situation. > 5. Problem-solving - Al addresses huge variety of problems. For example, finding out winning moves on the board games, planning actions in order to achieve the defined task, PRR ania Intelligence (MU B.Sc. IT- Sem-V)_1:8 Introduction to Artificial inte identifying various objects from given images, etc. As per the types of Probie there is variety of problem solving strategies in Al. ~ Problem solving methods are mainly divided into general purpose methods ls special purpose methods. General purpose methods are applicable t0 Wide raya of problems while, special purpose methods are customized to solve partioyg| type of problems. > 6. Natural Language Processing Natural Language Processing, involves machines or robots to understand and Process the language that human speak, and infer knowledge from the speech input, It also involves the active Participation from machine in the form of dialog ie, NLP aims at the text or verbal output from the machine or robot. The input and output of an NLP system can be speech and written text respectively, 1.4.1 Computational Intelligence Vs Artificial Intelligence Computational Intelligence (CI) Artificial Intelligence (Al) Computational Intelligence is the study of the Attificial Intelligence is study of making design of intelligent agents machines which can do things which at Presents human do better, io Cl involves numbers and computations, Al involves designs and symbolic knowledge representations, CI constructs the system starting from the bottom level computations, hence follows bottom-up approach. Al analys the overall structure of an intelligent system by follows ing top down approach. CI concentrates on low level cognitive Al concentrates of high level cognitive function implementation. structure design, g ‘Arificia! Intelligence (MU B.Sc. IT -Sem-V)__1-9 Introduction to Artificial inteligence ——————————————___ Syllabus Topic : History of Artificial Intelllgence 1.5 History of Artificial Intelligence ‘The term Artificial Intelligence (AI) v defined artificial intelli: introduced by John McCarthy, in 1955. He nce as “The science and engineering of making intelligent machines”. - Mathematician Alan Turing and others presented a study based on logic driven computational theories which showed that any computer program can work by simply shuffling “O” and “I” (i.e. electricity off and electricity on). Also, during that time period, research was going on in the areas like Automations, Neurology, Control theory, Information theory, etc. = This inspired a group of researchers to think about the possibility of creating an electronic brain. In the year 1956 a conference was conducted at the campus of Dartmouth College where the field of artificial intelligence research was founded. - This conference was attended by John McCarthy, Marvin Minsky, Allen Newell and Herbert Simon, etc., who are supposed to be the pioneers of artificial intelligence research for a very long time. During that time period, Artificial Intelligence systems were developed by these researchers and their students. © Let's see few examples of such artificial intelligent systems : - Game - Checkers : Computer played as an opponent, - Education - Algebra : For solving word problems, = Education - Math : Proving logical theorems, - Education - Language : Speaking English, etc. = During that time period these founders predicted that in few years machines can do any work that a man can do, but they failed to recognize the difficulties which can be faced. — Meanwhile we will see the ideas, viewpoints and techniques which Artificial Intelligence has inherited from other disciplines. They can be given as follows : a 1. Philosophy : Theories of reasoning and learning have emerged, along with the view port that the mind is constituted by the operation of a physical system. 2. Mathematical : Formal theories of logic, probability, decision making and computation have emerged. troduction to Artificial Intelligency PP atiicia Intelligence (MU B.Sc. IT - Sem-V) _1-10 int eine gris has emerged tools to investigate the human mind ang 3. Psychology : Psychology siteaien [ting a scientific language which are used to express the resultis aa 4, Linguistic : Theories of the structure and meaning of language have emerged. 5. Computer science : The tools which can make artificial intelligence a reality has emerged. Applications of Artificial Intelligence ‘You must have seen use of Artificial Intelligence in many SCI-FI movies. To name a few we have I Robot, Wall-E, The Matrix Trilogy, Star Wars, etc. movies. Many a times these movies show positive potential of using AI and sometimes also emphasize the dangers of using AI. Also there are games based on such movies, which show us many probable: applications of Al. Artificial Intelligence is commonly used for problem solving by analyzing or/and Predicting output for a system. AI can provide solutions for constraint satisfaction problems. It is used in wide range of fields for example in diagnosing diseases, in business, in education, in controlling a robots, in entertainment field, etc. Fig. C1.2 shows few fields in which we have applications of artificial intelligence. There can be many fields in which Artificially Intelligent Systems can be used. Business and Manutacturing } 6, Automated planning land scheduling 7, Voice Technology } 8. Heavy Industry Fig. Cl.2: Fields of AI ‘Application 5. a ai i icamieneit ¥ 1S - Training simulators can be built using artificial intelligence techniques, Software for pre-school children are developed to enable learning with fun games. ~ Automated grading, Interactive tutoring. instructional theory are the current areas of application. Entertainment ~ Many movies, games, robots arc designed to play as a character. ~ In games they can play as an opponent when human player is not available or not desirable. Medical — Al bas applications in the field of cardiology (CRG), Neurology (MRD), Embryology (Sonography), complex operations of intemal organs, etc. — It can be also used in organizing bed schedules, managing staff rotations, store and retrieve information of patient. — Many expert systems are enabled to predict the decease and can provide with medical prescriptions Military — Training simulators can be used in military applications, Also areas where human cannot reach of in life stacking conditions, robots can be very well used to do the required jobs = When decisions have to be made quickly taking into account an cnarmous amount of information, and when lives are at stake, artificial intelligence can provide crucial assistance = From developing intricate flight plans to implementing complex supply systems or creating training simulation exercises, Al is a natural partner in the modern miliary Business and Manufacturing Latest generation of robots are equipped well with the performance advances, growing integration of vision and an enlarging capability to transform manufacturing. > 17 “Various” sub domains! areas in intelligent systems Introduction to Arti 6. Automated planning and scheduling : ne © Intelligent planners ‘are available with AI systems, which can process large datasey and can consider all the constraints to design plans satisfying all of them. 7. “Voice Technology © ~ Voice recognition is improved a lot with AI. Systems are designed to take Voie inputs which are very much applicable in case of handicaps. ‘ — Also ‘scientists are developing an intelligent machine to emulate activities ofa Skillful. musician, Composition, performance, sound processing, music theory are some of the major areas of research. 8. Heavy Industry ~ Huge machines involve risk in operating and maintaining them. Human robot are better replacing human operators, These robots are safe and efficient. —. Robot are proven to be effective as compare to human in the jobs of repetitive nature, human may fail due to lack of continuous attention or laziness. Sub Areas/ Domains of Artificial Intelligence Intelligent Systems & 1. Natural language Processing 2. Robotics 3. Neural networks une hy Fig. C13: Sub-areas in Intelligent Systems AI Applications can be roughly classified based on the type of tools/approaches used for inoculating intelligence in the system, forming sub areas of AI. can be given as follows; Natural Language Processing, Robotics, Neural Networks and Fuzzy Logic. Fig. C1.3 ‘shows these’ areas in Intelligent Systems. 1. Natural language processing : ~ One of the application of AI is in fi eld of Natural‘ Language Processing (NLP): _NLP enables interaction between co puters and human (natural) language. 7 Practical applications. of NLP are in. machine translation (¢.g, Lunar System), information retrieval, text Categorization, etc. - Few more applications are extracting 3D information using. vision, speech recognition, perception, image formation. > 2, Robotics: i -. .Zyy, ORE More major application of Al is in Robotics. Robot is an active agent whose ie environment is the physical world, ~ Robots can be used in manufacturing and handling material, in medical field, in military etc. for autornallng the manual work. > 3. Neural networks: | (= Another application of Al is using Neural Networks. Neural Network is a system us that works like a human brain/nervous system. — “Tt can be useful for stock market analysis, in’ character recognition, in image compression, in security, face recognition, handwriting recognition, Optical Character Recognition (OCR), etc. > 4. “Fuzzy logic: = Apart from these AI systems are developed with the help of Fuzzy Logic. ~ Furzy Logic can be useful in making approximations rather than having a fixed and exact reasoning for a problem. - You must have seen systems like AC, fridge, washing machines which are based on fuzzy logic (they call it “6" sense technology!”), Syllabus Topic : The State of Art A | Today 1.8 The State of Art Artificial Intelligence Today =>. Artificial Intelligence has touched each and every aspect’ of -our life. From washing machine, Air conditioners, to smart phones everywhere Al is serving to ease our life. In industry, AI is doing marvellous work as well. - Robots are doing the sound work in factories. Driverless cars have become a reality. WiFi-enabled Barbie uses speech-recognition to talk and listen to children. — Companies are using AI to improve their product and increase sales, AI saw significant _ advances in machine learning. Following are the areas in which AI is showing significant advancements. Artificial intelli (MU B.Sc. IT - Sem-V) Introduction to Ar . Deep Learning Convolutional Neural Networks enabling the concept of deep learning is the top mog area of focus in Artificial intelligence in todays’ era. Many problems and applications areas of Al like, natural language and tex Processing, speech recognition, computer vision, information retrieval, and multimodal information processing empowered by multi-task deep learning. 2. Machine Learning The goal of machine leaming is to program computers to use example data or pas experience to solve a given problem. Many successful applications of machine leamning include systems that analyse pas sales data to predict customer behaviour, optimize robot behav’ ‘our so that a task cag be completed using minimum resources, and extract knowledge from bioinformatics data 3. Al Replacing Workers 4, Internet of Things (loT) 5. Ei = ' Computers’ ability to understand speech will lead to an almost In industry where there are safety hazards, robots are doing @ good job. Human Fesources are getting replaced by robots rapidly. People are worries to sce that the white color jobs of data Processing are being d exceedingly well by intelligent programs. ing done A study from The National Academy of Sciences brought together techn 01 economists and socal scientists to figure ou whats going to happen ogists and ‘The concepts of smarter homes, smarter cars and smarter world jg evolvi ; vi : with the invention of internet of things. ing Tapidly ‘The future is no far when cach and every object will be Wirelessly something in order to perform soma smart actions without any human in “rected to interference, ‘Stions or ‘The worry is how the mined data can potentially be exploited, i motional Al Emotional Al, where Al can detect human emotions, is anothe, ines, important area of research. Ming and Monet between human and computer. TACtio, in [ET anticia! intetigence (MU B.Sc. IT-Sem-V)_1-15 Introduction to Artificial Intelligence Se eS = With increasingly accurate cameras, voice and facial recognition, computers are better able to detect our emotional state. _ Researchers are exploring how this new knowledge can be used in education, to treat depression, to accurately predict medical diagnoses, and to improve customer service and shopping online. 6. Allin shopping and customer service ~ Using AI, customers’ buying patterns, behavioral patterns can be studied and systems that can predict the purchase or can help customer to figure out the perfect item. - Al cab be used to find out what will make the customer happy or unhappy. - For example, if a customer is shopping online, like a dress pattern but needs dark shades and thick material, computer understand the need and brings out new set of perfectly matching clothing for him. 7. Ethical Al - With all the evolution happening in technology in every walk of life, ethics must be considered at the forefront of research. For example, in case of driverless car, while driving, if the decision has to be made between weather to dash a cat or a lady having both in an uncontrollable distance in front of the car, is an ethical decision. - In such cases how the programming should decide who is more valuable, is a question. - These are not the problems to be solved by computer engineers or research scientists but someone has to come up with an answer. Syllabus Topic : Agents and Environment 1.9 Intelligent Agents 1.9.1. What is an Agent ? a Define in your own words, the following terms : 4... Agent 2. Agent function 3. Agent program 4, Autonomy What is an Agent 2.” BPP acces Intelligence (MU B.Sc. IT-Sem-V) 1-16 Introduction to Artificial Intell ey ~» Agent is something that perceives its environment through sensors and acts upon environment through effectors or actuators. Fig. 1.9.1 shows agent and environment, Take a simple example of a human agent. It has five senses : Eyes, cars, nose, shy tongue. These senses sense the environment are called as sensors. Sensors Colle Percepts or inputs from environment and passes it to the processing unit. Actuators or effectors are the organs or tools using which the agent acts upon the environment. Once the sensor senses the environment, it gives this information to nervowy system which takes appropriate action with the help of actuators. In case of human agents we have hands, legs as actuators or effectors. Agent Aotion is the the environment Fig. 1.9.1 : Agent and Environment ~) Fig. 1.9.2 shows generic robotic agent structure. Perception Fig. 1.9.2: Generic Robotic Agent Architecture [EP aniicia intotigance (MU B.Sc. IT - Se 1-17, Introduction to Arificial Intelligence After understanding what an agent is, let’s try to figure out sensor and actuator for a robotic agent, can you think of sensors and actuators in case of a robotic agent? ‘The robotic agent has cameras, infrared range finders, scanners, etc. used as sensors, while various types of motors, screen, printing devices, etc. used as actuators to perform action on given input. (708, 088, and other organs for sensors; qf Human hands, legs, mouth, and other. body patts for actuators ‘eamoras and infrared | range finders for sensors; _ various motors for actuators Fig. 1.9.3 : Sensors and Actuators in Human and Robotic Agent ‘The agent function is the description of what all functionalities the agent is supposed to do. The agent function provides mapping between percept sequences to the desired actions. It can be represented as [f : P* => A] Agent program is a computer program that implements agent function in an architecture suitable language. Agent programs needs to be installed on a device in order to run the device accordingly. That device must have some form of sensors to sense the environment and actuators to act upon it. Hence agent is a combination of the architecture hardware and program software. Agent = Architecture + Program Take a simple example of vacuum cleaner agent. You might have seen vacuum cleaner agent in “WALL-E"(animated movie), Let’s understand how to represent the percept's (input) and actions (outputs) used in case of a vacuum cleaner agent, A B BS | BS Fig. 1.9.4: Vacuum cleaner Agent g Artificial inteligance ( T= SomV) 1-10 Introduction to Artiticlal Lntoligonce r Artificial inteltigance (MU B.Sc, I i As shown in Fig. 1.9.4, there are two blocks A and B having some dirt. Vacuum cleaner | = Asshow » LO, agent supposed to sense the dirt and collect it, thereby making the room clean. In order (9 do that the agent must have a camera to see the dirt and a mechanism to Move forward, backward, left and right to reach to the dirt, Also it should absorb the Based on the percepts, actions will be performed. For example : Move lett, Move Fight, absorb, No 4 Operation, ~ Hence the sensor for vacuum cleaner Agent can be camera, dirt sensor and the actuator can be motor to make it move, absorption mechanism. And it can be represented as {A, Dirty), [B, Clean}, [A, absorb},[B, Nop], ete. 1.9.2 Definitions of Agent There are various definitions exist for an Agent. Let's see few of them. ~ IBM states that agents are software entiti of a user or another program, ~ FIPA : Foundation for Intelligent Physical Agents (FIPA) terms that, an agent is a computational process that implements the autonomous functionality of an ~ Another definition is given as “An agent is nything that ean be viewed as perceiving its environment through sensors and acting upon the envi s that carry out some set of operations on behalf application. ironment through effectors”, ‘Agent will perform all tho tasks on, your behalf Washing clothes Cleaning vio Fig. 19.5: Interactive Intelligent Agent By Russell and Norvig, F. Mills and R. Sty mat (PP anincia! inotigence (MU B. Introduction to Artticial Intelligence - From above definitions we can understand that an agent is : (As per Terziyan, 1993) © Goal-oriented © Creative © Adaptive © Mobile © Social © Self-configurable 1.9.3 Intelligent Agent = Whats intelligent agent 2 Inthe human agent example, we read that there is something called as which helps in deciding an action with the as given by sensors. In robotic agent, we have software's which demonstrates the functionality of nervous system. “Nervous System” sistance of effectors, based on the input Intelligent agent is the one which can take in sensors and act upon the environment throu, put from the environment through its igh its actuators. Its actions are always directed to achieve a goal, The basic abilities of an intelligent agent are to exist to be self-governed, responsive, goal-oriented, etc, In case of intelligent agents, the software modules are res; ponsible for exhibiting intelligence. Generally observed capabilities of an intelligent agent can be given as follows : Ability to remain autonomous (Self- 1. Reactiveness - It means giving reaction to a situation in a stipulated time frame. An agent can perceive the environment and respond to the situation in a particular time frame. = Incase of reactiveness, reaction within situation time frame is more important. ‘You can understand this with above example, where, if an agent takes more time to take his hand away from the hot pan then agents hand will be burnt. > 2. Pro-activeness : — It is controlling a situation rather than just responding to it. Intelligent agent show goal-directed behavior by taking the initiative. — For example : If you are playing chess then winning the game is the main objective. So here we try to control a situation rather than just responding to one- ‘one action which means that killing or losing any of the 16 pieces is not important, whether that action can be helpful to checkmate your opponent is more important. > 3. Social ability : ~ Intelligent agents can interact with other agents (also humans). Take automatic car driver example, where agent might have to interact with other agent or a human being while driving the car. Features of Intelligent ‘agent [zn Fig, C1,5 : Features of an Intelligent Agent Following are few more features of an intelligent agent : 31. Self-Learning : An intelligent agent changes its behaviour based on its previous experience. This agent keeps updating its knowledge base all the time. Introduction to Artificial Intelligency Pr aniciat Intelligance (MU > 2. Movable/Mobile : ; / An Intelligent agent can move from one machine to another while performing actions. > 3. Self-governing : An Intelligent agent has control over its own actions. Syllabus Toplc : Good Behaviour 1.10 Rational Agent 'Q. ~ What is Rational Agent ? E Define rationality and rational agent. Give an example of rational action performed 3 _ any intelligent agent. @ Good Behaviour For problem solving, if an agent makes a decision based on some logical reasoning, then, the decision is called as a “Rational Decision” or “good behaviour”. The way humans have ability to make right decisions, based on his/her experience and logical reasoning; an agent should also be able to make correct decisions, based on what it knows from the percept sequence and actions which are carried out by that agent from its knowledge. Agents perceive their environment through sensors over a prolonged time period and adapt to change to create and pursue goals and take actions through actuators to achieve those goals. A rational agent is the one that does “right” things and acts rationally so as to achieve the best outcome even when there is uncertainty in knowledge. A rational agent is an agent that has clear preferences, can model uncertainty via expected values of variables or functions of variables, and always chooses to perform the action with the optimal expected outcome for itself from among all feasible actions. A rational agent can be anything that makes decisions, typically a person, a machine, of software program. * *: Rationality depends on four main criteria: First is the performance measure which | defines the criterion of success for an agent, second is the agent's prior knowledge of the environment, and third is the action performed by the agent and the last one is agent's percept sequence to date. ig Performance measure is one of the major criteria fo . measurin, al performance. Take a vacuum-cleaner agent's example, Success of an agents a j Introduction to Artificial Intelligence een tcl intelligence The performance measure of a vacuum-cleaner agent can depend upon various factors like it's dirt cleaning ability, time taken to clean that dirt, consumption of electricity, etc, For every percept sequence a built-in knowledge base is updated, which is very useful for decision making, because it stores the consequences of performing some particular action. If the consequences direct to achieve desired goal then we get a good performance measure factor, else, if the consequences do not Iead to desired goal state, then we get a poor performance measure factor. (a) Agent's finger is hurt while using Nail and (b) Agent is using Nail and hammer hammer efficiently Fig. 1.10.1 For example, see Fig. 1.10.1. If agent hurts his finger while using nail and hammer, then, while using it for the next time agent will be more careful and the probability of not getting hurt will increase. In short agent will be able to use the hammer and nail more efficiently. > Altamate possible actions ted Selected actions which leads to Agent ‘optimal expected results Fig. 1.10.2 : Rational Agent Rational agent can be defined as an agent who makes use of its percept sequence, experience and knowledge to maximize the performance measure of an agent for every c a BFF asticiat Intelligence (MU B.Sc. IT-Sem-V)_1-24 Introduction to Artificial Inteligency Probable action. It selects the most feasible action which will lead to the ex, optimally. Syllabus Topic : Nature of Environment Ay Pected results 1__Nature of Environment and PEAS Properties of Agent 1.11.1 Nature of Environment What are various agent environments ? Deseribe different types of environments applicable to Al agents. a Environments Types 1. Fully observable vs. Partially observable 2. Single agent vs. Multi-agent 8, Deterministic vs, Stochastic 4. Episodic vs. Sequential 5. Static vs. Dynamic 6. Discrete vs. Continuous Fig: CL.6 : Environments types Fully observable vs, Partially observable ' The first type of environment is based on the observability, Whether the agent sensors can have access to complete state of environment at any given time or not, decides if it is a | fally observable or partially observable environment, : In Fully observable environments required to take actions. Also in to keep records of internal states, Agents are able to For example, Word-block problem, 8-puzzle problem, Problem worlds, the state is complete] Sudoku puzzle, etc, in all thes? ly Visible at any poi Puzzle, ete, in al int Of time, Introduction to Artificial Intelligence ‘Artificial Int (MU B. Environments are called partially observable when sensors cannot provide errorless ° information at any given time for every internal state, as the environment is not seen completely at any point of time. © Also there can be unobservable environments where the agent sensors fail to provide information about internal states. © For example, In case of an automated car driver system, automated car cannot predict what the other drivers are thinking while driving cars. Only because of the sensor's information gathering expertise it is possible for an automated car driver to take the actions. 2. Single agent vs. Multi-agent = The second type of an environment is based on the number of agents acting in the environment. Whether the agent is operating on its own or in collaboration with other agents decides if it is a Single agent or a multi-agent environment. ~ For example : An agent playing Tetris by itself can be a single agent environment, whereas we can have an agent playing checkers in a two-agent environment. Or in case of vacuum cleaner world, only one machine is working, so it’s a single agent while in case of car driving agent, there are multiple agents driving on the road, hence it’s a multi- agent environment. Multi-agent environment is further classified as Co-operative multi-agent and Competitive multi-agent. Now, you might be thinking in case of an automated car driver system which type of agent environment do we have? Let's understand it with the help of an automated car driving example. For a car driving system 'X’, other car say "Y' is considered as an Agent. When 'Y' tries to maximize its performance measure and the input taken by car ‘Y' depends on the car 'X', Thus it can be said that for an automated car driving system we have a cooperative multi-agent environment. Whereas in case of “chess game” when two agents are operating as opponents, and trying to maximize their own performance, they are acting in competitive multi agent environment. 3. Deterministic vs. Stochastic ‘An environment is called deterministic environment, when the next state of the environment can be completely determined by the previous state and the action executed sel by the agent. fib a Introduction to Artificial intelligene, ‘Artificial Intelligence (MU. ase of vacuum éleaner world, 8-puzzle problem, chess game the ney the action performed jy| "For example, in ¢: state of the environment solely depends on the current state and. agent. Stochastic environment generally mean: enumerated in terms of probabilities. That means environment changes while agent i taking action, hence the next state of the world does not merely depends on the curey state and agent’s action. And there are few changes happening in the environmen irrespective of the agent’s action. An automated car driving system has a stochastic environment as the agent cannot control the traffic conditions on the road. s that the indecision about the actions i, Incase of checkers we have a multi-agent environment where an agent might be unable to predict the action of the other player. In such cases if we have partially observable environment then the environment is considered to be stochastic. - If the environment is deterministic except for the actions of other agents, then the environment is strategic. That is, in case of game like chess, the next state of environment does not only depend upon the current action of agent but it is also influenced by the strategy developed by both the opponents for future moves. i =) We have one more type of environment in this category. That is when the environmen! types are not fully observable or non-deterministic; such type of environment is called a uncertain environment. 4. Episodic vs. Sequential - An episodic task environment is the one where each of the agent's action is divided into an atomic incidents or episodes. - The current incident is different than the previous incident and there is no dependency ‘between the current and the previous incident. In each incident the agent receives an input from environment and then performs a corresponding action, ~ Generally, classification tasks are considered a8 episodic. Consider an example of pith and place robot agent, which is used to detect defective parts from the‘conveyor belt of a2 assembly line. Here, every time agent will make the decision based on current part, there will not be any dependency between the current and previous decision, - In sequential environments, as per the name suggests, the Previous décision can affect all future decisions. The next,action of the agent depends on what action he has take? previously and what action he is supposed to take in future, — For example, in checkers where previous move can affect all the following moves. Als. sequential environment can be understood with the help of an automate car civil pe ficial Intelligence (MU IT - Som-V)_1-27 Introduction to Artificial Inteligence example where, current decision can affect the next decisions. If agent is initiating breaks, then he has to press clutch and lower down the gear as next consequent actions. 5. Static vs. Dynamic — You have learnt about static and dynamic terms in previous semesters with respect to web pages. Same way we have static (vs. dynamic) environments. - If an environment remains unchanged while the agent is performing given tasks then it is called as a static environment. For example, Sudoku puzzle or vacuum cleaner environment are static in nature. = Ifenvironment is not changing over the time but, an agent's performance is changing then, it is called as a semi-dynamic environment. That means, there is a timer exist in the environment who is affecting the performance of the agent. — For example, In chess game or any puzzle like block word problem or 8-puzzle if we introduce timer, and if agent’s performance is calculated by time taken to play the move or to solve the puzzle, then it is called as semi-dynamic environment. — Lastly, if the environment changes while an agent is performing some task, then it is called dynamic environment. In this type of environment agent's sensors have to continuously keep sending signals to agent about the current state of the environment so that appropriate action can be taken with immediate effect. Automatic car driver example comes under dynamic environment as the environment keeps changing all the time. 6. Discrete vs. Continuous — You have seen discrete and continuous signals in old semesters. When you have distinct, quantized, clearly defined values of a signal it is considered as disrete signal = Same way, when there are distinct and clearly defined inputs and outputs or precepts and actions, then itis called a discrete environment. For example : chess environment has a finite number of distinct inputs and actions. s input signal is received by an agent, all the precepts and actions - When a continuou: For example : cannot be defined beforehand then it is called continuous environment. ‘An automatic car driving system.. Introduction to Artificial Intellig ence (MU B.Sc. IT - Sem-V) _1-28 _ “Known vs. Unknown "na known environment, the output forall probable actions is given. Obviously, in ay, | of unknown environment, for an agent to make a decision, it has to gain knowledge about - how the environment works. Table 1.11.1 summarizes few task environment and their characteristics. Table 1.11.1 : Task Environments = Car Part- Cross word | Soccer game driving, Picking puzzle 5 «Robot Observable | Partially Partially fully partially Agents Multi agent | Single agent | single Multi agent | Multi agent (cooperative) (competitive) | (competitive) | Strategic Deterministic | Stochastic Stochastic deterministic | Strategic Episodic Sequential | Episodic | sequential __| sequential _—_| Sequential Static Dynamic Dynamic static Dynamic Semi Discrete | Continuous _| Discrete Discrete Continuous Discrete Known and | Unknown Known Known Known Known Unknown —_t_ 1.11.2 PEAS Properties of Agent Q. ~ Explain PEAS representation with example. @. Give PEAS description for a robot soccer player. Characterize ite environment. :@,__ What are PEAS descriptor ? Give PEAS descriptors for Part _- picking Robot, Py - PEAS : PEAS stands for Performance Measure, Environment, Actuators, at Sensors. It is the short form used for performance issues grouped under Tas! Environment. — . You might have seen driverless/ self driving car videos of Audi/ Volvo/ Mercedes, ete. develop such driverless cars we need to first define PEAS parameter, ; 8. — Performance Measure : It the objective function to Judge the performance of the ag For example, in case of pick and place robot, number of correct parts in a bin can be performance measure. ‘Artificial Inteligence (MU B. IT- Sem-V) Introduction to Artiicial intelligence Environment : It the real environment where the agent need to deliberate actions. Actuators : These are the tools, equipment or organs using which agent performs actions in the environment. This works as the output of the agent. Sensors : These are the tools, equipment or organs using which agent captures the state of the environment. This works as the input to the agent. To understand the concept of PEAS, consider following examples. (A) Automated Car driving agent 1. Performance measures which should be satisfied by the automated car driver : (i) Safety : Automated system should be able to drive the car safely without dashing anywhere. (ii) Optimum speed : Automated system should be able to maintain the optimal speed depending upon the surroundings. (iii) Comfortable journey : Automated system should be able to give a comfortable journey to the end user, i. depending upon the road it should ensure the comfort of the end user. (iy) Maximize profits : Automated system should provide good mileage on various roads, the amount of energy consumed to automate the system should not be very high, etc. such features ensure that the user is benefited with the automated features of the system and it can be useful for maximizing the profits. 2. Environment (Roads : Automated car driver should be able to drive on any kind of a road ranging from city roads to highway. (ii) Traffic conditions : You will find different set of traffic conditions for different type of roads. Automated system should be able to drive efficiently in all types of traffic conditions. Sometimes traffic conditions are formed because of pedestrians, animals, etc, (iii) Clients : Automated cars are created depending on the client's environment. For example, in some countries you will see left hand drive and in some countries there is fa right hand drive. Every country/state can have different weather conditions. Depending upon such constraints automated car driver should be designed. 3. Actuators are responsible for performing actions/providing output to an environment. Incase of car driving agent following are the actuators : (@) Steering wheel which can be used to direct car in desired direction (i.e. right/left) Introduction to Artificial int ligence (MU B.Se. IT - Sem-V) d i) Aaccelerator, gear, etc. can be useful to increase or decrease the speed of the cal @ Bear, etc. (iii) Brake is used to stop the car. ‘ be (iv) Light signal, horn can be very useful as indicators for an automated car. ‘ é i in car driving example cameras, sonar sys 4. Sensors : To take input from environment in car driving. speedometer, GPS, engine sensors, etc. are used as sensors. (8) Part-picking ARM robot 1. Performance measures ; Number of parts in correct container. 2. Environment : Conveyor belt used for handling parts, containers used to keep Part, and Parts. Actuators : Arm with tooltips, to pick and drop parts from one place to another, Sensors : Camera to scan the position from where angle sensors which are used to sense the obs! {C) Medical diagnosis system part should be picked and join tacles and move in appropriate place. 1. Performance Measures Healthy patient : system should make use of sterilized instruments to ensure the safety (healthiness) of the patient, Minimize costs : the automated system resul Its should not be very f 4 overall expenses of the patent may increase, Lawsuits Medical we hen should be legal. iagnosis system 2, Environment : Patient, Doctors, Hospital Environment 3. Sensors : Screen, printer 4. Actuators : Keyboard and mouse which is usefuy to findings, patient's answers to given questions. S click pictures of patients, (D) Soccer Player Robot canner to so My of symptoms, on the reports camera to 1. Performance Measures : Number of goals, speed, le, Bal ame, 2. Environment : Team players, opponent team players, » Playing Stoung 3. Sensors : Camera, proximity sensors, infrared sehsors, * 8al net, 4. Actuators : Joint angles, motors. 1-31 Introduction to Artificial Intelligence Depending upon the degree of intelligence and ability to achieve the goal, agents are categorized into five basic types. These five types of agents are depicted in the Fig. C1.7. ‘Types of Agents 1. Simple Reflex Agents 2, Model-based Reflex Agents 3. Goal-based Agents 4, Uiilty-Based Agents ] 5. Learning Agents Fig. C1.7 : Types of agents Let us understand these agent types one by one. 1.12.1 Simple Reflex Agents cs Explain simple reflex agent architecture. Simple Reflex Agent ‘What fs the current ;state.of the envionment Fig. 1.12.1 : Simple reflex agents “artificial Intelligence (MU B.Sc. I - tis * true, then matching action - You approaches eye then, natural/innate reflex. deci tabulated in Table 1.12.1. - Few possible input sequences ar ‘An agent which performs actions previous inputs is called as simp a totally uncomplicated type of agent. the situation and its corresponding action «considering the percept history a real life example, say some objeq je reflex agent. is taken without can understand simple reflexes with the help of you will blink your eye. Thi Consider the example of the vacuum cleaner agent. It is a simple reflex agent, as it sion is based only on whether the current location contains dirt. The agent function based on the current input © ‘The simple reflex agent's function is based q (condition-action protocol). If the condition jg nd outputs for vacuum cleaner world with 2 locations ar s type of simple reflex is’ called considered for simplicity. Table 1.12.1 Input sequence Output / actic {location, content } Right, left, suck, no-op ah” x (A, clean) Right a {8 {B, clean} j=) (A, dirt Introduction to Artificial Intelligence ©. Input sequence Output / action {location, content } Right, left, suck, no-op (B, dirt) Suck Input sequence Output / action {location, content } Right, left, suck, no-op A F {A, clean} {A, clean) Right A 6 {A, clean} {A, dirt} Suck A B |__| — Incase of above mentioned vacuum agent only one sensor is used and that is a dirt sensor. This dirt sensor can detect if there is dirt or not. So the possible inputs are ‘dirt’ and ‘clean’. = Also the agent will have to maintain a database of actions, which will help to decide what output should be given by an agent. ~ Database will contain conditions like : If there is dirt on the floor to left or right then find out if there is dirt in the next location and repeat these actions till the entire assigned area is cleaned then, vacuum cleaner should suck that dirt. Else, dirt should move. Once the assigned area is fully covered, no other action should be taken until further instruction. an area, then, it will surely acum cleaner agent keeps searching for dirt and cle: trapped in an infinite 1op- — infinite loops are unavoidable for simple reflex agents operating in partially observable By randomizing its actions the simple reflex agent can avoid these ‘infinit| on receiving {clean} as input, the vacuum cleaner agent should eit environments. loops. For example, | go to left or right direction. If the performance of an age! considered as rational in few multi-agent environments. 4.12.2 Model-based Reflex Agents nt is of the right kind then randomized behaviour can te Explain structure of an agent which ‘keeps track of the Partially observable environment cannot be handled well by simple reflex agents bec: it does not keep track on the previous state. So, one more type of agent was created that i model based reflex agent. model-based agent. - From Fig. 1.12.2 it can be seen that once the sensor takes input from the environmed state which shows how the world is developing and how the environment is affected b the action which was taken by the agent at earlier stage. This is termed as model of Introduction to Artificial Intelligence ‘Artificial Intelligence (MU B. IT - Sem-V) =. Once this is verified, based on the condition-action protocol an action is decided. This decision is given to effectors and the effectors give this output to the environment. — The knowledge about “how the world is changing” is called as a model of the world. Agent which uses such model while working is called as the “model-based agent”. - Consider a simple example of automated car driver system. Here, the world keeps changing all the time. You must have taken a wrong tum while driving on some or the ' other day of your life. Same thing applies for an agent. Suppose if some car “X” is overtaking our automated driver agent “A”, then speed and direction in which “X” and “A” are moving their steering wheels is important. Take a scenario where agent missed a | sign board as it was overtaking other car. The world around that agent will be different in that case. | = Internal model based on the input history should be maintained by model-based reflex 4 agent, which can reflect at least some of the unobserved aspects of the current state. Once this is done it chooses an action in the same way as the simple reflex agent. } 1.12. Goal-based Agents How the world sdevelonment ?_ [What will be the state it | some action A's performed ? “What action should be taken next ? output / action Effectors Goal-based Agents Fig, 1.12.3: Goal-based agents — “Model-based agents are further developed based on the “goal” information. This new type of agent is called as goal-based agent. As the name suggests, Goal information will illustrate the situations that is desired. These agents are provided with goals along with the differentiate between goal states’ ang Goal based agents. can only % or zero. non-goal states. Hence, their performance can be 100 ‘The Limitation of goal based agent comes with its definition itself. Once the goal is fixed, | all the actions are taken to fulfil it. And the agent loses flexibility to change its actions according to the current situation. oal is to Keep the house You can take example of a vacuum cleaning robot agent whose g clean all the time. This agent will keep searching for dirt in house and will keep the house clean all the time. Remember M-O the cleaning robot from Wall-E movie which keeps cleaning all the time no matter what is the environment or the Healthcare companion robot Baymax from Big Hero 6 which does not deactivate until user says that he/she is satisfied with care. 1.12.4 Utillty-Based Agents -Q. Explain utility based agents with the help of neat diagram. inpupercept output / 4 £ i BS Artificial MI T : tr B.Sc. IT-Sem-V) 1-37 Introduction to Artificial Intelligence ~ Utility function is used to map a state to a measure of utility of that state. We can define a esis, for determining how advantageous a particular state is for an agent. To obtain this measure utility function can be used, ~The term utility is used to depict how “happy” the agent is to find out a generalized Performance measure, various world states according to exactly how happy they would make an agent is compared. ~ Take one example; you might have used Google maps to find out a route which can take you from source location to your destination location in least possible time. Same logic is followed by utility based automatic car driving agent. Goals utility based automatic car driving agent can be used to reach given location safely within least possible time and save fuel. So this car driving agent will check the possible Toutes and the traffic conditions on these routes and will select the route which can take the car at destination in least possible time safely and without consuming much fuel. 1.12.5 Learning Agents Q) Explain the teaming agent with the help of suitable diagram. Q. Explain the structure of learning agent architecture. What is role of critic in leaming 2 QQ. What are the basic building blocks of leaming agent ? Explain each of them with a neat block diagram. Performance standard input/percept ‘Sensors. Performance, element, output / action Leaming element [| g 5 3 goals ) Problem generator Effectors Learning Agents Fig. 1.12.5 : Learning agents .s marks for some question, you come to “Why do you give mock tests ? When you get les eee iad sou ur answer. Then you learn the correct that you have made some mistake in yot = Following are the comp’ concept is followed ~ Learning based age can initially operate in an environment based on few xther examinations, You Write the stion in fu ‘ade in the mock test. This say at same que’ i you get th mistakes which were ™ avoid the by the learning agent. nt is advantageous in many cases, because with its basic knowledge unknown environment and then it can gain knowledge from ty parameters and perform actions to give better results. onents of Jearning agent = “The components of learning agent 1. Critic ] 2, Learning element 3. Performance element 4, Problem generator iM Fig: C18 : Components of Learning Agent Critic : ing effect of agent’s action on ti ¢ who compares sensor's input specify’ d generate feedback for leant It is the one environment with the performance standards an element. Learning element : ‘This component is responsible to learn from the difference between perform standards and the feedback from critic. According to the current percept supposed to understand the expected behavior and enhance its standards. Performance element : bent on the current percept received from sensors and the input obtained wy learning element, performance element is responsible to choose the action 1% upon the external environment. Problem generator : . ‘Based on the new goals learnt b i ests. s Based on y learning agent, problem gene 25 lternate actions which will lead to new and Ease cee a a rstanding.

You might also like