When configuring a task assigned to an AI agent, use these guidelines to write effective instructions in the Description field in Agentforce Operations. Clear instructions lead to more reliable results.
Required Editions
| License Required |
|---|
|
This feature is a workspace that’s external to your Salesforce org and requires an Agentforce Operations license. To purchase an Agentforce Operations license, contact your Salesforce account executive. |
Instruction Writing Guidelines
- Include all required instructions in the Description field.
- Keep instructions clear and concise.
- For multi-step work, list the steps in order.
- To use a field’s value in the instructions, add a merge field by @ mentioning the field,
such as
@Supplier Nameor@Invoice Number. Learn more about @ mentioning fields in the Description field in Configuring Tasks. - For document extraction, instructions in the Description field are optional unless you want to explain an edge case.
- For .docx templates, match variable placeholders exactly, such as
{{ supplier_name }}and{{ invoice_number }}. - Test the AI agent task. If your instructions don't result in the output you want, revise the instructions and test again. Editing the task erases any saved plan, so run the test again to generate and save a new plan before publishing.
Instruction Examples
| Use Case | Good Example | Needs Improvement |
|---|---|---|
| Triage |
Review the Invoice Amount field and classify the invoice by using these rules:
Enter the result in the Priority field. |
Prioritize the invoice based on importance. |
| Fill .docx Template |
Use the shared fields to populate the contract template. Variable placeholders must match exactly:
|
Fill in the template with the supplier info. |
| Audit |
Review the purchase order by using these steps: 1. Check the Vendor Name field against the Approved Vendor List field. If the vendor isn’t on the list, enter "Unapproved vendor" in the Audit Result field and stop. 2. Check the PO Amount field. If it exceeds the value in the Spending Limit field, enter "Exceeds spending limit" in the Audit Result field and stop. 3. If all checks pass, enter "Approved" in the Audit Result field. |
Check the purchase order and make sure that everything looks right. |