Represents a part of a ChatMessage that originates from a single action/tool. It is designed to support rich data formats beyond simple text, allowing for a more dynamic and interactive chat experience. Each fragment can include various types of content, such as text, search queries, action information, and more. Also, each ChatMessageFragment should only have one of structuredResults, querySuggestion, writeAction, followupAction, agentRecommendation, followupRoutingSuggestion or file.
| Field | Type | Required | Description | Example |
|---|---|---|---|---|
structured_results |
List[models.StructuredResult] | ➖ | An array of entities in the work graph retrieved via a data request. | |
tracking_token |
Optional[str] | ➖ | An opaque token that represents this particular result in this particular query. To be used for /feedback reporting. | |
text |
Optional[str] | ➖ | N/A | |
query_suggestion |
Optional[models.QuerySuggestion] | ➖ | N/A | { "query": "app:github type:pull author:mortimer", "label": "Mortimer's PRs", "datasource": "github" } |
file |
Optional[models.ChatFile] | ➖ | Structure for file uploaded by a user for Chat. | |
action |
Optional[models.ToolInfo] | ➖ | N/A | |
citation |
Optional[models.ChatMessageCitation] | ➖ | Information about the source for a ChatMessage. |