人工智能英文版课件:02 Intelligent Agents_第1页
人工智能英文版课件:02 Intelligent Agents_第2页
人工智能英文版课件:02 Intelligent Agents_第3页
人工智能英文版课件:02 Intelligent Agents_第4页
人工智能英文版课件:02 Intelligent Agents_第5页
已阅读5页,还剩98页未读 继续免费阅读

下载本文档

版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领

文档简介

1、Chapter 2 Intelligent Agents2OutlineAgents and EnvironmentsGood Behavior: The Concept of RationalityThe Nature of EnvironmentsThe Structure of Agents3Agents and EnvironmentsAgentPerceiving its environment through sensorsActing upon that environment through actuatorsHuman agentSensors: eyes, Ears and

2、 other organsActuators: hands, legs, mouths, etc.4Agentsensors?ActuatorsEnvironmentPerceptsActionsInteraction between agent and environment through sensors and actuators.5Agents and EnvironmentsRobotic AgentSensors: cameras, infrared range finderActuators: various motorsSoftware agentSensors: receiv

3、ing keystrokes, file contents, network packetsActuators: display on screen, sending network packets, writing filesCalculator as agentSensors: Inputs from keyboard, e.g. “2+2 =”Actuators: Display, e.g. “4”6Agents and EnvironmentsPerceptAgents perceptual inputs at any given instantPercept SequenceThe

4、complete history of everything the agent has ever perceivedAn Agents choice of action at any given instant can depend on the entire percept sequence observed to date7Agents and EnvironmentsAgent FunctionDescribe behaviors of an agentMaps any given percept sequence to an actionTabulating an agent fun

5、ctionUsually a very large tableInfiniteTry out ALL possible percept sequence and record which actions the agent does in responseIf the action is in probability of occurrence, we need to try many times for each percept sequence8Agents and EnvironmentsAgent function tableOnly record the external chara

6、cterization of the agentAbstract mathematical descriptionAgent ProgramInternally, the agent function of an intelligent agent is implemented by an agent programConcrete implementation and running on the agent architecture9Agents and EnvironmentsExample: Vacuum-cleaner worldVery simple, we could descr

7、ibe everything that happensOnly has two locations: Squares A and B10Agents and EnvironmentsThe vacuum agent perceivesWhich square it is inWhether it is clean or dirtyThe vacuum agent actionsMove leftMove rightSuck up the dirtDo nothing11Agents and EnvironmentsAn example of the agent function for our

8、 vacuum agent:Percept sequenceActionA,CleanRightA, DirtySuckB, CleanLeftB, DirtySuckA, Clean,A, CleanRightA, Clean,A, DirtySuckA,Clean,A,Clean,A,CleanA,Clean,A,Clean,A,DirtyRightSuck12Agents and EnvironmentsIs it the right way to fill in the agent function like this? If not, how?Percept sequenceActi

9、onA,CleanRightA, DirtySuckB, CleanLeftB, DirtySuckA, Clean,A, CleanRightA, Clean,A, DirtySuck13Agents and EnvironmentsWhat makes an agent good or bad?What makes an agent intelligent or stupid?14Good Behavior: The Concept of RationalityRational AgentThe one does the right thingEvery entry of the agen

10、t function is filled out correctlyIs it better to do the right thing instead of doing the wrong thing?What does it mean to do the right thing?Is eating a chicken leg in canteen a right thing?Is eating a chicken leg in classroom a right thing?15Good Behavior: The Concept of RationalityRight thing The

11、 action that will cause the agent to be most successfulHow to measure the successfulness of the agent?A complete specification of the task facing by the agentThe description of the environmentThe sensors and actuators of the agentThe performance measure16Good Behavior: The Concept of RationalityPerf

12、ormance Measures The criterion for success of an agents behaviorWhen the agent is placed in an environmentIt generates a sequence of actions according to the percepts 感知信息 it receives.This sequence of actions causes the environment to go through a sequence of statesIf the sequence is desirable, the

13、agent performed wellThere is not a fixed measure that suitable for all agents17Good Behavior: The Concept of RationalityWe could ask the agent for a subjective opinion of how happy it is with its own performanceSome agents may not be able to answerSome may delude themselves 迷惑Human agents in particu

14、lar is notorious for “sour grapes”We will insist on an objective performance measure客观性能度量Usually imposed by the designer of the agent18Good Behavior: The Concept of RationalityExample: vacuum cleaner agentThe amount of dirt cleaned up in a single eight-hour shiftA rational agent can maximize its pe

15、rformance measure by Cleaning up the dirtDumping it all on the floorCleaning it up againrepeat and repeatIt maximize the number of dirt being cleaned. But, is it what you want?19Good Behavior: The Concept of RationalityAn alternative performance measureReward one point for each clean square at each

16、time step (e.g. every eight hours)It is better to design the performance measure according to what one actually wants in the environmentRather than according to how one thinks the agent should behave20Good Behavior: The Concept of RationalityThe “clean floor” is based on average cleanliness over tim

17、eTwo agents earn the same pointsAn agent does a mediocre job all the timeAn agent cleans energetically but takes a long breakWhich one is more preferable?A philosophical question: a reckless life of highs and lows,起伏不定的不计后果的生活 or a safe but boring existence21Good Behavior: The Concept of Rationality

18、Rationality depends onThe performance measure that defines the criterion of successesThe agents prior knowledge of the environment智能体对环境的先验认识The actions that the agent can performThe agents percept sequence to date智能体到那时为止的感知序列22Good Behavior: The Concept of RationalityDefinition of a Rational Agent

19、For each possible percept sequence, a rational agent should select an action that is expected to maximize its performance measure, given the evidence provided by the percept sequence and whatever built-in knowledge23Agents and EnvironmentsIs this vacuum cleaner agent rational?It depends on the perfo

20、rmance measure, the environment and what sensors and actuators it hasPercept sequenceActionA,CleanRightA, DirtySuckB, CleanLeftB, DirtySuckA, Clean,A, CleanRightA, Clean,A, DirtySuck24Good Behavior: The Concept of RationalityExample:The performance measure awards one point for each clean square at e

21、ach time step over a “lifetime” of 1000 time stepsThe “geography” of the environment is known a priori (Squares A & B). But we do not know the initial location and the dirt distribution. Clean squares stay clean and sucking clean the current square. The Left and Right actions move the agent except i

22、t will goes outside the environment.The only available actions are: Left, Right, Suck and NoOpThe agent correctly perceives its location and whether the location contains dirt25Good Behavior: The Concept of RationalityUnder this circumstances, the agent is indeed rational and its performance is at l

23、east as good as any other agentsIt will become irrationalThe agent will oscillate needlessly back and forthIf the performance measure reduces one point for each movement, this agent will perform very badA better agent should do nothing when the entire environment is clean and occasionally check & re

24、-clean the environment if neededIf the environment is unknown, exploration is needed26Good Behavior: The Concept of RationalityOmniscienceAn omniscience agent knows the actual outcome of its actions and can act accordinglyBut, omniscience is impossible in realityExample:A couple finished breakfast a

25、nd walking along the street and want to buy a newspaper across the street.There is no traffic nearby and they are not otherwise engagedBeing rational, should they cross the street?27Good Behavior: The Concept of RationalityExample:A young couple is walking along a very beautiful street and talking a

26、bout the excellent breakfast they had in the morning. There is no traffic nearby and they are not otherwise engaged. Should they cross the street to buy a newspaper?So, this person crosses the street28Good Behavior: The Concept of RationalityExample:A young couple is walking along a very beautiful s

27、treet and talking about the excellent breakfast they had in the morning. There is no traffic nearby and they are not otherwise engaged.This person crosses the streetMeanwhile, at 33000 feet, a cargo door falls off a passing airlinerA real case at Kent, Washington, USA in 7 Sep 2012The couple crossin

28、g the street is nearly flattenedIs it irrational to cross the street?Could one say that it is an idiot attempt to cross street?29Good Behavior: The Concept of RationalityRationality It is not the same as perfection理性不等同于完美It is to maximize expected performance它使期望的性能最大化In contrast, perfection is to

29、maximize actual performance而完美使实际性能的最大化Retreating from a requirement of perfection is not just a question of being fair to agentsIt will be impossible to design an agent to do what turns out to be the best action after the factunless we have a time machine30Good Behavior: The Concept of RationalityR

30、ationality Does not require omniscience全知Rational choice depends only on the percept sequence to date理性的选择只取决于到当时为止的感知序列Information gathering is important part of rationalityBefore crossing a road, one will look at both sides of the road for any incoming carExploration of the environment for our vac

31、uum cleaning agent31Good Behavior: The Concept of RationalityLearningA rational agent also need to learn as much as possible from what it perceivesThe initial configuration of the agent may reflect some prior knowledge of the environment智能体最初的设定可能反映了环境的一些先验知识After gaining experience, this may be mod

32、ified or augmented增加No learning is needed if we completely know the environment a prioribut this is the not case in reality32Good Behavior: The Concept of RationalitySuccessful agents should split the task of computing the agent function into 3 different periods成功的智能体会把智能体函数的计算任务分成三个不同时期When the age

33、nt is being designed. 设计智能体时Some of the computation is done by its designers设计者完成一些计算When it is deliberating on its next action思考下一步行动时The agent does more computationIt learns from experienceIt does even more computation to decide how to modify its behavior进行更多的计算来决定如何修改自己的行为33Good Behavior: The Con

34、cept of RationalityAutonomy自主性An agent lacks of autonomy if it ignore its own percepts and relies on the prior knowledge of its designerA rational agent should be autonomousIt should learn what it can to compensate for partial or incorrect prior knowledgeIf the vacuum cleaner agent can foresee where

35、 and when additional dirt will appear, it will do betterIn practice, one seldom requires complete autonomy from the start34Good Behavior: The Concept of RationalityLearning allows one to design a single rational agent that will succeed in a vast variety of environmentsAfter sufficient experience of

36、its environment, the behavior of a rational agent can become effectively independent of its prior knowledge35The Nature of EnvironmentsTask EnvironmentEssentially the “problem” to which rational agents are the “solution”The flavor of the task environment directly affects the appropriate design for t

37、he agent program任务环境的风味直接影响智能体程序的适当设计36The Nature of EnvironmentsThe Task Environment could be described by the PEAS DescriptionPerformance性能Environment环境Actuators执行器Sensors传感器In designing an agent, the first step must always be specifying详细说明 the task environment as fully as possible尽可能全面37The Natu

38、re of EnvironmentsExample: Automated Taxi DriverThe full driving task is extremely open-endedThere is no limit to the novel combinations of circumstances that can arisePEAS description of the task environment for an automated taxiAgent TypePerformance MeasureEnvironmentActuators执行器SensorsTaxidriverS

39、afe, fast,legal, comfortable trip,MaximizeprofitsRoads, other traffic,pedestrians,customersSteering,方向盘Accelerator, brake,刹车signal, horn,喇叭displayCameras, sonar, speedometer,GPS, odometer,里程engine sensors,Keyboard38The Nature of EnvironmentsPerformance measure of automated taxiGetting to the correct

40、 destinationMinimizing the fuel consumptionMinimizing the trip time and/or costMinimizing violation of traffic laws and disturbance to other driversMaximizing safety and passenger comfortMaximizing profitSome of these goals conflict, need to have tradeoffs折衷39The Nature of EnvironmentsEnvironment of

41、 automated taxiVariety of roadsRanging from rural lanes to 12-lanes freewaysThe roads contain other traffic, animals, road works, police cars, etcInteract with potential and actual passengersSome optional choicesSnow is not an issue in Guangzhou, but is a normal circumstance in HarbinIn Hong Kong, B

42、ritish and Japan, car is driving on the left-hand-side of roads40The Nature of EnvironmentsActuators of automated taxiControl over engine through accelerator and control over steering and brakingOutput to a display screen or voice synthesizer to talk back to the passengers Even communicate with othe

43、r vehicles41The Nature of EnvironmentsSensors of automated taxiTV camerasSpeedometerOdometerArray of engine and electrical system sensorsGPSInfrared or sonar to detect distances to other carsKeyboard or microphone for passenger to input the destination42The Nature of EnvironmentsMore PEAS descriptio

44、ns for other agentsAgent TypePerformance MeasureEnvironmentActuatorsSensorsMedicalDiagnosis systemHealthy patient,Minimize costs,lawsuitsPatient, hospital,staffDisplay, diagnose, questions, tests,treatments,ReferralsKeyboard entry of symptoms,Findings,patients answersSatellite imageAnalysis systemCo

45、rrect imagecategorizationDownlink fromOrbiting satelliteDisplayCategorization of sceneColor pixelarraysPart-pickingrobotPercentage ofParts in correct binsConveyor beltWith parts, binsJointed arm andhandCamera, joint angle sensorsRefinerycontrollerMaximize purity,Yield, safetyRefinery,operatorsValves

46、, pumps,heaters, displaysTemperature, pressure,Chemical sensorsInteractiveEnglish tutorMaximize students scoreSet of students,Testing agencyDisplay exercises,suggestions,correctionsKeyboard entry.43The Nature of EnvironmentsSome environment defined in the table is not a real environmentArtificial en

47、vironment defined by keyboard input and character output on a screenThis is not important to distinct between “real” or “artificial” environmentsOur concern is the complexity of the relationship among之间的关系复杂性The behavior of the agent智能体行为The percept sequence generated by the environment 环境产生的感知序列The

48、 performance measure性能度量44The Nature of EnvironmentsSome real environments could be simpleA robot designed to inspect parts as they come by on a conveyor belt传送带上零件We could make assumption to simplify the situationLighting is always just so照明一直不变 and the only thing on the conveyer belt will be parts

49、 of a kind that it knows about它了解的一类零件The robot only needs to perform two actions: accept or reject45The Nature of EnvironmentsSoftware agent (a.k.a. 又叫做software robot or softbot)Example: a softbot designed to fly a flight simulator for a large commercial airplaneThe simulator could be very detailed

50、. Including complex environment including other aircrafts and ground operations. It must choose from a wide variety of actions in real timeExample: a softbot search for interesting news and display it to customersIt needs to scan the Internet and find news sourcesCustomer interests may change dailyI

51、t requires natural language processing Web pages on the Internet is not well-organized46The Nature of EnvironmentsProperties of task environmentsThe range of task environments in AI is obviously vastWe may categorize them into several dimensionsList of dimensionsFully observable vs Partially observa

52、bleDeterministic vs StochasticEpisodic vs Sequential片段式或延续式Static vs DynamicDiscrete vs ContinuousSingle agent vs multiagent47The Nature of EnvironmentsFully observableIf an agents sensors give it access to the complete state of the environment at each point in time, the sensors detect all aspects t

53、hat are relevant to the choice of actionRelevance, in turn, depends on the performance measureConvenient because agent need not to maintain any internal state to keep track of the worldPartially observableNoisy and inaccurate sensorsParts of the state are missing from the sensor data48The Nature of

54、EnvironmentsDeterministicThe next state of the environment is completely determined by the current state and the action executed by the agentotherwise stochasticIf the environment is fully observable and deterministic, there is no uncertaintyIf an environment is deterministic except for the actions

55、of other agents, the environment is StrategicStochastic 随机的An partially observable environment is usually stochasticTaxi driving is stochastic because you do not know what do other drivers thinking and what will they do next49The Nature of EnvironmentsEpisodicAgents experience is divided into atomic

56、 episodesEach episode consists of the agent perceiving and then performing a single actionThe next episode does not depend on the actions taken in previous episodesSo, action in each episode only depends on the episode itselfClassification tasks are usually episodicSequentialCurrent decision could a

57、ffect all future decisionsChess playing and taxi driving are examples of sequential environments50The Nature of EnvironmentsDynamicEnvironments which change while an agent is deliberating Continuously asking the agent what it wants to doIf the agent is not yet decided what to do, it is counted as de

58、cided to do nothing at that timeIf the environment does not change, but the agents performance score does, it is a semi-dynamic environment半动态StaticEasy, no need to keep looking at the world for deciding on an actionNo need to worry about the passage of time51The Nature of EnvironmentsContinuousThe

59、discrete and continuous distinction can be applied To the state of the environmentTo the way time is handledTo the Percepts 感知信息 and actions of the agentThe speed and location of the taxi and of the other cars sweep through a range of continuous values over time. The actions of taxi-driving is conti

60、nuous, e.g. steering anglesDiscreteIn chess game, there are finite number of distinct discrete-states. Actions and percepts are also discrete.52The Nature of EnvironmentsSingle agentAn agent solving crossword puzzle by itself is a single agent environmentMulti-agentTwo agents playing chess game toge

温馨提示

  • 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
  • 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
  • 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
  • 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
  • 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
  • 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
  • 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。

评论

0/150

提交评论