Commit 6ce0afc
docs: add citations guide (#2267)
* docs: add citations guide
Add docs/features/citations.md covering the experimental citations
surface: enabling `enableCitations` on session create/resume in all six
SDKs, reading the `citations` payload from `assistant.message` events,
the payload/type reference, how to supply citable material via document
attachments or tool `citableSources`, and current limitations.
Link the new guide from the features index.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: 0c184f59-0104-4a89-a350-4096597a89b3
* docs: address review feedback on citations guide
* Fix UTF-16 span offset handling. Python slices by code point and Go
and Rust strings are UTF-8, so all three examples now convert the
content to UTF-16 code units before slicing. Corrected the
accompanying tip, which wrongly implied only non-BMP characters were
affected in Go and Rust.
* Replace the Rust example's raw JSON dump with a real span-to-source
walk using typed_data::<AssistantMessageData>(), matching the other
languages.
* Fall back through url, path, and id when a CitationSource has no
title, in the Java, .NET, Go, Python, and TypeScript examples.
* Narrow the image-input.md link descriptions, since that guide covers
image attachments rather than document support.
* Drop the "(experimental)" suffix from the features index entry; the
guide body still carries the experimental warning.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: 0c184f59-0104-4a89-a350-4096597a89b3
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: 0c184f59-0104-4a89-a350-4096597a89b31 parent 737551b commit 6ce0afc
2 files changed
Lines changed: 444 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
| 19 | + | |
19 | 20 | | |
20 | 21 | | |
21 | 22 | | |
| |||
0 commit comments