All Downloads are FREE. Search and download functionalities are using the official Maven repository.

cn.homj.autogen4j.support.openai.chat.Choice Maven / Gradle / Ivy

The newest version!
package cn.homj.autogen4j.support.openai.chat;

import com.alibaba.fastjson2.annotation.JSONField;

import cn.homj.autogen4j.support.Message;
import lombok.Data;

/**
 * @author jiehong.jh
 * @date 2023/11/23
 */
@Data
public class Choice {
    /**
     * This index of this completion in the returned list.
     */
    private Integer index;
    /**
     * The assistant message or delta (when streaming) which was generated
     */
    @JSONField(alternateNames = "delta")
    private Message message;
    /**
     * The reason the model stopped generating tokens.
     * 
    *
  • stop: if the model hit a natural stop point or a provided stop sequence
  • *
  • length: if the maximum number of tokens specified in the request was reached
  • *
  • content_filter: if content was omitted due to a flag from our content filters
  • *
  • tool_calls: if the model called a tool
  • *
*/ @JSONField(name = "finish_reason") private String finishReason; }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy