-
Notifications
You must be signed in to change notification settings - Fork 46
Bugfix/ait 133 citations #3100
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: AIT-129-AIT-Docs-release-branch
Are you sure you want to change the base?
Bugfix/ait 133 citations #3100
Conversation
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the You can disable this status message by setting the Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
| meta_keywords: "citations, references, source attribution, message annotations, AI transparency, source tracking, annotation summaries" | ||
| --- | ||
|
|
||
| AI agents often draw information from external sources such as documents, web pages, or databases. Citations to those sources enable users to verify information, explore sources in detail, and understand where responses came from. Ably's [message annotations](/docs/messages/annotations) provide a model-agnostic, structured way to attach source citations to AI responses without modifying the response content. It enable clients to append information to existing messages on a channel. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| AI agents often draw information from external sources such as documents, web pages, or databases. Citations to those sources enable users to verify information, explore sources in detail, and understand where responses came from. Ably's [message annotations](/docs/messages/annotations) provide a model-agnostic, structured way to attach source citations to AI responses without modifying the response content. It enable clients to append information to existing messages on a channel. | |
| AI agents often draw information from external sources such as documents, web pages, or databases. Citations to those sources enable users to verify information, explore sources in detail, and understand where responses came from. Ably's [message annotations](/docs/messages/annotations) provide a model-agnostic, structured way to attach source citations to AI responses without modifying the response content. It enables clients to append information to existing messages on a channel. |
| - Transparency: Users can verify claims and understand the basis for AI responses. This builds trust and allows users to fact-check information independently. | ||
| - Source exploration: Citations enable users to dive deeper into topics by accessing original sources. This is particularly valuable for research, learning, and decision-making workflows. | ||
| - Attribution: Proper attribution respects content creators and helps users understand which sources informed the AI's response. | ||
| - Audit trails: For enterprise applications, citations provide an audit trail showing which information sources were consulted during AI interactions. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| - Audit trails: For enterprise applications, citations provide an audit trail showing which information sources were consulted during AI interactions. | |
| - Audit trails: For enterprise applications, citations provide explicit traceability between LLM responses and the information sources that were consulted when generating them. |
|
|
||
| 1. The agent publishes an AI response as a single message, or builds it incrementally using [message appends](/docs/ai-transport/message-per-response). | ||
| 2. The agent publishes one or more annotations to attach citations to the response message, each referencing the response message [`serial`](/docs/messages#properties). | ||
| 3. Ably automatically aggregates annotations and generates summaries showing total counts and groupings (for example, by domain name). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| 3. Ably automatically aggregates annotations and generates summaries showing total counts and groupings (for example, by domain name). | |
| 3. Ably automatically aggregates annotations and generates summaries showing total counts and groupings (for example, by source domain name). |
| 1. Go to the [Ably dashboard](https://www.ably.com/dashboard) and select your app. | ||
| 2. Navigate to the "Configuration" > "Rules" section from the left-hand navigation bar. | ||
| 3. Choose "Add new rule". | ||
| 4. Enter a channel name or namespace pattern (e.g. `ai:*` for all channels starting with `ai:`). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| 4. Enter a channel name or namespace pattern (e.g. `ai:*` for all channels starting with `ai:`). | |
| 4. Enter a channel name or namespace pattern (e.g. `ai` for all channels starting with `ai:`). |
Do we need to check for other occurrences of this?
| 5. Select the "Message annotations, updates, deletes and appends" option from the list. | ||
| 6. Click "Create channel rule". | ||
|
|
||
| The examples in this guide use the `ai:` namespace prefix, which assumes you have configured the rule for `ai:*`. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| The examples in this guide use the `ai:` namespace prefix, which assumes you have configured the rule for `ai:*`. | |
| The examples in this guide use the `ai:` namespace prefix, which assumes you have configured the rule for `ai`. |
|
|
||
| ## Citation data model <a id="data-model"/> | ||
|
|
||
| Citations are implemented using [message annotations](/docs/messages/annotations). Each citation consists of an annotation type that determines how citations are aggregated into summaries, and a data payload containing the citation details. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| Citations are implemented using [message annotations](/docs/messages/annotations). Each citation consists of an annotation type that determines how citations are aggregated into summaries, and a data payload containing the citation details. | |
| Citations are implemented using [message annotations](/docs/messages/annotations). Each citation includes an annotation `type` that determines how citations are aggregated into summaries, and a `data` payload containing the citation details. |
| </Aside> | ||
|
|
||
| <Aside data-type="note"> | ||
| Identify the agent with a [`clientId`](/docs/messages#properties) in order to attribute citations to a specific agent. This is useful in multi-agent architectures where multiple agents may contribute citations to the same response. For more information, see [Agent identity](/docs/ai-transport/features/sessions-identity/identifying-users-and-agents#agent-identity). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| Identify the agent with a [`clientId`](/docs/messages#properties) in order to attribute citations to a specific agent. This is useful in multi-agent architectures where multiple agents may contribute citations to the same response. For more information, see [Agent identity](/docs/ai-transport/features/sessions-identity/identifying-users-and-agents#agent-identity). | |
| Identify the agent with a [`clientId`](/docs/messages#properties) in order to attribute a citation to a specific agent. This is useful in multi-agent architectures where multiple agents may contribute citations to the same response. For more information, see [Agent identity](/docs/ai-transport/features/sessions-identity/identifying-users-and-agents#agent-identity). |
Description
Misc. fixes and improvements to the citations docs page.
Checklist