Search Results for

    Show / Hide Table of Contents

    Class CohereChatResponse

    Inheritance
    object
    CohereChatResponse
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: Glitch9.AIDevKit.Cohere
    Assembly: Glitch9.AIDevKit.Provider.Cohere.dll
    Syntax
    public sealed class CohereChatResponse

    Properties

    | Edit this page View Source

    FinishReason

    The reason a chat request has finished.

    complete: The model finished sending a complete message.
    max_tokens: The number of generated tokens exceeded the model???context length or the value specified via the max_tokens parameter.
    stop_sequence: One of the provided stop_sequence entries was reached in the model???generation.
    tool_call: The model generated a Tool Call and is expecting a Tool Message in return
    error: The generation failed due to an internal error
    timeout: The generation was stopped because it exceeded the allowed time limit.

    Declaration
    [JsonProperty("finish_reason")]
    public FinishReason FinishReason { get; set; }
    Property Value
    Type Description
    FinishReason
    | Edit this page View Source

    Id

    Unique identifier for the generated reply. Useful for submitting feedback.

    Declaration
    [JsonProperty("id")]
    public string Id { get; set; }
    Property Value
    Type Description
    string
    | Edit this page View Source

    Logprobs

    Declaration
    [JsonProperty("logprobs")]
    public CohereLogProbs Logprobs { get; set; }
    Property Value
    Type Description
    CohereLogProbs
    | Edit this page View Source

    Message

    A message from the assistant role can contain text and tool call information.

    Declaration
    [JsonProperty("message")]
    public Message Message { get; set; }
    Property Value
    Type Description
    Message
    | Edit this page View Source

    Usage

    Declaration
    [JsonProperty("usage")]
    public CohereUsage Usage { get; set; }
    Property Value
    Type Description
    CohereUsage

    Extension Methods

    ArrayExtensions.ToArrayOrEmpty<T>(T)
    ArrayExtensions.ToArrayOrNull<T>(T)
    EventExtensions.ToDelta<T>(T, string, int, string, bool)
    EventExtensions.ToDone<T>(T, string, int, string)
    EventExtensions.ToEvent<T>(T)
    EventExtensions.UpcastDelta<T1, T2>(T1, string, int, string, bool)
    FallbackExtensions.IsOr<TParent, TChild>(TParent, TChild)
    ResponseCastingExtensions.GetResult<T>(T)
    SystemExtensions.GetName(object)
    • Edit this page
    • View Source
    In this article
    Back to top AI DevKit Documentation