Agentforce Guide to Achieving Reliable Agent Behavior

A Framework for 5 Levels of Determinism

Flowchart graphic showing the Agentforce building blocks.
Graphic showing the control levels for increased agent behavior.
Flow chart graphic showing a high-level decision tree of the Agentforce Reasoning Engine.

Activity Steps Description
Agent Invocation 1 Agent is invoked.
Topic Classification 2-3 The engine analyzes the customer's message and matches it to the most appropriate topic based on the topic name and classification description.
Context Assembly 4-5 Once a topic is selected, the engine gathers the topic's scope, instructions, and available actions along with the conversation history. (Note: Instructions are covered in level two, Agentic Control.)

Decision Making
Using all this information, the engine determines whether to:
• Run an action to retrieve or update information
• Ask the customer for more details
• Respond directly with an answer
Action Execution 6-8 If an action is needed, the engine runs it and collects the results.
Action Loop The engine evaluates the new information and decides again what to do next—whether to run another action, ask for more information, or respond.
Grounding Check Before sending a final response, the engine checks that the response:
• Is based on accurate information from actions or instructions
• Follows the guidelines provided in the topic's instructions
• Stays within the boundaries set by the topic's scope
Send Response The grounded response is sent to the customer.
Graphic showing the flow of Topic Classification from agent conversation to plan.
Graphic showing the flow of classifying actions from an agent conversation to a plan.
Graphic showing the looping over next action classification in the flow from agent conversation to plan.
Graphic showing the reasoning engine in action in the flow from an Agent conversation to plan.
Salesforce UI showcasing plan tracing within Agent reasoning.
Flowchart graphic showing an Agent flow with RAG between Platform and Data Cloud.

Context Variables Custom Variables
Can be instantiated by user X
Can be Input of Actions
Can be output of Actions X

Can be updated by actions
X
Can be used in filters of actions and topics
Flowchart graphic showing the retrieving, setting, and using stages of troubleshooting.
Flowchart graphic showcasing an Agent using filters for troubleshooting or providing resolution.
Flowchart graphic showing a marketing journey.

AI determinism FAQs

The five levels of determinism in AI are: instruction-free topic and action selection, agent instructions, data grounding, agent variables, and deterministic actions using flows, Apex, and APIs.

Understanding AI determinism is crucial for building reliable agents that can perform critical business functions accurately and consistently, striking a balance between creative fluidity and enterprise control.

In AI, "deterministic" refers to the ability of a system to produce the same output given the same input and conditions, imposing a rigidity and discipline essential for reliable agent behavior.

Non-determinism in AI systems arises primarily due to the use of Large Language Models (LLMs), which are non-deterministic by nature, allowing agents to be flexible and adaptive.

The levels of determinism progressively enhance the determinism of AI agents, thereby affecting their autonomy - as the levels progress, agents become less autonomous but more reliable and aligned with business processes.

Less deterministic AI systems present challenges in terms of reliability and compliance with business requirements, as their inherent non-determinism can lead to unpredictable behavior.

Businesses manage AI systems with varying levels of determinism by applying a layered approach that includes thoughtful design, clear instructions, data grounding, state management through variables, and deterministic process automation using flows, Apex, and APIs.