Understanding the Root Cause
To resolve this issue, it’s essential to understand the root cause of the problem. The employee agent runs in a user context, which means that the user needs to have the necessary permissions to access the knowledge base and data library.
The root cause of the issue is often related to insufficient permissions, incorrect data library assignments, or inadequate topic instructions. Ensuring that the user has the necessary permissions, such as Prompt Template User, Knowledge, and Data Cloud User, and that the data library is properly assigned and indexed, can help resolve the issue.
Step-by-Step Solution
To fix the knowledge search issue in your employee agent, follow these steps:
- Ensure that the user has the necessary permissions, including Prompt Template User, Knowledge, and Data Cloud User.
- Verify that the data library is properly assigned to the agent and that it is indexed in Data Cloud.
- Check that the topic instructions are sufficient to guide the agent in searching the knowledge base.
- Test the agent using the Prompt Builder to ensure that the resolved utterance includes the expected article.
- Run batch testing using the Testing Center to see if the agent returns the expected response.
Troubleshooting Tips
If you’re still experiencing issues, try the following troubleshooting tips:
- Check the agent’s language settings to ensure that they match the language of the knowledge articles.
- Verify that the knowledge articles are properly published and indexed in the data library.
- Test the agent using different search queries to see if the issue is specific to certain topics or keywords.
Example Code
// Example code to verify data library assignment
var dataLibrary = DataLibrary.get('Knowledge_Base');
if (dataLibrary != null) {
System.debug('Data library assigned: ' + dataLibrary.getName());
} else {
System.debug('Data library not assigned');
}
Heads up: Ensure that you have the necessary permissions and access to the data library and knowledge base to troubleshoot and resolve the issue.
Checklist
- Verify user permissions: Prompt Template User, Knowledge, and Data Cloud User
- Assign data library to the agent
- Index data library in Data Cloud
- Test agent using Prompt Builder
- Run batch testing using Testing Center
- Verify agent language settings
Frequently Asked Questions
What permissions are required for the employee agent to search the knowledge base?
The user needs to have Prompt Template User, Knowledge, and Data Cloud User permissions.
How do I assign a data library to the agent?
You can assign a data library to the agent in the Agentforce configuration settings.
What if I’m still experiencing issues after following the troubleshooting tips?
Reach out to Salesforce support for further assistance.
Can I use a custom retriever with the employee agent?
Yes, you can use a custom retriever with the employee agent, but ensure that it is properly configured and tested.
Need help shipping this in production?
Genetrix builds and untangles Salesforce Marketing Cloud and Agentforce setups for teams that want it done right the first time. If anything in this post sounds familiar, talk to us before it ships.