INTELLIGENT AGENTS · 8 MIN
Intelligent Agents (PEAS)
An agent perceives its environment through sensors and acts through actuators to maximise a performance measure.
NEURA explains
- PEAS: Performance measure, Environment, Actuators, Sensors.
- Simple reflex agents react to the current percept; model-based agents remember state; goal-based agents plan.
- Utility-based agents pick the action with the highest expected 'happiness'.
Real world: A robot vacuum: sensors = bump + dirt sensors, actuators = wheels + brush, performance = clean area per minute.
Code
def reflex_vacuum(location, dirty):
if dirty: return "Suck"
return "Right" if location == "A" else "Left"
print(reflex_vacuum("A", False))Output ›
RightTry it in the online compiler →Checkpoint quiz
In PEAS, what does 'A' stand for?