modelmix
Version:
🧬 Reliable interface with automatic fallback for AI LLMs.
15 lines (12 loc) • 391 B
JavaScript
import { ModelMix } from '../index.js';
try { process.loadEnvFile(); } catch { }
const model = ModelMix.new()
.deepseekV4Flash()
.addText("Create exactly 5 characters for a narrative game.")
const jsonResult = await model.json([], [{
name: "character name",
role: "role in the story",
trait: "main trait",
goal: "short character goal"
}]);
console.log(jsonResult);