22
Intelligent Agents Intelligent Agents ออออออออออออ ออออออออออ ออออออออออออ ออออออออออ อออออออออออออออออออออออ อออออออออออออออออออออออ อออออออออออออ อออออออออออออ อออออออออออออออออ อออออออออออออออออ อออออออออออออออออออออ อออออออออออออออออออออ

Intelligent Agents อาจารย์อุทัย เซี่ยงเจ็น สำนักเทคโนโลยีสารสนเทศและการ สื่อสาร

Embed Size (px)

Citation preview

Page 1: Intelligent Agents อาจารย์อุทัย เซี่ยงเจ็น สำนักเทคโนโลยีสารสนเทศและการ สื่อสาร

Intelligent AgentsIntelligent Agents

อาจารย์�อ�ทัย์ เซี่ �ย์งเจ�นอาจารย์�อ�ทัย์ เซี่ �ย์งเจ�นสำ�านกเทัคโนโลย์ สำารสำนเทัศและการสำ�านกเทัคโนโลย์ สำารสำนเทัศและการ

สำ��อสำารสำ��อสำารมหาวิ�ทัย์าลย์นเรศวิร วิ�ทัย์าเขตมหาวิ�ทัย์าลย์นเรศวิร วิ�ทัย์าเขต

สำารสำนเทัศพะเย์าสำารสำนเทัศพะเย์า

Page 2: Intelligent Agents อาจารย์อุทัย เซี่ยงเจ็น สำนักเทคโนโลยีสารสนเทศและการ สื่อสาร

Notion of an AgentNotion of an Agent

environmentagent

?

sensors

actuators laser range finder

sonarstouch sensors

Page 3: Intelligent Agents อาจารย์อุทัย เซี่ยงเจ็น สำนักเทคโนโลยีสารสนเทศและการ สื่อสาร

Notion of an AgentNotion of an Agent

environmentagent

?

sensors

actuators

•Locality of sensors/actuators•Imperfect modeling•Time/resource constraints•Sequential interaction•Multi-agent worlds

Page 4: Intelligent Agents อาจารย์อุทัย เซี่ยงเจ็น สำนักเทคโนโลยีสารสนเทศและการ สื่อสาร

Example: Tracking a TargetExample: Tracking a Target

targetrobot

• The robot must keep the target in view• The target’s trajectory is not known in advance• The robot may not know all the obstacles in advance• Fast decision is required

Page 5: Intelligent Agents อาจารย์อุทัย เซี่ยงเจ็น สำนักเทคโนโลยีสารสนเทศและการ สื่อสาร

What is Artificial Intelligence? What is Artificial Intelligence? (revised)(revised)

Study of design of rational agents Study of design of rational agents

agent = thing that acts in environment agent = thing that acts in environment

Rational agent = agent that acts Rational agent = agent that acts rationally: rationally: – actions are appropriate for goals and actions are appropriate for goals and

circumstances to changing environments circumstances to changing environments and goals and goals

– learns from experiencelearns from experience

Page 6: Intelligent Agents อาจารย์อุทัย เซี่ยงเจ็น สำนักเทคโนโลยีสารสนเทศและการ สื่อสาร

Goals of Artificial IntelligenceGoals of Artificial Intelligence

Scientific goal: Scientific goal: – understand principles that make rational understand principles that make rational

(intelligent) behavior possible, in natural or (intelligent) behavior possible, in natural or artificial systems. artificial systems.

Engineering goal: Engineering goal: – specify methods for design of useful, specify methods for design of useful,

intelligent artifacts. intelligent artifacts.

Psychological goal: Psychological goal: – understanding/modeling people understanding/modeling people – cognitive science (not this course)cognitive science (not this course)

Page 7: Intelligent Agents อาจารย์อุทัย เซี่ยงเจ็น สำนักเทคโนโลยีสารสนเทศและการ สื่อสาร

Goals of This CourseGoals of This Course

Introduce key methods & techniques Introduce key methods & techniques from AI from AI – searching,searching,– reasoning and decision making (logical and reasoning and decision making (logical and

probabilistic)probabilistic)– learning language understanding,learning language understanding,– . . . . . .

Understand applicability and limitations Understand applicability and limitations of these methods of these methods

Page 8: Intelligent Agents อาจารย์อุทัย เซี่ยงเจ็น สำนักเทคโนโลยีสารสนเทศและการ สื่อสาร

Goals of This CourseGoals of This Course

Our approach: Our approach: – Characterize Environments Characterize Environments – Identify agent that is most effective for Identify agent that is most effective for

each environment each environment

Study increasingly complicated agent Study increasingly complicated agent architectures requiring architectures requiring – increasingly sophisticated representations, increasingly sophisticated representations, – increasingly powerful reasoning strategies increasingly powerful reasoning strategies

Page 9: Intelligent Agents อาจารย์อุทัย เซี่ยงเจ็น สำนักเทคโนโลยีสารสนเทศและการ สื่อสาร

Intelligent AgentsIntelligent Agents

Definition: An Intelligent Agent perceives its Definition: An Intelligent Agent perceives its environment via sensors and acts rationally environment via sensors and acts rationally upon that environment with its actuators.upon that environment with its actuators.Hence, an agent gets percepts one at a time, Hence, an agent gets percepts one at a time, and maps this percept sequence to actions.and maps this percept sequence to actions.PropertiesProperties– AutonomousAutonomous– Interacts with other agents Interacts with other agents

plus the environmentplus the environment– Adaptive to the environmentAdaptive to the environment– Pro-active (goal-directed)Pro-active (goal-directed)

Page 10: Intelligent Agents อาจารย์อุทัย เซี่ยงเจ็น สำนักเทคโนโลยีสารสนเทศและการ สื่อสาร

Applications of AgentsApplications of Agents

Autonomous delivery/cleaning robot Autonomous delivery/cleaning robot – roams around home/office environment, delivering roams around home/office environment, delivering

coffee, parcels,. . . vacuuming, dusting,. . . coffee, parcels,. . . vacuuming, dusting,. . .

Diagnostic assistant helps a human Diagnostic assistant helps a human troubleshoot problems and suggest repairs or troubleshoot problems and suggest repairs or treatments. treatments. – E.g., electrical problems, medical diagnosis. E.g., electrical problems, medical diagnosis.

Infobot searches for information on computer Infobot searches for information on computer system or network. system or network.

Autonomous Space Probes Autonomous Space Probes

. . . . . .

Page 11: Intelligent Agents อาจารย์อุทัย เซี่ยงเจ็น สำนักเทคโนโลยีสารสนเทศและการ สื่อสาร

Task Environments: Task Environments: PPEEAASS

PPerformance Measureerformance Measure– Criterion of successCriterion of success

EEnvironmentnvironmentAActuators(ctuators(เคล��อนไหวิเคล��อนไหวิ))– Mechanisms for the agent to affect the Mechanisms for the agent to affect the

environmentenvironment

SSensorsensors– Channels for the agent to perceive the Channels for the agent to perceive the

environmentenvironment

Page 12: Intelligent Agents อาจารย์อุทัย เซี่ยงเจ็น สำนักเทคโนโลยีสารสนเทศและการ สื่อสาร

Example: Taxi DrivingExample: Taxi Driving

PPerformance Measureerformance Measure– Safe, fast, legal, comfortable trip, maximize profitSafe, fast, legal, comfortable trip, maximize profit

EEnvironmentnvironment– Roads, other traffic, pedestrians, customersRoads, other traffic, pedestrians, customers

AActuatorsctuators– Steering, accelerator, break, signal, horn, …Steering, accelerator, break, signal, horn, …

SSensorsensors– Cameras, sonar, speedometer, GPS, …Cameras, sonar, speedometer, GPS, …

Page 13: Intelligent Agents อาจารย์อุทัย เซี่ยงเจ็น สำนักเทคโนโลยีสารสนเทศและการ สื่อสาร

Types of EnvironmentsTypes of Environments

Fully observable (accessible) or notFully observable (accessible) or not

Episodic(Episodic(ตอนตอน)) vs. sequential vs. sequential((ล�าดับล�าดับ))

Static vs. dynamicStatic vs. dynamic

Discrete vs. continuousDiscrete vs. continuous

Single agent vs. multi-agentSingle agent vs. multi-agent– competitive vs. cooperativecompetitive vs. cooperative

Page 14: Intelligent Agents อาจารย์อุทัย เซี่ยงเจ็น สำนักเทคโนโลยีสารสนเทศและการ สื่อสาร

Agent Function and ProgramAgent Function and Program

Agent specified by agent function Agent specified by agent function – mapping percept sequences to actions mapping percept sequences to actions – Aim: Concisely implement “rational agent Aim: Concisely implement “rational agent

function”function”

Agent program Agent program – InputInput: a single percept-vector : a single percept-vector – ProcessProcess: (keeps/updates internal state) : (keeps/updates internal state) – OutputOutput: returns action : returns action

Page 15: Intelligent Agents อาจารย์อุทัย เซี่ยงเจ็น สำนักเทคโนโลยีสารสนเทศและการ สื่อสาร

Skeleton Agent ProgramSkeleton Agent Program

functionfunction SkeletonAgent( SkeletonAgent(perceptpercept) ) returnsreturns actionaction staticstatic: memory, [agent's memory of the world] : memory, [agent's memory of the world] memory memory UpdateMemory(memory,percept) UpdateMemory(memory,percept) action action ChooseBestAction(memory) ChooseBestAction(memory) memory memory UpdateMemory(memory, action) UpdateMemory(memory, action) returnreturn action action

Page 16: Intelligent Agents อาจารย์อุทัย เซี่ยงเจ็น สำนักเทคโนโลยีสารสนเทศและการ สื่อสาร

Types of AgentsTypes of Agents

Simple reflex agentsSimple reflex agents– Actions are determined by sensory input onlyActions are determined by sensory input only

Model-based reflex agentsModel-based reflex agents– Has internal statesHas internal states

Goal-based agentsGoal-based agents– Action may be driven by a goalAction may be driven by a goal

Utility-based agentsUtility-based agents– Maximizes a utility functionMaximizes a utility function

Page 17: Intelligent Agents อาจารย์อุทัย เซี่ยงเจ็น สำนักเทคโนโลยีสารสนเทศและการ สื่อสาร

Simple Reflex AgentSimple Reflex Agent

Page 18: Intelligent Agents อาจารย์อุทัย เซี่ยงเจ็น สำนักเทคโนโลยีสารสนเทศและการ สื่อสาร

ExampleExample

A LEGO MindStormA LEGO MindStormTMTM program: program:if (isDark(leftLightSensor)) if (isDark(leftLightSensor)) turnLeft()turnLeft()else if (isDark(rightLightSensor)) else if (isDark(rightLightSensor)) turnRight()turnRight()

else goStraight()else goStraight()

What’s the agent function?What’s the agent function?

Page 19: Intelligent Agents อาจารย์อุทัย เซี่ยงเจ็น สำนักเทคโนโลยีสารสนเทศและการ สื่อสาร

Model-Based AgentModel-Based Agent

Page 20: Intelligent Agents อาจารย์อุทัย เซี่ยงเจ็น สำนักเทคโนโลยีสารสนเทศและการ สื่อสาร

Goal-based AgentGoal-based Agent

Page 21: Intelligent Agents อาจารย์อุทัย เซี่ยงเจ็น สำนักเทคโนโลยีสารสนเทศและการ สื่อสาร

Utility-based AgentUtility-based Agent

Page 22: Intelligent Agents อาจารย์อุทัย เซี่ยงเจ็น สำนักเทคโนโลยีสารสนเทศและการ สื่อสาร

SummarySummary

Intelligent AgentIntelligent Agent

PEASPEAS

Types of AgentsTypes of Agents