Build Trust in AI Responses with Citations
Citations link AI-generated responses to the grounding sources that are relevant to the response. Use citations to see what information the large language model (LLM) used to generate the response, and to verify the validity of the source data. Citations help you identify potential inaccuracies or hallucinations in the generated responses, increasing your confidence in using AI tools.
Required Editions
| Available in: Enterprise, Performance, and Unlimited Editions with an Einstein for Sales, Einstein for Platform, Einstein for Service, Einstein 1 Service, or Einstein GPT Service add-on. To purchase add-ons, contact your Salesforce account executive. |
About Citations
Citations are useful for several reasons.
- Verifiability: Users can verify the accuracy and origin of the information provided by the agent.
- Trust: By providing sources, the system demonstrates that the responses are data-based and trustworthy.
- Deeper Insight: Users can explore the source material for more detailed information.
In an agent context, citations refer to the way the system references the sources of information used to generate responses or take actions. Supported sources include knowledge articles, data from PDF files, and information from external web pages.
Source URLs can be viewed through Agent Builder, Agent API, Lightning Experience, the Salesforce mobile app for Android and iOS, and Enhanced Chat.
Platform-Managed and Instructions-Based Citations
Citations can be implemented in two ways.
- Platform-Managed Citations: A dedicated platform service provides platform-managed citations out of the box. This service formats, displays, and links citations, ensuring a structured and consistent user experience.
- Instructions-Based Citations: You provide custom instructions to generate citations in prompt templates or subagents.
Platform-managed citations are available at the action level and are supported for these actions.
- Answer Questions with Knowledge action via Agentforce Data Library: To enable platform-based citations, see, Show Sources for Answer Questions with Knowledge Standard Action.
- Custom actions built by using prompt templates: To enable service-managed citations for
custom actions based on prompt templates, see Configure Citations for Custom Actions. To include citations for custom actions,
the prompt template must include at least 1 Einstein Search
retriever.
Note Currently, inline citations aren’t available for custom actions that are based on prompt templates. - Citations with Apex-based agent actions.
Consider these points when choosing between platform-managed and instruction-based citations.
| CONSIDERATION | PLATFORM-MANAGED | INSTRUCTION-BASED |
|---|---|---|
| Citation Handling | Provides a structured way to handle citations with a dedicated service. You can benefit from the built-in functionality. |
Allows for flexibility in how citations are formatted and presented. Requires you to manually add instructions and logic for generating citations. |
| Prompt Impact | Reduces the need for adding specific citation instructions within prompts and prompt fine-tuning. Useful for minimizing prompt context/word count. | Can consume prompt context/word count by requiring specific citation instructions. Can require additional fine-tuning to generate citations consistently. |
| Display Options | Are displayed in a separate Sources section at the end of the response. Inline citations are numbered links. Currently, inline citations aren’t available for custom actions that are based on prompt templates. If a citation involves an image, then it's displayed as a clickable link to the image. |
Formatting and display are defined as part of prompt instructions, which you can customize. |
| Large Language Model (LLM) | Leverage a Salesforce managed fine-tuned language model. | Specific to the LLM selected by you and can vary depending on the LLM. |
Example of Platform Citations
Here's an example of how platform citations are displayed.
Additional details and metadata related to citations are stored in Data 360 DMOs as part of the audit trail data. See the Einstein Generative AI Gateway Object Record Citation Reference DMO in Data Model for Generative AI Audit and Feedback.

