ResponseApiRequest
@JsonIgnoreProperties(ignoreUnknown = true) public class ResponseApiRequest
io/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:28–312响应 API 请求,与模型服务通信并返回生成或向量化结果。位于 io.agentscope.runtime.protocol.responseapi.model 包。核心成员包括 getBackground、setBackground、getConversation、setConversation、getInclude、setInclude。
POJO for OpenAI Responses API request body.
方法摘要Method Summary
方法详情Method Detail
getBackground
public Boolean getBackground()
获取 getBackground。
Returns the background.
Booleanio/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:93–95setBackground
public void setBackground(Boolean background)
设置 setBackground。
Sets the background.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
background | Boolean | background(类型 `Boolean`)。The background. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:97–99getConversation
public Conversation getConversation()
获取会话。
Returns the conversation.
Conversationio/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:105–107setConversation
public void setConversation(Conversation conversation)
设置会话。
Sets the conversation.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
conversation | Conversation | 会话(类型 `Conversation`)。The conversation. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:109–111getInclude
public List<Object> getInclude()
获取 getInclude。
Returns the include.
List<Object>io/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:113–115setInclude
public void setInclude(List<Object> include)
设置 setInclude。
Sets the include.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
include | List<Object> | include(类型 `List`)。The include. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:117–119getInput
public Object getInput()
获取输入。
Returns the input.
Objectio/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:121–123setInput
public void setInput(Object input)
设置输入。
Sets the input.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
input | Object | 输入消息(类型 `Object`)。The input. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:125–127getInstructions
public String getInstructions()
获取指令。
Returns the instructions.
Stringio/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:129–131setInstructions
public void setInstructions(String instructions)
设置指令。
Sets the instructions.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
instructions | String | 指令(类型 `String`)。The instructions. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:133–135getMaxOutputTokens
public Integer getMaxOutputTokens()
获取最大输出令牌数。
Returns the max output tokens.
Integerio/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:137–139setMaxOutputTokens
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/ResponseApiRequest.java:141–143getMaxToolCalls
public Integer getMaxToolCalls()
获取最大工具调用。
Returns the max tool calls.
Integerio/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:145–147setMaxToolCalls
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/ResponseApiRequest.java:149–151getMetadata
public Map<String, Object> getMetadata()
获取元数据。
Returns the metadata.
Map<String, Object>io/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:153–155setMetadata
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/ResponseApiRequest.java:157–159getModel
public String getModel()
获取模型。
Returns the model.
Stringio/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:161–163setModel
public void setModel(String model)
设置模型。
Sets the model.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
model | String | 模型实例(类型 `String`)。The model. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:165–167getParallelToolCalls
public Boolean getParallelToolCalls()
获取 getParallelToolCalls。
Returns the parallel tool calls.
Booleanio/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:169–171setParallelToolCalls
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/ResponseApiRequest.java:173–175getPreviousResponseId
public String getPreviousResponseId()
获取上一个响应标识。
Returns the previous response id.
Stringio/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:177–179setPreviousResponseId
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/ResponseApiRequest.java:181–183getPrompt
public ResponsePrompt getPrompt()
获取提示词。
Returns the prompt.
ResponsePromptio/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:185–187setPrompt
public void setPrompt(ResponsePrompt prompt)
设置提示词。
Sets the prompt.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
prompt | ResponsePrompt | 提示词(类型 `ResponsePrompt`)。The prompt. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:189–191getPromptCacheKey
public String getPromptCacheKey()
获取提示词缓存键。
Returns the prompt cache key.
Stringio/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:193–195setPromptCacheKey
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/ResponseApiRequest.java:197–199getPromptCacheRetention
public String getPromptCacheRetention()
获取 getPromptCacheRetention。
Returns the prompt cache retention.
Stringio/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:201–203setPromptCacheRetention
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/ResponseApiRequest.java:205–207getReasoning
public ResponseReasoning getReasoning()
获取推理。
Returns the reasoning.
ResponseReasoningio/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:209–211setReasoning
public void setReasoning(ResponseReasoning reasoning)
设置推理。
Sets the reasoning.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
reasoning | ResponseReasoning | 推理(类型 `ResponseReasoning`)。The reasoning. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:213–215getSafetyIdentifier
public String getSafetyIdentifier()
获取 getSafetyIdentifier。
Returns the safety identifier.
Stringio/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:217–219setSafetyIdentifier
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/ResponseApiRequest.java:221–223getServiceTier
public String getServiceTier()
获取 getServiceTier。
Returns the service tier.
Stringio/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:225–227setServiceTier
public void setServiceTier(String serviceTier)
设置 setServiceTier。
Sets the service tier.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
serviceTier | String | 服务 Tier(类型 `String`)。The service tier. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:229–231getStore
public Boolean getStore()
获取存储。
Returns the store.
Booleanio/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:233–235setStore
public void setStore(Boolean store)
设置存储。
Sets the store.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
store | Boolean | 存储实例(类型 `Boolean`)。The store. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:237–239getStream
public Boolean getStream()
获取流。
Returns the stream.
Booleanio/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:241–243setStream
public void setStream(Boolean stream)
设置流。
Sets the stream.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
stream | Boolean | 流(类型 `Boolean`)。The stream. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:245–247getStreamOptions
public Object getStreamOptions()
获取流选项。
Returns the stream options.
Objectio/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:249–251setStreamOptions
public void setStreamOptions(Object streamOptions)
设置流选项。
Sets the stream options.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
streamOptions | Object | 流选项(类型 `Object`)。The stream options. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:253–255getTemperature
public float getTemperature()
获取 getTemperature。
Returns the temperature.
floatio/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:257–259setTemperature
public void setTemperature(float temperature)
设置 setTemperature。
Sets the temperature.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
temperature | float | temperature(类型 `float`)。The temperature. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:261–263getText
public Object getText()
获取文本。
Returns the text.
Objectio/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:265–267setText
public void setText(Object text)
设置文本。
Sets the text.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
text | Object | 文本(类型 `Object`)。The text. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:269–271getToolChoice
public Object getToolChoice()
获取工具选项。
Returns the tool choice.
Objectio/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:273–275setToolChoice
public void setToolChoice(Object toolChoice)
设置工具选项。
Sets the tool choice.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
toolChoice | Object | 工具选项(类型 `Object`)。The tool choice. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:277–279getTools
public List<Object> getTools()
获取工具。
Returns the tools.
List<Object>io/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:281–283setTools
public void setTools(List<Object> tools)
设置工具。
Sets the tools.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
tools | List<Object> | 工具列表(类型 `List`)。The tools. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:285–287getTopLogprobs
public Integer getTopLogprobs()
获取 getTopLogprobs。
Returns the top logprobs.
Integerio/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:289–291setTopLogprobs
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/ResponseApiRequest.java:293–295getTopP
public Integer getTopP()
获取 getTopP。
Returns the top p.
Integerio/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:297–299setTopP
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/ResponseApiRequest.java:301–303getTruncation
public String getTruncation()
获取 getTruncation。
Returns the truncation.
Stringio/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:305–307setTruncation
public void setTruncation(String truncation)
设置 setTruncation。
Sets the truncation.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
truncation | String | truncation(类型 `String`)。The truncation. |
io/agentscope/runtime/protocol/responseapi/model/ResponseApiRequest.java:309–311