PEAS: How to Describe Task Environments for Agents in AI

Rachael Ferguson
4 min readAug 7, 2022

--

On the left side: background of bright green peas outside of the pod, on top is two pea pods cracked open with individual peas peeking out. On the right is computer art of blue and green circuit lines in the shape of a human brain.
📷 Cite: Peas and AI

Made famous in the textbook Artificial Intelligence: A Modern Approach, PEAS is an acronym to represent the various types of descriptors used to describe a task environment for an agent. That is, what the environment is composed of, how the agent can interact, and what the goal is.

The acronym is composed of:

Performance: Defines the criteria needed to be achieved for success
Environment: What the agent knows about the world around it
Actuators: What actions the agent can perform
Sensors: How the agent can sense what is around it

The easiest way to understand PEAS is to look through examples of agents around us.

Real-Life Agents

Robot Vacuum

Imagine a little Roomba vacuum zipping about your home, cleaning up dirt and dust on the floor while you’re away at work. This robot is a rational agent, and we can describe its task using PEAS.

📷 Cite: southernliving.com
  • Performance: cleanliness, battery life, efficiency, …
  • Environment: carpet, hard flooring, rug, table, couch, dirt, stairs (edge), …
  • Actuators: brushes, wheels, suction, …
  • Sensors: camera, dirt detection, edge detection, wall sensor, …

Notice the ellipses after each descriptor. That is, while there is a general set of items that will describe most of the task aspects, it is by no means a complete description. For example, we could write about endless items that are in the vacuum’s environment, from child toys to wind from a fan.

This is very common for real-world environments and is why it can be difficult to take an algorithm that works well in a hypothetical defined environment and bring it into the real world.

Human

Yep, people are agents too! Complex ones, of course. But, let’s write out PEAS for the task environment of going on a hike to a mountain top.

A man with a large backpack and walking sticks looks at a green mountain valley with snowy mountain peaks in the distance
📷 Cite: coloradotrail.org
  • Performance: efficiency (very common performance metric), heart rate, oxygen level, pain level, completeness
  • Environment: trees, rocks, dirt, trail signs, wind, bugs, cliffs, …
  • Actuators: hands, legs, feet, lungs, walking stick
  • Sensors: eyes, skin, ears

“Hypothetical” Agent

Now, let’s describe a new agent and its environment. Called DishPutter, this robot will fill your dishwasher for you. All you have to do is leave your dirty dishes around the kitchen and DishPutter will move them into the dishwasher for you! (Not as useful for a home cook, but think of the help for restaurants!)

DishPutter will turn on when you push its “on” button. It will move around the kitchen, pick up dishes with its cushioned claws, put them in the dishwasher, start the washer, and then play a cute song while it powers back down. It is very good at organizing dishes in the dishwasher to conserve space.

Believe it or not, a crude form of this robot is a reality as of 2016 from Boston Dynamics! But, certainly not at the level of our hypothetical dish putter. In the past couple of years, robots have been getting better. Samsung’s Handy Bot is a notable agent.

📷 Cite: Samsung

Given the above description, let’s write up PEAS to describe the task environment for DishPutter.

  • Performance: Efficiency, safety (doesn’t run into any humans), battery life, recall (collects all the dirty dishes), precision (collects only dirt dishes), damage control (doesn’t cause harm to any kitchen equipment)
  • Environment: Room, sink, counter, stove, dishwasher, different dish types, dishwasher soap, people, floor which may have spills, counter
  • Actuators: Wheels, padded claws, speaker for music, music, battery
  • Sensors: Vision sensor (for dish type, location, level of dirt, and dishwasher “fullness”), lasers to determine room layout and any moving objects to avoid crashes, texture sensor for floor to detect spills

Takeaways

PEAS is great as an initial step to understanding the task your agent is given when solving a problem. Next, we can dive further into describing the environment type, agent type, and more! Look forward to further articles that I will link to below as we dive deep into this topic.

--

--