Table of Contents

Enum ChatRole

Namespace
Glitch9.AIDevKit
public enum ChatRole

Fields

Assistant = 3

Messages sent by the model in response to user messages.

The Google equivalent for this role is 'model', and it is converted to 'assistant' with the JsonConverter.

System = 1
Tool = 4

Messages sent by the model. The message includes the function calls the model wants to make.
Google Gemini equivalent for this role is 'function', and it is converted to 'tool' with the JsonConverter.

[2025-04-12]
Important: OpenAI has deprecated this role for tool calls. These are replaced by 'tools' within assistant messages.
However, the role is still used for returning tool outputs from the client side to the model.

Unset = 0
User = 2

Messages sent by an end user, containing prompts or additional context information.