Seed Text Generation
Seed is ByteDance's large language model series with strong Chinese understanding and generation. It is fully OpenAI-compatible, so you can migrate existing OpenAI apps with zero code changes.
Endpoint
Seed provides two compatible endpoints. They behave identically — choose either:
- OpenAI-compatible:
POST $URL/v1/chat/completions - Volcengine native:
POST $URL/api/v3/chat/completions
When using the OpenAI SDK, set base_url to either $URL/v1 or $URL/api/v3.
Supported Models
| Model | Description |
|---|---|
seed-2.0-pro | Flagship, best overall capability |
seed-2.0-lite | Lightweight, high cost-efficiency |
seed-2.0-mini | Mini, extreme speed |
seed-2.1-pro | 2.1 flagship, enhanced reasoning & long context |
seed-2.1-turbo | 2.1 high-speed, low latency |
All models also support a
doubao-prefix (e.g.doubao-seed-2.0-pro); behavior is identical.
See the Console "Model Market" for more versions.
Parameters
| Param | Type | Required | Description |
|---|---|---|---|
model | string | yes | Model name above |
messages | array | yes | Conversation messages; each has role (system/user/assistant) and content |
stream | boolean | no | Stream the response, default false |
temperature | number | no | Sampling temperature 0–2, default 1 |
top_p | number | no | Nucleus sampling probability 0–1, default 1 |
max_tokens | integer | no | Max tokens to generate |
presence_penalty | number | no | Presence penalty −2–2, default 0 |
frequency_penalty | number | no | Frequency penalty −2–2, default 0 |
stop | string / array | no | Stop sequence(s) |
response_format | object | no | Force a specific output format (e.g. {"type":"json_object"}) |
Request Example
bash
curl $URL/v1/chat/completions \
-H "Authorization: Bearer $YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "seed-2.0-pro",
"messages": [
{"role": "user", "content": "Explain quantum computing in one sentence"}
]
}'python
from openai import OpenAI
client = OpenAI(api_key="YOUR_API_KEY", base_url="$URL/v1")
resp = client.chat.completions.create(
model="seed-2.0-pro",
messages=[{"role": "user", "content": "Explain quantum computing in one sentence"}],
)
print(resp.choices[0].message.content)ts
import OpenAI from 'openai'
const client = new OpenAI({
apiKey: process.env.YOUR_API_KEY,
baseURL: '$URL/v1',
})
const resp = await client.chat.completions.create({
model: 'seed-2.0-pro',
messages: [{ role: 'user', content: 'Explain quantum computing in one sentence' }],
})
console.log(resp.choices[0].message.content)Response Fields
| Field | Type | Description |
|---|---|---|
id | string | Unique request ID |
object | string | Always chat.completion |
created | integer | Creation timestamp (seconds) |
model | string | Model actually used |
choices | array | Candidate completions |
choices[].index | integer | Candidate index |
choices[].message | object | The message object |
choices[].message.role | string | Always assistant |
choices[].message.content | string | Reply text |
choices[].finish_reason | string | Stop reason (stop/length/content_filter etc.) |
usage | object | Token usage |
usage.prompt_tokens | integer | Input tokens |
usage.completion_tokens | integer | Output tokens |
usage.total_tokens | integer | Total tokens |
Response Example
json
{
"id": "chatcmpl-abc123",
"object": "chat.completion",
"created": 1700000000,
"model": "seed-2.0-pro",
"choices": [
{
"index": 0,
"message": {
"role": "assistant",
"content": "Quantum computing uses superposition and entanglement of qubits to process information in parallel, beating classical computers on certain problems."
},
"finish_reason": "stop"
}
],
"usage": {
"prompt_tokens": 12,
"completion_tokens": 38,
"total_tokens": 50
}
}