代码拉取完成,页面将自动刷新
package claude
// CompletionResponse is the response from the Anthropic API for a completion request.
type CompletionResponse struct {
Completion string `json:"completion"`
StopReason string `json:"stop_reason"`
Stop string `json:"stop"`
}
// StreamResponse is the response from the Anthropic API for a stream of completions.
type StreamResponse struct {
Completion string `json:"completion"`
StopReason string `json:"stop_reason"`
Model string `json:"model"`
Stop string `json:"stop"`
LogID string `json:"log_id"`
}
// MessageResponse is a subset of the response from the Anthropic API for a message response.
type MessagePartResponse struct {
Type string `json:"type"`
Text string `json:"text"`
// Optional fields, only present for tools responses
ID string `json:"id,omitempty"`
Name string `json:"name,omitempty"`
Input map[string]interface{} `json:"input,omitempty"`
}
// MessageResponse is the response from the Anthropic API for a message response.
type MessageResponse struct {
ID string `json:"id"`
Type string `json:"type"`
Model string `json:"model"`
Role string `json:"role"`
Content []MessagePartResponse `json:"content"`
StopReason string `json:"stop_reason"`
Stop string `json:"stop"`
StopSequence string `json:"stop_sequence"`
Usage MessageUsage `json:"usage"`
}
type MessageUsage struct {
InputTokens int `json:"input_tokens"`
OutputTokens int `json:"output_tokens"`
}
type MessageStreamResponse struct {
Type string `json:"type"`
Delta MessageStreamDelta `json:"delta"`
Usage MessageStreamUsage `json:"usage"`
}
type MessageStreamDelta struct {
Type string `json:"type"`
Text string `json:"text"`
StopReason string `json:"stop_reason"`
StopSequence string `json:"stop_sequence"`
}
type MessageStreamUsage struct {
InputTokens int `json:"input_tokens"`
OutputTokens int `json:"output_tokens"`
}
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。