Skip to main content
POST
Chat completion: DeepSeek V4 Flash text generation
오른쪽의 플레이그라운드를 사용해 직접 테스트하십시오. Bearer sk-your-api-keyAuthorization에 넣으십시오. 기본 예시에서는 이미 심층 추론을 비활성화합니다 (thinking.disabled), 따라서 전송 시 빠른 응답을 받습니다.
이 모델은 기본적으로 많이 추론합니다 — 한 줄 질문에도 먼저 수백 개의 reasoning token을 출력합니다. 디버깅하는 동안 예시의 "thinking": {"type": "disabled"}를 유지하십시오. 기능, 과금 및 캐싱에 대해서는 DeepSeek V4 Flash 개요를 참고하십시오.
  • 추론이 켜져 있을 때는 max_tokens에 여유를 두십시오(추론은 출력 쿼터에 포함됩니다) — 3000+를 권장합니다
  • response_format는 영향을 주지 않습니다: json_schema를 전달하면 스키마를 완전히 무시한 채 200을 반환합니다. 구조화된 출력에는 tools를 사용하십시오
  • n는 조용히 무시됩니다: n=2를 전달하면 choices에 정확히 하나의 요소가 들어 있는 상태로 200을 반환합니다
  • 텍스트 전용 모델 — 이미지 콘텐츠 블록을 전달하면 Model do not support image input를 반환합니다

매개변수 빠른 참조

컨텍스트 및 출력 상한

322,055-token 입력이 문서 중간의 needle이 올바르게 검색된 상태로 14.77초 만에 반환되었습니다.

암시적 캐시

추가 매개변수는 필요 없습니다 — 동일한 긴 접두사는 두 번째 요청에서 적중합니다: 캐시된 token은 백만 개당 $0.028로 과금됩니다. 타임스탬프, 랜덤 ID 및 기타 가변 콘텐츠는 prompt의 끝에 두세요 — 이를 접두사에 섞으면 적중률이 0으로 떨어집니다.

구조화된 출력이 필요하십니까? 도구를 사용하십시오

choices[0].message.tool_calls[0].function.arguments에서 JSON 문자열을 사용하십시오 — 안정적으로 파싱됩니다.

인증

Authorization
string
header
필수

API Key obtained from the APIYI console

본문

application/json
model
enum<string>
기본값:deepseek-v4-flash-ga-260731
필수

Model ID, fixed to deepseek-v4-flash-ga-260731

사용 가능한 옵션:
deepseek-v4-flash-ga-260731
messages
object[]
필수

Message array in standard OpenAI format. Text only — image content blocks are not supported

max_tokens
integer
기본값:500

Max output tokens, hard ceiling 393,216. Reasoning counts toward this when thinking is on

필수 범위: x <= 393216
thinking
object

Deep thinking switch. Passing {"type": "disabled"} saved 200+ reasoning tokens on simple tasks in our tests

reasoning_effort
enum<string>

Reasoning depth tier. Only minimal is deterministic (reasoning tokens always 0); low/medium/high/max do not form a monotonic ladder, and within-tier variance exceeds between-tier differences

사용 가능한 옵션:
minimal,
low,
medium,
high,
max
stream
boolean
기본값:false

Stream the response over SSE. Pair with stream_options.include_usage to get usage at the end

temperature
number

Sampling temperature

top_p
number

Nucleus sampling threshold

stop
string[]

Stop sequences, verified to truncate correctly

seed
integer

Random seed

logprobs
boolean

Return token log probabilities, verified to be populated

tools
object[]

Function Call tool list in standard OpenAI format. Tool arguments are genuinely constrained — use this instead of response_format when you need structured output

응답

Completion succeeded

id
string

Request ID

model
string
choices
object[]

Completion results. Besides content, message carries reasoning_content when thinking is on

usage
object

Usage. completion_tokens_details.reasoning_tokens is reasoning spend; prompt_tokens_details.cached_tokens is the implicit cache hit