Class ChatResponse
java.lang.Object
io.github.easy4j.opencode.api.model.ChatResponse
OpenAI Chat Completions API response (aligned with OpenClaw/Hermes).
OpenCode internally returns PromptResult; the SDK automatically converts:
PromptResult.getTextContent() is mapped to choices[0].message.content.
- Since:
- 1.0.0
- Author:
- Loong Wan
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic class响应中的一个选择。static classToken 使用统计。 -
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
ChatResponse
public ChatResponse()
-
-
Method Details
-
getContent
快捷获取第一选择的消息内容。- Returns:
- 服务端或 CLI 返回的文本值;无内容时可能为空字符串
-