top_p
但不是两者。temperature
但不是两者。data: [DONE]
发送,流由消息终止。有关示例代码,请参阅 OpenAI Cookbook 。{
"model": "claude-3-7-sonnet-20250219-thinking",
"max_tokens": 1024,
"messages": [
{
"role": "user",
"content": "say 1"
}
],
"stream":false
}
curl --location --request POST '/v1/messages' \
--header 'Accept: application/json' \
--header 'Authorization: sk-L7fNKCciMifMrAeE25401dEd52A54669Bc832851C460D7Be' \
--header 'Authorization;' \
--header 'Content-Type: application/json' \
--data-raw '{
"model": "claude-3-7-sonnet-20250219-thinking",
"max_tokens": 1024,
"messages": [
{
"role": "user",
"content": "say 1"
}
],
"stream":false
}'
{
"id": "chatcmpl-123",
"object": "chat.completion",
"created": 1677652288,
"choices": [
{
"index": 0,
"message": {
"role": "assistant",
"content": "\n\nHello there, how may I assist you today?"
},
"finish_reason": "stop"
}
],
"usage": {
"prompt_tokens": 9,
"completion_tokens": 12,
"total_tokens": 21
}
}