ResponseApiResponse
@JsonIgnoreProperties(ignoreUnknown = true) public class ResponseApiResponse
io/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:28–332响应 API 响应,与模型服务通信并返回生成或向量化结果。位于 io.agentscope.runtime.protocol.responseapi.model 包。核心成员包括 getBackground、setBackground、getConversation、setConversation、getCreatedAt、setCreatedAt。
POJO for Responses API response object.
方法摘要Method Summary
方法详情Method Detail
getBackground
public Boolean getBackground()
获取 getBackground。
Returns the background.
Booleanio/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:101–103setBackground
public void setBackground(Boolean background)
设置 setBackground。
Sets the background.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
background | Boolean | background(类型 `Boolean`)。The background. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:105–107getConversation
public Conversation getConversation()
获取会话。
Returns the conversation.
Conversationio/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:109–111setConversation
public void setConversation(Conversation conversation)
设置会话。
Sets the conversation.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
conversation | Conversation | 会话(类型 `Conversation`)。The conversation. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:113–115getCreatedAt
public Integer getCreatedAt()
获取已创建 At。
Returns the created at.
Integerio/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:117–119setCreatedAt
public void setCreatedAt(Integer createdAt)
设置已创建 At。
Sets the created at.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
createdAt | Integer | 已创建 At(类型 `Integer`)。The created at. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:121–123getError
public Error getError()
获取错误。
Returns the error.
Errorio/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:125–127setError
public void setError(Error error)
设置错误。
Sets the error.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
error | Error | 错误(类型 `Error`)。The error. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:129–131getId
public String getId()
获取标识。
Returns the id.
Stringio/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:133–135setId
public void setId(String id)
设置标识。
Sets the id.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
id | String | 标识(类型 `String`)。The id. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:137–139getIncompleteDetail
public IncompleteDetail getIncompleteDetail()
获取 getIncompleteDetail。
Returns the incomplete detail.
IncompleteDetailio/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:141–143setIncompleteDetail
public void setIncompleteDetail(IncompleteDetail incompleteDetail)
设置 setIncompleteDetail。
Sets the incomplete detail.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
incompleteDetail | IncompleteDetail | incomplete 详情(类型 `IncompleteDetail`)。The incomplete detail. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:145–147getInstructions
public Object getInstructions()
获取指令。
Returns the instructions.
Objectio/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:149–151setInstructions
public void setInstructions(Object instructions)
设置指令。
Sets the instructions.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
instructions | Object | 指令(类型 `Object`)。The instructions. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:153–155getMaxOutputTokens
public Integer getMaxOutputTokens()
获取最大输出令牌数。
Returns the max output tokens.
Integerio/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:157–159setMaxOutputTokens
public void setMaxOutputTokens(Integer maxOutputTokens)
设置最大输出令牌数。
Sets the max output tokens.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
maxOutputTokens | Integer | 最大输出令牌数(类型 `Integer`)。The max output tokens. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:161–163getMaxToolCalls
public Integer getMaxToolCalls()
获取最大工具调用。
Returns the max tool calls.
Integerio/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:165–167setMaxToolCalls
public void setMaxToolCalls(Integer maxToolCalls)
设置最大工具调用。
Sets the max tool calls.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
maxToolCalls | Integer | 最大工具调用(类型 `Integer`)。The max tool calls. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:169–171getMetadata
public Map<String, Object> getMetadata()
获取元数据。
Returns the metadata.
Map<String, Object>io/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:173–175setMetadata
public void setMetadata(Map<String, Object> metadata)
设置元数据。
Sets the metadata.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
metadata | Map<String, Object> | 元数据(类型 `Map`)。The metadata. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:177–179getModel
public String getModel()
获取模型。
Returns the model.
Stringio/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:181–183setModel
public void setModel(String model)
设置模型。
Sets the model.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
model | String | 模型实例(类型 `String`)。The model. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:185–187getObject
public String getObject()
获取对象。
Returns the object.
Stringio/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:189–191setObject
public void setObject(String object)
设置对象。
Sets the object.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
object | String | 对象(类型 `String`)。The object. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:193–195getOutput
public List<OutputMessage> getOutput()
获取输出。
Returns the output.
List<OutputMessage>io/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:197–199setOutput
public void setOutput(List<OutputMessage> output)
设置输出。
Sets the output.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
output | List<OutputMessage> | 输出(类型 `List`)。The output. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:201–203getParallelToolCalls
public Boolean getParallelToolCalls()
获取 getParallelToolCalls。
Returns the parallel tool calls.
Booleanio/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:205–207setParallelToolCalls
public void setParallelToolCalls(Boolean parallelToolCalls)
设置 setParallelToolCalls。
Sets the parallel tool calls.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
parallelToolCalls | Boolean | parallel 工具调用(类型 `Boolean`)。The parallel tool calls. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:209–211getPreviousResponseId
public String getPreviousResponseId()
获取上一个响应标识。
Returns the previous response id.
Stringio/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:213–215setPreviousResponseId
public void setPreviousResponseId(String previousResponseId)
设置上一个响应标识。
Sets the previous response id.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
previousResponseId | String | 上一个响应标识(类型 `String`)。The previous response id. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:217–219getPrompt
public ResponsePrompt getPrompt()
获取提示词。
Returns the prompt.
ResponsePromptio/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:221–223setPrompt
public void setPrompt(ResponsePrompt prompt)
设置提示词。
Sets the prompt.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
prompt | ResponsePrompt | 提示词(类型 `ResponsePrompt`)。The prompt. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:225–227getPromptCacheKey
public String getPromptCacheKey()
获取提示词缓存键。
Returns the prompt cache key.
Stringio/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:229–231setPromptCacheKey
public void setPromptCacheKey(String promptCacheKey)
设置提示词缓存键。
Sets the prompt cache key.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
promptCacheKey | String | 提示词缓存键(类型 `String`)。The prompt cache key. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:233–235getPromptCacheRetention
public String getPromptCacheRetention()
获取 getPromptCacheRetention。
Returns the prompt cache retention.
Stringio/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:237–239setPromptCacheRetention
public void setPromptCacheRetention(String promptCacheRetention)
设置 setPromptCacheRetention。
Sets the prompt cache retention.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
promptCacheRetention | String | 提示词缓存 Retention(类型 `String`)。The prompt cache retention. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:241–243getReasoning
public ResponseReasoning getReasoning()
获取推理。
Returns the reasoning.
ResponseReasoningio/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:245–247setReasoning
public void setReasoning(ResponseReasoning reasoning)
设置推理。
Sets the reasoning.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
reasoning | ResponseReasoning | 推理(类型 `ResponseReasoning`)。The reasoning. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:249–251getSafetyIdentifier
public String getSafetyIdentifier()
获取 getSafetyIdentifier。
Returns the safety identifier.
Stringio/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:253–255setSafetyIdentifier
public void setSafetyIdentifier(String safetyIdentifier)
设置 setSafetyIdentifier。
Sets the safety identifier.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
safetyIdentifier | String | safety Identifier(类型 `String`)。The safety identifier. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:257–259getStatus
public String getStatus()
获取状态。
Returns the status.
Stringio/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:261–263setStatus
public void setStatus(String status)
设置状态。
Sets the status.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
status | String | 状态(类型 `String`)。The status. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:265–267getTemperature
public Integer getTemperature()
获取 getTemperature。
Returns the temperature.
Integerio/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:269–271setTemperature
public void setTemperature(Integer temperature)
设置 setTemperature。
Sets the temperature.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
temperature | Integer | temperature(类型 `Integer`)。The temperature. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:273–275getText
public ResponseText getText()
获取文本。
Returns the text.
ResponseTextio/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:277–279setText
public void setText(ResponseText text)
设置文本。
Sets the text.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
text | ResponseText | 文本(类型 `ResponseText`)。The text. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:281–283getToolChoice
public Object getToolChoice()
获取工具选项。
Returns the tool choice.
Objectio/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:285–287setToolChoice
public void setToolChoice(Object toolChoice)
设置工具选项。
Sets the tool choice.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
toolChoice | Object | 工具选项(类型 `Object`)。The tool choice. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:289–291getTools
public List<Object> getTools()
获取工具。
Returns the tools.
List<Object>io/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:293–295setTools
public void setTools(List<Object> tools)
设置工具。
Sets the tools.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
tools | List<Object> | 工具列表(类型 `List`)。The tools. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:297–299getTopLogprobs
public Integer getTopLogprobs()
获取 getTopLogprobs。
Returns the top logprobs.
Integerio/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:301–303setTopLogprobs
public void setTopLogprobs(Integer topLogprobs)
设置 setTopLogprobs。
Sets the top logprobs.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
topLogprobs | Integer | top Logprobs(类型 `Integer`)。The top logprobs. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:305–307getTopP
public Integer getTopP()
获取 getTopP。
Returns the top p.
Integerio/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:309–311setTopP
public void setTopP(Integer topP)
设置 setTopP。
Sets the top p.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
topP | Integer | top P(类型 `Integer`)。The top p. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:313–315getTruncation
public String getTruncation()
获取 getTruncation。
Returns the truncation.
Stringio/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:317–319setTruncation
public void setTruncation(String truncation)
设置 setTruncation。
Sets the truncation.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
truncation | String | truncation(类型 `String`)。The truncation. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:321–323getUsage
public ResponseUsage getUsage()
获取用量。
Returns the usage.
ResponseUsageio/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:325–327setUsage
public void setUsage(ResponseUsage usage)
设置用量。
Sets the usage.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
usage | ResponseUsage | 用量(类型 `ResponseUsage`)。The usage. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiResponse.java:329–331