DeepSeekText Generation Model

    DeepSeek V4 Flash

    The efficient tier of DeepSeek's open-weight V4 family: a sparse Mixture-of-Experts that activates only a small fraction of its parameters per token, with a 1M-token context and selectable reasoning effort. Frontier-adjacent quality at a fraction of frontier cost.

    import OpenAI from "openai";
    
    const openai = new OpenAI({
      baseURL: "https://api.inference.net/v1",
      apiKey: "<YOUR_API_KEY>",
    });
    
    const completion = await openai.chat.completions.create({
      model: "deepseek-v4-flash",
      messages: [
        {
          role: "user",
          content: "What is the meaning of life?"
        }
      ],
      stream: true,
    });
    
    for await (const chunk of completion) {
      process.stdout.write(chunk.choices[0]?.delta.content as string);
    }

    Start building with DeepSeek V4 Flash today

    Serverless, OpenAI-compatible, and billed per token. No commitments.