ข้ามไปยังเนื้อหา

CogVideoX-5B

ผสานการทำงาน

ID โมเดล cogvideox-5b
# Run the model; wait up to 20 s for the finished result in the same call
curl -X POST "https://api.doitong.com/v1/run/cogvideox-5b?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "prompt": "A red fox trots through fresh snow at sunrise, soft golden light, shallow depth of field"
  }'

# Still "queued" or "running"? Poll with the id from the response:
curl "https://api.doitong.com/v1/requests/REQUEST_ID?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY"

คำขอนี้: $0.20 200 เครดิต API เรียกใช้ในหน้านี้

รับคีย์ API

การสร้างวิดีโอจากข้อความด้วย CogVideoX-5B รองรับ LoRA และปรับอัตราเฟรมได้

Zhipu AI · วิดีโอ

ผลลัพธ์แรกของคุณจะแสดงที่นี่

สร้างคำขอด้านล่างและเรียกใช้ด้วยคีย์ API ของคุณ เอาต์พุตจะถูกคัดลอกไปยังพื้นที่จัดเก็บของเรา และเก็บไว้ตลอดไปหรือฟรี 7 วัน

สร้างคำขอ

ตัวควบคุมสร้างจากสคีมาของโมเดล โค้ดและราคาจะอัปเดตเมื่อคุณเปลี่ยนค่า

•จำเป็น

พรอมต์ที่ใช้เป็นพื้นฐานสำหรับการสร้างวิดีโอ

ขั้นสูง negative_prompt · video_size · num_inference_steps · guidance_scale · export_fps · seed · use_rife · enable_safety_checker · loras
ค่าเริ่มต้น

พรอมต์เชิงลบสำหรับการสร้างวิดีโอ

video_size ค่าเริ่มต้น {"height":480,"width"...

ขนาดของวิดีโอที่สร้างขึ้น

ค่าเริ่มต้น 50

จำนวนขั้นตอน inference ที่ต้องดำเนินการ

ค่าเริ่มต้น 7

การยึดตามพรอมต์เมื่อโมเดลค้นหาวิดีโอที่เกี่ยวข้องเพื่อแสดง โดยแสดงผ่านสเกล CFG (Classifier Free Guidance)

ค่าเริ่มต้น 16

อัตราเฟรมเป้าหมายของวิดีโอในหน่วย FPS

Seed สำหรับการสร้างวิดีโอซ้ำ การสร้างซ้ำให้เหมือนเดิมทุกครั้งต้องคงเวอร์ชันโมเดล พรอมต์ และ seed เดิมไว้

ค่าเริ่มต้น []

ระบุ LoRA เดียวสำหรับการสร้างรูปภาพ ขณะนี้ยังไม่รองรับ LoRA หลายรายการ

POST /run/cogvideox-5b?wait=20 ใบเสนอราคา → $0.20
# Run the model; wait up to 20 s for the finished result in the same call
curl -X POST "https://api.doitong.com/v1/run/cogvideox-5b?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "prompt": "A red fox trots through fresh snow at sunrise, soft golden light, shallow depth of field"
  }'

# Still "queued" or "running"? Poll with the id from the response:
curl "https://api.doitong.com/v1/requests/REQUEST_ID?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY"

เรียกใช้คำขอนี้

คีย์ของคุณจะอยู่ในเบราว์เซอร์นี้ โดยส่งไปยัง Doitong API เท่านั้น และจะบันทึกใน localStorage ก็ต่อเมื่อคุณเลือกจดจำ รับคีย์ API

เกี่ยวกับ CogVideoX-5B

สร้างวิดีโอสั้นจากข้อความ `prompt` เลือกค่าที่กำหนดไว้ล่วงหน้าของ `video_size` เช่น square_hd หรือ landscape_16_9 ตั้ง `num_inference_steps` (1 ถึง 50) และ `guidance_scale` (0 ถึง 20) และเพิ่ม `negative_prompt` ได้ `export_fps` มีค่าตั้งแต่ 4 ถึง 32 การอินเตอร์โพเลชัน RIFE เปิดใช้งานเป็นค่าเริ่มต้น และสามารถใช้ LoRA ได้ 1 รายการ

พารามิเตอร์

ชื่อประเภท ค่าเริ่มต้นค่าที่อนุญาต คำอธิบาย
promptจำเป็น
ประเภทstring
พรอมต์ที่ใช้เป็นพื้นฐานสำหรับการสร้างวิดีโอ
video_sizeไม่บังคับ
ประเภทobject
ค่าเริ่มต้น{"height":480,"width":720}
square_hdsquareportrait_4_3portrait_16_9landscape_4_3landscape_16_9
ขนาดของวิดีโอที่สร้างขึ้น
negative_promptไม่บังคับ
ประเภทstring
ค่าเริ่มต้น
พรอมต์เชิงลบสำหรับการสร้างวิดีโอ
lorasไม่บังคับ
ประเภทobject[]
ค่าเริ่มต้น[]
ระบุ LoRA เดียวสำหรับการสร้างรูปภาพ ขณะนี้ยังไม่รองรับ LoRA หลายรายการ
loras[].pathจำเป็น
ประเภทstring
ตำแหน่งของน้ำหนัก LoRA ระบุเป็น URL หรือพาธ
loras[].scaleไม่บังคับ
ประเภทnumber
ค่าเริ่มต้น1
0 – 4
ตัวคูณที่ใช้กับน้ำหนัก LoRA ก่อนผสานเข้ากับโมเดลพื้นฐาน
num_inference_stepsไม่บังคับ
ประเภทinteger
ค่าเริ่มต้น50
1 – 50
จำนวนขั้นตอน inference ที่ต้องดำเนินการ
seedไม่บังคับ
ประเภทinteger | null
Seed สำหรับการสร้างวิดีโอซ้ำ การสร้างซ้ำให้เหมือนเดิมทุกครั้งต้องคงเวอร์ชันโมเดล พรอมต์ และ seed เดิมไว้
guidance_scaleไม่บังคับ
ประเภทnumber
ค่าเริ่มต้น7
0 – 20
การยึดตามพรอมต์เมื่อโมเดลค้นหาวิดีโอที่เกี่ยวข้องเพื่อแสดง โดยแสดงผ่านสเกล CFG (Classifier Free Guidance)
use_rifeไม่บังคับ
ประเภทboolean
ค่าเริ่มต้นtrue
เปิดใช้การแทรกเฟรมวิดีโอด้วย RIFE
export_fpsไม่บังคับ
ประเภทinteger
ค่าเริ่มต้น16
4 – 32
อัตราเฟรมเป้าหมายของวิดีโอในหน่วย FPS
enable_safety_checkerไม่บังคับ
ประเภทboolean
ค่าเริ่มต้นtrue
สามารถผ่อนปรนการคัดกรองได้โดยตั้งค่าเป็น false หากผู้เรียกมีสิทธิ์
จำเป็น

เอาต์พุต

GET /requests/req_8k2m4q7x1z9c3v5b6n0p2r4t
{
  "id": "req_8k2m4q7x1z9c3v5b6n0p2r4t",
  "object": "request",
  "model": "cogvideox-5b",
  "status": "succeeded",
  "created_at": "2026-10-20T12:00:00Z",
  "started_at": "2026-10-20T12:00:02Z",
  "completed_at": "2026-10-20T12:00:09Z",
  "queue_position": null,
  "cost": {
    "credits": 200,
    "usd": "0.20",
    "charged": 200,
    "refunded": 0
  },
  "input": {
    "prompt": "A red fox trots through fresh snow at sunrise, soft golden light, shallow depth of field"
  },
  "output": {
    "video": {
      "url": "https://content.doitong.com/dev-api/2026/10/20/req_8k2m4q7x1z9c3v5b6n0p2r4t/0-output.mp4",
      "content_type": "video/mp4",
      "file_name": "0-output.mp4",
      "file_size": 1843200
    },
    "timings": {},
    "seed": 42,
    "prompt": "string"
  },
  "outputs": [
    {
      "type": "video",
      "url": "https://content.doitong.com/dev-api/2026/10/20/req_8k2m4q7x1z9c3v5b6n0p2r4t/0-output.mp4",
      "content_type": "video/mp4",
      "file_size": 1843200,
      "width": 1280,
      "height": 720,
      "duration": 5,
      "stored": true
    }
  ],
  "error": null,
  "metrics": {
    "inference_seconds": 6.8
  },
  "urls": {
    "self": "https://api.doitong.com/v1/requests/req_8k2m4q7x1z9c3v5b6n0p2r4t",
    "cancel": "https://api.doitong.com/v1/requests/req_8k2m4q7x1z9c3v5b6n0p2r4t/cancel"
  }
}
ไฟล์ของคุณ คุณเลือกเองทุก outputs[].url คือสำเนาบนพื้นที่จัดเก็บของเรา: เก็บไว้ตลอดไป (คิดค่าบริการต่อ GB-เดือน) หรือฟรี 7 วัน โดยกำหนดได้ในการตั้งค่าบัญชีหรือ ?storage=
รูปแบบเดียวกันในทุกโมเดลtype, url, content_type, width, height และ duration สำหรับภาพ วิดีโอ และเสียงเหมือนกันทั้งหมด ส่วน output คือออบเจ็กต์ผลลัพธ์ของโมเดลเอง
ฟิลด์ของเอาต์พุต
video
object {url, content_type, file_name, file_size}URL ที่ชี้ไปยังวิดีโอที่สร้างขึ้น
timings
object
seed
integerSeed จริงที่ใช้สร้างวิดีโอ รวมถึงค่าที่สุ่มเลือกเมื่ออินพุตไม่ได้ระบุ seed มิฉะนั้นจะตรงกับ seed อินพุต
prompt
stringพรอมต์ที่ใช้สร้างวิดีโอ

โมเดลเพิ่มเติม: ข้อความเป็นวิดีโอ

สำหรับเอเจนต์ AI: หน้า Markdown นี้อยู่ที่ https://doitong.com/th/developers/models/cogvideox-5b.md. โมเดลและคู่มือทั้งหมด: https://doitong.com/developers/llms.txt