Introduction to Agents in Artificial Intelligence
Today, Agents in Artificial Intelligence is the new electricity. It is revolutionizing technology. Artificial Intelligence is making machines/computers smart like humans.
What is an Agent?
An Agent is anything that takes actions according to the information that it gains from the environment. A human agent has sensory organs to sense the environment and the body parts to act while a robot agent has sensors to perceive the environment.
How does the Agent Interact with the Environment?
The agents interact with the environment in two ways:
Perception is a passive interaction, where the agent gains information about the environment without changing the environment. The sensors of the robot help it to gain information about the surroundings without affecting the surrounding. Hence, gaining information through sensors is called perception.
Action is an active interaction where the environment is changed. When the robot moves an obstacle using its arm, it is called an action as the environment is changed. The arm of the robot is called an “Effector” as it performs the action.
Explanation of the above image:
- The interaction of the Agent with the Environment is through Sensors and Effectors.
- Consider the example of a chatbot which is a virtual assistant. When it reads and understands the meaning of a user’s messages, it is called perception. And when it replies to the user after analyzing the user’s message, it is called the action.
How Agents should Act in Artificial Intelligence?
Below are the points that explain how an agent should act:
- A rational agent does the right thing. The right action is the one that causes the agent to be the most successful.
- An omniscient agent knows what impact the action will have and can act accordingly, but in reality, it is not possible.
- The degree of success which is defined by the performance measure
- The percept sequence which is the entire sequence of perceptions by the agent until the present moment
- The knowledge of agent about the environment
- What actions can the agent perform
Mapping of Percept Sequences to Actions
When it is known that the action of agent depends completely on the perceptual history – the percept sequence, then the agent can be described by using a mapping. Mapping is a list that maps the percept sequence to the action. When we specify which action an agent should take corresponding to the given percept sequence, then we are specifying the design for an ideal agent.
4.5 (2,263 ratings)
The behavior of an agent depends on its own experience as well as the built-in knowledge of the agent instilled by the agent designer. A system is autonomous if it takes actions according to its experience. So for the initial phase, as it does not have any experience, it is good to provide built-in knowledge. The agent learns then through evolution. A truly autonomous intelligent agent if given sufficient time to adapt should be able to operate successfully in a wide variety of environments.
Types of Agents in Artificial Intelligence
Following are the 4 types of agents:
1. Reflex Agent
Reflex Agent works similar to the reflex action of our body (eg when we immediately lift our finger when it touches the tip of the flame). Just as the prompt response of our body based on the current situation, the agent also responds based on the current environment irrespective of the past state of the environment. The reflex agent can work properly only if the decisions to be made are based on the current percept.
2. Agents that keep Track of the World
These are the agents with memory. It stores the information about the previous state, the current state and performs the action accordingly. Just as while driving, if the driver wants to change the lane, he looks into the mirror to know the present position of vehicles behind him. While looking in front, he can only see the vehicles in front and as he already has the information on the position of vehicles behind him (from the mirror a moment ago), he can safely change the lane. The previous and the current state get updated quickly for deciding the action.
3. Goal-based Agents
In some circumstances, just the information of the current state may not help in making the right decision. If the goal is known, then the agent takes into account the goal information besides the current state information to make the right decision. For eg., if the agent is a self-driving car and the goal is the destination, then the information of the route to the destination helps the car in deciding when to turn left or right.
‘Search’ and ‘planning’ are the two subfields of AI that help the agent achieve its goals. Though the goal-based agent may appear less efficient, yet it is flexible. Considering the same example mentioned above, if the destination changes then the agent will manipulate its actions accordingly. This will not be the case with the reflex agent as all the rules need to be rewritten with the change in goal.
4. Utility Agents
There can be many possible sequences to achieve the goal but some will be better than others. Considering the same example mentioned above, the destination is known but there are multiple routes. Choosing an appropriate route also matters to the overall success of the agent. There are many factors in deciding the route like the shortest one, the comfortable one, etc. The success depends on the utility of the agent-based on user preferences.
The utility is a function that maps a state to a real number that describes the degree of happiness. The utility function specifies the appropriate trade-off in case the goals are conflicting.
Conclusion – Agents in Artificial Intelligence
An agent is anything that takes actions according to the information that it gains from the environment. The agents interact with the environment in two ways: Perception and Action. Agents can be rational or omniscient.
Following are the 4 types of agents:
- Reflex (reactive) agent – an agent without
- Agents that keep track of the world
- Goal-based agents
- Utility agents
This is a guide to Agents in Artificial Intelligence. Here we discuss what is an agent, how the agent interacts with the environment, and the four types of agent. You can also go through our other related articles to learn more –
- Artificial Intelligence Technology
- How Artificial Intelligence Works?
- Applications of Machine Learning
- Types of Machine Learning Algorithms
- Artificial Intelligence Techniques
- Top 12 Types of Sensors and their Applications
- Hill Climbing in Artificial Intelligence | Types
- Top 4 Major Fields of Future of Artificial Intelligence