import OpenAI from "openai"
const openai = new OpenAI({
baseURL: "https://api.aiapilab.com/v1",
apiKey: $AIAPILAB_API_KEY
})
async function main() {
const completion = await openai.chat.completions.create({
model: "deepseek-coder",
messages: [
{
"role": "user",
"content": "Write a blog about cat."
}
]
})
console.log(completion.choices[0].message)
}
main()
Feature/Aspect | GPT-4 Turbo | CodeLlama-34B | DeepSeek V3 Coder |
---|---|---|---|
Availability | Available via OpenAI API and ChatGPT | Available via Hugging Face and API | Open-source, available via Hugging Face and GitHub |
Training Data | 1.5 trillion tokens (varied) | 1.8 trillion tokens (varied) | 2 trillion tokens (87% code, 13% natural language) |
Context Window | 8,000 tokens | 4,000 tokens | 16,000 tokens |
Model Size Options | 175B | 34B | 1.3B, 5.7B, 6.7B, 33B |
Supported Languages | 100+ programming languages | 80 programming languages | 338 programming languages |
Performance Benchmarks | Industry-leading in various benchmarks | Competitive but lower than DeepSeek V3 Coder | State-of-the-art on HumanEval, MBPP, DS-1000 |
Specialized Capabilities | Advanced reasoning, general coding, and writing tasks | General coding tasks | Project-level code completion, infilling, and bug detection |