{"version":"e14614f340a2","source":"src/model-hub.jsx","code":"({ h: createElement, Fragment: __Fragment, useState, useEffect, useRef, useMemo, fetchData, now: clock = Date.now }) => {\n  // Text sets its quotes and apostrophes as curly ones, the way Mintlify sets\n  // page text. Code keeps them as typed.\n  const AS_TYPED = new Set(['code', 'pre', 'kbd', 'samp', 'textarea']);\n  const typeset = text => text\n    .replace(/(\\w)'(?=\\w)/g, '$1\\u2019')\n    .replace(/(s)'(?=$|[\\s.,;:!?)\\]])/g, '$1\\u2019')\n    .replace(/(^|[\\s([{\\u2013\\u2014])'/g, '$1\\u2018')\n    .replace(/'/g, '\\u2019')\n    .replace(/(^|[\\s([{\\u2013\\u2014])\"/g, '$1\\u201c')\n    .replace(/\"/g, '\\u201d');\n  const __jsx = (type, props, ...kids) => (type === __Fragment || (typeof type === 'string' && !AS_TYPED.has(type))\n    ? createElement(type, props, ...kids.map(kid => (typeof kid === 'string' && /['\"]/.test(kid) ? typeset(kid) : kid)))\n    : createElement(type, props, ...kids));\n\n  /* ------------------------------------------------------------ data */\n\n  const CATALOG_PATH = '/data/model-catalog.json';\n  const API = 'https://api.venice.ai/api/v1';\n  const store = { catalog: null, promise: null };\n\n  const loadCatalog = () => {\n    if (store.catalog) return Promise.resolve(store.catalog);\n    if (store.promise) return store.promise;\n    store.promise = fetchData(CATALOG_PATH)\n      .then(catalog => { store.catalog = catalog; return catalog; })\n      .catch(err => { store.promise = null; throw err; });\n    return store.promise;\n  };\n\n  const useCatalog = () => {\n    const [state, setState] = useState({ catalog: store.catalog, error: null });\n    useEffect(() => {\n      if (state.catalog) return undefined;\n      let alive = true;\n      loadCatalog()\n        .then(catalog => alive && setState({ catalog, error: null }))\n        .catch(error => alive && setState({ catalog: null, error }));\n      return () => { alive = false; };\n    }, []);\n    return state;\n  };\n\n  // Performance figures change every hour, so model pages load them rather\n  // than carry them in their data.\n  const PERFORMANCE_PATH = '/data/model-performance.json';\n  const performanceStore = { data: null, promise: null };\n\n  const loadPerformance = () => {\n    if (performanceStore.data) return Promise.resolve(performanceStore.data);\n    if (performanceStore.promise) return performanceStore.promise;\n    performanceStore.promise = fetchData(PERFORMANCE_PATH)\n      .then(data => { performanceStore.data = data; return data; })\n      .catch(err => { performanceStore.promise = null; throw err; });\n    return performanceStore.promise;\n  };\n\n  const usePerformance = () => {\n    const [state, setState] = useState({ data: performanceStore.data, failed: false });\n    useEffect(() => {\n      if (state.data) return undefined;\n      let alive = true;\n      loadPerformance()\n        .then(data => alive && setState({ data, failed: false }))\n        .catch(() => alive && setState({ data: null, failed: true }));\n      return () => { alive = false; };\n    }, []);\n    return state;\n  };\n\n  const useNow = () => useState(() => (typeof clock === 'function' ? clock() : clock))[0];\n\n  const readParams = () => (typeof window === 'undefined' ? new URLSearchParams() : new URLSearchParams(window.location.search));\n  const listParam = (params, key) => (params.get(key) ? params.get(key).split(',').filter(Boolean) : []);\n  const writeParams = updates => {\n    if (typeof window === 'undefined') return;\n    const params = readParams();\n    Object.entries(updates).forEach(([key, value]) => {\n      const empty = value == null || value === '' || value === false || (Array.isArray(value) && !value.length);\n      if (empty) params.delete(key);\n      else params.set(key, Array.isArray(value) ? value.join(',') : String(value));\n    });\n    const qs = params.toString();\n    window.history.replaceState(window.history.state, '', `${window.location.pathname}${qs ? `?${qs}` : ''}${window.location.hash}`);\n  };\n\n  // Links from API data open only as http(s); anything else, such as a\n  // javascript: URL, is dropped.\n  const safeUrl = value => {\n    try {\n      const url = new URL(String(value || ''));\n      return url.protocol === 'https:' || url.protocol === 'http:' ? url.href : null;\n    } catch (e2) {\n      return null;\n    }\n  };\n  const weightsName = href => {\n    const { hostname, pathname } = new URL(href);\n    const path = pathname.replace(/^\\/+|\\/+$/g, '');\n    return hostname === 'huggingface.co' && path ? path : [hostname, path].filter(Boolean).join('/');\n  };\n\n  const copyText = text => {\n    if (typeof navigator !== 'undefined' && navigator.clipboard) return navigator.clipboard.writeText(text).catch(() => {});\n    return Promise.resolve();\n  };\n\n  /* ------------------------------------------------------------ vocabulary */\n\n  const MODALITIES = [\n    { key: 'text', label: 'Text', path: '/models/text' },\n    { key: 'image', label: 'Image', path: '/models/image' },\n    { key: 'video', label: 'Video', path: '/models/video' },\n    { key: 'audio', label: 'Audio', path: '/models/text-to-speech' },\n    { key: 'embedding', label: 'Embeddings', path: '/models/embeddings' }\n  ];\n  // The explorer's modality facet, checkboxes as in Gordon's design; none\n  // checked shows every modality. Each family has one key: audio splits by\n  // task and decision models stand apart from chat.\n  const SCOPES = [\n    { key: 'text', label: 'Text' }, { key: 'image', label: 'Image' }, { key: 'video', label: 'Video' },\n    { key: 'tts', label: 'Text to speech', short: 'Speech' }, { key: 'stt', label: 'Speech to text', short: 'Transcription' },\n    { key: 'music', label: 'Music & sound effects', short: 'Music' },\n    { key: 'embedding', label: 'Embeddings' }, { key: 'decision', label: 'Decisions' }\n  ];\n  const AUDIO_SCOPES = ['tts', 'stt', 'music'];\n  const familyScope = family => {\n    if (family.modality === 'text') return family.task === 'decision' ? 'decision' : 'text';\n    if (family.modality === 'audio') return family.task === 'sfx' ? 'music' : family.task;\n    return family.modality;\n  };\n  const initialScope = (modality, task) => (modality === 'all' ? null : modality === 'audio' ? task || 'tts' : modality);\n  // `m` names the chosen modality; `all` or nothing valid means All. Links from\n  // when several could be checked open on the first one they list.\n  const parseScope = value => String(value || '').split(',').find(key => SCOPES.some(s => s.key === key)) || null;\n  const VIEWS = ['list', 'table', 'grid'];\n  const PAGE_SIZE = 60;\n  const defaultView = modality => (modality === 'image' || modality === 'video' ? 'grid' : 'list');\n  const TASK_LABELS = {\n    chat: 'Chat', decision: 'Decisions', 'image-generation': 'Image generation', 'image-edit': 'Image editing',\n    'image-upscale': 'Upscaling', 'background-removal': 'Background removal', video: 'Video',\n    tts: 'Text to speech', stt: 'Speech to text', music: 'Music', sfx: 'Sound effects', embedding: 'Embeddings'\n  };\n  const VARIANT_LABELS = {\n    standard: 'Standard', fast: 'Fast', e2ee: 'E2EE', tee: 'TEE', generate: 'Generate', edit: 'Edit', upscale: 'Upscale',\n    'background-removal': 'Background removal', t2v: 'Text to video', i2v: 'Image to video', r2v: 'Reference to video',\n    flf: 'First & last frame', v2v: 'Video edit', motion: 'Motion control', transition: 'Transition', 'multi-angle': 'Multi-angle'\n  };\n  const MODE_SHORT = { t2v: 'T2V', i2v: 'I2V', r2v: 'R2V', flf: 'Keyframes', v2v: 'Edit', motion: 'Motion', transition: 'Transition', 'multi-angle': 'Multi-angle', upscale: 'Upscale' };\n  const PRIVACY = {\n    e2ee: { label: 'E2EE', icon: 'lock', desc: \"This model supports end-to-end encryption (E2EE) and runs in a Trusted Execution Environment (TEE). Your prompt is encrypted on your client and decrypted on the GPU within the TEE. The response is then encrypted and sent back to your client for decryption. Venice's system prompt and web search are disabled to preserve end-to-end encryption. Attestation evidence is available for independent verification.\" },\n    tee: { label: 'TEE', icon: 'shield', desc: 'This model runs in a Trusted Execution Environment (TEE). Attestation evidence is available for independent verification.' },\n    private: { label: 'Private', icon: 'eyeOff', desc: 'This model is private and no prompt data is stored in any capacity.' },\n    anonymized: { label: 'Anonymized', icon: 'mask', desc: 'The provider of this model may retain prompt data (though it is anonymized by Venice). For sensitive content, use a private model.' }\n  };\n  const PRIVACY_ORDER = ['e2ee', 'tee', 'private', 'anonymized'];\n  const TEXT_CAPS = [\n    { key: 'tools', label: 'Function calling', short: 'Tools', icon: 'tool', desc: 'Tool and function calls, including tool_choice' },\n    { key: 'structured', label: 'Structured outputs', short: 'JSON', icon: 'braces', desc: 'response_format with a JSON schema' },\n    { key: 'reasoning', label: 'Reasoning', short: 'Reasoning', icon: 'brain', desc: 'Thinks before answering' },\n    { key: 'effort', label: 'Reasoning effort control', short: 'Effort', icon: 'gauge', desc: 'Adjustable with reasoning_effort' },\n    { key: 'vision', label: 'Image input', short: 'Vision', icon: 'eye', desc: 'Accepts images in messages' },\n    { key: 'videoInput', label: 'Video input', short: 'Video in', icon: 'film', desc: 'Accepts video in messages' },\n    { key: 'audioInput', label: 'Audio input', short: 'Audio in', icon: 'mic', desc: 'Accepts audio in messages' },\n    { key: 'webSearch', label: 'Web search', short: 'Web', icon: 'globe', desc: 'Venice web search and citations' },\n    { key: 'xSearch', label: 'X search', short: 'X', icon: 'at', desc: 'Search posts on X' },\n    { key: 'caching', label: 'Prompt caching', short: 'Cache', icon: 'zap', desc: 'Discounted cache reads' },\n    { key: 'logprobs', label: 'Log probabilities', short: 'Logprobs', icon: 'activity', desc: 'Token logprobs in responses' },\n    { key: 'code', label: 'Optimized for code', short: 'Code', icon: 'code', desc: 'Tuned for software engineering' }\n  ];\n  const QUANT_LABELS = { fp4: 'FP4', fp8: 'FP8', fp16: 'FP16', bf16: 'BF16', int4: 'INT4' };\n  const QUANT_NOTES = {\n    fp4: '4-bit floating point weights. Lowest memory and cost; small accuracy loss on some tasks.',\n    int4: '4-bit integer weights. Lowest memory and cost; small accuracy loss on some tasks.',\n    fp8: '8-bit floating point. Near-lossless against BF16 on most benchmarks.',\n    bf16: '16-bit brain float, the precision most labs publish weights in.',\n    fp16: '16-bit floating point, full published precision.'\n  };\n\n  /* ------------------------------------------------------------ format */\n\n  const usd = n => {\n    if (n == null || !Number.isFinite(n)) return '—';\n    if (n === 0) return 'Free';\n    const a = Math.abs(n);\n    if (a >= 1000) return `$${Math.round(n).toLocaleString('en-US')}`;\n    if (a >= 100) return `$${n.toFixed(0)}`;\n    if (a >= 1) return `$${n.toFixed(2)}`;\n    // Sub-dollar prices keep up to four decimals, so $0.1725 isn't shown as $0.17.\n    if (a >= 0.0001) return `$${n.toFixed(4).replace(/0+$/, '').replace(/\\.(\\d?)$/, (m, d) => `.${d.padEnd(2, '0')}`)}`;\n    return `$${Number(n.toPrecision(2))}`;\n  };\n  // 128,000 is a multiple of 1024 too, so decimal sizes are checked first.\n  const tokens = n => {\n    if (!n) return '—';\n    if (n >= 1e6) return `${n % 1e6 && n % 1048576 === 0 ? n / 1048576 : Math.round(n / 1e4) / 100}M`;\n    if (n >= 1e3) return `${n % 1e3 && n % 1024 === 0 ? n / 1024 : Math.round(n / 1e3)}K`;\n    return String(n);\n  };\n  const MONTHS = ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'];\n  const fmtDate = ts => {\n    if (!ts) return '—';\n    const d = new Date(ts * 1000);\n    return `${MONTHS[d.getUTCMonth()]} ${d.getUTCDate()}, ${d.getUTCFullYear()}`;\n  };\n  const shortDate = ts => {\n    if (!ts) return '—';\n    const d = new Date(ts * 1000);\n    return `${MONTHS[d.getUTCMonth()]} ${d.getUTCFullYear()}`;\n  };\n  const fmtMs = ms => {\n    if (ms == null || !Number.isFinite(ms)) return '—';\n    if (ms < 1000) return `${Math.round(ms)} ms`;\n    return `${(ms / 1000).toFixed(ms < 10000 ? 2 : 1)} s`;\n  };\n  const fmtSpeed = v => (v == null || !Number.isFinite(v) ? '—' : `${v < 10 ? v.toFixed(1) : Math.round(v).toLocaleString('en-US')} tok/s`);\n  const fmtUptime = pct => (pct == null || !Number.isFinite(pct) ? '—' : `${pct}%`);\n  // In the reader's time zone, since the figures run up to the last hour.\n  const fmtClock = ms => new Date(ms).toLocaleString('en-US', { month: 'short', day: 'numeric', hour: 'numeric', minute: '2-digit' });\n  const fmtTime = ms => new Date(ms).toLocaleTimeString('en-US', { hour: 'numeric', minute: '2-digit' });\n  const fmtAgo = ms => {\n    const minutes = Math.max(0, Math.round(ms / 60000));\n    if (minutes < 1) return 'just now';\n    if (minutes < 60) return `${minutes} minute${minutes === 1 ? '' : 's'} ago`;\n    const hours = Math.round(minutes / 60);\n    return `${hours} hour${hours === 1 ? '' : 's'} ago`;\n  };\n  const isNew = (ts, now) => Boolean(now && ts && (now - ts * 1000) / 86400000 <= 30);\n  const plural = (n, word) => `${n.toLocaleString('en-US')} ${n === 1 ? word : word.endsWith('y') ? `${word.slice(0, -1)}ies` : `${word}s`}`;\n  const cls = (...parts) => parts.filter(Boolean).join(' ');\n\n  /* ------------------------------------------------------------ model helpers */\n\n  const privacyTiers = list => PRIVACY_ORDER.filter(tier => (list || []).includes(tier));\n  const hasCap = (model, key) => {\n    const text = model.text || {};\n    const caps = text.caps || {};\n    if (key === 'reasoning') return Boolean(text.reasoning);\n    if (key === 'effort') return Boolean(text.reasoning && text.reasoning.effort && text.reasoning.effort.length);\n    if (key === 'caching') return model.pricing && model.pricing.cacheRead != null;\n    return Boolean(caps[key]);\n  };\n  // E2EE models also run in TEE-only mode under the same ID.\n  const offersTier = (m, tier) => m.privacy === tier || (tier === 'tee' && Boolean(m.text && m.text.caps && m.text.caps.tee));\n  const maxVideoHeight = model => Math.max(0, ...((model.video && model.video.resolutions) || []).map(r => r.height || 0));\n  const maxVideoSeconds = model => Math.max(0, ...((model.video && model.video.durations) || []).map(d => d.seconds || 0));\n  const minVideoSeconds = model => {\n    const list = ((model.video && model.video.durations) || []).map(d => d.seconds).filter(Boolean);\n    return list.length ? Math.min(...list) : 0;\n  };\n  // Clip lengths in seconds, sorted, with the spacing between them when it's even.\n  const durationSteps = durations => {\n    const secs = (durations || []).map(d => d.seconds).filter(Boolean).sort((a, b) => a - b);\n    const step = secs.length > 2 ? secs[1] - secs[0] : null;\n    return { secs, step: step && secs.every((x, i) => i === 0 || x - secs[i - 1] === step) ? step : null };\n  };\n  // A long, evenly spaced list of lengths reads as a range.\n  const durationText = durations => {\n    const { secs, step } = durationSteps(durations);\n    if (secs.length > 6 && step) return `${secs[0]}–${secs[secs.length - 1]}s, ${step === 1 ? 'any whole second' : `in ${step}s steps`}`;\n    return (durations || []).map(d => (d.seconds ? `${d.seconds}s` : d.value)).join(', ');\n  };\n  const upperFirst = text => text.charAt(0).toUpperCase() + text.slice(1);\n  // Upscalers take no prompt. Seedance's edit model reads its source clip\n  // from reference_video_urls instead of video_url.\n  const videoInputList = video => {\n    const inputs = (video && video.inputs) || {};\n    return [\n      video && video.mode !== 'upscale' && 'prompt',\n      inputs.image && 'image',\n      inputs.endImage && 'end frame',\n      inputs.reference && 'reference images',\n      (inputs.video || inputs.referenceVideo) && 'video',\n      inputs.audio && 'audio'\n    ].filter(Boolean);\n  };\n  // Price rows for the video calculator and the static text when a model has\n  // more than six lengths: the shortest, 5s, 10s and the longest, led by a\n  // per-second row when every length costs the same rate per second.\n  const clipTable = (model, cols, audioKey) => {\n    const p = model.pricing || {};\n    const quotes = p.quotes || {};\n    const durs = ((model.video && model.video.durations) || []).filter(d => d.seconds).sort((a, b) => a.seconds - b.seconds);\n    if (durs.length <= 6) return null;\n    const first = durs[0];\n    const last = durs[durs.length - 1];\n    const rates = cols.map(c => {\n      const points = durs.map(d => [d.seconds, quotes[`${c.value}|${d.value}|${audioKey}`]]).filter(([, q]) => q != null);\n      if (points.length < 2) return null;\n      const fitted = points.reduce((sum, [sec, q]) => sum + sec * q, 0) / points.reduce((sum, [sec]) => sum + sec * sec, 0);\n      // Quotes are rounded to the cent.\n      if (!points.every(([sec, q]) => Math.abs(q - fitted * sec) <= 0.01)) return null;\n      return (p.perSecond || {})[`${c.value}|${audioKey}`] || fitted;\n    });\n    const perSecond = rates.every(rate => rate != null) ? rates : null;\n    const { step } = durationSteps(durs);\n    const span = step\n      ? `Any length from ${first.seconds} to ${last.seconds} seconds${step > 1 ? ` in ${step}-second steps` : ''}`\n      : `${durs.length} lengths from ${first.seconds} to ${last.seconds} seconds`;\n    return {\n      rows: durs.filter(d => d === first || d === last || d.seconds === 5 || d.seconds === 10),\n      rates: perSecond,\n      note: `${span}${perSecond ? ', priced per second' : ''}.`\n    };\n  };\n  const imageMaxRes = model => {\n    const list = (model.image && model.image.resolutions) || [];\n    if (list.includes('4K')) return '4K';\n    if (list.includes('2K')) return '2K';\n    if (list.includes('1K')) return '1K';\n    return list.length ? list[list.length - 1] : null;\n  };\n  const heightLabel = h => (h >= 2160 ? '4K' : h >= 1440 ? '1440p' : h ? `${h}p` : '—');\n  const listText = items => (items.length > 1 ? `${items.slice(0, -1).join(', ')} and ${items[items.length - 1]}` : items[0] || '');\n\n  const IMAGE_TASK_WORDS = { 'image-generation': 'generation', 'image-edit': 'editing', 'image-upscale': 'upscaling' };\n  // What a family does across its variants, e.g. \"Image generation and editing\".\n  const familyTask = (family, models) => {\n    if (family.task === 'chat') return null;\n    if (family.modality === 'video') return 'Video generation';\n    if (family.modality === 'image') {\n      const words = [...new Set(models.map(m => IMAGE_TASK_WORDS[m.task]).filter(Boolean))];\n      return words.length ? `Image ${listText(words)}` : TASK_LABELS[family.task] || null;\n    }\n    return TASK_LABELS[family.task] || null;\n  };\n\n  // Video prices are quote-derived at build time. A model page asks for a\n  // resolution, duration and audio setting; the closest supported option is\n  // used and flagged when it differs from the request.\n  const videoPrice = (model, lens) => {\n    const p = model.pricing || {};\n    if (p.status !== 'quoted') return { status: p.status || 'unavailable' };\n    const video = model.video || {};\n    const res = (video.resolutions || []).filter(r => r.height).sort((a, b) => a.height - b.height);\n    const pick = res.find(r => r.height === lens.h) || res.find(r => r.height > lens.h) || res[res.length - 1] || null;\n    const resKey = pick ? pick.value : '-';\n    const audioKey = video.audio === 'optional' ? (lens.a === 'on' ? 'on' : 'off') : (video.audio === 'native' ? 'on' : 'off');\n    const durs = (video.durations || []).map(d => d.seconds).filter(Boolean);\n    const dur = durs.includes(lens.s) ? lens.s : durs.reduce((best, d) => (Math.abs(d - lens.s) < Math.abs(best - lens.s) ? d : best), durs[0]);\n    const clip = p.quotes ? p.quotes[`${resKey}|${dur}s|${audioKey}`] : null;\n    let perSecond = p.perSecond ? p.perSecond[`${resKey}|${audioKey}`] : null;\n    if (perSecond == null && clip != null && dur) perSecond = clip / dur;\n    return {\n      status: 'quoted', perSecond, clip, seconds: dur, resolution: pick ? pick.label : null,\n      exactRes: !pick || pick.height === lens.h, exactDur: dur === lens.s,\n      audio: audioKey === 'on', forcedAudio: video.audio === 'native' && lens.a !== 'on', noAudio: video.audio === 'none' && lens.a === 'on'\n    };\n  };\n  // A model with duration options accepts only those lengths, one per tier.\n  const tierLabel = (t, fixed) => (fixed || t.from === t.upTo ? `${t.upTo}s` : t.from ? `${t.from}–${t.upTo}s` : `Up to ${t.upTo}s`);\n\n  // The explorer prices a model at its cheapest option, or, once the\n  // resolution, length or audio filter is set, at that setting. `from` marks\n  // the lowest of several prices and `breakdown` lists them.\n  const spread = (options, unit) => {\n    const values = options.map(([, value]) => value);\n    const varies = new Set(values).size > 1;\n    return {\n      value: values.length ? Math.min(...values) : null,\n      unit,\n      from: varies,\n      breakdown: varies ? options.map(([label, value]) => [label, `${usd(value)} ${unit}`]) : null\n    };\n  };\n  const IMAGE_RESOLUTIONS = ['1K', '2K', '4K'];\n  // Per second at the lowest resolution at or above the filter, with or\n  // without audio as filtered; a length filter adds the shortest clip that\n  // long.\n  const videoListPrice = (model, f) => {\n    const p = model.pricing || {};\n    if (p.status !== 'quoted') return { value: null, unit: '/ sec', status: p.status || 'unavailable' };\n    const video = model.video || {};\n    const h = Number(f.res) || 0;\n    const res = (video.resolutions || []).filter(r => r.height).sort((a, b) => a.height - b.height);\n    const shown = h ? res.filter(r => r.height >= h).slice(0, 1) : res;\n    const audio = video.audio !== 'optional' ? [video.audio === 'native' ? 'on' : 'off']\n      : f.audio === 'audio' ? ['on'] : f.audio === 'silent' ? ['off'] : ['off', 'on'];\n    const options = (shown.length ? shown : [{ value: '-', label: null }])\n      .flatMap(r => audio.map(a => ({ r, a, value: (p.perSecond || {})[`${r.value}|${a}`] })))\n      .filter(o => o.value != null);\n    if (!options.length) return { value: null, unit: '/ sec', status: 'unavailable' };\n    const label = o => {\n      const text = [o.r.label, audio.length > 1 ? (o.a === 'on' ? 'with audio' : 'silent') : null].filter(Boolean).join(' · ');\n      return text.charAt(0).toUpperCase() + text.slice(1);\n    };\n    const best = options.reduce((min, o) => (o.value < min.value ? o : min));\n    const out = { ...spread(options.map(o => [label(o), o.value]), '/ sec'), status: 'quoted' };\n    if (h && best.r.height && best.r.height !== h) out.note = `No ${heightLabel(h)}; priced at ${best.r.label}.`;\n    const s = Number(f.dur) || 0;\n    if (s) {\n      out.seconds = (video.durations || []).map(d => d.seconds).filter(Boolean).sort((a, b) => a - b).find(d => d >= s) || null;\n      out.clip = out.seconds && p.quotes ? p.quotes[`${best.r.value}|${out.seconds}s|${best.a}`] : null;\n    }\n    return out;\n  };\n  const listPrice = (model, f) => {\n    const p = model.pricing || {};\n    if (model.modality === 'video') return videoListPrice(model, f);\n    if (model.task === 'image-generation' && p.byResolution && Object.keys(p.byResolution).length) {\n      if (f.res && p.byResolution[f.res] != null) return { value: p.byResolution[f.res], unit: '/ image' };\n      return spread(IMAGE_RESOLUTIONS.filter(r => p.byResolution[r] != null).map(r => [r, p.byResolution[r]]), '/ image');\n    }\n    if (p.kind === 'tiered' && (p.tiers || []).length) return spread(p.tiers.map(t => [tierLabel(t, model.audio && model.audio.durationOptions), t.usd]), '/ track');\n    return { value: model.headline ? model.headline.value : null, unit: headlineUnit(model) };\n  };\n  // The unit a model is billed in, as the pricing section's note reads it.\n  const priceUnit = model => {\n    if (model.modality === 'text' || model.modality === 'embedding') return model.modality === 'embedding' ? 'per 1M input tokens' : 'per 1M tokens';\n    if (model.modality === 'video') return 'per clip';\n    if (model.task === 'tts') return 'per 1M characters';\n    if (model.task === 'stt') return 'per second of audio';\n    if (model.modality === 'audio') {\n      if (model.pricing && model.pricing.kind === 'tiered') return 'per track, by length';\n      return model.headline && model.headline.basis === 'track' ? 'per track' : 'per minute of audio';\n    }\n    if (model.task === 'image-edit') return 'per edit';\n    if (model.task === 'image-upscale') return 'per upscale';\n    return 'per image';\n  };\n\n  const headlineUnit = model => {\n    if (model.task === 'decision') return '/ 1M input tok';\n    if (model.modality === 'video') return '/ sec';\n    if (model.modality === 'text' && model.task === 'chat') return '/ 1M tok';\n    if (model.modality === 'embedding') return '/ 1M tok';\n    if (model.task === 'tts') return '/ 1M chars';\n    if (model.task === 'stt') return '/ audio hr';\n    if (model.modality === 'audio') return model.headline && model.headline.basis === 'track' ? '/ track' : '/ min';\n    if (model.task === 'image-edit') return '/ edit';\n    if (model.task === 'image-upscale') return '/ 2x';\n    if (model.modality === 'image') return '/ image';\n    return '';\n  };\n\n  // One line per variant, as the variant chips and the page's static text show it.\n  const priceSummary = m => (m.modality === 'text' && m.pricing ? `${usd(m.pricing.input)} / ${usd(m.pricing.output)} per 1M`\n    : m.modality === 'video' ? (m.pricing && m.pricing.status === 'quoted' ? `from ${usd(m.pricing.fromPerSecond)} / sec` : 'priced by source')\n      : m.headline && m.headline.value != null ? `${usd(m.headline.value)} ${headlineUnit(m)}` : '');\n\n  // The reference clips on a video model page.\n  const DRAFT_CLIP = { h: 720, s: 5, a: 'off' };\n  const PRODUCTION_CLIP = { h: 1080, s: 10, a: 'on' };\n\n  const searchText = (family, models, providers) => [\n    family.name, family.slug, providers[family.provider] && providers[family.provider].name, family.task,\n    ...models.map(m => m.id), ...(family.sets || []), ...(family.traits || [])\n  ].filter(Boolean).join(' ').toLowerCase();\n\n  const matchesQuery = (text, query) => query.toLowerCase().split(/\\s+/).filter(Boolean).every(token => text.includes(token));\n\n  /* ------------------------------------------------------------ icons */\n\n  const ICONS = {\n    search: __jsx(__Fragment, null, __jsx('circle', { cx: \"11\", cy: \"11\", r: \"7\",} ), __jsx('path', { d: \"m20 20-3.5-3.5\" ,} )),\n    x: __jsx('path', { d: \"M18 6 6 18M6 6l12 12\"     ,} ),\n    check: __jsx('path', { d: \"M20 6 9 17l-5-5\"   ,} ),\n    minus: __jsx('path', { d: \"M5 12h14\" ,} ),\n    plus: __jsx('path', { d: \"M12 5v14M5 12h14\"  ,} ),\n    copy: __jsx(__Fragment, null, __jsx('rect', { x: \"9\", y: \"9\", width: \"13\", height: \"13\", rx: \"2\",} ), __jsx('path', { d: \"M5 15H4a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h9a2 2 0 0 1 2 2v1\"                ,} )),\n    arrowRight: __jsx('path', { d: \"M5 12h14m-6-6 6 6-6 6\"    ,} ),\n    external: __jsx('path', { d: \"M15 3h6v6M10 14 21 3M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6\"                   ,} ),\n    chevronDown: __jsx('path', { d: \"m6 9 6 6 6-6\"    ,} ),\n    chevronRight: __jsx('path', { d: \"m9 18 6-6-6-6\"  ,} ),\n    sliders: __jsx('path', { d: \"M4 21v-7M4 10V3M12 21v-9M12 8V3M20 21v-5M20 12V3M1 14h6M9 8h6M17 16h6\"         ,} ),\n    grid: __jsx(__Fragment, null, __jsx('rect', { x: \"3\", y: \"3\", width: \"7\", height: \"7\", rx: \"1.5\",} ), __jsx('rect', { x: \"14\", y: \"3\", width: \"7\", height: \"7\", rx: \"1.5\",} ), __jsx('rect', { x: \"3\", y: \"14\", width: \"7\", height: \"7\", rx: \"1.5\",} ), __jsx('rect', { x: \"14\", y: \"14\", width: \"7\", height: \"7\", rx: \"1.5\",} )),\n    rows: __jsx('path', { d: \"M3 6h18M3 12h18M3 18h18\"   ,} ),\n    columns: __jsx(__Fragment, null, __jsx('rect', { x: \"3\", y: \"4\", width: \"7\", height: \"16\", rx: \"1.5\",} ), __jsx('rect', { x: \"14\", y: \"4\", width: \"7\", height: \"16\", rx: \"1.5\",} )),\n    tool: __jsx('path', { d: \"M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.8-3.8a6 6 0 0 1-7.9 7.9l-6.9 6.9a2.1 2.1 0 0 1-3-3l6.9-6.9a6 6 0 0 1 7.9-7.9z\"                             ,} ),\n    braces: __jsx('path', { d: \"M8 3H7a2 2 0 0 0-2 2v5a2 2 0 0 1-2 2 2 2 0 0 1 2 2v5a2 2 0 0 0 2 2h1M16 21h1a2 2 0 0 0 2-2v-5a2 2 0 0 1 2-2 2 2 0 0 1-2-2V5a2 2 0 0 0-2-2h-1\"                                            ,} ),\n    brain: __jsx('path', { d: \"M12 5a3 3 0 1 0-6 .1 4 4 0 0 0-2.5 5.8 4 4 0 0 0 .6 6.6A4 4 0 1 0 12 18zM12 5a3 3 0 1 1 6 .1 4 4 0 0 1 2.5 5.8 4 4 0 0 1-.6 6.6A4 4 0 1 1 12 18zM12 5v13\"                                                    ,} ),\n    gauge: __jsx('path', { d: \"m12 14 4-4M3.3 19a10 10 0 1 1 17.4 0\"         ,} ),\n    eye: __jsx(__Fragment, null, __jsx('path', { d: \"M2 12s3-7 10-7 10 7 10 7-3 7-10 7-10-7-10-7Z\"        ,} ), __jsx('circle', { cx: \"12\", cy: \"12\", r: \"3\",} )),\n    eyeOff: __jsx('path', { d: \"M9.9 4.2A9 9 0 0 1 12 4c7 0 10 8 10 8a13 13 0 0 1-1.7 2.7M6.6 6.6A13 13 0 0 0 2 12s3 8 10 8a9 9 0 0 0 5.4-1.6M2 2l20 20M9.9 9.9a3 3 0 0 0 4.2 4.2\"                                         ,} ),\n    mask: __jsx('path', { d: \"M2 10c0-3 4-5 10-5s10 2 10 5c0 5-4 9-7 9-2 0-2-2-3-2s-1 2-3 2c-3 0-7-4-7-9zM7 11h3M14 11h3\"               ,} ),\n    film: __jsx(__Fragment, null, __jsx('rect', { x: \"2\", y: \"3\", width: \"20\", height: \"18\", rx: \"2\",} ), __jsx('path', { d: \"M7 3v18M17 3v18M2 8h5M2 16h5M17 8h5M17 16h5\"      ,} )),\n    mic: __jsx('path', { d: \"M12 2a3 3 0 0 0-3 3v7a3 3 0 0 0 6 0V5a3 3 0 0 0-3-3zM19 10v2a7 7 0 0 1-14 0v-2M12 19v3\"                       ,} ),\n    globe: __jsx(__Fragment, null, __jsx('circle', { cx: \"12\", cy: \"12\", r: \"10\",} ), __jsx('path', { d: \"M2 12h20M12 2a15 15 0 0 1 4 10 15 15 0 0 1-4 10 15 15 0 0 1-4-10 15 15 0 0 1 4-10z\"                         ,} )),\n    at: __jsx(__Fragment, null, __jsx('circle', { cx: \"12\", cy: \"12\", r: \"4\",} ), __jsx('path', { d: \"M16 8v5a3 3 0 0 0 6 0v-1a10 10 0 1 0-4 8\"            ,} )),\n    activity: __jsx('path', { d: \"M22 12h-4l-3 9L9 3l-3 9H2\"    ,} ),\n    zap: __jsx('path', { d: \"M13 2 3 14h9l-1 8 10-12h-9z\"     ,} ),\n    code: __jsx('path', { d: \"m16 18 6-6-6-6M8 6l-6 6 6 6\"      ,} ),\n    lock: __jsx(__Fragment, null, __jsx('rect', { x: \"4\", y: \"11\", width: \"16\", height: \"10\", rx: \"2\",} ), __jsx('path', { d: \"M8 11V7a4 4 0 0 1 8 0v4\"       ,} )),\n    shield: __jsx('path', { d: \"M12 22s8-4 8-10V5l-8-3-8 3v7c0 6 8 10 8 10z\"        ,} ),\n    shieldCheck: __jsx('path', { d: \"M12 22s8-4 8-10V5l-8-3-8 3v7c0 6 8 10 8 10zM9 12l2 2 4-4\"           ,} ),\n    sparkles: __jsx('path', { d: \"m12 3 1.9 5.1L19 10l-5.1 1.9L12 17l-1.9-5.1L5 10l5.1-1.9zM19 16l.7 1.8 1.8.7-1.8.7L19 21l-.7-1.8-1.8-.7 1.8-.7z\"            ,} ),\n    clock: __jsx(__Fragment, null, __jsx('circle', { cx: \"12\", cy: \"12\", r: \"10\",} ), __jsx('path', { d: \"M12 6v6l4 2\"  ,} )),\n    image: __jsx(__Fragment, null, __jsx('rect', { x: \"3\", y: \"3\", width: \"18\", height: \"18\", rx: \"2\",} ), __jsx('circle', { cx: \"9\", cy: \"9\", r: \"2\",} ), __jsx('path', { d: \"m21 15-3.1-3.1a2 2 0 0 0-2.8 0L6 21\"       ,} )),\n    video: __jsx(__Fragment, null, __jsx('path', { d: \"m16 13 5.2 3.1a.5.5 0 0 0 .8-.4V8.3a.5.5 0 0 0-.8-.4L16 11\"           ,} ), __jsx('rect', { x: \"2\", y: \"6\", width: \"14\", height: \"12\", rx: \"2\",} )),\n    music: __jsx(__Fragment, null, __jsx('path', { d: \"M9 18V5l12-2v13\" ,} ), __jsx('circle', { cx: \"6\", cy: \"18\", r: \"3\",} ), __jsx('circle', { cx: \"18\", cy: \"16\", r: \"3\",} )),\n    text: __jsx('path', { d: \"M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z\"                  ,} ),\n    layers: __jsx('path', { d: \"m12 2 10 5-10 5L2 7zM2 17l10 5 10-5M2 12l10 5 10-5\"           ,} ),\n    info: __jsx(__Fragment, null, __jsx('circle', { cx: \"12\", cy: \"12\", r: \"10\",} ), __jsx('path', { d: \"M12 16v-4M12 8h.01\"  ,} )),\n    play: __jsx('path', { d: \"M7 4.5v15l12.5-7.5z\" , fill: \"currentColor\", stroke: \"none\",} ),\n    pause: __jsx('path', { d: \"M7 4h3.5v16H7zM13.5 4H17v16h-3.5z\"  , fill: \"currentColor\", stroke: \"none\",} ),\n    volume: __jsx('path', { d: \"M11 5 6 9H2v6h4l5 4zM15.5 8.5a5 5 0 0 1 0 7M19 5a10 10 0 0 1 0 14\"                  ,} ),\n    mute: __jsx('path', { d: \"M11 5 6 9H2v6h4l5 4zM22 9l-6 6M16 9l6 6\"        ,} ),\n    link: __jsx('path', { d: \"M10 13a5 5 0 0 0 7.5.5l3-3a5 5 0 0 0-7-7l-1.7 1.7M14 11a5 5 0 0 0-7.5-.5l-3 3a5 5 0 0 0 7 7l1.7-1.7\"                       ,} ),\n    trophy: __jsx('path', { d: \"M6 9H4.5a2.5 2.5 0 0 1 0-5H6M18 9h1.5a2.5 2.5 0 0 0 0-5H18M4 22h16M10 14.7V17c0 .6-.5 1-1 1.2C7.9 18.8 7 20.2 7 22M14 14.7V17c0 .6.5 1 1 1.2 1.1.6 2 2 2 3.8M18 2H6v7a6 6 0 0 0 12 0z\"                                       ,} ),\n    flask: __jsx('path', { d: \"M9 3h6M10 9V3M14 9V3M10 9 4.5 19a2 2 0 0 0 1.8 3h11.4a2 2 0 0 0 1.8-3L14 9\"                  ,} ),\n    server: __jsx(__Fragment, null, __jsx('rect', { x: \"2\", y: \"3\", width: \"20\", height: \"8\", rx: \"2\",} ), __jsx('rect', { x: \"2\", y: \"13\", width: \"20\", height: \"8\", rx: \"2\",} ), __jsx('path', { d: \"M6 7h.01M6 17h.01\"  ,} )),\n    terminal: __jsx('path', { d: \"m4 17 6-6-6-6M12 19h8\"   ,} ),\n    book: __jsx('path', { d: \"M4 19.5A2.5 2.5 0 0 1 6.5 17H20V2H6.5A2.5 2.5 0 0 0 4 4.5zM4 19.5A2.5 2.5 0 0 0 6.5 22H20v-5\"                    ,} ),\n    maximize: __jsx('path', { d: \"M8 3H5a2 2 0 0 0-2 2v3M21 8V5a2 2 0 0 0-2-2h-3M3 16v3a2 2 0 0 0 2 2h3M16 21h3a2 2 0 0 0 2-2v-3\"                        ,} ),\n    dollar: __jsx('path', { d: \"M12 2v20M17 5H9.5a3.5 3.5 0 0 0 0 7h5a3.5 3.5 0 0 1 0 7H6\"              ,} ),\n    bolt: __jsx('path', { d: \"M13 2 3 14h9l-1 8 10-12h-9z\"     ,} ),\n    wand: __jsx('path', { d: \"m15 4 5 5M4 20 16 8M18 2v4M20 4h-4M8 2v2M9 3H7\"          ,} )\n  };\n  const Icon = ({ name, size = 16, className }) => (\n    __jsx('svg', { className: cls('vx-icon', className), width: size, height: size, viewBox: \"0 0 24 24\"   , fill: \"none\", stroke: \"currentColor\", strokeWidth: \"1.8\", strokeLinecap: \"round\", strokeLinejoin: \"round\", 'aria-hidden': \"true\",}\n      , ICONS[name] || null\n    )\n  );\n\n  /* ------------------------------------------------------------ atoms */\n\n  const ProviderLogo = ({ provider, size = 32, title = provider && provider.name }) => {\n    const box = { width: size, height: size };\n    const name = (provider && provider.name) || undefined;\n    const tip = title || undefined;\n    if (!provider || !provider.logo) {\n      const initial = (name || '?').charAt(0);\n      return __jsx('span', { className: \"vx-logo vx-logo-initial\" , style: { ...box, fontSize: Math.round(size * 0.5) }, title: tip, 'aria-hidden': \"true\",}, initial);\n    }\n    // Translated pages keep the page data of their last sync, which can still\n    // name the old single-color icons; those draw only as masks.\n    if (provider.mono || provider.logo.startsWith('/images/icons/models/')) {\n      return __jsx('span', { className: \"vx-logo vx-logo-mono\" , style: { ...box, '--vx-logo': `url('${provider.logo}')` }, title: tip, 'aria-hidden': \"true\",} );\n    }\n    return __jsx('img', { className: \"vx-logo\", src: provider.logo, width: size, height: size, alt: \"\", title: tip, 'aria-hidden': \"true\", loading: \"lazy\", decoding: \"async\",} );\n  };\n\n  const PrivacyBadge = ({ tier }) => {\n    const meta = PRIVACY[tier];\n    if (!meta) return null;\n    return __jsx('span', { className: cls('vx-badge', `vx-privacy-${tier}`), title: meta.desc,}, meta.label);\n  };\n\n  const PrivacyStack = ({ tiers }) => (\n    __jsx('span', { className: \"vx-badges\",}\n      , privacyTiers(tiers).map(tier => __jsx(PrivacyBadge, { key: tier, tier: tier,} ))\n    )\n  );\n\n  // HoverTips shows the text on hover or keyboard focus, and, for an info\n  // icon, on tap.\n  const InfoTip = ({ text, size = 13 }) => (\n    __jsx('span', { className: \"vx-info\", title: text, tabIndex: 0, role: \"img\", 'aria-label': text,}, __jsx(Icon, { name: \"info\", size: size,} ))\n  );\n\n  const Tag = ({ tone, children, title }) => (\n    __jsx('span', { className: cls('vx-badge', tone && `vx-badge-${tone}`), title: title,}, children)\n  );\n\n  const TypeBadge = ({ family }) => {\n    const scope = SCOPES.find(s => s.key === familyScope(family));\n    return scope ? __jsx('span', { className: `vx-type vx-type-${scope.key}`, role: \"img\", 'aria-label': scope.label, 'data-tip-label': scope.label, title: SCOPE_BLURBS[scope.key],} ) : null;\n  };\n\n  const StatusTags = ({ item, now }) => (\n    __jsx(__Fragment, null\n      , isNew(item.created, now) ? __jsx(Tag, { tone: \"new\", title: \"Added in the last 30 days.\"     ,}, \"New\") : null\n      , item.beta ? __jsx(Tag, { tone: \"beta\", title: \"Experimental. May change or be removed without notice.\"       ,}, \"Beta\") : null\n      , item.deprecated || item.deprecation ? __jsx(Tag, { tone: \"deprecated\", title: \"Scheduled for removal. See Deprecations.\"    ,}, \"Deprecated\") : null\n    )\n  );\n\n  const CopyButton = ({ text, label, className, iconOnly, small }) => {\n    const [done, setDone] = useState(false);\n    const onClick = event => {\n      event.preventDefault();\n      event.stopPropagation();\n      copyText(text).then(() => {\n        setDone(true);\n        setTimeout(() => setDone(false), 1400);\n      });\n    };\n    return (\n      __jsx('button', { type: \"button\", className: cls(iconOnly ? 'vx-icon-btn' : 'vx-btn', small && 'vx-btn-sm', done && 'is-done', className), onClick: onClick, 'aria-label': label || `Copy ${text}`, title: iconOnly ? (label || 'Copy') : undefined,}\n        , __jsx(Icon, { name: done ? 'check' : 'copy', size: 14,} )\n        , iconOnly ? __jsx('span', { className: \"vx-sr-only\", 'aria-live': \"polite\",}, done ? 'Copied' : '') : __jsx('span', { 'aria-live': \"polite\",}, done ? 'Copied' : (label || 'Copy'))\n      )\n    );\n  };\n\n  const ModelId = ({ id }) => {\n    const [done, setDone] = useState(false);\n    const copy = () => copyText(id).then(() => {\n      setDone(true);\n      setTimeout(() => setDone(false), 1400);\n    });\n    return (\n      __jsx('span', { className: \"vx-id\",}\n        , __jsx('code', { title: id,}, id)\n        , __jsx('button', { type: \"button\", className: cls('vx-id-copy', done && 'is-done'), onClick: copy, 'aria-label': `Copy model ID ${id}`,}\n          , __jsx('span', { 'aria-live': \"polite\",}, done ? 'Copied' : 'Copy')\n        )\n      )\n    );\n  };\n\n  const Segmented = ({ options, value, onChange, ariaLabel }) => (\n    __jsx('div', { className: \"vx-seg\", role: \"radiogroup\", 'aria-label': ariaLabel,}\n      , options.map(option => (\n        __jsx('button', { key: String(option.value), type: \"button\", role: \"radio\", 'aria-checked': value === option.value,\n          className: cls('vx-seg-btn', value === option.value && 'is-active'), disabled: option.disabled,\n          onClick: () => onChange(option.value), title: option.title, 'aria-label': option.label ? undefined : option.title,}\n          , option.icon ? __jsx(Icon, { name: option.icon, size: 14,} ) : null\n          , option.label\n        )\n      ))\n    )\n  );\n\n  const CapIcons = ({ model }) => (\n    __jsx('span', { className: \"vx-caps\",}\n      , TEXT_CAPS.filter(cap => ['tools', 'reasoning', 'vision', 'structured', 'webSearch'].includes(cap.key) && hasCap(model, cap.key)).map(cap => (\n        __jsx('span', { key: cap.key, className: \"vx-cap\", 'data-tip-label': cap.label, title: cap.desc,}, __jsx(Icon, { name: cap.icon, size: 15,} ), __jsx('span', { className: \"vx-sr-only\",}, cap.label))\n      ))\n    )\n  );\n\n  const Stat = ({ label, value, sub, tip, last }) => (\n    __jsx('div', { className: cls('vx-stat', last && 'is-last'),}\n      , __jsx('div', { className: \"vx-stat-label\",}, label, tip ? __jsx(InfoTip, { text: tip, size: 11,} ) : null)\n      , __jsx('div', { className: \"vx-stat-value\",}, value)\n      , sub ? __jsx('div', { className: \"vx-stat-sub\",}, sub) : null\n    )\n  );\n\n  const Empty = ({ title, children }) => (\n    __jsx('div', { className: \"vx-empty\", role: \"status\",}\n      , __jsx('div', { className: \"vx-empty-title\",}, title)\n      , children ? __jsx('div', { className: \"vx-empty-body\",}, children) : null\n    )\n  );\n\n  const CatalogSkeleton = () => (\n    __jsx('div', { className: \"vx-skeleton\", 'aria-hidden': \"true\",}\n      , Array.from({ length: 8 }, (_, i) => __jsx('div', { key: i, className: \"vx-skel-row\",}, __jsx('span', null ), __jsx('span', null ), __jsx('span', null ), __jsx('span', null )))\n    )\n  );\n\n  /* ------------------------------------------------------------ media */\n\n  // The gallery compares models on one reference prompt: a model's render of\n  // it, or, for a model that transforms an input, its output from that\n  // prompt's render. The displayed variant comes first, then its siblings.\n  const GALLERY_PROMPTS = { image: 'photoreal', video: 'cinematic-landscape' };\n  const galleryMedia = (family, display, catalog) => {\n    const prompt = GALLERY_PROMPTS[family.modality];\n    const pick = model => {\n      const media = (model && model.media) || [];\n      return media.find(m => m.prompt === prompt) || media.find(m => m.from === prompt);\n    };\n    return pick(display) || family.variants.map(id => catalog.models[id]).map(pick).find(Boolean) || null;\n  };\n\n  // Sources attach only as a tile nears the viewport, so a gallery doesn't\n  // open dozens of video requests at once; a skeleton holds the tile until\n  // the first frame paints.\n  const HoverVideo = ({ src, poster, className, autoPlay }) => {\n    const ref = useRef(null);\n    const [near, setNear] = useState(false);\n    const [ready, setReady] = useState(false);\n    useEffect(() => {\n      const el = ref.current;\n      if (!el || near) return undefined;\n      if (typeof IntersectionObserver === 'undefined') { setNear(true); return undefined; }\n      const observer = new IntersectionObserver(entries => {\n        if (entries.some(entry => entry.isIntersecting)) { setNear(true); observer.disconnect(); }\n      }, { rootMargin: '300px 0px' });\n      observer.observe(el);\n      return () => observer.disconnect();\n    }, [near]);\n    const play = () => { if (ref.current && near) ref.current.play().catch(() => {}); };\n    const stop = () => { if (ref.current && !autoPlay) { ref.current.pause(); } };\n    const show = () => setReady(true);\n    // Without a poster, the #t fragment makes browsers seek and paint a first frame.\n    const url = poster || /#t=/.test(src) ? src : `${src}#t=0.1`;\n    return (\n      __jsx(__Fragment, null\n        , ready ? null : __jsx('span', { className: \"vx-media-skeleton\", 'aria-hidden': \"true\",} )\n        , __jsx('video', { ref: ref, className: cls(className, !ready && 'is-loading'), src: near ? url : undefined, poster: poster, muted: true, loop: true, playsInline: true, preload: \"metadata\",\n          autoPlay: autoPlay, onLoadedData: show, onError: show, onMouseEnter: play, onMouseLeave: stop, onFocus: play, onBlur: stop,} )\n      )\n    );\n  };\n\n  // venice.ai serves its samples through its image optimizer at these widths.\n  const SAMPLE_WIDTHS = [256, 384, 640, 828];\n  const SAMPLE_PATH = /^https:\\/\\/venice\\.ai(\\/samples\\/[^?#]+)$/;\n  const sampleSrcSet = url => {\n    const match = SAMPLE_PATH.exec(url);\n    if (!match) return undefined;\n    const path = encodeURIComponent(match[1]);\n    return SAMPLE_WIDTHS.map(w => `https://venice.ai/_next/image?url=${path}&w=${w}&q=75 ${w}w`).join(', ');\n  };\n  // Tiles run two to a row on phones and about 280px wide elsewhere.\n  const CARD_SIZES = '(max-width: 700px) calc(50vw - 22px), 280px';\n\n  const MediaFallback = ({ label = 'No reference render yet' }) => (\n    __jsx('div', { className: \"vx-media-fallback\",}, __jsx('span', null, label))\n  );\n\n  const FOCUSABLE = 'a[href], button:not([disabled]), input:not([disabled]), select:not([disabled]), textarea:not([disabled]), video[controls], [tabindex]:not([tabindex=\"-1\"])';\n\n  // Modal: focus moves to Close, Tab cycles inside the dialog, and focus\n  // returns to the opener when it closes.\n  const Lightbox = ({ item, onClose }) => {\n    const closeRef = useRef(null);\n    const dialogRef = useRef(null);\n    const onCloseRef = useRef(onClose);\n    onCloseRef.current = onClose;\n    useEffect(() => {\n      if (!item) return undefined;\n      const previous = document.activeElement;\n      if (closeRef.current) closeRef.current.focus();\n      const onKey = e => {\n        if (e.key === 'Escape') onCloseRef.current();\n        if (e.key !== 'Tab' || !dialogRef.current) return;\n        const items = [...dialogRef.current.querySelectorAll(FOCUSABLE)];\n        if (!items.length) return;\n        const first = items[0];\n        const last = items[items.length - 1];\n        const inside = dialogRef.current.contains(document.activeElement);\n        if (e.shiftKey && (document.activeElement === first || !inside)) { e.preventDefault(); last.focus(); }\n        else if (!e.shiftKey && (document.activeElement === last || !inside)) { e.preventDefault(); first.focus(); }\n      };\n      window.addEventListener('keydown', onKey);\n      return () => {\n        window.removeEventListener('keydown', onKey);\n        if (previous && previous.focus) previous.focus();\n      };\n    }, [item]);\n    if (!item) return null;\n    return (\n      __jsx('div', { ref: dialogRef, className: \"vx-lightbox\", role: \"dialog\", 'aria-modal': \"true\", 'aria-label': item.title, onClick: onClose,}\n        , __jsx('div', { className: \"vx-lightbox-inner\", onClick: e => e.stopPropagation(),}\n          , __jsx('button', { ref: closeRef, type: \"button\", className: \"vx-icon-btn vx-lightbox-close\" , onClick: onClose, 'aria-label': \"Close\",}, __jsx(Icon, { name: \"x\", size: 18,} ))\n          , __jsx('div', { className: \"vx-lightbox-media\",}\n            , item.type === 'video'\n              ? __jsx('video', { src: item.url, controls: true, autoPlay: true, loop: true, playsInline: true,} )\n              : __jsx('img', { src: item.url, alt: item.caption || item.title,} )\n          )\n          , __jsx('div', { className: \"vx-lightbox-meta\",}\n            , __jsx('div', { className: \"vx-lightbox-title\",}, item.title)\n            , __jsx('p', null, item.caption)\n          )\n        )\n      )\n    );\n  };\n\n  const MediaGallery = ({ model }) => {\n    const [open, setOpen] = useState(null);\n    const media = model.media || [];\n    const isVideo = model.modality === 'video';\n    if (!media.length) {\n      return __jsx('p', { className: \"vx-text\",}, \"This variant has not been rendered on the reference prompts yet.\"          );\n    }\n    return (\n      __jsx(__Fragment, null\n        , __jsx('div', { className: cls('vx-gallery', isVideo ? 'vx-gallery-video' : 'vx-gallery-image', !isVideo && media.length === 4 && 'is-four'),}\n          , media.map(item => (\n            __jsx('figure', { key: item.url, className: \"vx-shot\",}\n              , __jsx('button', { type: \"button\", className: \"vx-shot-media\", onClick: () => setOpen(item), 'aria-label': `Open ${item.title} sample`,}\n                , item.type === 'video'\n                  ? __jsx(HoverVideo, { src: item.url, className: \"vx-shot-el\",} )\n                  : __jsx('img', { className: \"vx-shot-el\", src: item.url, alt: item.caption || item.title, loading: \"lazy\",} )\n              )\n              , __jsx('figcaption', null\n                , __jsx('span', { className: \"vx-shot-title\",}, item.title)\n                , item.caption ? __jsx('span', { className: \"vx-shot-caption\", title: item.caption,}, item.caption) : null\n              )\n            )\n          ))\n        )\n        , __jsx(Lightbox, { item: open, onClose: () => setOpen(null),} )\n      )\n    );\n  };\n\n  /* ------------------------------------------------------------ explorer */\n\n  const PAGE_TITLES = {\n    all: 'Models', text: 'Text Models', image: 'Image Models', video: 'Video Models', embedding: 'Embedding Models',\n    tts: 'Text-to-Speech Models', stt: 'Speech-to-Text Models', music: 'Music & Sound Effects Models', decision: 'Decision Models'\n  };\n  const UNIT_NOTES = { text: 'prices per 1M tokens' };\n  // The setting the filters price image and video at, for the count line.\n  const settingNote = (modality, f) => {\n    if (modality === 'image' && f.res) return `prices at ${f.res}`;\n    if (modality !== 'video') return null;\n    const h = Number(f.res) || 0;\n    const parts = [h ? `${heightLabel(h)}${h < 2160 ? ' or higher' : ''}` : null, f.audio === 'audio' ? 'with audio' : f.audio === 'silent' ? 'silent' : null].filter(Boolean);\n    return parts.length ? `prices at ${parts.join(', ')}` : null;\n  };\n  // Each blurb fits one line of the explorer's header, and two on a 360 px\n  // phone, so switching modality doesn't move the toolbar under it.\n  const SCOPE_BLURBS = {\n    all: 'Every model on the Venice API, with prices, limits and privacy tiers.',\n    text: 'Chat, reasoning, coding and agent models, priced per 1M tokens.',\n    image: 'Image generation, editing, upscaling and background removal, priced per image.',\n    video: 'Text, image and reference to video, video editing and upscaling, priced per clip from quotes.',\n    tts: 'Speech synthesis with multilingual voices, priced per character.',\n    stt: 'Transcription with timestamps, priced per second of audio.',\n    music: 'Songs, instrumental tracks and sound effects, priced per track or minute.',\n    embedding: 'Vectors for search and retrieval, priced per 1M input tokens.',\n    decision: 'Typed judgments instead of generated text, priced per 1M tokens.'\n  };\n\n  const EMPTY_FILTERS = { providers: [], privacy: [], caps: [], modes: [], flags: [], quant: [], ctx: '', price: '', res: '', audio: '', dur: '' };\n\n  const filtersFromParams = params => ({\n    providers: listParam(params, 'provider'), privacy: listParam(params, 'privacy'), caps: listParam(params, 'cap'),\n    modes: listParam(params, 'mode'), flags: listParam(params, 'flag'), quant: listParam(params, 'quant'),\n    ctx: params.get('ctx') || '', price: params.get('price') || '', res: params.get('res') || '', audio: params.get('audio') || '', dur: params.get('dur') || ''\n  });\n  const filtersToParams = f => ({\n    provider: f.providers, privacy: f.privacy, cap: f.caps, mode: f.modes, flag: f.flags, quant: f.quant,\n    ctx: f.ctx, price: f.price, res: f.res, audio: f.audio, dur: f.dur\n  });\n  const activeFilterCount = f => ['providers', 'privacy', 'caps', 'modes', 'flags', 'quant'].reduce((n, k) => n + f[k].length, 0) +\n    ['ctx', 'price', 'res', 'audio', 'dur'].filter(k => f[k]).length;\n\n  // A family matches when any of its variants matches; the first matching\n  // variant becomes the row's display variant so prices follow the filters.\n  const variantMatches = (model, f, catalog) => {\n    if (f.privacy.length && !f.privacy.some(tier => offersTier(model, tier))) return false;\n    if (f.caps.length) {\n      if (model.modality === 'text' && !f.caps.every(key => hasCap(model, key))) return false;\n      if (model.modality === 'image' && f.caps.includes('webSearch') && !(model.image && model.image.webSearch)) return false;\n      if (model.modality === 'image' && f.caps.includes('multiImage') && !((model.image && model.image.maxInputImages) > 1)) return false;\n    }\n    if (f.modes.length && model.modality === 'video' && !f.modes.includes(model.variant)) return false;\n    if (f.modes.length && model.modality === 'image') {\n      const map = { generate: 'image-generation', edit: 'image-edit', upscale: 'image-upscale', 'background-removal': 'background-removal' };\n      if (!f.modes.some(mode => map[mode] === model.task)) return false;\n    }\n    if (f.quant.length && model.modality === 'text') {\n      const q = (model.text && model.text.quantization) || 'none';\n      if (!f.quant.includes(q)) return false;\n    }\n    if (f.ctx && model.modality === 'text' && !((model.text && model.text.context) >= Number(f.ctx))) return false;\n    if (f.price && model.modality === 'text' && !(model.pricing && model.pricing.input != null && model.pricing.input <= Number(f.price))) return false;\n    if (f.res && model.modality === 'image' && !((model.image && model.image.resolutions) || []).includes(f.res)) return false;\n    if (f.res && model.modality === 'video' && !(maxVideoHeight(model) >= Number(f.res))) return false;\n    if (f.audio && model.modality === 'video') {\n      const audio = model.video && model.video.audio;\n      if (f.audio === 'audio' && audio === 'none') return false;\n      if (f.audio === 'silent' && audio === 'native') return false;\n    }\n    if (f.dur && model.modality === 'video' && !(maxVideoSeconds(model) >= Number(f.dur))) return false;\n    return true;\n  };\n\n  const modelsOf = (catalog, family) => family.variants.map(id => catalog.models[id]).filter(Boolean);\n  // Groups whose checked options must all hold; in the others any may.\n  const ALL_OF = ['caps', 'flags'];\n\n  const familyMatches = (family, models, f, now) => {\n    if (f.providers.length && !f.providers.includes(family.provider)) return false;\n    if (f.flags.includes('new') && !isNew(family.updated || family.created, now)) return false;\n    if (f.flags.includes('beta') && !family.beta) return false;\n    if (f.flags.includes('deprecated') && !family.deprecated) return false;\n    if (f.flags.includes('open') && !family.openWeights) return false;\n    if (f.flags.includes('uncensored') && !family.uncensored) return false;\n    return models.some(model => variantMatches(model, f));\n  };\n\n  const SORTS = {\n    name: { label: 'Name A–Z', dir: 'ascending', fn: (a, b) => a.family.name.localeCompare(b.family.name) },\n    newest: { label: 'Newest', dir: 'descending', fn: (a, b) => (b.family.updated || 0) - (a.family.updated || 0) || a.family.name.localeCompare(b.family.name) },\n    price: { label: 'Price, low to high', dir: 'ascending', fn: (a, b) => (a.price == null ? 1e9 : a.price) - (b.price == null ? 1e9 : b.price) },\n    context: { label: 'Context, largest', dir: 'descending', fn: (a, b) => ((b.display.text && b.display.text.context) || 0) - ((a.display.text && a.display.text.context) || 0) },\n    input: { label: 'Input price, low to high', dir: 'ascending', fn: (a, b) => ((a.display.pricing && a.display.pricing.input) || 1e9) - ((b.display.pricing && b.display.pricing.input) || 1e9) },\n    output: { label: 'Output price, low to high', dir: 'ascending', fn: (a, b) => ((a.display.pricing && a.display.pricing.output) || 1e9) - ((b.display.pricing && b.display.pricing.output) || 1e9) }\n  };\n  const DEFAULT_SORT = 'newest';\n\n  const FilterGroup = ({ title, icon, children, defaultOpen = true, role }) => {\n    const [open, setOpen] = useState(defaultOpen);\n    return (\n      __jsx('div', { className: cls('vx-fgroup', open && 'is-open'),}\n        , __jsx('button', { type: \"button\", className: \"vx-fgroup-head\", onClick: () => setOpen(!open), 'aria-expanded': open,}\n          , __jsx(Icon, { name: icon, size: 16,} )\n          , __jsx('span', null, title)\n          , __jsx(Icon, { name: \"chevronDown\", size: 14, className: \"vx-fgroup-chevron\",} )\n        )\n        , open ? __jsx('div', { className: \"vx-fgroup-body\", role: role, 'aria-label': role ? title : undefined,}, children) : null\n      )\n    );\n  };\n\n  const Check = ({ checked, onChange, label, count, title, disabled, logo }) => (\n    __jsx('label', { className: cls('vx-check', checked && 'is-checked', disabled && 'is-disabled'), title: title,}\n      , __jsx('input', { type: \"checkbox\", checked: checked, onChange: onChange, disabled: disabled,} )\n      , __jsx('span', { className: \"vx-check-box\",}, __jsx(Icon, { name: \"check\", size: 12,} ))\n      , logo\n      , __jsx('span', { className: \"vx-check-label\",}, label)\n      , count != null ? __jsx('span', { className: \"vx-check-count\",}, count) : null\n    )\n  );\n\n  // A modality, picked like a page in a nav: its type icon, and the chosen\n  // one filled. The radio stays for keyboard and screen readers.\n  const ScopeOption = ({ scope, checked, onChange, label, count }) => (\n    __jsx('label', { className: cls('vx-check vx-scope', checked && 'is-checked'),}\n      , __jsx('input', { type: \"radio\", name: \"vx-modality\", checked: checked, onChange: onChange,} )\n      , __jsx('span', { className: `vx-scope-icon vx-type-${scope || 'all'}`, 'aria-hidden': \"true\",} )\n      , __jsx('span', { className: \"vx-check-label\",}, label)\n      , __jsx('span', { className: \"vx-check-count\",}, count)\n    )\n  );\n\n  // The same choice as tabs above the results, each with its type icon and its\n  // count, the chosen one underlined. Their radios are a group of their own:\n  // sharing the sidebar's name, the browser would uncheck one for the other.\n  const ScopeTabs = ({ scope, counts, onScope }) => {\n    const ref = useRef(null);\n    const shown = SCOPES.filter(s => !counts || counts[s.key]);\n    const total = counts ? shown.reduce((n, s) => n + counts[s.key], 0) : null;\n    // Where the row scrolls, as on a phone, the chosen tab is scrolled into\n    // view. Sideways only: scrollIntoView would also move the page.\n    useEffect(() => {\n      const row = ref.current;\n      const tab = row && row.querySelector('.is-checked');\n      if (tab && (tab.offsetLeft < row.scrollLeft || tab.offsetLeft + tab.offsetWidth > row.scrollLeft + row.clientWidth)) row.scrollLeft = tab.offsetLeft - 16;\n    }, [scope]);\n    return (\n      __jsx('div', { ref: ref, className: \"vx-tabs\", role: \"radiogroup\", 'aria-label': \"Modality\",}\n        , [{ key: null, label: 'All' }, ...shown].map(s => (\n          __jsx('label', { key: s.key || 'all', className: cls('vx-tab', (scope || null) === s.key && 'is-checked'), title: s.short ? s.label : undefined,}\n            , __jsx('input', { type: \"radio\", name: \"vx-modality-tab\", checked: (scope || null) === s.key, onChange: () => onScope(s.key),} )\n            , __jsx('span', { className: `vx-scope-icon vx-type-${s.key || 'all'}`, 'aria-hidden': \"true\",} )\n            , __jsx('span', null, s.short || s.label)\n            , counts ? __jsx('span', { className: \"vx-tab-count\",}, s.key ? counts[s.key] : total) : null\n          )\n        ))\n      )\n    );\n  };\n\n  // The filter column; below 1024px it opens as a drawer from the toolbar.\n  const DRAWER_MAX_WIDTH = 1024;\n  const FilterRail = ({ modality, task, scope, scopeCounts, onScope, statuses, filters, setFilters, facetCount, providerCounts, providers, onClear, open, onClose }) => {\n    const toggleIn = (key, value) => setFilters(prev => ({ ...prev, [key]: prev[key].includes(value) ? prev[key].filter(v => v !== value) : [...prev[key], value] }));\n    // An option nothing in scope matches is disabled unless already checked.\n    // A checked status stays, so it can be unchecked.\n    const hasStatus = flag => statuses[flag] || filters.flags.includes(flag);\n    const option = (key, value, label, title) => {\n      const checked = filters[key].includes(value);\n      const count = facetCount(key, value);\n      return __jsx(Check, { key: value, checked: checked, onChange: () => toggleIn(key, value), label: label, title: title, count: count, disabled: !checked && count === 0,} );\n    };\n    // Single-choice filters are segmented tracks, as in Gordon's column.\n    const range = (key, title, icon, options) => (\n      __jsx(FilterGroup, { title: title, icon: icon,}\n        , __jsx(Segmented, { ariaLabel: title, value: filters[key], onChange: value => setFilters(prev => ({ ...prev, [key]: value })),\n          options: options.map(([value, label, hint]) => ({ value, label, title: hint })),} )\n      )\n    );\n    const [showAll, setShowAll] = useState(false);\n    const providerName = slug => (providers[slug] && providers[slug].name) || slug;\n    const providerList = Object.entries(providerCounts).sort((a, b) => b[1] - a[1] || providerName(a[0]).localeCompare(providerName(b[0])));\n    // The short list is the top ten that would leave results, plus any checked\n    // provider wherever it ranks; Show all adds the rest, disabled.\n    const visibleProviders = showAll ? providerList : providerList.filter(([slug, n], i) => (i < 10 && n > 0) || filters.providers.includes(slug));\n    const count = activeFilterCount(filters);\n    return (\n      __jsx('aside', { id: \"vx-filters\", className: cls('vx-side vx-filters', open && 'is-open'), 'aria-label': \"Filters\",\n        role: open ? 'dialog' : undefined, 'aria-modal': open ? 'true' : undefined,}\n        , __jsx('div', { className: \"vx-side-inner\",}\n          , __jsx('div', { className: \"vx-rail-head\",}\n            , __jsx('span', null, \"Filters\")\n            , count ? __jsx('button', { type: \"button\", className: \"vx-link-btn\", onClick: onClear,}, \"Clear all (\"  , count, \")\") : null\n            , __jsx('button', { type: \"button\", className: \"vx-btn vx-btn-sm vx-rail-done\"  , onClick: onClose,}, \"Done\")\n          )\n\n          , __jsx(FilterGroup, { title: \"Modality\", icon: \"layers\", role: \"radiogroup\",}\n            , __jsx(ScopeOption, { checked: !scope, onChange: () => onScope(null), label: \"All\", count: Object.values(scopeCounts).reduce((n, c) => n + c, 0),} )\n            , SCOPES.filter(s => scopeCounts[s.key]).map(s => (\n              __jsx(ScopeOption, { key: s.key, scope: s.key, checked: scope === s.key, onChange: () => onScope(s.key), label: s.label, count: scopeCounts[s.key],} )\n            ))\n          )\n\n          , __jsx(FilterGroup, { title: \"Privacy\", icon: \"shield\",}\n            , PRIVACY_ORDER.map(tier => option('privacy', tier, PRIVACY[tier].label, PRIVACY[tier].desc))\n          )\n\n          , modality === 'text' ? (\n            __jsx(__Fragment, null\n              , __jsx(FilterGroup, { title: \"Capabilities\", icon: \"sparkles\",}\n                , TEXT_CAPS.filter(c => !['logprobs', 'xSearch', 'audioInput'].includes(c.key)).map(cap => option('caps', cap.key, cap.label, cap.desc))\n              )\n              , range('ctx', 'Context length', 'maximize', [['', 'Any'], ['128000', '128K', '128K tokens or more'], ['256000', '256K', '256K tokens or more'], ['1000000', '1M', '1M tokens or more']])\n              , range('price', 'Input price (per 1M tokens)', 'dollar', [['', 'Any'], ['0.5', '≤$0.5', 'Up to $0.50'], ['2', '≤$2', 'Up to $2'], ['5', '≤$5', 'Up to $5']])\n              , __jsx(FilterGroup, { title: \"Served precision\" , icon: \"gauge\", defaultOpen: false,}\n                , [['bf16', 'BF16'], ['fp16', 'FP16'], ['fp8', 'FP8'], ['fp4', 'FP4'], ['int4', 'INT4'], ['none', 'Not disclosed']].map(([value, label]) => option('quant', value, label, QUANT_NOTES[value]))\n              )\n            )\n          ) : null\n\n          , modality === 'image' ? (\n            __jsx(__Fragment, null\n              , __jsx(FilterGroup, { title: \"Task\", icon: \"wand\",}\n                , [['generate', 'Generate'], ['edit', 'Edit'], ['upscale', 'Upscale'], ['background-removal', 'Remove background']].map(([value, label]) => option('modes', value, label))\n              )\n              , range('res', 'Output resolution', 'maximize', [['', 'Any'], ['2K', '2K', '2K available'], ['4K', '4K', '4K available']])\n              , __jsx(FilterGroup, { title: \"Features\", icon: \"zap\",}\n                , option('caps', 'webSearch', 'Web-grounded generation')\n                , option('caps', 'multiImage', 'Multi-image editing')\n              )\n            )\n          ) : null\n\n          , modality === 'video' ? (\n            __jsx(__Fragment, null\n              , __jsx(FilterGroup, { title: \"Mode\", icon: \"film\",}\n                , ['t2v', 'i2v', 'r2v', 'v2v', 'flf', 'motion', 'transition'].map(mode => option('modes', mode, VARIANT_LABELS[mode]))\n              )\n              , range('audio', 'Audio', 'volume', [['', 'Any'], ['audio', 'Audio', 'Generates audio'], ['silent', 'Silent', 'Can be silent']])\n              , range('res', 'Resolution', 'maximize', [['', 'Any'], ['720', '720p', '720p or higher'], ['1080', '1080p', '1080p or higher'], ['1440', '1440p', '1440p or higher'], ['2160', '4K']])\n              , range('dur', 'Clip length', 'clock', [['', 'Any'], ['10', '10s', '10 seconds or longer'], ['15', '15s', '15 seconds or longer'], ['20', '20s', '20 seconds or longer'], ['30', '30s', '30 seconds or longer']])\n            )\n          ) : null\n\n          , hasStatus('beta') || hasStatus('deprecated') || filters.flags.includes('new') ? (\n            __jsx(FilterGroup, { title: \"Status\", icon: \"clock\",}\n              , option('flags', 'new', 'New', 'Added in the last 30 days.')\n              , hasStatus('beta') ? option('flags', 'beta', 'Beta', 'Experimental. May change or be removed without notice.') : null\n              , hasStatus('deprecated') ? option('flags', 'deprecated', 'Deprecated', 'Scheduled for removal. See Deprecations.') : null\n            )\n          ) : null\n\n          , __jsx(FilterGroup, { title: \"Attributes\", icon: \"sliders\",}\n            , option('flags', 'open', 'Open weights')\n            , option('flags', 'uncensored', 'Uncensored')\n          )\n\n          , __jsx(FilterGroup, { title: \"Provider\", icon: \"server\",}\n            , visibleProviders.map(([slug, n]) => {\n              const checked = filters.providers.includes(slug);\n              return __jsx(Check, { key: slug, checked: checked, onChange: () => toggleIn('providers', slug), label: providerName(slug), count: n, disabled: !checked && n === 0,\n                logo: __jsx(ProviderLogo, { provider: providers[slug], size: 18, title: null,} ),} );\n            })\n            , providerList.length > 10 ? (\n              __jsx('button', { type: \"button\", className: \"vx-link-btn vx-more\" , onClick: () => setShowAll(!showAll),}, showAll ? 'Show fewer' : `Show all ${providerList.length}`)\n            ) : null\n          )\n        )\n      )\n    );\n  };\n\n  // Titles in a view show as tooltips: after a beat on hover, and at once on\n  // keyboard focus. The pointer test looks beneath a row's link, so a logo or\n  // badge under it shows its tooltip while a click still opens the row. The\n  // title is set aside while its tooltip shows, so the browser's own stays\n  // hidden. data-tip-label adds a heading, and data-tip replaces the title as\n  // the text. A title that only repeats text in full view shows nothing.\n  const TIP_DELAY = 150;\n  const HoverTips = () => {\n    const anchor = useRef(null);\n    const [tip, setTip] = useState(null);\n    useEffect(() => {\n      const root = anchor.current && anchor.current.parentElement;\n      if (!root) return undefined;\n      let target = null;\n      let pending = null;\n      let timer = 0;\n      let frame = 0;\n      const tippable = el => el.nodeType === 1 && root.contains(el) && !el.closest('.vx-tip-anchor')\n        && (el.hasAttribute('title') || el.hasAttribute('data-tip-label'));\n      const restore = () => {\n        if (!target) return;\n        if (target.hasAttribute('data-tip-title')) {\n          target.setAttribute('title', target.getAttribute('data-tip-title'));\n          target.removeAttribute('data-tip-title');\n        }\n        target.classList.remove('is-tipped');\n        target = null;\n      };\n      const hide = () => {\n        clearTimeout(timer);\n        pending = null;\n        restore();\n        setTip(null);\n      };\n      const show = el => {\n        const title = el.getAttribute('title');\n        const label = el.getAttribute('data-tip-label');\n        const text = el.getAttribute('data-tip') || title;\n        const clipped = [el, ...el.querySelectorAll('*')].some(node => node.scrollWidth > node.clientWidth);\n        const repeats = !label && text && text === el.textContent.trim() && !clipped;\n        if ((!label && !text) || repeats) return;\n        if (title != null) {\n          el.setAttribute('data-tip-title', title);\n          el.removeAttribute('title');\n        }\n        el.classList.add('is-tipped');\n        target = el;\n        const r = el.getBoundingClientRect();\n        const lines = (text ? text.split('\\n').length : 0) + (label ? 1 : 0);\n        const above = r.top > lines * 17 + 32;\n        const x = Math.min(Math.max(r.left + r.width / 2, 148), window.innerWidth - 148);\n        setTip({ label, text: text === label ? null : text, above, style: { left: x, top: above ? r.top - 8 : r.bottom + 8 } });\n      };\n      const over = el => {\n        if (el ? el === target || el === pending : !target && !pending) return;\n        hide();\n        if (!el) return;\n        pending = el;\n        timer = setTimeout(() => { pending = null; show(el); }, TIP_DELAY);\n      };\n      const onMove = e => {\n        if (e.pointerType === 'touch') return;\n        const { clientX, clientY } = e;\n        cancelAnimationFrame(frame);\n        frame = requestAnimationFrame(() => over(document.elementsFromPoint(clientX, clientY).find(tippable) || null));\n      };\n      const onFocus = e => {\n        if (!tippable(e.target) || !e.target.matches(':focus-visible')) return;\n        hide();\n        show(e.target);\n      };\n      const onKey = e => { if (e.key === 'Escape') hide(); };\n      // Touch has no hover, so a tap on an info icon shows its tip, and the\n      // next tap hides it. The tip opens on click, after the tap moves focus.\n      let touched = null;\n      const onDown = e => {\n        touched = e.pointerType === 'touch' ? { open: target } : null;\n        hide();\n      };\n      const onClick = e => {\n        const info = touched && e.target.closest ? e.target.closest('.vx-info') : null;\n        if (info && root.contains(info) && info !== touched.open) show(info);\n        touched = null;\n      };\n      const onLeave = e => { if (e.pointerType !== 'touch') hide(); };\n      root.addEventListener('pointermove', onMove);\n      root.addEventListener('pointerleave', onLeave);\n      root.addEventListener('focusin', onFocus);\n      root.addEventListener('focusout', hide);\n      root.addEventListener('click', onClick);\n      document.addEventListener('pointerdown', onDown, true);\n      document.addEventListener('keydown', onKey);\n      window.addEventListener('scroll', hide, true);\n      return () => {\n        cancelAnimationFrame(frame);\n        root.removeEventListener('pointermove', onMove);\n        root.removeEventListener('pointerleave', onLeave);\n        root.removeEventListener('focusin', onFocus);\n        root.removeEventListener('focusout', hide);\n        root.removeEventListener('click', onClick);\n        document.removeEventListener('pointerdown', onDown, true);\n        document.removeEventListener('keydown', onKey);\n        window.removeEventListener('scroll', hide, true);\n        clearTimeout(timer);\n        restore();\n      };\n    }, []);\n    return (\n      __jsx(__Fragment, null\n        , __jsx('span', { ref: anchor, hidden: true,} )\n        , tip ? (\n          __jsx('span', { className: cls('vx-hovertip', !tip.above && 'is-below'), role: \"tooltip\", style: tip.style,}\n            , tip.label ? __jsx('strong', null, tip.label) : null\n            , tip.text ? __jsx('span', null, tip.text) : null\n          )\n        ) : null\n      )\n    );\n  };\n\n  // A \"from\" price lists its options on hover, focus or tap. The trigger is a\n  // button described by the list, so screen readers announce the options with\n  // the price. The list is fixed to the viewport so table and card overflow\n  // can't clip it.\n  let tipCount = 0;\n  const PriceTip = ({ breakdown, children }) => {\n    const ref = useRef(null);\n    const [tipId] = useState(() => `vx-tip-${(tipCount += 1)}`);\n    const [pos, setPos] = useState(null);\n    useEffect(() => {\n      if (!pos) return undefined;\n      const close = () => setPos(null);\n      const closeOutside = e => { if (ref.current && !ref.current.contains(e.target)) close(); };\n      window.addEventListener('scroll', close, true);\n      window.addEventListener('resize', close);\n      document.addEventListener('pointerdown', closeOutside);\n      return () => {\n        window.removeEventListener('scroll', close, true);\n        window.removeEventListener('resize', close);\n        document.removeEventListener('pointerdown', closeOutside);\n      };\n    }, [pos]);\n    if (!breakdown) return children;\n    const open = () => {\n      const r = ref.current.getBoundingClientRect();\n      const below = window.innerHeight - r.bottom > breakdown.length * 20 + 32;\n      const left = r.left < window.innerWidth / 2;\n      setPos({\n        top: below ? r.bottom + 6 : null,\n        bottom: below ? null : window.innerHeight - r.top + 6,\n        left: left ? r.left : null,\n        right: left ? null : window.innerWidth - r.right\n      });\n    };\n    return (\n      __jsx('button', { ref: ref, type: \"button\", className: \"vx-tip-anchor\", 'aria-describedby': tipId,\n        onMouseEnter: open, onMouseLeave: () => setPos(null), onFocus: open, onBlur: () => setPos(null), onClick: open,\n        onKeyDown: e => { if (e.key === 'Escape' && pos) { e.stopPropagation(); setPos(null); } },}\n        , children\n        , __jsx('span', { id: tipId, role: \"tooltip\", className: \"vx-tip\", style: pos || undefined, hidden: !pos,}\n          , breakdown.map(([label, text]) => __jsx('span', { key: label, className: \"vx-tip-row\",}, __jsx('span', null, label), __jsx('span', null, text)))\n        )\n      )\n    );\n  };\n\n  const PriceCell = ({ value, unit, note, strong, from, breakdown }) => (\n    __jsx(PriceTip, { breakdown: breakdown,}\n      , __jsx('span', { className: cls('vx-price', strong && 'is-strong'),}\n        , from ? __jsx('span', { className: \"vx-price-from\",}, \"from \" ) : null\n        , __jsx('span', { className: \"vx-price-value\",}, usd(value))\n        , unit && value != null && value !== 0 ? __jsx('span', { className: \"vx-price-unit\",}, unit) : null\n        , note ? __jsx('span', { className: \"vx-price-note\", title: note,}, \"*\") : null\n      )\n    )\n  );\n  const OfferPrice = ({ offer, strong }) => (\n    __jsx(PriceCell, { value: offer.value, unit: offer.unit, note: offer.note, from: offer.from, breakdown: offer.breakdown, strong: strong,} )\n  );\n\n  const modelHref = (family, id) => `/models/${family.slug}${id !== family.primary ? `?v=${encodeURIComponent(id)}` : ''}`;\n  const privacySummary = tiers => privacyTiers(tiers).map(tier => (PRIVACY[tier] ? PRIVACY[tier].label : tier)).join(', ');\n\n  const ModelCell = ({ row, providers, now, showScope }) => {\n    const { family, display } = row;\n    const provider = providers[family.provider];\n    const extra = family.variants.length - 1;\n    return (\n      __jsx('div', { className: \"vx-mcell\",}\n        , __jsx(ProviderLogo, { provider: provider, size: 28,} )\n        , __jsx('div', { className: \"vx-mcell-body\",}\n          , __jsx('div', { className: \"vx-mcell-top\",}\n            , __jsx('a', { className: \"vx-mcell-name\", href: modelHref(family, display.id),}, family.name)\n            , showScope ? __jsx(TypeBadge, { family: family,} ) : null\n            , __jsx(CopyButton, { text: display.id, iconOnly: true, label: `Copy model ID ${display.id}`, className: \"vx-row-copy\",} )\n            , __jsx(StatusTags, { item: family, now: now,} )\n          )\n          , extra > 0 ? __jsx('div', { className: \"vx-mcell-sub\",}, __jsx('span', { className: \"vx-mcell-more\", title: family.variants.join('\\n'),}, \"+\", extra, \" \" , extra === 1 ? 'variant' : 'variants')) : null\n          , __jsx('div', { className: \"vx-mcell-mobile\",}, [keySpec(display), privacySummary(family.privacy)].filter(Boolean).join(' · '))\n        )\n      )\n    );\n  };\n\n  const modeChips = (family, catalog) => (family.variants || []).map(id => catalog.models[id]).filter(Boolean).map(m => m.variant);\n\n  const ModeList = ({ modes, active, labels }) => (\n    __jsx('span', { className: \"vx-modes\",}\n      , modes.map(v => __jsx('span', { key: v, className: v === active ? 'is-active' : undefined,}, labels[v] || v))\n    )\n  );\n\n  // `hide` drops a column below a breakpoint (lg 1280px, md 1024px, sm 700px);\n  // the model cell repeats the key spec and privacy tier on small screens.\n  const explorerColumns = (modality, task, filters, catalog) => {\n    const privacy = { key: 'privacy', label: 'Privacy', hide: 'sm', render: row => __jsx(PrivacyStack, { tiers: row.family.privacy,} ) };\n    const added = { key: 'added', label: 'Added', sort: 'newest', align: 'right', hide: 'lg', render: row => __jsx('span', { className: \"vx-muted vx-nowrap\" ,}, shortDate(row.family.updated || row.family.created)) };\n    if (modality === 'text') {\n      return [\n        { key: 'context', label: 'Context', sort: 'context', align: 'right', hide: 'sm', render: row => __jsx('span', { className: \"vx-num\",}, tokens(row.display.text && row.display.text.context)) },\n        { key: 'input', label: 'Input', sort: 'input', align: 'right', hide: 'md', render: row => __jsx(PriceCell, { value: row.display.pricing && row.display.pricing.input,} ) },\n        { key: 'output', label: 'Output', sort: 'output', align: 'right', hide: 'md', render: row => __jsx(PriceCell, { value: row.display.pricing && row.display.pricing.output,} ) },\n        { key: 'cache', label: 'Cached', align: 'right', hide: 'lg', hint: 'Cached input (prompt cache read)', render: row => __jsx(PriceCell, { value: row.display.pricing && row.display.pricing.cacheRead,} ) },\n        { key: 'blended', label: 'Blended', sort: 'price', align: 'right', hint: 'Blended = (3 × input + output) / 4, the mix Artificial Analysis uses.', render: row => __jsx(PriceCell, { value: row.price, strong: true,} ) },\n        { key: 'caps', label: 'Capabilities', hide: 'md', render: row => __jsx(CapIcons, { model: row.display,} ) },\n        privacy\n      ];\n    }\n    if (modality === 'image') {\n      return [\n        { key: 'tasks', label: 'Tasks', hide: 'md', render: row => __jsx(ModeList, { modes: [...new Set(modeChips(row.family, catalog))], labels: VARIANT_LABELS,} ) },\n        { key: 'price', label: filters.res ? `Price at ${filters.res}` : 'Price', sort: 'price', align: 'right', render: row => __jsx(OfferPrice, { offer: row.offer, strong: true,} ) },\n        { key: 'res', label: 'Max output', align: 'right', hide: 'sm', render: row => __jsx('span', { className: \"vx-num\",}, imageMaxRes(row.display) || '—') },\n        { key: 'ar', label: 'Aspect ratios', align: 'right', hide: 'lg', render: row => __jsx('span', { className: \"vx-num\",}, ((row.display.image && row.display.image.aspectRatios) || []).filter(a => a !== 'auto').length || '—') },\n        privacy\n      ];\n    }\n    if (modality === 'video') {\n      return [\n        { key: 'modes', label: 'Modes', hide: 'md', render: row => __jsx(ModeList, { modes: modeChips(row.family, catalog), active: row.display.variant, labels: MODE_SHORT,} ) },\n        { key: 'persec', label: 'Per second', sort: 'price', align: 'right', render: row => (row.offer.status === 'quoted'\n          ? __jsx(OfferPrice, { offer: row.offer, strong: true,} )\n          : __jsx('span', { className: \"vx-muted\", title: \"Priced by the length of the source video. Use /video/quote.\"         ,}, \"By source\" )) },\n        filters.dur ? { key: 'clip', label: `${filters.dur}s clip`, align: 'right', hide: 'sm', render: row => (row.offer.clip != null\n          ? __jsx(PriceCell, { value: row.offer.clip, unit: row.offer.seconds !== Number(filters.dur) ? `${row.offer.seconds}s` : null,} )\n          : __jsx('span', { className: \"vx-muted\",}, \"—\")) } : null,\n        { key: 'max', label: 'Max', align: 'right', hide: 'lg', render: row => __jsx('span', { className: \"vx-num\",}, heightLabel(maxVideoHeight(row.display)), \" · \"  , maxVideoSeconds(row.display) ? `${maxVideoSeconds(row.display)}s` : 'source') },\n        { key: 'audio', label: 'Audio', hide: 'md', render: row => {\n          const a = row.display.video && row.display.video.audio;\n          return __jsx('span', { className: a === 'native' || a === 'optional' ? undefined : 'vx-muted',}, a === 'native' ? 'Native' : a === 'optional' ? 'Optional' : 'None');\n        } },\n        privacy\n      ].filter(Boolean);\n    }\n    if (modality === 'audio') {\n      if (task === 'stt') {\n        return [\n          { key: 'hour', label: 'Per audio hour', sort: 'price', align: 'right', render: row => __jsx(PriceCell, { value: row.display.pricing && row.display.pricing.perHour, strong: true,} ) },\n          { key: 'k', label: 'Per 1K minutes', align: 'right', hide: 'sm', render: row => __jsx(PriceCell, { value: row.display.pricing && row.display.pricing.perMinute != null ? row.display.pricing.perMinute * 1000 : null,} ) },\n          privacy\n        ];\n      }\n      if (task === 'music') {\n        return [\n          { key: 'type', label: 'Type', hide: 'md', render: row => TASK_LABELS[row.display.task] },\n          { key: 'price', label: 'Price', sort: 'price', align: 'right', render: row => __jsx(OfferPrice, { offer: row.offer, strong: true,} ) },\n          { key: 'len', label: 'Max length', align: 'right', hide: 'sm', render: row => __jsx('span', { className: \"vx-num\",}, row.display.audio && row.display.audio.maxDuration ? `${Math.round(row.display.audio.maxDuration / 60 * 10) / 10} min` : '—') },\n          { key: 'lyrics', label: 'Lyrics', hide: 'lg', render: row => (row.display.audio && row.display.audio.lyrics ? 'Yes' : __jsx('span', { className: \"vx-muted\",}, \"No\")) },\n          privacy\n        ];\n      }\n      return [\n        { key: 'chars', label: 'Per 1M chars', sort: 'price', align: 'right', render: row => __jsx(PriceCell, { value: row.price, strong: true,} ) },\n        { key: 'min', label: 'Per minute', align: 'right', hide: 'sm', hint: 'At about 825 characters per minute of speech.', render: row => __jsx(PriceCell, { value: row.display.pricing && row.display.pricing.perMinute,} ) },\n        { key: 'voices', label: 'Voices', align: 'right', hide: 'md', render: row => __jsx('span', { className: \"vx-num\",}, (row.display.audio && row.display.audio.voiceCount) || '—') },\n        privacy\n      ];\n    }\n    if (modality === 'embedding') {\n      return [\n        { key: 'dims', label: 'Dimensions', align: 'right', hide: 'sm', render: row => __jsx('span', { className: \"vx-num\",}, (row.display.embedding && row.display.embedding.dimensions) ? row.display.embedding.dimensions.toLocaleString('en-US') : '—') },\n        { key: 'max', label: 'Max input', align: 'right', hide: 'md', render: row => __jsx('span', { className: \"vx-num\",}, tokens(row.display.embedding && row.display.embedding.maxInputTokens)) },\n        { key: 'price', label: 'Per 1M tokens', sort: 'price', align: 'right', render: row => __jsx(PriceCell, { value: row.price, strong: true,} ) },\n        privacy\n      ];\n    }\n    return [\n      { key: 'type', label: 'Type', hide: 'sm', render: row => __jsx('span', { className: \"vx-nowrap\",}, TASK_LABELS[row.display.task] || row.family.modality) },\n      { key: 'price', label: 'Price', align: 'right', hint: 'Blended per 1M tokens for text; per image, second, character or minute elsewhere.', render: row => __jsx(OfferPrice, { offer: row.offer, strong: true,} ) },\n      { key: 'spec', label: 'Key spec', hide: 'md', render: row => __jsx('span', { className: \"vx-muted vx-nowrap\" ,}, keySpec(row.display)) },\n      privacy, added\n    ];\n  };\n\n  const keySpec = model => {\n    if (model.modality === 'text' && model.text) return `${tokens(model.text.context)} context`;\n    if (model.modality === 'image') return imageMaxRes(model) ? `Up to ${imageMaxRes(model)}` : VARIANT_LABELS[model.variant] || '';\n    if (model.modality === 'video') return `${heightLabel(maxVideoHeight(model))} · ${maxVideoSeconds(model) ? `up to ${maxVideoSeconds(model)}s` : 'source length'}`;\n    if (model.task === 'tts') return `${(model.audio && model.audio.voiceCount) || 0} voices`;\n    if (model.modality === 'embedding' && model.embedding) return `${model.embedding.dimensions || '—'} dims`;\n    return TASK_LABELS[model.task] || '';\n  };\n\n  const hideCls = col => (col.hide ? `vx-hide-${col.hide}` : null);\n\n  const HeaderLabel = ({ col }) => (\n    __jsx(__Fragment, null\n      , col.label\n      , col.sub ? __jsx('span', { className: \"vx-th-sub\",}, col.sub) : null\n    )\n  );\n\n  const ExplorerTable = ({ rows, columns, sort, setSort, providers, now, showScope }) => (\n    __jsx('div', { className: \"vx-table-wrap\",}\n      , __jsx('table', { className: \"vx-table\",}\n        , __jsx('thead', null\n          , __jsx('tr', null\n            , __jsx('th', { className: \"vx-th-model\", 'aria-sort': sort === 'name' ? 'ascending' : undefined,}\n              , __jsx('button', { type: \"button\", className: cls('vx-th-btn', sort === 'name' && 'is-sorted'), onClick: () => setSort('name'),}, \"Model\"\n                , __jsx(Icon, { name: \"chevronDown\", size: 12, className: \"vx-sort-icon is-up\" ,} )\n              )\n            )\n            , columns.map(col => (\n              __jsx('th', { key: col.key, className: cls(col.align && `vx-al-${col.align}`, hideCls(col)), title: col.hint,\n                'aria-sort': col.sort && sort === col.sort ? SORTS[col.sort].dir : undefined,}\n                , col.sort ? (\n                  __jsx('button', { type: \"button\", className: cls('vx-th-btn', sort === col.sort && 'is-sorted'), onClick: () => setSort(col.sort),}\n                    , __jsx(HeaderLabel, { col: col,} )\n                    , __jsx(Icon, { name: \"chevronDown\", size: 12, className: cls('vx-sort-icon', SORTS[col.sort].dir === 'ascending' && 'is-up'),} )\n                  )\n                ) : __jsx(HeaderLabel, { col: col,} )\n              )\n            ))\n          )\n        )\n        , __jsx('tbody', null\n          , rows.map(row => (\n            __jsx('tr', { key: row.family.slug,}\n              , __jsx('td', { className: \"vx-td-model\",}, __jsx(ModelCell, { row: row, providers: providers, now: now, showScope: showScope,} ))\n              , columns.map(col => __jsx('td', { key: col.key, className: cls(col.align && `vx-al-${col.align}`, hideCls(col)),}, col.render(row)))\n            )\n          ))\n        )\n      )\n    )\n  );\n\n  const ExplorerCard = ({ row, now, catalog, showScope }) => {\n    const { family, display } = row;\n    const isVideo = family.modality === 'video';\n    const media = galleryMedia(family, display, catalog);\n    const { offer } = row;\n    const href = modelHref(family, display.id);\n    const extra = family.variants.length - 1;\n    return (\n      __jsx('article', { className: \"vx-card\",}\n        , __jsx('a', { className: cls('vx-card-media', isVideo ? 'is-video' : 'is-image'), href: href, tabIndex: -1, 'aria-hidden': \"true\",}\n          , media\n            ? (media.type === 'video' ? __jsx(HoverVideo, { src: media.url, className: \"vx-card-el\",} ) : __jsx('img', { className: \"vx-card-el\", src: media.url, srcSet: sampleSrcSet(media.url), sizes: CARD_SIZES, alt: \"\", loading: \"lazy\", decoding: \"async\",} ))\n            : __jsx(MediaFallback, null )\n          , isVideo && media ? __jsx('span', { className: \"vx-card-play\",}, __jsx(Icon, { name: \"play\", size: 10,} )) : null\n        )\n        , __jsx('div', { className: \"vx-card-body\",}\n          , __jsx('div', { className: \"vx-card-top\",}\n            , __jsx('a', { className: \"vx-card-name\", href: href, title: family.name,}, family.name)\n            , showScope ? __jsx(TypeBadge, { family: family,} ) : null\n            , __jsx(CopyButton, { text: display.id, iconOnly: true, label: `Copy model ID ${display.id}`, className: \"vx-row-copy\",} )\n            , __jsx(StatusTags, { item: family, now: now,} )\n          )\n          , __jsx('div', { className: \"vx-card-variants\",}\n            , extra > 0 ? __jsx('span', { className: \"vx-list-more\", title: family.variants.join('\\n'),}, \"+\", extra, \" \" , extra === 1 ? 'variant' : 'variants') : null\n          )\n          , __jsx('div', { className: \"vx-card-foot\",}\n            , isVideo && offer.status !== 'quoted' ? __jsx('span', { className: \"vx-card-price vx-muted\" ,}, \"Priced by source length\"   ) : (\n              __jsx(PriceTip, { breakdown: offer.breakdown,}\n                , __jsx('span', { className: \"vx-card-price\",}\n                  , offer.from ? 'from ' : null, __jsx('strong', null, usd(offer.value)), \" \" , offer.unit\n                  , offer.clip != null ? __jsx('span', { className: \"vx-muted\",}, \" · \"  , usd(offer.clip), \" per \"  , offer.seconds, \"s\") : null\n                )\n              )\n            )\n            , __jsx(PrivacyStack, { tiers: family.privacy,} )\n          )\n          , isVideo ? __jsx(ModeList, { modes: modeChips(family, catalog), active: display.variant, labels: MODE_SHORT,} ) : null\n        )\n      )\n    );\n  };\n\n  // List view: logo, name and price; the description when the\n  // catalog has one; then the model ID, type (when the results mix types),\n  // privacy and key specs on one line. Capabilities are left to the filters\n  // and the table.\n  const TYPE_LABELS = {\n    chat: 'Text', decision: 'Decision', 'image-generation': 'Image', 'image-edit': 'Image edit', 'image-upscale': 'Upscale',\n    'background-removal': 'Background removal', video: 'Video', tts: 'Text to speech', stt: 'Speech to text', music: 'Music', sfx: 'Sound effects', embedding: 'Embedding'\n  };\n\n  const rowPrice = row => {\n    const { display, offer } = row;\n    const p = display.pricing || {};\n    if (display.task === 'chat') return p.input != null ? __jsx(__Fragment, null, usd(p.input), \" / \"  , usd(p.output), __jsx('span', { className: \"vx-muted\",}, \" per 1M\"  )) : null;\n    if (display.modality === 'video' && offer.status !== 'quoted') return __jsx('span', { className: \"vx-muted\",}, \"By source\" );\n    return offer.value != null ? __jsx(OfferPrice, { offer: offer,} ) : null;\n  };\n\n  // The price already leads the row, so text lists limits rather than\n  // repeating it.\n  const rowSummary = model => {\n    if (model.task !== 'chat' || !model.text) return keySpec(model);\n    const p = model.pricing || {};\n    return [\n      model.text.context ? `${tokens(model.text.context)} context` : null,\n      model.text.maxOutput ? `${tokens(model.text.maxOutput)} max output` : null,\n      p.cacheRead != null ? `${usd(p.cacheRead)}/M cached input` : null\n    ].filter(Boolean).join(' · ');\n  };\n\n  const ExplorerList = ({ rows, providers, now, showType, showScope }) => (\n    __jsx('ul', { className: \"vx-list\",}\n      , rows.map(row => {\n        const { family, display } = row;\n        const provider = providers[family.provider];\n        const extra = family.variants.length - 1;\n        const description = display.description || family.description;\n        const type = TYPE_LABELS[display.task] || family.modality;\n        const spec = rowSummary(display);\n        const details = [showType ? type : null, display.privacy === 'e2ee' ? null : privacySummary(family.privacy), spec === type || spec === TASK_LABELS[display.task] ? null : spec].filter(Boolean).join(' · ');\n        return (\n          __jsx('li', { key: family.slug, className: \"vx-list-row\",}\n            , __jsx('div', { className: \"vx-list-top\",}\n              , __jsx(ProviderLogo, { provider: provider, size: 22,} )\n              , __jsx('a', { className: \"vx-list-name\", href: modelHref(family, display.id),}, display.privacy === 'e2ee' ? __jsx(__Fragment, null, family.name.replace(/ E2EE$/, ''), \" \" , __jsx(Tag, { tone: \"e2ee\", title: PRIVACY.e2ee.desc,}, __jsx(Icon, { name: \"lock\", size: 10,} ), \"E2EE\")) : family.name)\n              , showScope ? __jsx(TypeBadge, { family: family,} ) : null\n              , __jsx(CopyButton, { text: display.id, iconOnly: true, label: `Copy model ID ${display.id}`, className: \"vx-row-copy\",} )\n              , __jsx(StatusTags, { item: family, now: now,} )\n              , __jsx('span', { className: \"vx-list-price\",}, rowPrice(row))\n            )\n            , description ? __jsx('p', { className: \"vx-list-desc\",}, description) : null\n            , __jsx('div', { className: \"vx-list-sum\",}\n              , extra > 0 ? __jsx('span', { className: \"vx-list-more\", title: family.variants.join('\\n'),}, \"+\", extra, \" \" , extra === 1 ? 'variant' : 'variants') : null\n              , __jsx('span', null, details)\n            )\n          )\n        );\n      })\n    )\n  );\n\n  // Families with nothing on the gallery's prompt go in a table under it\n  // rather than as tiles of another scene, so the grid compares like with like.\n  const Gallery = ({ rows, columns, sort, setSort, providers, now, catalog, modality, showScope }) => {\n    const rendered = rows.filter(row => galleryMedia(row.family, row.display, catalog));\n    const pending = rows.filter(row => !galleryMedia(row.family, row.display, catalog));\n    const prompt = ((catalog.mediaSuite || {})[modality] || []).find(item => item.id === GALLERY_PROMPTS[modality]);\n    const transforms = rendered.some(row => galleryMedia(row.family, row.display, catalog).from);\n    return (\n      __jsx(__Fragment, null\n        , rendered.length && prompt ? (\n          __jsx('p', { className: \"vx-gallery-prompt\",}\n            , __jsx('span', { className: \"vx-gallery-prompt-label\",}, \"Prompt\")\n            , __jsx('q', null, prompt.prompt)\n            , transforms ? __jsx('span', { className: \"vx-gallery-prompt-note\",}, \"Models that edit, extend or upscale start from a render of it.\"           ) : null\n          )\n        ) : null\n        , rendered.length ? (\n          __jsx('div', { className: cls('vx-cards', modality === 'video' && 'is-video'),}\n            , rendered.map(row => __jsx(ExplorerCard, { key: row.family.slug, row: row, now: now, catalog: catalog, showScope: showScope,} ))\n          )\n        ) : null\n        , pending.length ? (\n          __jsx('section', { className: \"vx-unrendered\", 'aria-labelledby': \"vx-unrendered-title\",}\n            , __jsx('h3', { id: \"vx-unrendered-title\", className: \"vx-h3\",}, prompt ? `Not rendered on the ${prompt.title.toLowerCase()} prompt` : 'No reference renders yet', \" \" , __jsx('span', { className: \"vx-muted\",}, plural(pending.length, 'family')))\n            , __jsx(ExplorerTable, { rows: pending, columns: columns, sort: sort, setSort: setSort, providers: providers, now: now, showScope: showScope,} )\n          )\n        ) : null\n      )\n    );\n  };\n\n  const ModelExplorer = ({ modality: initialModality = 'all', task: initialTask }) => {\n    const { catalog, error } = useCatalog();\n    const now = useNow();\n    const startScope = initialScope(initialModality, initialTask);\n    // A link's state applies on the first render, so a shared view opens as\n    // it was.\n    const [linked] = useState(() => {\n      const params = readParams();\n      // `m=audio&t=stt` is the shape of links from before the facet.\n      const m = params.get('m') === 'audio' ? params.get('t') || 'tts' : params.get('m') || (initialModality === 'audio' && params.get('t'));\n      const scope = m === 'all' ? null : parseScope(m) || startScope;\n      return {\n        scope,\n        query: params.get('q') || '',\n        sort: params.get('sort') && SORTS[params.get('sort')] ? params.get('sort') : DEFAULT_SORT,\n        // Links leave the view out when it is the modality's default.\n        view: VIEWS.includes(params.get('view')) ? params.get('view') : defaultView(scope),\n        filters: { ...EMPTY_FILTERS, ...filtersFromParams(params) }\n      };\n    });\n    const [scope, setScope] = useState(linked.scope);\n    const [query, setQuery] = useState(linked.query);\n    const [filters, setFilters] = useState(linked.filters);\n    const [sort, setSort] = useState(linked.sort);\n    const [view, setView] = useState(linked.view);\n    const [railOpen, setRailOpen] = useState(false);\n    const [limit, setLimit] = useState(PAGE_SIZE);\n    const searchRef = useRef(null);\n    // A chosen modality brings its columns, filters and price lenses; All\n    // shows the cross-modality view.\n    const modality = AUDIO_SCOPES.includes(scope) ? 'audio' : scope && scope !== 'decision' ? scope : 'all';\n    const task = AUDIO_SCOPES.includes(scope) ? scope : 'tts';\n\n    useEffect(() => {\n      // \"/\" jumps to the search unless the reader is typing somewhere or the\n      // filter drawer holds focus.\n      const typing = el => Boolean(el && (el.isContentEditable || ['INPUT', 'TEXTAREA', 'SELECT'].includes(el.tagName)));\n      const onKey = e => {\n        if (e.key !== '/' || e.defaultPrevented || e.metaKey || e.ctrlKey || e.altKey) return;\n        if (typing(e.target) || typing(document.activeElement) || document.querySelector('#vx-filters[aria-modal]')) return;\n        e.preventDefault();\n        if (searchRef.current) searchRef.current.focus();\n      };\n      window.addEventListener('keydown', onKey);\n      return () => window.removeEventListener('keydown', onKey);\n    }, []);\n\n    useEffect(() => {\n      writeParams({\n        m: scope === startScope ? null : scope || 'all',\n        q: query || null,\n        sort: sort !== DEFAULT_SORT ? sort : null,\n        view: view !== defaultView(modality) ? view : null,\n        ...filtersToParams(filters)\n      });\n    }, [scope, query, sort, view, filters]);\n\n    useEffect(() => { setLimit(PAGE_SIZE); }, [scope, filters, query, sort, view]);\n\n    useEffect(() => {\n      if (!railOpen) return undefined;\n      // The drawer is modal: focus moves into it on open and back to the\n      // toggle on close, Tab stays inside it and the page under it holds still.\n      const drawer = document.getElementById('vx-filters');\n      const done = drawer && drawer.querySelector('.vx-rail-done');\n      if (done) done.focus();\n      const root = document.documentElement;\n      const overflow = root.style.overflow;\n      root.style.overflow = 'hidden';\n      const tabbable = () => (drawer ? [...drawer.querySelectorAll(FOCUSABLE)].filter(el => el.offsetParent !== null) : []);\n      const onKey = e => {\n        if (e.key === 'Escape') { setRailOpen(false); return; }\n        if (e.key !== 'Tab') return;\n        const items = tabbable();\n        if (!items.length) return;\n        const first = items[0];\n        const last = items[items.length - 1];\n        const inside = drawer.contains(document.activeElement);\n        if (e.shiftKey && (!inside || document.activeElement === first)) { e.preventDefault(); last.focus(); }\n        else if (!e.shiftKey && (!inside || document.activeElement === last)) { e.preventDefault(); first.focus(); }\n      };\n      // Widening past the drawer breakpoint turns it back into the column.\n      const wide = window.matchMedia(`(min-width: ${DRAWER_MAX_WIDTH + 1}px)`);\n      const onWide = () => { if (wide.matches) setRailOpen(false); };\n      window.addEventListener('keydown', onKey);\n      wide.addEventListener('change', onWide);\n      return () => {\n        window.removeEventListener('keydown', onKey);\n        wide.removeEventListener('change', onWide);\n        root.style.overflow = overflow;\n        const toggle = document.querySelector('[aria-controls=\"vx-filters\"]');\n        if (toggle && drawer && drawer.contains(document.activeElement)) toggle.focus();\n      };\n    }, [railOpen]);\n\n    // Filters for one modality and the provider list reset with the facet,\n    // so no checked filter is left out of view.\n    const chooseScope = key => {\n      setScope(key);\n      setFilters(prev => ({ ...EMPTY_FILTERS, providers: [], privacy: prev.privacy, flags: prev.flags }));\n      setView(defaultView(key));\n      if (key !== 'text' && !['newest', 'name', 'price'].includes(sort)) setSort(DEFAULT_SORT);\n    };\n\n    const providers = catalog ? catalog.providers : {};\n\n    const scoped = useMemo(() => (catalog ? catalog.families.filter(family => !scope || familyScope(family) === scope) : []), [catalog, scope]);\n    // The Status group shows only where the modality has beta or deprecated\n    // families, counted before search and filters so it doesn't come and go\n    // while typing. New alone doesn't keep it: New changes with the date, so\n    // the build-time first screen and the live view could disagree on it.\n    const statuses = useMemo(() => ({ beta: scoped.some(family => family.beta), deprecated: scoped.some(family => family.deprecated) }), [scoped]);\n\n    const scopeCounts = useMemo(() => {\n      const out = {};\n      (catalog ? catalog.families : []).forEach(family => { const key = familyScope(family); out[key] = (out[key] || 0) + 1; });\n      return out;\n    }, [catalog]);\n\n    const searched = useMemo(() => (catalog && query ? scoped.filter(family => matchesQuery(searchText(family, modelsOf(catalog, family), providers), query)) : scoped), [catalog, scoped, query, providers]);\n\n    // An option's count is the families it would leave, run through the same\n    // test as the filter so the two never disagree: the search and every\n    // other group apply, and within its own group the option joins the\n    // checked ones where all must hold, or stands alone where any may.\n    const facetCount = useMemo(() => {\n      const cache = new Map();\n      return (key, value) => {\n        const id = `${key}:${value}`;\n        if (!cache.has(id)) {\n          const f = { ...filters, [key]: ALL_OF.includes(key) ? [...new Set([...filters[key], value])] : [value] };\n          cache.set(id, searched.filter(family => familyMatches(family, modelsOf(catalog, family), f, now)).length);\n        }\n        return cache.get(id);\n      };\n    }, [catalog, searched, filters, now]);\n\n    const rows = useMemo(() => {\n      if (!catalog) return [];\n      const list = [];\n      for (const family of searched) {\n        const models = modelsOf(catalog, family);\n        if (!familyMatches(family, models, filters, now)) continue;\n        const display = models.find(m => variantMatches(m, filters)) || catalog.models[family.primary] || models[0];\n        const offer = listPrice(display, filters);\n        list.push({ family, models, display, offer, price: offer.value });\n      }\n      const sorter = SORTS[sort] || SORTS[DEFAULT_SORT];\n      return list.sort(sorter.fn);\n    }, [catalog, searched, filters, sort, now]);\n\n    // Providers count the same way, in one pass. Every provider in scope, and\n    // any checked from a link, stays listed so it can show as disabled or be\n    // unchecked.\n    const providerCounts = useMemo(() => {\n      const counts = Object.fromEntries([...scoped.map(family => family.provider), ...filters.providers].map(slug => [slug, 0]));\n      const others = { ...filters, providers: [] };\n      searched.forEach(family => { if (familyMatches(family, modelsOf(catalog, family), others, now)) counts[family.provider] += 1; });\n      return counts;\n    }, [catalog, scoped, searched, filters, now]);\n\n    const modelCount = rows.reduce((n, row) => n + row.family.variants.length, 0);\n    const page = rows.slice(0, limit);\n    const remaining = rows.length - page.length;\n    const columns = catalog ? explorerColumns(modality, task, filters, catalog) : [];\n    const canGrid = modality === 'image' || modality === 'video';\n    // A gallery link opened with text or audio in scope falls back to the list.\n    const shownView = view === 'grid' && !canGrid ? 'list' : view;\n    // A type badge only tells rows apart when the list mixes types.\n    const showScope = new Set(rows.map(row => familyScope(row.family))).size > 1;\n    const filterCount = activeFilterCount(filters);\n    const scopeKey = scope || 'all';\n    const unitNote = settingNote(modality, filters) || (shownView !== 'grid' ? UNIT_NOTES[scopeKey] : null);\n\n    const updated = catalog && catalog.generatedAt ? fmtDate(Math.floor(new Date(catalog.generatedAt).getTime() / 1000)) : null;\n\n    return (\n      __jsx('div', { className: \"vx vx-page vx-explorer not-prose\"   ,}\n        , __jsx(HoverTips, null )\n        , __jsx('div', { className: \"vx-page-grid\",}\n          , catalog ? (\n            __jsx(FilterRail, { modality: modality, task: task, scope: scope, scopeCounts: scopeCounts, onScope: chooseScope, statuses: statuses,\n              filters: filters, setFilters: setFilters, facetCount: facetCount, providerCounts: providerCounts, providers: providers,\n              onClear: () => setFilters(EMPTY_FILTERS), open: railOpen, onClose: () => setRailOpen(false),} )\n          ) : __jsx('aside', { className: \"vx-side vx-filters\" , 'aria-hidden': \"true\",} )\n          , railOpen ? __jsx('div', { className: \"vx-filters-backdrop\", onClick: () => setRailOpen(false), 'aria-hidden': \"true\",} ) : null\n\n          , __jsx('div', { className: \"vx-page-main\",}\n            , __jsx('header', { className: \"vx-hero\",}\n              , __jsx('div', { className: \"vx-hero-text\",}\n                , __jsx('h1', { className: \"vx-h1\",}, PAGE_TITLES[scopeKey] || PAGE_TITLES.all)\n                , __jsx('p', { className: \"vx-lede\",}, SCOPE_BLURBS[scopeKey] || SCOPE_BLURBS.all)\n              )\n              , __jsx('div', { className: \"vx-hero-actions\",}\n                , __jsx('a', { className: \"vx-btn vx-btn-tertiary\" , href: \"/api-reference/endpoint/models/list\",}, \"Models API\" )\n              )\n            )\n\n            , __jsx('div', { className: \"vx-toolbar\",}\n              , __jsx('button', { type: \"button\", className: cls('vx-btn vx-rail-toggle', filterCount && 'vx-btn-active'), onClick: () => setRailOpen(!railOpen), 'aria-expanded': railOpen, 'aria-controls': \"vx-filters\", disabled: !catalog,}, \"Filters\"\n                , filterCount ? __jsx('span', { className: \"vx-btn-count\",}, filterCount) : null\n              )\n              , __jsx('div', { className: \"vx-search\",}\n                , __jsx(Icon, { name: \"search\", size: 16,} )\n                , __jsx('input', { ref: searchRef, type: \"search\", value: query, onChange: e => setQuery(e.target.value),\n                  placeholder: \"Search by name, ID or provider\"     , 'aria-label': \"Search models\" ,} )\n                , query ? __jsx('button', { type: \"button\", className: \"vx-icon-btn\", onClick: () => setQuery(''), 'aria-label': \"Clear search\" ,}, __jsx(Icon, { name: \"x\", size: 14,} )) : __jsx('kbd', { 'aria-hidden': \"true\",}, \"/\")\n              )\n              , __jsx('select', { className: \"vx-select\", value: sort, onChange: e => setSort(e.target.value), 'aria-label': \"Sort\",}\n                , ['newest', 'name', 'price', ...(modality === 'text' ? ['context', 'input', 'output'] : [])].map(key => __jsx('option', { key: key, value: key,}, SORTS[key].label))\n              )\n              , __jsx(Segmented, { ariaLabel: \"View\", value: shownView, onChange: setView,\n                options: [{ value: 'list', label: 'List' }, { value: 'table', label: 'Table' },\n                  { value: 'grid', label: 'Gallery', disabled: !canGrid, title: canGrid ? undefined : 'Sample images and videos, for image and video models' }],} )\n            )\n\n            , __jsx(ScopeTabs, { scope: scope, counts: catalog ? scopeCounts : null, onScope: chooseScope,} )\n\n            , !catalog ? (\n              error\n                ? __jsx('div', { className: \"vx-error\", role: \"alert\",}, \"The model catalog could not load. Reload the page to try again.\"           )\n                : __jsx(__Fragment, null, __jsx('span', { className: \"vx-sr-only\", role: \"status\",}, \"Loading models\" ), __jsx(CatalogSkeleton, null ))\n            ) : (\n              __jsx('section', { className: \"vx-results\", 'aria-label': \"Models\",}\n                , __jsx('div', { className: \"vx-countline\",}\n                  , __jsx('span', { className: \"vx-result-count\", 'aria-live': \"polite\",}\n                    , __jsx('strong', null, plural(rows.length, 'family')), \" · \"  , plural(modelCount, 'model ID'), unitNote ? ` · ${unitNote}` : ''\n                  )\n                  , updated ? __jsx('span', { className: \"vx-source\",}, \"Updated \" , updated) : null\n                )\n\n                , rows.length === 0 ? (\n                  __jsx(Empty, { title: \"No models match\"  ,}\n                    , query ? __jsx(__Fragment, null, \"Nothing matches “\"  , query, \"”\", filterCount ? ' with the current filters' : '', \". \" ) : 'Try removing a filter. '\n                    , __jsx('button', { type: \"button\", className: \"vx-btn vx-btn-sm\" , onClick: () => { setFilters(EMPTY_FILTERS); setQuery(''); },}, \"Clear \" , query && filterCount ? 'search and filters' : query ? 'search' : 'filters')\n                  )\n                ) : shownView === 'grid' ? (\n                  __jsx(Gallery, { rows: page, columns: columns, sort: sort, setSort: setSort, providers: providers, now: now, catalog: catalog, modality: modality, showScope: showScope,} )\n                ) : shownView === 'table' ? (\n                  __jsx(ExplorerTable, { rows: page, columns: columns, sort: sort, setSort: setSort, providers: providers, now: now, showScope: showScope,} )\n                ) : (\n                  __jsx(ExplorerList, { rows: page, providers: providers, now: now, showType: new Set(rows.map(row => row.display.task)).size > 1, showScope: showScope,} )\n                )\n\n                , remaining > 0 ? (\n                  __jsx('div', { className: \"vx-more-row\",}\n                    , __jsx('button', { type: \"button\", className: \"vx-btn vx-more-btn\" , onClick: () => setLimit(limit + PAGE_SIZE),}\n                      , remaining > PAGE_SIZE ? `Show ${PAGE_SIZE} more · ${remaining} remaining` : `Show the last ${remaining}`\n                    )\n                  )\n                ) : null\n\n                , __jsx('footer', { className: \"vx-explorer-foot\",}\n                  , __jsx('nav', { 'aria-label': \"Related pages\" ,}\n                    , __jsx('a', { href: \"/models/methodology\",}, \"Methodology\")\n                    , __jsx('a', { href: \"/overview/deprecations\",}, \"Deprecations\")\n                    , __jsx('a', { href: \"/overview/beta-models\",}, \"Beta models\" )\n                  )\n                )\n              )\n            )\n          )\n        )\n      )\n    );\n  };\n\n  /* ------------------------------------------------------------ code samples */\n\n  const VARIANT_PROMPTS = {\n    chat: 'Explain TEE attestation in two sentences.',\n    image: 'A retro travel poster with the bold headline \"VENICE\" in large condensed serif type, sunset color palette',\n    video: 'Slow aerial drone shot over a misty mountain valley at golden hour',\n    videoEdit: 'Turn the scene into a snowy winter morning',\n    videoExtend: 'Continue the drone shot as it rises above the clouds into clear sky',\n    videoRecast: 'Recast the person in the video as the person in the reference image',\n    videoMotion: 'The character follows the movements in the source video',\n    music: 'Warm lo-fi hip hop beat with soft piano and vinyl crackle',\n    lyrics: '[Verse]\\\\nCity lights are calling me home\\\\n[Chorus]\\\\nWe are the dreamers',\n    sfx: 'Heavy wooden door creaking open in a stone hallway'\n  };\n\n  const codeSamples = (model, endpointId, { voice: chosenVoice } = {}) => {\n    const id = model.id;\n    const key = '$VENICE_API_KEY';\n    const auth = `-H \"Authorization: Bearer ${key}\" \\\\\\n  -H \"Content-Type: application/json\"`;\n    const pyHead = 'import os\\nfrom openai import OpenAI\\n\\nclient = OpenAI(\\n    api_key=os.environ[\"VENICE_API_KEY\"],\\n    base_url=\"https://api.venice.ai/api/v1\",\\n)\\n';\n    const tsHead = 'import OpenAI from \"openai\";\\n\\nconst client = new OpenAI({\\n  apiKey: process.env.VENICE_API_KEY,\\n  baseURL: \"https://api.venice.ai/api/v1\",\\n});\\n';\n    const reqHead = 'import os, requests\\n\\nAPI = \"https://api.venice.ai/api/v1\"\\nHEADERS = {\"Authorization\": f\"Bearer {os.environ[\\'VENICE_API_KEY\\']}\"}\\n';\n    const fetchHead = 'const API = \"https://api.venice.ai/api/v1\";\\nconst headers = {\\n  Authorization: `Bearer ${process.env.VENICE_API_KEY}`,\\n  \"Content-Type\": \"application/json\",\\n};\\n';\n    const text = model.text || {};\n    const effort = text.reasoning && text.reasoning.effort && text.reasoning.effort.length\n      ? (text.reasoning.defaultEffort && text.reasoning.effort.includes(text.reasoning.defaultEffort) ? text.reasoning.defaultEffort : text.reasoning.effort[text.reasoning.effort.length - 1])\n      : null;\n\n    if (model.task === 'chat' && endpointId === 'responses') {\n      return {\n        curl: `curl ${API}/responses \\\\\\n  ${auth} \\\\\\n  -d '{\\n    \"model\": \"${id}\",\\n    \"input\": \"${VARIANT_PROMPTS.chat}\"${effort ? `,\\n    \"reasoning\": { \"effort\": \"${effort}\" }` : ''}\\n  }'`,\n        python: `${pyHead}\\nresponse = client.responses.create(\\n    model=\"${id}\",\\n    input=\"${VARIANT_PROMPTS.chat}\",${effort ? `\\n    reasoning={\"effort\": \"${effort}\"},` : ''}\\n)\\nprint(response.output_text)`,\n        typescript: `${tsHead}\\nconst response = await client.responses.create({\\n  model: \"${id}\",\\n  input: \"${VARIANT_PROMPTS.chat}\",${effort ? `\\n  reasoning: { effort: \"${effort}\" },` : ''}\\n});\\nconsole.log(response.output_text);`\n      };\n    }\n    if (model.task === 'chat') {\n      const opts = effort ? `(${text.reasoning.effort.join(' | ')})` : '';\n      return {\n        curl: `curl ${API}/chat/completions \\\\\\n  ${auth} \\\\\\n  -d '{\\n    \"model\": \"${id}\",\\n    \"messages\": [{ \"role\": \"user\", \"content\": \"${VARIANT_PROMPTS.chat}\" }]${effort ? `,\\n    \"reasoning_effort\": \"${effort}\"` : ''}\\n  }'`,\n        python: `${pyHead}\\nresponse = client.chat.completions.create(\\n    model=\"${id}\",\\n    messages=[{\"role\": \"user\", \"content\": \"${VARIANT_PROMPTS.chat}\"}],${effort ? `\\n    reasoning_effort=\"${effort}\",  # ${opts}` : ''}\\n)\\nprint(response.choices[0].message.content)`,\n        typescript: `${tsHead}\\nconst response = await client.chat.completions.create({\\n  model: \"${id}\",\\n  messages: [{ role: \"user\", content: \"${VARIANT_PROMPTS.chat}\" }],${effort ? `\\n  reasoning_effort: \"${effort}\",` : ''}\\n});\\nconsole.log(response.choices[0].message.content);`\n      };\n    }\n    if (model.task === 'image-generation') {\n      const image = model.image || {};\n      const res = image.defaultResolution ? `,\\n    \"resolution\": \"${image.defaultResolution}\"` : '';\n      const ar = image.aspectRatios && image.aspectRatios.length ? `,\\n    \"aspect_ratio\": \"${image.defaultAspectRatio || image.aspectRatios[0]}\"` : '';\n      const body = `{\\n    \"model\": \"${id}\",\\n    \"prompt\": \"${VARIANT_PROMPTS.image.replace(/\"/g, '\\\\\"')}\"${res}${ar}\\n  }`;\n      return {\n        curl: `curl ${API}/image/generate \\\\\\n  ${auth} \\\\\\n  -d '${body.replace(/'/g, \"'\\\\''\")}'`,\n        python: `import base64\\n${reqHead}\\nres = requests.post(f\"{API}/image/generate\", headers=HEADERS, json={\\n    \"model\": \"${id}\",\\n    \"prompt\": \"A retro travel poster with the headline VENICE\",${image.defaultResolution ? `\\n    \"resolution\": \"${image.defaultResolution}\",` : ''}\\n})\\nres.raise_for_status()\\nwith open(\"image.webp\", \"wb\") as f:\\n    f.write(base64.b64decode(res.json()[\"images\"][0]))`,\n        typescript: `${fetchHead}\\nconst res = await fetch(\\`\\${API}/image/generate\\`, {\\n  method: \"POST\",\\n  headers,\\n  body: JSON.stringify({\\n    model: \"${id}\",\\n    prompt: \"A retro travel poster with the headline VENICE\",${image.defaultResolution ? `\\n    resolution: \"${image.defaultResolution}\",` : ''}\\n  }),\\n});\\nconst { images } = await res.json(); // base64-encoded`\n      };\n    }\n    if (model.task === 'image-edit' || model.task === 'image-upscale' || model.task === 'background-removal') {\n      const path = model.task === 'image-edit' ? '/image/edit' : model.task === 'image-upscale' ? '/image/upscale' : '/image/background-remove';\n      const extra = model.task === 'image-edit' ? `,\\n    \"prompt\": \"Make it a rainy night scene\"` : model.task === 'image-upscale' ? ',\\n    \"scale\": 2' : '';\n      const pyExtra = model.task === 'image-edit' ? '\\n    \"prompt\": \"Make it a rainy night scene\",' : model.task === 'image-upscale' ? '\\n    \"scale\": 2,' : '';\n      return {\n        curl: `curl ${API}${path} \\\\\\n  ${auth} \\\\\\n  -d '{\\n    \"model\": \"${id}\",\\n    \"image\": \"<base64-encoded image>\"${extra}\\n  }' --output result.png`,\n        python: `import base64\\n${reqHead}\\nwith open(\"photo.jpg\", \"rb\") as f:\\n    image = base64.b64encode(f.read()).decode()\\n\\nres = requests.post(f\"{API}${path}\", headers=HEADERS, json={\\n    \"model\": \"${id}\",\\n    \"image\": image,${pyExtra}\\n})\\nres.raise_for_status()\\nwith open(\"result.png\", \"wb\") as f:\\n    f.write(res.content)`,\n        typescript: `${fetchHead}\\nimport { readFile, writeFile } from \"node:fs/promises\";\\n\\nconst image = (await readFile(\"photo.jpg\")).toString(\"base64\");\\nconst res = await fetch(\\`\\${API}${path}\\`, {\\n  method: \"POST\",\\n  headers,\\n  body: JSON.stringify({ model: \"${id}\", image${model.task === 'image-edit' ? ', prompt: \"Make it a rainy night scene\"' : model.task === 'image-upscale' ? ', scale: 2' : ''} }),\\n});\\nawait writeFile(\"result.png\", Buffer.from(await res.arrayBuffer()));`\n      };\n    }\n    if (model.modality === 'video') {\n      const video = model.video || {};\n      const inputs = video.inputs || {};\n      const upscale = video.mode === 'upscale';\n      // Source-length models list only \"Auto\", which /video/queue rejects; they take no duration.\n      const timed = (video.durations || []).filter(d => d.seconds);\n      const dur = timed.find(d => d.seconds === 5) || timed[0];\n      const res = upscale ? null : (video.resolutions || []).find(r => r.height === 720) || (video.resolutions || [])[0];\n      const prompt = upscale ? null\n        : video.mode === 'motion' ? VARIANT_PROMPTS.videoMotion\n        : video.mode !== 'v2v' ? VARIANT_PROMPTS.video\n        : inputs.reference ? VARIANT_PROMPTS.videoRecast\n        : /extend/.test(id) ? VARIANT_PROMPTS.videoExtend\n        : VARIANT_PROMPTS.videoEdit;\n      const fields = [\n        `\"model\": \"${id}\"`,\n        prompt ? `\"prompt\": \"${prompt}\"` : null,\n        dur ? `\"duration\": \"${dur.value}\"` : null,\n        res ? `\"resolution\": \"${res.value}\"` : null,\n        upscale ? '\"upscale_factor\": 2' : null,\n        video.aspectRatios && video.aspectRatios.length ? `\"aspect_ratio\": \"${video.aspectRatios[0]}\"` : null,\n        video.audio === 'optional' ? '\"audio\": true' : null,\n        inputs.image ? `\"image_url\": \"https://example.com/${video.mode === 'motion' ? 'character' : 'first-frame'}.jpg\"` : null,\n        inputs.endImage ? '\"end_image_url\": \"https://example.com/last-frame.jpg\"' : null,\n        inputs.reference ? '\"reference_image_urls\": [\"https://example.com/character.jpg\"]' : null,\n        inputs.video ? '\"video_url\": \"https://example.com/source.mp4\"' : null,\n        inputs.referenceVideo ? '\"reference_video_urls\": [\"https://example.com/source.mp4\"]' : null\n      ].filter(Boolean);\n      const pyFields = fields.map(f => f.replace(/\": true/, '\": True'));\n      return {\n        curl: `# 1. Queue the job (returns a queue_id)\\ncurl ${API}/video/queue \\\\\\n  ${auth} \\\\\\n  -d '{\\n    ${fields.join(',\\n    ')}\\n  }'\\n\\n# 2. Poll until the MP4 is ready (JSON with the status until then)\\ncurl ${API}/video/retrieve \\\\\\n  ${auth} \\\\\\n  -d '{ \"model\": \"${id}\", \"queue_id\": \"<queue_id>\" }' --output video.mp4\\n\\n# If the queue response has a download_url, retrieve only reports the\\n# status: download the MP4 from that URL once it is COMPLETED.`,\n        python: `import time\\n${reqHead}\\nres = requests.post(f\"{API}/video/queue\", headers=HEADERS, json={\\n    ${pyFields.join(',\\n    ')},\\n})\\nres.raise_for_status()\\njob = res.json()\\n\\nwhile True:\\n    res = requests.post(f\"{API}/video/retrieve\", headers=HEADERS,\\n                        json={\"model\": \"${id}\", \"queue_id\": job[\"queue_id\"]})\\n    res.raise_for_status()  # a failed job returns its error here\\n    if res.headers.get(\"content-type\", \"\").startswith(\"video/\"):\\n        video = res.content\\n        break\\n    if res.json().get(\"status\") == \"COMPLETED\":  # the MP4 is at download_url\\n        video = requests.get(job[\"download_url\"]).content\\n        break\\n    time.sleep(5)  # still processing\\n\\nopen(\"video.mp4\", \"wb\").write(video)`,\n        typescript: `${fetchHead}\\nimport { writeFile } from \"node:fs/promises\";\\n\\nconst queued = await fetch(\\`\\${API}/video/queue\\`, {\\n  method: \"POST\",\\n  headers,\\n  body: JSON.stringify({\\n    ${fields.map(f => f.replace(/^\"([a-z_]+)\":/, '$1:')).join(',\\n    ')},\\n  }),\\n});\\nif (!queued.ok) throw new Error(await queued.text());\\nconst job = await queued.json();\\n\\nlet video;\\nwhile (!video) {\\n  await new Promise(r => setTimeout(r, 5000));\\n  const res = await fetch(\\`\\${API}/video/retrieve\\`, {\\n    method: \"POST\",\\n    headers,\\n    body: JSON.stringify({ model: \"${id}\", queue_id: job.queue_id }),\\n  });\\n  if (!res.ok) throw new Error(await res.text()); // a failed job returns its error here\\n  if (res.headers.get(\"content-type\")?.startsWith(\"video/\")) video = await res.arrayBuffer();\\n  else if ((await res.json()).status === \"COMPLETED\") video = await (await fetch(job.download_url)).arrayBuffer(); // the MP4 is at download_url\\n}\\nawait writeFile(\"video.mp4\", Buffer.from(video));`\n      };\n    }\n    if (model.task === 'tts' && !(model.audio && model.audio.async)) {\n      const voice = chosenVoice || (model.audio && model.audio.voices && model.audio.voices[0]) || 'default';\n      const format = (model.audio && (model.audio.defaultFormat || (model.audio.formats || [])[0])) || 'mp3';\n      return {\n        curl: `curl ${API}/audio/speech \\\\\\n  ${auth} \\\\\\n  -d '{\\n    \"model\": \"${id}\",\\n    \"input\": \"Private AI for everyone.\",\\n    \"voice\": \"${voice}\",\\n    \"response_format\": \"${format}\"\\n  }' --output speech.${format}`,\n        python: `${pyHead}\\nwith client.audio.speech.with_streaming_response.create(\\n    model=\"${id}\",\\n    voice=\"${voice}\",\\n    input=\"Private AI for everyone.\",\\n    response_format=\"${format}\",\\n) as response:\\n    response.stream_to_file(\"speech.${format}\")`,\n        typescript: `${tsHead}\\nimport { writeFile } from \"node:fs/promises\";\\n\\nconst speech = await client.audio.speech.create({\\n  model: \"${id}\",\\n  voice: \"${voice}\",\\n  input: \"Private AI for everyone.\",\\n  response_format: \"${format}\",\\n});\\nawait writeFile(\"speech.${format}\", Buffer.from(await speech.arrayBuffer()));`\n      };\n    }\n    if (model.task === 'stt') {\n      return {\n        curl: `curl ${API}/audio/transcriptions \\\\\\n  -H \"Authorization: Bearer ${key}\" \\\\\\n  -F model=${id} \\\\\\n  -F file=@meeting.mp3`,\n        python: `${pyHead}\\nwith open(\"meeting.mp3\", \"rb\") as audio:\\n    transcript = client.audio.transcriptions.create(model=\"${id}\", file=audio)\\nprint(transcript.text)`,\n        typescript: `${tsHead}\\nimport fs from \"node:fs\";\\n\\nconst transcript = await client.audio.transcriptions.create({\\n  model: \"${id}\",\\n  file: fs.createReadStream(\"meeting.mp3\"),\\n});\\nconsole.log(transcript.text);`\n      };\n    }\n    if (model.audio && model.audio.voiceChanger) {\n      const a = model.audio;\n      const voice = a.defaultVoice || (a.voices || [])[0];\n      const file = `converted.${(a.formats || [])[0] || 'mp3'}`;\n      return {\n        curl: `# 1. Queue the conversion (returns a queue_id)\\ncurl ${API}/audio/voice-changer/queue \\\\\\n  -H \"Authorization: Bearer ${key}\" \\\\\\n  -F model=${id} \\\\\\n${voice ? `  -F voice=${voice} \\\\\\n` : ''}  -F file=@take.wav\\n\\n# 2. Poll until the audio is ready (JSON with the status until then)\\ncurl ${API}/audio/voice-changer/retrieve \\\\\\n  ${auth} \\\\\\n  -d '{ \"model\": \"${id}\", \"queue_id\": \"<queue_id>\" }' --output ${file}`,\n        python: `import time\\n${reqHead}\\nwith open(\"take.wav\", \"rb\") as source:\\n    res = requests.post(f\"{API}/audio/voice-changer/queue\", headers=HEADERS,\\n                        data={\"model\": \"${id}\"${voice ? `, \"voice\": \"${voice}\"` : ''}}, files={\"file\": source})\\nres.raise_for_status()\\njob = res.json()\\n\\nwhile True:\\n    res = requests.post(f\"{API}/audio/voice-changer/retrieve\", headers=HEADERS,\\n                        json={\"model\": \"${id}\", \"queue_id\": job[\"queue_id\"]})\\n    res.raise_for_status()  # a failed job returns its error here\\n    if not res.headers.get(\"content-type\", \"\").startswith(\"application/json\"):\\n        open(\"${file}\", \"wb\").write(res.content)\\n        break\\n    time.sleep(3)  # still processing`,\n        typescript: `${fetchHead}\\nimport { readFile, writeFile } from \"node:fs/promises\";\\n\\nconst form = new FormData();\\nform.append(\"model\", \"${id}\");\\n${voice ? `form.append(\"voice\", \"${voice}\");\\n` : ''}form.append(\"file\", new Blob([await readFile(\"take.wav\")]), \"take.wav\");\\nconst queued = await fetch(\\`\\${API}/audio/voice-changer/queue\\`, {\\n  method: \"POST\",\\n  headers: { Authorization: headers.Authorization },\\n  body: form,\\n});\\nif (!queued.ok) throw new Error(await queued.text());\\nconst job = await queued.json();\\n\\nlet res;\\ndo {\\n  await new Promise(r => setTimeout(r, 3000));\\n  res = await fetch(\\`\\${API}/audio/voice-changer/retrieve\\`, {\\n    method: \"POST\",\\n    headers,\\n    body: JSON.stringify({ model: \"${id}\", queue_id: job.queue_id }),\\n  });\\n  if (!res.ok) throw new Error(await res.text()); // a failed job returns its error here\\n} while (res.headers.get(\"content-type\")?.startsWith(\"application/json\"));\\nawait writeFile(\"${file}\", Buffer.from(await res.arrayBuffer()));`\n      };\n    }\n    if (model.modality === 'audio') {\n      const prompt = model.task === 'sfx' ? VARIANT_PROMPTS.sfx : VARIANT_PROMPTS.music;\n      const isTts = model.task === 'tts';\n      const a = model.audio || {};\n      const seconds = a.durationOptions ? a.durationOptions[0] : a.defaultDuration ? Math.max(a.minDuration || 1, Math.min(30, a.defaultDuration)) : null;\n      const file = `audio.${(a.formats || [])[0] || 'mp3'}`;\n      const fields = [\n        `\"model\": \"${id}\"`,\n        `\"prompt\": \"${isTts ? 'Private AI for everyone.' : prompt}\"`,\n        isTts && chosenVoice ? `\"voice\": \"${chosenVoice}\"` : null,\n        !isTts && seconds ? `\"duration_seconds\": ${seconds}` : null,\n        a.lyrics ? `\"lyrics_prompt\": \"${VARIANT_PROMPTS.lyrics}\"` : null\n      ].filter(Boolean);\n      return {\n        curl: `# 1. Queue the job (returns a queue_id)\\ncurl ${API}/audio/queue \\\\\\n  ${auth} \\\\\\n  -d '{\\n    ${fields.join(',\\n    ')}\\n  }'\\n\\n# 2. Poll until the audio is ready (JSON with the status until then)\\ncurl ${API}/audio/retrieve \\\\\\n  ${auth} \\\\\\n  -d '{ \"model\": \"${id}\", \"queue_id\": \"<queue_id>\" }' --output ${file}`,\n        python: `import time\\n${reqHead}\\nres = requests.post(f\"{API}/audio/queue\", headers=HEADERS, json={\\n    ${fields.join(',\\n    ')},\\n})\\nres.raise_for_status()\\njob = res.json()\\n\\nwhile True:\\n    res = requests.post(f\"{API}/audio/retrieve\", headers=HEADERS,\\n                        json={\"model\": \"${id}\", \"queue_id\": job[\"queue_id\"]})\\n    res.raise_for_status()  # a failed job returns its error here\\n    if not res.headers.get(\"content-type\", \"\").startswith(\"application/json\"):\\n        open(\"${file}\", \"wb\").write(res.content)\\n        break\\n    time.sleep(3)  # still processing`,\n        typescript: `${fetchHead}\\nimport { writeFile } from \"node:fs/promises\";\\n\\nconst queued = await fetch(\\`\\${API}/audio/queue\\`, {\\n  method: \"POST\",\\n  headers,\\n  body: JSON.stringify({\\n    ${fields.map(f => f.replace(/^\"([a-z_]+)\":/, '$1:')).join(',\\n    ')},\\n  }),\\n});\\nif (!queued.ok) throw new Error(await queued.text());\\nconst job = await queued.json();\\n\\nlet res;\\ndo {\\n  await new Promise(r => setTimeout(r, 3000));\\n  res = await fetch(\\`\\${API}/audio/retrieve\\`, {\\n    method: \"POST\",\\n    headers,\\n    body: JSON.stringify({ model: \"${id}\", queue_id: job.queue_id }),\\n  });\\n  if (!res.ok) throw new Error(await res.text()); // a failed job returns its error here\\n} while (res.headers.get(\"content-type\")?.startsWith(\"application/json\"));\\nawait writeFile(\"${file}\", Buffer.from(await res.arrayBuffer()));`\n      };\n    }\n    if (model.modality === 'embedding') {\n      return {\n        curl: `curl ${API}/embeddings \\\\\\n  ${auth} \\\\\\n  -d '{\\n    \"model\": \"${id}\",\\n    \"input\": \"Private AI for everyone.\"\\n  }'`,\n        python: `${pyHead}\\nresult = client.embeddings.create(model=\"${id}\", input=\"Private AI for everyone.\")\\nvector = result.data[0].embedding  # ${model.embedding && model.embedding.dimensions ? `${model.embedding.dimensions} dimensions` : 'list of floats'}`,\n        typescript: `${tsHead}\\nconst result = await client.embeddings.create({\\n  model: \"${id}\",\\n  input: \"Private AI for everyone.\",\\n});\\nconst vector = result.data[0].embedding;`\n      };\n    }\n    return {\n      curl: `curl ${API}/decisions \\\\\\n  ${auth} \\\\\\n  -d '{\\n    \"model\": \"${id}\",\\n    \"state\": \"Help! My payouts have been failing for 3 days.\",\\n    \"questions\": {\\n      \"is_urgent\": { \"type\": \"noul\", \"instructions\": \"Does this need a reply within the hour?\" }\\n    }\\n  }'`,\n      python: `${reqHead}\\nres = requests.post(f\"{API}/decisions\", headers=HEADERS, json={\\n    \"model\": \"${id}\",\\n    \"state\": \"Help! My payouts have been failing for 3 days.\",\\n    \"questions\": {\\n        \"is_urgent\": {\"type\": \"noul\", \"instructions\": \"Does this need a reply within the hour?\"},\\n    },\\n})\\nprint(res.json()[\"answers\"][\"is_urgent\"][\"noul\"])  # 0 (no) to 1 (yes)`,\n      typescript: `${fetchHead}\\nconst res = await fetch(\\`\\${API}/decisions\\`, {\\n  method: \"POST\",\\n  headers,\\n  body: JSON.stringify({\\n    model: \"${id}\",\\n    state: \"Help! My payouts have been failing for 3 days.\",\\n    questions: { is_urgent: { type: \"noul\", instructions: \"Does this need a reply within the hour?\" } },\\n  }),\\n});\\nconst { answers } = await res.json();`\n    };\n  };\n\n  // Arrow keys, Home and End move between options in a tablist or radio\n  // group; only the selected option is in the tab order.\n  const rovingKeys = (keys, current, select) => e => {\n    const i = keys.indexOf(current);\n    const next = { ArrowRight: i + 1, ArrowDown: i + 1, ArrowLeft: i - 1, ArrowUp: i - 1, Home: 0, End: keys.length - 1 }[e.key];\n    if (next === undefined) return;\n    e.preventDefault();\n    const key = keys[(next + keys.length) % keys.length];\n    select(key);\n    const target = e.currentTarget.querySelector(`[data-key=\"${CSS.escape(String(key))}\"]`);\n    if (target) target.focus();\n  };\n\n  const CodeTabs = ({ samples }) => {\n    const [lang, setLang] = useState('curl');\n    const langs = [['curl', 'cURL'], ['python', 'Python'], ['typescript', 'TypeScript']];\n    return (\n      __jsx('div', { className: \"vx-code\",}\n        , __jsx('div', { className: \"vx-code-head\",}\n          , __jsx('div', { className: \"vx-code-tabs\", role: \"tablist\", 'aria-label': \"Language\", onKeyDown: rovingKeys(langs.map(([key]) => key), lang, setLang),}\n            , langs.map(([key, label]) => (\n              __jsx('button', { key: key, id: `vx-code-tab-${key}`, 'data-key': key, type: \"button\", role: \"tab\", 'aria-selected': lang === key, 'aria-controls': \"vx-code-panel\",\n                tabIndex: lang === key ? 0 : -1, className: cls('vx-code-tab', lang === key && 'is-active'), onClick: () => setLang(key),}, label)\n            ))\n          )\n          , __jsx(CopyButton, { text: samples[lang], label: \"Copy\", small: true,} )\n        )\n        , __jsx('pre', { id: \"vx-code-panel\", className: \"vx-code-body\", role: \"tabpanel\", 'aria-labelledby': `vx-code-tab-${lang}`, tabIndex: 0,}, __jsx('code', null, samples[lang]))\n      )\n    );\n  };\n\n  /* ------------------------------------------------------------ model page */\n\n  const SECTION_ICONS = {\n    overview: 'info', pricing: 'dollar', examples: 'image', voices: 'volume', specs: 'sliders',\n    capabilities: 'sparkles', api: 'code', variants: 'layers', related: 'link'\n  };\n  const pageSections = (model, { variants = 1, related = false, examples = false, capabilities = false } = {}) => {\n    const list = [['overview', 'Overview'], ['pricing', 'Pricing']];\n    if (examples) list.push(['examples', 'Examples']);\n    if (model.task === 'tts' && model.audio && model.audio.voices && model.audio.voices.length) list.push(['voices', 'Voices']);\n    list.push(['specs', 'Specs']);\n    if (capabilities) list.push(['capabilities', 'Capabilities']);\n    list.push(['api', 'API']);\n    if (variants > 1) list.push(['variants', 'Variants']);\n    if (related) list.push(['related', 'Related models']);\n    return list;\n  };\n\n  const useScrollSpy = ids => {\n    const [active, setActive] = useState(ids[0]);\n    const key = ids.join('|');\n    useEffect(() => {\n      if (typeof IntersectionObserver === 'undefined') return undefined;\n      const seen = new Map();\n      const observer = new IntersectionObserver(entries => {\n        entries.forEach(entry => seen.set(entry.target.id, entry.isIntersecting));\n        const first = ids.find(id => seen.get(id));\n        if (first) setActive(first);\n      }, { rootMargin: '-96px 0px -55% 0px' });\n      ids.forEach(id => { const el = document.getElementById(id); if (el) observer.observe(el); });\n      return () => observer.disconnect();\n    }, [key]);\n    return active;\n  };\n\n  const Section = ({ id, title, note, actions, children }) => (\n    __jsx('section', { id: id, className: \"vx-section\", 'aria-labelledby': `${id}-title`,}\n      , __jsx('div', { className: \"vx-section-head\",}\n        , __jsx('h2', { id: `${id}-title`, className: \"vx-h2\",}, title)\n        , note ? __jsx('span', { className: \"vx-section-note\",}, note) : null\n        , actions ? __jsx('div', { className: \"vx-section-actions\",}, actions) : null\n      )\n      , children\n    )\n  );\n\n  // Three cards a row, or four when a model has only four facts. Empty cells\n  // fill the last row so its hairlines stay unbroken.\n  const StatGrid = ({ items }) => {\n    const cells = items.filter(Boolean).slice(0, 6);\n    if (!cells.length) return null;\n    const cols = cells.length <= 4 ? cells.length : 3;\n    const empty = (cols - (cells.length % cols)) % cols;\n    return (\n      __jsx('div', { className: cls('vx-stats', cells.length % 2 && 'is-odd'), style: { '--vx-cols': cols },}\n        , cells.map((item, i) => __jsx(Stat, { key: item.label, ...item, last: i === cells.length - 1,} ))\n        , Array.from({ length: empty }, (_, i) => __jsx('span', { key: `empty-${i}`, className: \"vx-stat is-empty\" , 'aria-hidden': \"true\",} ))\n      )\n    );\n  };\n\n  const KeyStats = ({ model, models }) => {\n    const p = model.pricing || {};\n    if (model.modality === 'text' && model.task === 'chat') {\n      const text = model.text || {};\n      const caps = text.caps || {};\n      const r = text.reasoning;\n      const levels = (r && r.effort) || [];\n      return (\n        __jsx(StatGrid, { items: [\n          { label: 'Input / output', value: `${usd(p.input)} / ${usd(p.output)}`, sub: 'per 1M tokens' },\n          { label: 'Context', value: tokens(text.context), sub: text.maxOutput ? `${tokens(text.maxOutput)} max output` : 'max output not published' },\n          {\n            label: 'Reasoning',\n            value: !r ? 'None' : levels.length ? levels.join(', ') : 'On',\n            sub: !r ? 'answers directly' : r.defaultEffort ? `default ${r.defaultEffort}` : levels.length ? 'reasoning_effort' : 'fixed effort'\n          },\n          p.cacheRead != null\n            ? { label: 'Cached input', value: usd(p.cacheRead), sub: p.input ? `${Math.round((1 - p.cacheRead / p.input) * 100)}% off input` : 'per 1M tokens' }\n            : { label: 'Cached input', value: '—', sub: 'no prompt caching' },\n          { label: 'Modalities', value: ['Text', caps.vision && 'image', caps.videoInput && 'video', caps.audioInput && 'audio'].filter(Boolean).join(', '), sub: 'out: text' },\n          PRIVACY[model.privacy] ? { label: 'Privacy', value: PRIVACY[model.privacy].label, tip: PRIVACY[model.privacy].desc } : null\n        ],} )\n      );\n    }\n    if (model.task === 'decision') {\n      const d = model.decision || {};\n      return (\n        __jsx(StatGrid, { items: [\n          { label: 'Input / output', value: `${usd(p.input)} / ${usd(p.output)}`, sub: 'per 1M tokens' },\n          d.maxStateTokens ? { label: 'Max state', value: tokens(d.maxStateTokens), sub: 'tokens' } : null,\n          d.maxTotalTokens ? { label: 'Max total', value: tokens(d.maxTotalTokens), sub: 'tokens per request' } : null\n        ],} )\n      );\n    }\n    if (model.modality === 'image') {\n      const image = model.image || {};\n      const prices = p.byResolution ? Object.values(p.byResolution).filter(v => v != null) : [];\n      const lo = prices.length ? Math.min(...prices) : p.perImage;\n      const hi = prices.length ? Math.max(...prices) : p.perImage;\n      const unit = model.task === 'image-edit' ? 'edit' : model.task === 'image-upscale' ? '2x upscale' : 'image';\n      const resolutions = image.resolutions || [];\n      const ratios = (image.aspectRatios || []).filter(a => a !== 'auto');\n      const editor = model.task === 'image-edit' ? model : models.find(m => m.task === 'image-edit');\n      const refs = editor && editor.image && editor.image.maxInputImages;\n      return (\n        __jsx(StatGrid, { items: [\n          { label: `Price per ${unit}`, value: lo === hi ? usd(lo) : `${usd(lo)} – ${usd(hi)}`, sub: resolutions.length > 1 ? `${resolutions[0]} to ${resolutions[resolutions.length - 1]}` : resolutions[0] || null },\n          model.task === 'image-upscale' && p.upscale && p.upscale['4x'] != null ? { label: '4x upscale', value: usd(p.upscale['4x']), sub: 'per image' } : null,\n          resolutions.length ? { label: 'Resolution', value: resolutions.join(' · '), sub: image.defaultResolution ? `default ${image.defaultResolution}` : null } : null,\n          ratios.length ? { label: 'Aspect ratios', value: plural(ratios.length, 'ratio'), sub: image.defaultAspectRatio ? `default ${image.defaultAspectRatio}` : null } : null,\n          refs ? { label: 'Reference images', value: `Up to ${refs}`, sub: editor.image.combineImages ? 'combined in one edit' : 'per edit' } : null,\n          image.promptLimit ? { label: 'Prompt limit', value: image.promptLimit.toLocaleString('en-US'), sub: 'characters' } : null,\n          p.extraInputImage != null ? { label: 'Extra input image', value: usd(p.extraInputImage), sub: 'per additional image' } : null\n        ],} )\n      );\n    }\n    if (model.modality === 'video') {\n      const draft = videoPrice(model, DRAFT_CLIP);\n      const prod = videoPrice(model, PRODUCTION_CLIP);\n      const video = model.video || {};\n      return (\n        __jsx(StatGrid, { items: [\n          { label: 'From', value: p.status === 'quoted' ? `${usd(p.fromPerSecond)} / sec` : 'By source', sub: p.status === 'quoted' ? `up to ${usd(p.toPerSecond)} / sec` : 'priced per second of input' },\n          { label: 'Draft clip', value: draft.status === 'quoted' ? usd(draft.clip) : '—', sub: draft.status === 'quoted' ? `${draft.seconds}s · ${draft.resolution || 'default'}${draft.audio ? ' · audio' : ''}` : null },\n          { label: 'Production clip', value: prod.status === 'quoted' ? usd(prod.clip) : '—', sub: prod.status === 'quoted' ? `${prod.seconds}s · ${prod.resolution || 'default'}${prod.audio ? ' · audio' : ''}` : null },\n          { label: 'Max resolution', value: heightLabel(maxVideoHeight(model)), sub: plural((video.resolutions || []).length || 1, 'option') },\n          { label: 'Duration', value: minVideoSeconds(model) ? `${minVideoSeconds(model)}–${maxVideoSeconds(model)}s` : 'Source length', sub: plural((video.durations || []).length, 'option') },\n          { label: 'Audio', value: video.audio === 'native' ? 'Native' : video.audio === 'optional' ? 'Optional' : 'None', sub: video.audio === 'optional' ? 'toggle with audio' : null }\n        ],} )\n      );\n    }\n    if (model.task === 'tts') {\n      const audio = model.audio || {};\n      return (\n        __jsx(StatGrid, { items: [\n          { label: 'Per 1M characters', value: usd(p.per1MChars) },\n          { label: 'Per minute', value: usd(p.perMinute), sub: '≈ 825 characters' },\n          { label: 'Per hour', value: usd(p.perHour), sub: 'of generated speech' },\n          { label: 'Voices', value: (audio.voices && audio.voices.length) || '—', sub: audio.customVoice ? 'plus custom voice IDs' : null },\n          { label: 'Formats', value: (audio.formats && audio.formats.length) || '—', sub: audio.formats ? audio.formats.slice(0, 4).join(', ') : null }\n        ],} )\n      );\n    }\n    if (model.task === 'stt') {\n      return (\n        __jsx(StatGrid, { items: [\n          { label: 'Per audio second', value: usd(p.perSecond) },\n          { label: 'Per minute', value: usd(p.perMinute) },\n          { label: 'Per hour', value: usd(p.perHour) },\n          { label: 'Per 1K minutes', value: usd(p.perMinute != null ? p.perMinute * 1000 : null), sub: 'for batch planning' }\n        ],} )\n      );\n    }\n    if (model.modality === 'audio') {\n      const audio = model.audio || {};\n      return (\n        __jsx(StatGrid, { items: [\n          { label: 'Price', value: p.perMinute != null ? usd(p.perMinute) : usd(p.perTrack), sub: p.perMinute != null ? 'per minute of audio' : 'per track' },\n          { label: 'Length', value: audio.maxDuration ? `${audio.minDuration || 1}s–${Math.round(audio.maxDuration / 60 * 10) / 10}m` : '—' },\n          { label: 'Lyrics', value: audio.lyrics ? 'Supported' : 'No' },\n          { label: 'Instrumental', value: audio.instrumental ? 'Forceable' : '—' }\n        ],} )\n      );\n    }\n    if (model.modality === 'embedding') {\n      const e = model.embedding || {};\n      return (\n        __jsx(StatGrid, { items: [\n          { label: 'Per 1M tokens', value: usd(p.input) },\n          { label: 'Dimensions', value: e.dimensions ? e.dimensions.toLocaleString('en-US') : '—' },\n          { label: 'Max input', value: tokens(e.maxInputTokens), sub: 'tokens per item' },\n          { label: '1M docs × 500 tokens', value: usd(p.input != null ? p.input * 500 : null), sub: 'to embed once' }\n        ],} )\n      );\n    }\n    return null;\n  };\n\n  // A ruled table of what a model takes and does: supported values read in\n  // the success color, the rest muted.\n  const CapTable = ({ title, rows }) => (\n    __jsx('div', { className: \"vx-captable\",}\n      , __jsx('div', { className: \"vx-captable-head\",}, title)\n      , __jsx('dl', null\n        , rows.map(([label, value]) => (\n          __jsx('div', { key: label, className: \"vx-captable-row\",}\n            , __jsx('dt', null, label)\n            , __jsx('dd', { className: value ? 'is-on' : 'is-off',}, value || 'Not supported')\n          )\n        ))\n      )\n    )\n  );\n\n  const hasCapabilities = (model, models) => model.task === 'chat' || (model.modality === 'image' && models.some(m => m.task === 'image-generation'));\n\n  const CapabilityMatrix = ({ model, models }) => {\n    if (model.modality === 'image') {\n      const image = model.image || {};\n      const editor = models.find(m => m.task === 'image-edit');\n      const refs = editor && editor.image && editor.image.maxInputImages;\n      const upscale = model.pricing && model.pricing.upscale ? Object.keys(model.pricing.upscale).filter(k => model.pricing.upscale[k] != null) : [];\n      return (\n        __jsx('div', { className: \"vx-capgrid\",}\n          , __jsx(CapTable, { title: \"Modalities\", rows: [\n            ['Text', 'Input'],\n            ['Image', editor ? 'Input and output' : 'Output']\n          ],} )\n          , __jsx(CapTable, { title: \"Features\", rows: [\n            ['Image editing', editor ? __jsx('code', null, editor.id) : null],\n            ['Multi-image editing', refs > 1 ? `up to ${refs} images` : null],\n            ['Web-grounded generation', image.webSearch ? 'Supported' : null],\n            ['Style references', image.styleReferences ? 'Supported' : null],\n            ['Upscale', upscale.length ? listText(upscale) : null]\n          ],} )\n        )\n      );\n    }\n    const text = model.text || {};\n    const caps = text.caps || {};\n    const r = text.reasoning;\n    const levels = (r && r.effort) || [];\n    const per = (on, n) => (on ? `Input only${n ? ` · up to ${n}` : ''}` : null);\n    return (\n      __jsx('div', { className: \"vx-capgrid\",}\n        , __jsx(CapTable, { title: \"Modalities\", rows: [\n          ['Text', 'Input and output'],\n          ['Image', per(caps.vision, caps.maxImages)],\n          ['Audio', per(caps.audioInput)],\n          ['Video', per(caps.videoInput, caps.maxVideos)]\n        ],} )\n        , __jsx(CapTable, { title: \"Features\", rows: [\n          ['Streaming (SSE)', 'Supported'],\n          ['Function calling', caps.tools ? 'Supported' : null],\n          ['Structured output (json_schema)', caps.structured ? 'Supported' : null],\n          ['Reasoning effort', !r ? null : levels.length ? levels.join(', ') : 'Not adjustable'],\n          ['Prompt caching', hasCap(model, 'caching') ? 'Supported' : null],\n          ['Web search', caps.webSearch ? 'venice_parameters' : null],\n          ['X search', caps.xSearch ? 'venice_parameters' : null],\n          ['Log probabilities', caps.logprobs ? 'Supported' : null],\n          ['Fine-tuning', null],\n          ['Image generation', null]\n        ],} )\n      )\n    );\n  };\n\n  const count = n => n.toLocaleString('en-US');\n  const ratioShapes = (ratios, active) => __jsx('span', { className: \"vx-ratios\",}, ratios.map(ar => __jsx(AspectShape, { key: ar, ratio: ar, active: ar === active,} )));\n\n  // The rows each modality adds to Specs, between the IDs and the dates.\n  const modalitySpecs = model => {\n    if (model.task === 'chat') {\n      const t = model.text || {};\n      const r = t.reasoning;\n      const levels = (r && r.effort) || [];\n      const q = t.quantization;\n      const sampling = t.sampling && Object.keys(t.sampling).length ? Object.entries(t.sampling).map(([k, v]) => `${k} ${v}`).join(' · ') : null;\n      return [\n        ['Context window', t.context ? `${count(t.context)} tokens` : 'Not published'],\n        ['Max output', t.maxOutput ? `${count(t.maxOutput)} tokens` : 'Not published'],\n        ['Reasoning effort', !r ? 'No separate reasoning phase' : levels.length\n          ? __jsx(__Fragment, null, __jsx('code', null, \"reasoning_effort: \" , levels.join(' | ')), r.defaultEffort ? __jsx('span', { className: \"vx-muted\",}, \" · default \"   , r.defaultEffort) : null, \" · \"  , __jsx('a', { href: \"/guides/features/reasoning-models#reasoning-effort\",}, \"guide\"))\n          : __jsx(__Fragment, null, \"On at a fixed effort; send \"      , __jsx('code', null, '\"reasoning\": { \"enabled\": false }'), \" to turn it off where the model allows · \"          , __jsx('a', { href: \"/guides/features/reasoning-models\",}, \"guide\"))],\n        ['Served precision', q ? QUANT_LABELS[q] || q : model.privacy === 'anonymized' ? 'Set by the upstream provider' : 'Not disclosed'],\n        sampling ? ['Default sampling', sampling] : null\n      ];\n    }\n    if (model.task === 'decision') {\n      const d = model.decision || {};\n      return [\n        d.maxStateTokens ? ['Max state', `${count(d.maxStateTokens)} tokens`] : null,\n        d.maxTotalTokens ? ['Max total', `${count(d.maxTotalTokens)} tokens`] : null\n      ];\n    }\n    if (model.modality === 'image') {\n      const image = model.image || {};\n      return [\n        image.resolutions && image.resolutions.length ? ['Resolutions', `${image.resolutions.join(', ')}${image.defaultResolution ? ` (default ${image.defaultResolution})` : ''}`] : null,\n        image.aspectRatios && image.aspectRatios.length ? ['Aspect ratios', ratioShapes(image.aspectRatios, image.defaultAspectRatio)] : null,\n        image.promptLimit ? ['Prompt limit', `${count(image.promptLimit)} characters`] : null,\n        image.steps ? ['Steps', `default ${image.steps.default}, max ${image.steps.max}`] : null,\n        image.maxInputImages ? ['Input images', `Up to ${image.maxInputImages}${image.combineImages ? ', combined into one edit' : ''}`] : null\n      ];\n    }\n    if (model.modality === 'video') {\n      const video = model.video || {};\n      return [\n        ['Mode', VARIANT_LABELS[model.variant] || model.variant],\n        ['Inputs', upperFirst(videoInputList(video).join(', '))],\n        video.resolutions && video.resolutions.length ? ['Resolutions', video.resolutions.map(r => r.label).join(', ')] : null,\n        video.durations && video.durations.length ? ['Durations', durationText(video.durations)] : null,\n        video.aspectRatios && video.aspectRatios.length ? ['Aspect ratios', ratioShapes(video.aspectRatios)] : null,\n        ['Audio', video.audio === 'native' ? 'Always generated' : video.audio === 'optional' ? __jsx(__Fragment, null, \"Optional; set \"  , __jsx('code', null, \"\\\"audio\\\": true\" )) : 'Silent output'],\n        video.promptLimit ? ['Prompt limit', `${count(video.promptLimit)} characters`] : null\n      ];\n    }\n    if (model.task === 'tts') {\n      const a = model.audio || {};\n      return [\n        a.voices && a.voices.length ? ['Voices', `${a.voices.length}${a.customVoice ? ', plus custom voice IDs' : ''}`] : null,\n        a.formats && a.formats.length ? ['Formats', `${a.formats.join(', ')}${a.defaultFormat ? ` (default ${a.defaultFormat})` : ''}`] : null\n      ];\n    }\n    if (model.modality === 'audio' && model.task !== 'stt') {\n      const a = model.audio || {};\n      return [\n        a.durationOptions ? ['Duration', `${a.durationOptions.join(', ')} seconds${a.defaultDuration ? ` (default ${a.defaultDuration})` : ''}`]\n          : a.maxDuration ? ['Duration', `${a.minDuration || 1}–${a.maxDuration} seconds${a.defaultDuration ? ` (default ${a.defaultDuration})` : ''}`] : null,\n        ['Lyrics', a.lyricsRequired ? 'Required' : a.lyrics ? 'Supported' : 'Not supported'],\n        a.instrumental ? ['Instrumental', 'Can be forced'] : null,\n        a.loop ? ['Seamless loop', 'Supported'] : null,\n        a.formats && a.formats.length ? ['Formats', a.formats.join(', ')] : null,\n        a.promptLimit ? ['Prompt limit', `${count(a.promptLimit)} characters`] : null\n      ];\n    }\n    if (model.modality === 'embedding') {\n      const e = model.embedding || {};\n      return [\n        e.dimensions ? ['Dimensions', count(e.dimensions)] : null,\n        e.maxInputTokens ? ['Max input', `${count(e.maxInputTokens)} tokens per item`] : null\n      ];\n    }\n    return [];\n  };\n\n  const Specs = ({ model, models }) => {\n    const endpoint = (model.endpoints || []).find(e => e.recommended) || (model.endpoints || [])[0];\n    const editor = model.task === 'image-generation' ? models.find(m => m.task === 'image-edit') : null;\n    const rows = [\n      ['Model ID', __jsx('code', null, model.id)],\n      editor ? ['Edit model ID', __jsx('code', null, editor.id)] : null,\n      endpoint ? ['Endpoint', __jsx('code', null, endpoint.method, \" /api/v1\" , endpoint.path)] : null,\n      ...modalitySpecs(model),\n      PRIVACY[model.privacy] ? ['Privacy', __jsx(__Fragment, null, PRIVACY[model.privacy].label, __jsx(InfoTip, { text: PRIVACY[model.privacy].desc,} ))] : null,\n      ['Added', fmtDate(model.created)],\n      model.openWeights ? ['Weights', __jsx(__Fragment, null, safeUrl(model.source)\n        ? __jsx('a', { href: safeUrl(model.source), target: \"_blank\", rel: \"noopener noreferrer\" ,}, weightsName(safeUrl(model.source)), __jsx(Icon, { name: \"external\", size: 12,} ))\n        : 'Open', model.license ? ` · ${model.license}` : null)] : null\n    ].filter(Boolean);\n    return (\n      __jsx('dl', { className: \"vx-kv vx-specs\" ,}\n        , rows.map(([label, value]) => (\n          __jsx('div', { key: label, className: \"vx-kv-row\",}, __jsx('dt', null, label), __jsx('dd', null, value))\n        ))\n      )\n    );\n  };\n\n  // Lifecycle in words, for the page's static text.\n  const statusText = model => {\n    const d = model.deprecation;\n    if (d) {\n      const date = d.removesAt && Number.isFinite(Date.parse(d.removesAt)) ? fmtDate(Math.floor(Date.parse(d.removesAt) / 1000)) : null;\n      return `Deprecated${date ? `, retiring ${date}` : ''}${d.replacement ? `; use ${d.replacement}` : ''}`;\n    }\n    return model.beta ? 'Beta' : 'Stable';\n  };\n\n  // One card per billed unit, four a row, on the same hairline gaps as the\n  // key numbers.\n  const PriceCards = ({ items }) => {\n    const cells = items.filter(Boolean);\n    if (!cells.length) return null;\n    const cols = Math.min(cells.length, 4);\n    const empty = (cols - (cells.length % cols)) % cols;\n    return (\n      __jsx('div', { className: cls('vx-prices', cells.length % 2 && 'is-odd'), style: { '--vx-cols': cols },}\n        , cells.map((item, i) => (\n          __jsx('div', { key: item.label, className: cls('vx-price-card', i === cells.length - 1 && 'is-last'),}\n            , __jsx('div', { className: \"vx-price-card-label\",}, item.label, item.hint ? __jsx('span', { className: \"vx-muted\",}, \" \" , item.hint) : null)\n            , __jsx('div', { className: \"vx-price-card-value\",}, item.value)\n            , item.sub ? __jsx('div', { className: \"vx-price-card-sub\",}, item.sub) : null\n          )\n        ))\n        , Array.from({ length: empty }, (_, i) => __jsx('span', { key: `empty-${i}`, className: \"vx-price-card is-empty\" , 'aria-hidden': \"true\",} ))\n      )\n    );\n  };\n\n  // This model's prices against similar models on Venice. The bar scales one\n  // column across the rows; it repeats the figures, so it's hidden from\n  // assistive tech.\n  const SimilarPrices = ({ columns, bar, rows }) => {\n    const shown = rows.filter(row => row.current || columns.some(col => col.get(row) != null));\n    if (shown.length < 2) return null;\n    const values = shown.map(bar.get).filter(v => v != null && v > 0);\n    const max = values.length ? Math.max(...values) : 0;\n    return (\n      __jsx('div', { className: \"vx-table-wrap vx-ruled vx-ptable-wrap\"  ,}\n        , __jsx('table', { className: \"vx-ptable\",}\n          , __jsx('thead', null\n            , __jsx('tr', null\n              , __jsx('th', { scope: \"col\",}, \"Similar models\" )\n              , columns.map(col => __jsx('th', { key: col.label, scope: \"col\", className: \"vx-al-right\",}, col.label))\n              , __jsx('th', { scope: \"col\", className: \"vx-ptable-bar-head vx-hide-sm\" ,}, bar.label)\n            )\n          )\n          , __jsx('tbody', null\n            , shown.map(row => {\n              const value = bar.get(row);\n              return (\n                __jsx('tr', { key: row.key, className: cls(row.current && 'is-current'),}\n                  , __jsx('th', { scope: \"row\",}, row.href ? __jsx('a', { href: row.href,}, row.name) : row.name)\n                  , columns.map(col => __jsx('td', { key: col.label, className: \"vx-al-right vx-num\" ,}, usd(col.get(row))))\n                  , __jsx('td', { className: \"vx-ptable-bar vx-hide-sm\" , 'aria-hidden': \"true\",}\n                    , __jsx('span', { className: \"vx-ptable-track\",}, __jsx('span', { style: { width: value && max ? `${Math.max(1, (value / max) * 100)}%` : 0 },} ))\n                  )\n                )\n              );\n            })\n          )\n        )\n      )\n    );\n  };\n\n  const similarRows = (related, current) => [\n    current,\n    ...((related && related.similar) || []).filter(item => item.pricing).map(item => ({ key: item.slug, name: item.name, href: `/models/${item.slug}`, ...item.pricing }))\n  ];\n\n  const TextPricing = ({ model, family, related }) => {\n    const p = model.pricing || {};\n    const ext = p.extended;\n    const above = value => (ext && value != null ? `${usd(value)} above ${tokens(ext.threshold)}` : null);\n    return (\n      __jsx(__Fragment, null\n        , __jsx(PriceCards, { items: [\n          { label: 'Input', value: usd(p.input), sub: above(ext && ext.input) },\n          p.cacheRead != null ? { label: 'Cached input', value: usd(p.cacheRead), sub: above(ext && ext.cacheRead) } : null,\n          p.cacheWrite != null ? { label: 'Cache write', value: usd(p.cacheWrite), sub: above(ext && ext.cacheWrite) } : null,\n          { label: 'Output', hint: model.text && model.text.reasoning ? 'incl. reasoning' : null, value: usd(p.output), sub: above(ext && ext.output) }\n        ],} )\n        , __jsx(SimilarPrices, {\n          columns: [{ label: 'Input', get: row => row.input }, { label: 'Output', get: row => row.output }],\n          bar: { label: 'Output price, relative', get: row => row.output },\n          rows: similarRows(related, { key: model.id, name: family.name, current: true, input: p.input, output: p.output }),} )\n        , p.cacheRead != null ? __jsx('p', { className: \"vx-footnote\",}, \"Prompt caching is automatic; see \"     , __jsx('a', { href: \"/guides/features/prompt-caching\",}, \"Prompt caching\" ), \".\") : null\n      )\n    );\n  };\n\n  const VideoCalculator = ({ model }) => {\n    const video = model.video || {};\n    const p = model.pricing || {};\n    const res = (video.resolutions || []).filter(r => r.height).sort((a, b) => a.height - b.height);\n    const durs = (video.durations || []).filter(d => d.seconds);\n    const [h, setH] = useState(() => ((res.find(r => r.height === 720) || res[0] || {}).height || 720));\n    const [s, setS] = useState(() => ((durs.find(d => d.seconds === 5) || durs[0] || {}).seconds || 5));\n    const [a, setA] = useState(video.audio === 'native' ? 'on' : 'off');\n    useEffect(() => {\n      setH((res.find(r => r.height === 720) || res[0] || {}).height || 720);\n      setS((durs.find(d => d.seconds === 5) || durs[0] || {}).seconds || 5);\n      setA(video.audio === 'native' ? 'on' : 'off');\n    }, [model.id]);\n    if (p.status === 'input-dependent') {\n      return __jsx('p', { className: \"vx-text\",}, \"This mode bills by the length of the source video you upload. Call \"             , __jsx('code', null, \"POST /video/quote\" ), \" with your \"   , __jsx('code', null, \"video_url\"), \" for an exact price before queueing.\"      );\n    }\n    if (p.status !== 'quoted') return __jsx('p', { className: \"vx-text\",}, \"Use \" , __jsx('code', null, \"POST /video/quote\" ), \" for this model's price.\"    );\n    const vp = videoPrice(model, { h, s, a });\n    // The selected clip's own rate, not the median across lengths.\n    const perSecond = vp.clip != null && vp.seconds ? vp.clip / vp.seconds : null;\n    const clipNote = `${vp.seconds}s${vp.resolution ? ` · ${vp.resolution}` : ''} · ${vp.audio ? 'with audio' : 'silent'}`;\n    const audioKey = video.audio === 'optional' ? a : (video.audio === 'native' ? 'on' : 'off');\n    const resKeys = res.length ? res : [{ value: '-', label: 'Default', height: 0 }];\n    const table = clipTable(model, resKeys, audioKey) || { rows: durs, rates: null, note: null };\n    // With per-second pricing the card shows the rate every length shares.\n    const shared = table.rates ? table.rates[Math.max(0, resKeys.findIndex(r => r.height === h))] : null;\n    const rate = shared != null ? shared : perSecond;\n    // Many evenly spaced lengths get a slider rather than a button each.\n    const lengths = durationSteps(durs);\n    const slider = durs.length > 6 && lengths.step ? lengths : null;\n    return (\n      __jsx('div', { className: \"vx-calc\",}\n        , __jsx('div', { className: \"vx-calc-controls\",}\n          , res.length > 1 ? (\n            __jsx('div', { className: \"vx-control\",}, __jsx('span', { className: \"vx-control-label\",}, \"Resolution\")\n              , __jsx(Segmented, { ariaLabel: \"Resolution\", value: h, onChange: setH, options: res.map(r => ({ value: r.height, label: r.label })),} )\n            )\n          ) : null\n          , durs.length > 1 ? (\n            __jsx('div', { className: \"vx-control\",}, __jsx('span', { className: \"vx-control-label\",}, \"Duration\")\n              , slider ? (\n                __jsx('span', { className: \"vx-range\",}\n                  , __jsx('input', { type: \"range\", min: slider.secs[0], max: slider.secs[slider.secs.length - 1], step: slider.step, value: s,\n                    'aria-label': \"Duration\", 'aria-valuetext': `${s} seconds`, onChange: e => setS(Number(e.target.value)),} )\n                  , __jsx('span', { className: \"vx-range-value\",}, s, \"s\")\n                )\n              ) : (\n                __jsx(Segmented, { ariaLabel: \"Duration\", value: s, onChange: setS, options: durs.map(d => ({ value: d.seconds, label: `${d.seconds}s` })),} )\n              )\n            )\n          ) : null\n          , video.audio === 'optional' ? (\n            __jsx('div', { className: \"vx-control\",}, __jsx('span', { className: \"vx-control-label\",}, \"Audio\")\n              , __jsx(Segmented, { ariaLabel: \"Audio\", value: a, onChange: setA, options: [{ value: 'off', label: 'Silent' }, { value: 'on', label: 'With audio' }],} )\n            )\n          ) : null\n        )\n        , __jsx('div', { className: \"vx-estimate\", 'aria-live': \"polite\",}\n          , __jsx(PriceCards, { items: [\n            { label: 'Per clip', value: usd(vp.clip), sub: clipNote },\n            { label: 'Per second', value: usd(rate), sub: shared != null ? 'any length' : 'this clip' },\n            // A minute only means something when one clip can run that long.\n            maxVideoSeconds(model) >= 60 ? { label: 'Per minute', value: usd(rate != null ? rate * 60 : null), sub: 'at this rate' } : null\n          ],} )\n        )\n        , __jsx('div', { className: \"vx-table-wrap vx-ruled\" ,}\n          , __jsx('table', { className: \"vx-dtable vx-matrix\" ,}\n            , __jsx('caption', { className: \"vx-sr-only\",}, \"Clip price by duration and resolution\"     , video.audio === 'optional' ? (a === 'on' ? ', with audio' : ', silent') : '')\n            , __jsx('thead', null\n              , __jsx('tr', null, __jsx('th', null, \"Duration\"), resKeys.map(r => __jsx('th', { key: r.value, className: \"vx-al-right\",}, r.label)))\n            )\n            , __jsx('tbody', null\n              , table.rates ? (\n                __jsx('tr', { className: \"vx-rate-row\",}\n                  , __jsx('th', { scope: \"row\",}, \"Per second\" )\n                  , table.rates.map((rate, i) => __jsx('td', { key: resKeys[i].value, className: \"vx-al-right\",}, usd(rate)))\n                )\n              ) : null\n              , table.rows.map(d => (\n                __jsx('tr', { key: d.value,}\n                  , __jsx('th', { scope: \"row\",}, d.seconds, \"s\")\n                  , resKeys.map(r => {\n                    const q = p.quotes && p.quotes[`${r.value}|${d.value}|${audioKey}`];\n                    const active = d.seconds === s && (r.height === h || !res.length);\n                    return (\n                      __jsx('td', { key: r.value, className: \"vx-al-right\",}\n                        , __jsx('button', { type: \"button\", className: cls('vx-cell-btn', active && 'is-active'), 'aria-pressed': active, disabled: q == null,\n                          onClick: () => { setS(d.seconds); if (r.height) setH(r.height); },}, usd(q))\n                      )\n                    );\n                  })\n                )\n              ))\n            )\n          )\n        )\n        , __jsx('p', { className: \"vx-footnote\",}, table.note ? `${table.note} ` : '', \"Quoted from \"  , __jsx('code', null, \"POST /video/quote\" ), p.quotedAt ? ` on ${fmtDate(Math.floor(new Date(p.quotedAt).getTime() / 1000))}` : '', \".\")\n      )\n    );\n  };\n\n  const ImagePricing = ({ model, models, family, related }) => {\n    const p = model.pricing || {};\n    const verb = model.task === 'image-edit' ? 'edit' : 'generation';\n    const editor = model.task === 'image-generation' ? models.find(m => m.task === 'image-edit') : null;\n    const editPrice = editor && editor.pricing ? (editor.pricing.edit != null ? editor.pricing.edit : editor.pricing.perImage) : null;\n    const upscale = p.upscale && model.task !== 'image-upscale' ? Object.entries(p.upscale).filter(([, v]) => v != null) : [];\n    const resolutions = p.byResolution ? Object.keys(p.byResolution) : [];\n    const top = resolutions[resolutions.length - 1];\n    const at = (row, res) => (row.byResolution ? row.byResolution[res] : res === resolutions[0] ? row.perImage : null);\n    const qualityRes = p.byQuality ? Object.keys(p.byQuality) : [];\n    const levels = ['low', 'medium', 'high'].filter(level => qualityRes.some(res => p.byQuality[res][level] != null));\n    return (\n      __jsx(__Fragment, null\n        , __jsx(PriceCards, { items: [\n          ...(p.byResolution\n            ? Object.entries(p.byResolution).map(([res, value]) => ({ label: `${res} ${verb}`, value: usd(value), sub: p.defaultQuality ? `${p.defaultQuality} quality` : null }))\n            : [{ label: model.task === 'image-edit' ? 'Edit' : model.task === 'image-upscale' ? '2x upscale' : 'Per image', value: usd(p.perImage) }]),\n          model.task === 'image-upscale' && p.upscale && p.upscale['4x'] != null ? { label: '4x upscale', value: usd(p.upscale['4x']) } : null,\n          editPrice != null ? { label: 'Edit', value: usd(editPrice) } : null,\n          p.extraInputImage != null ? { label: 'Extra input image', value: usd(p.extraInputImage) } : null\n        ],} )\n        , levels.length ? (\n          __jsx(__Fragment, null\n            , __jsx('div', { className: \"vx-table-wrap vx-ruled\" ,}\n              , __jsx('table', { className: \"vx-dtable\",}\n                , __jsx('caption', { className: \"vx-sr-only\",}, \"Price per \"  , verb === 'edit' ? 'edit' : 'image', \" by quality and resolution\"    )\n                , __jsx('thead', null\n                  , __jsx('tr', null, __jsx('th', null, \"Quality\"), qualityRes.map(res => __jsx('th', { key: res, className: \"vx-al-right\",}, res)))\n                )\n                , __jsx('tbody', null\n                  , levels.map(level => (\n                    __jsx('tr', { key: level,}\n                      , __jsx('th', { scope: \"row\",}, upperFirst(level), level === p.defaultQuality ? __jsx('span', { className: \"vx-muted\",}, \" · default\"  ) : null)\n                      , qualityRes.map(res => __jsx('td', { key: res, className: \"vx-al-right vx-num\" ,}, usd(p.byQuality[res][level])))\n                    )\n                  ))\n                )\n              )\n            )\n            , __jsx('p', { className: \"vx-footnote\",}\n              , model.task === 'image-edit'\n                ? __jsx(__Fragment, null, __jsx('code', null, \"POST /image/edit\" ), \" runs at the default quality. To pick another, send \"          , __jsx('code', null, \"quality\"), \" to \"  , __jsx('code', null, \"POST /image/multi-edit\" ), \".\")\n                : __jsx(__Fragment, null, \"Send \" , __jsx('code', null, \"quality\"), \" to pick a tier\"    , p.defaultQuality ? `; requests without it run at ${p.defaultQuality}` : '', \".\")\n            )\n          )\n        ) : null\n        , model.task === 'image-generation' && resolutions.length ? (\n          __jsx(SimilarPrices, {\n            columns: [...resolutions.map(res => ({ label: res, get: row => at(row, res) })), { label: 'Edit', get: row => row.edit }],\n            bar: { label: `${top}, relative`, get: row => at(row, top) },\n            rows: similarRows(related, { key: model.id, name: family.name, current: true, byResolution: p.byResolution, perImage: p.perImage, edit: editPrice }),} )\n        ) : null\n        , upscale.length ? __jsx('p', { className: \"vx-footnote\",}, \"Optional upscale: \"  , listText(upscale.map(([k, v]) => `${usd(v)} at ${k}`)), \".\") : null\n      )\n    );\n  };\n\n  const AudioPricing = ({ model }) => {\n    const p = model.pricing || {};\n    if (model.task === 'tts') {\n      return (\n        __jsx(__Fragment, null\n          , __jsx(PriceCards, { items: [\n            { label: '1M characters', hint: 'billed unit', value: usd(p.per1MChars) },\n            { label: '1 minute', value: usd(p.perMinute), sub: '≈ 825 characters' },\n            { label: '1 hour', value: usd(p.perHour) },\n            { label: '2,000-word article', value: usd(p.per1MChars != null ? p.per1MChars * 0.012 : null), sub: '≈ 12K characters' }\n          ],} )\n          , __jsx('p', { className: \"vx-footnote\",}, \"Minute and hour figures assume 150 words per minute.\"        )\n        )\n      );\n    }\n    if (model.task === 'stt') {\n      return (\n        __jsx(PriceCards, { items: [\n          { label: '1 second', hint: 'billed unit', value: usd(p.perSecond) },\n          { label: '1 minute', value: usd(p.perMinute) },\n          { label: '1 hour', value: usd(p.perHour) },\n          { label: '1,000 minutes', value: usd(p.perMinute != null ? p.perMinute * 1000 : null) }\n        ],} )\n      );\n    }\n    if (p.kind === 'tiered' && p.tiers) {\n      const fixed = model.audio && model.audio.durationOptions;\n      return (\n        __jsx(__Fragment, null\n          , __jsx('div', { className: \"vx-table-wrap vx-ruled\" ,}\n            , __jsx('table', { className: \"vx-dtable\",}\n              , __jsx('thead', null, __jsx('tr', null, __jsx('th', null, \"Track length\" ), __jsx('th', { className: \"vx-al-right\",}, \"Price\")))\n              , __jsx('tbody', null\n                , p.tiers.map(t => (\n                  __jsx('tr', { key: t.upTo,}, __jsx('td', null, tierLabel(t, fixed)), __jsx('td', { className: \"vx-al-right vx-num\" ,}, usd(t.usd)))\n                ))\n              )\n            )\n          )\n          , __jsx('p', { className: \"vx-footnote\",}, fixed\n            ? __jsx(__Fragment, null, \"Send one of these lengths as \"      , __jsx('code', null, \"duration_seconds\"), \".\")\n            : __jsx(__Fragment, null, \"Billed by duration bucket. Use \"     , __jsx('code', null, \"POST /audio/quote\" ), \" for an exact price.\"    ))\n        )\n      );\n    }\n    return __jsx('p', { className: \"vx-text\",}, p.kind === 'per-second' ? `${usd(p.perSecond)} per second of generated audio.` : p.kind === 'per-track' ? `${usd(p.perTrack)} per generated track.` : 'Use POST /audio/quote for this model.');\n  };\n\n  const AspectShape = ({ ratio, active }) => {\n    const [w, h] = String(ratio).split(':').map(Number);\n    if (!w || !h) return __jsx('span', { className: \"vx-ratio\",}, __jsx('span', null, ratio));\n    const scale = 22 / Math.max(w, h);\n    return (\n      __jsx('span', { className: cls('vx-ratio', active && 'is-active'), title: ratio,}\n        , __jsx('span', { className: \"vx-ratio-shape\", style: { width: Math.max(6, w * scale), height: Math.max(6, h * scale) },} )\n        , __jsx('span', null, ratio)\n      )\n    );\n  };\n\n  const VOICE_LIMIT = 48;\n\n  const Voices = ({ model }) => {\n    const [q, setQ] = useState('');\n    const [all, setAll] = useState(false);\n    const voices = (model.audio && model.audio.voices) || [];\n    const matches = voices.filter(v => v.toLowerCase().includes(q.toLowerCase()));\n    const shown = all || q ? matches : matches.slice(0, VOICE_LIMIT);\n    return (\n      __jsx('div', { className: \"vx-voices\",}\n        , __jsx('div', { className: \"vx-voices-head\",}\n          , __jsx('div', { className: \"vx-search vx-search-sm\" ,}\n            , __jsx(Icon, { name: \"search\", size: 14,} )\n            , __jsx('input', { type: \"search\", value: q, onChange: e => setQ(e.target.value), placeholder: `Filter ${voices.length} voices`, 'aria-label': \"Filter voices\" ,} )\n          )\n        )\n        , shown.length ? (\n          __jsx('div', { className: \"vx-voice-grid\",}\n            , shown.map(v => __jsx(VoiceChip, { key: v, voice: v,} ))\n          )\n        ) : __jsx('p', { className: \"vx-muted\",}, \"No voice matches “\"   , q, \"”.\")\n        , !q && matches.length > VOICE_LIMIT ? (\n          __jsx('button', { type: \"button\", className: \"vx-link-btn vx-more\" , onClick: () => setAll(!all),}, all ? 'Show fewer' : `Show all ${matches.length} voices`)\n        ) : null\n      )\n    );\n  };\n\n  const VoiceChip = ({ voice }) => {\n    const [done, setDone] = useState(false);\n    return (\n      __jsx('button', { type: \"button\", className: cls('vx-voice', done && 'is-done'), 'aria-label': `Copy voice ID ${voice}`,\n        onClick: () => copyText(voice).then(() => { setDone(true); setTimeout(() => setDone(false), 1200); }),}\n        , done ? __jsx(Icon, { name: \"check\", size: 12,} ) : null, voice\n      )\n    );\n  };\n\n  const MethodPath = ({ method, path }) => (\n    __jsx('span', { className: \"vx-endpoint\",}, __jsx('span', { className: \"vx-method\",}, method), __jsx('code', null, \"/api/v1\", path))\n  );\n\n  const Endpoints = ({ model, endpointId, setEndpointId }) => {\n    const list = model.endpoints || [];\n    const active = list.find(e => e.id === endpointId) || list[0];\n    if (!active) return null;\n    const isFlow = list.some(e => /-(retrieve|quote)$/.test(e.id));\n    return (\n      __jsx('div', { className: \"vx-endpoints\",}\n        , list.length > 1 ? (\n          __jsx(Segmented, { ariaLabel: \"Endpoint\", value: active.id, onChange: setEndpointId,\n            options: list.map(e => ({ value: e.id, label: e.name, disabled: e.supported === false, title: e.supported === false ? (e.note || 'Not supported for this model') : undefined })),} )\n        ) : null\n        , __jsx('div', { className: \"vx-endpoint-line\",}\n          , __jsx(MethodPath, { method: active.method, path: active.path,} )\n          , active.recommended && list.length > 1 && !isFlow ? __jsx(Tag, { tone: \"accent\",}, \"Recommended\") : null\n        )\n        , active.recommendation ? __jsx('p', { className: \"vx-endpoint-note\",}, active.recommendation) : null\n      )\n    );\n  };\n\n  const VariantsTable = ({ models, activeId, onSelect }) => {\n    const first = models[0];\n    const isText = first.modality === 'text' && first.task === 'chat';\n    const isVideo = first.modality === 'video';\n    const showEffort = isText && models.some(m => m.text && m.text.reasoning && m.text.reasoning.effort && m.text.reasoning.effort.length);\n    const showPrecision = isText && models.some(m => m.text && m.text.quantization);\n    return (\n      __jsx('div', { className: \"vx-table-wrap vx-ruled\" ,}\n        , __jsx('table', { className: \"vx-dtable vx-variants-table\" ,}\n          , __jsx('thead', null\n            , __jsx('tr', null\n              , __jsx('th', null, \"Variant\"), __jsx('th', null, \"Model ID\" ), __jsx('th', { className: \"vx-hide-sm\",}, \"Privacy\")\n              , isText ? __jsx(__Fragment, null, __jsx('th', { className: \"vx-al-right vx-hide-sm\" ,}, \"Context\"), __jsx('th', { className: \"vx-al-right vx-hide-md\" ,}, \"Max output\" ), __jsx('th', { className: \"vx-al-right\",}, \"Input / output\"  ), showEffort ? __jsx('th', { className: \"vx-hide-md\",}, \"Effort\") : null, showPrecision ? __jsx('th', { className: \"vx-hide-lg\",}, \"Precision\") : null) : null\n              , isVideo ? __jsx(__Fragment, null, __jsx('th', { className: \"vx-hide-md\",}, \"Inputs\"), __jsx('th', { className: \"vx-al-right\",}, \"From\"), __jsx('th', { className: \"vx-al-right vx-hide-sm\" ,}, \"Max\")) : null\n              , !isText && !isVideo ? __jsx('th', { className: \"vx-al-right\",}, \"Price\") : null\n              , __jsx('th', { className: \"vx-al-right vx-hide-md\" ,}, \"Added\")\n            )\n          )\n          , __jsx('tbody', null\n            , models.map(m => (\n              __jsx('tr', { key: m.id, className: cls(m.id === activeId && 'is-current', 'is-clickable'), onClick: () => onSelect(m.id),}\n                , __jsx('td', null, __jsx('button', { type: \"button\", className: \"vx-row-btn\", 'aria-pressed': m.id === activeId, onClick: e => { e.stopPropagation(); onSelect(m.id); },}, VARIANT_LABELS[m.variant] || m.variant))\n                , __jsx('td', null, __jsx('span', { className: \"vx-id vx-id-inline\" , title: m.id,}, __jsx('code', null, m.id), __jsx(CopyButton, { text: m.id, iconOnly: true, label: `Copy model ID ${m.id}`,} )))\n                , __jsx('td', { className: \"vx-hide-sm\",}, PRIVACY[m.privacy] ? PRIVACY[m.privacy].label : m.privacy)\n                , isText ? (\n                  __jsx(__Fragment, null\n                    , __jsx('td', { className: \"vx-al-right vx-num vx-hide-sm\"  ,}, tokens(m.text && m.text.context))\n                    , __jsx('td', { className: \"vx-al-right vx-num vx-hide-md\"  ,}, tokens(m.text && m.text.maxOutput))\n                    , __jsx('td', { className: \"vx-al-right vx-num\" ,}, usd(m.pricing && m.pricing.input), \" / \"  , usd(m.pricing && m.pricing.output))\n                    , showEffort ? __jsx('td', { className: \"vx-hide-md vx-wrap\" ,}, m.text && m.text.reasoning && m.text.reasoning.effort && m.text.reasoning.effort.length ? m.text.reasoning.effort.join(', ') : __jsx('span', { className: \"vx-muted\",}, \"—\")) : null\n                    , showPrecision ? __jsx('td', { className: \"vx-hide-lg\",}, m.text && m.text.quantization ? QUANT_LABELS[m.text.quantization] || m.text.quantization : __jsx('span', { className: \"vx-muted\",}, \"Not disclosed\" )) : null\n                  )\n                ) : null\n                , isVideo ? (\n                  __jsx(__Fragment, null\n                    , __jsx('td', { className: \"vx-hide-md\",}, videoInputList(m.video).map(upperFirst).join(', '))\n                    , __jsx('td', { className: \"vx-al-right vx-num\" ,}, m.pricing && m.pricing.status === 'quoted' ? `${usd(m.pricing.fromPerSecond)} / sec` : 'By source')\n                    , __jsx('td', { className: \"vx-al-right vx-num vx-hide-sm\"  ,}, heightLabel(maxVideoHeight(m)))\n                  )\n                ) : null\n                , !isText && !isVideo ? __jsx('td', { className: \"vx-al-right vx-num\" ,}, usd(m.headline && m.headline.value), \" \" , __jsx('span', { className: \"vx-muted\",}, headlineUnit(m))) : null\n                , __jsx('td', { className: \"vx-al-right vx-muted vx-hide-md\"  ,}, shortDate(m.created))\n              )\n            ))\n          )\n        )\n      )\n    );\n  };\n\n  // Text lists input and output, as the price comparison does, rather than\n  // the blended figure the catalog sorts by.\n  const relatedPrice = item => {\n    const p = item.pricing;\n    if (p && p.input != null && p.output != null) return __jsx(__Fragment, null, usd(p.input), \" / \"  , usd(p.output), __jsx('span', { className: \"vx-muted\",}, \" per 1M\"  ));\n    if (item.modality === 'video' && item.videoFrom != null) return __jsx(__Fragment, null, \"from \" , usd(item.videoFrom), __jsx('span', { className: \"vx-muted\",}, \" / sec\"  ));\n    if (item.headline && item.headline.value != null) return __jsx(__Fragment, null, usd(item.headline.value), __jsx('span', { className: \"vx-muted\",}, \" \" , item.headline.unit));\n    return null;\n  };\n\n  const RelatedList = ({ items, providers, title }) => {\n    if (!items || !items.length) return null;\n    return (\n      __jsx('div', { className: \"vx-related\",}\n        , __jsx('h3', { className: \"vx-related-head\",}, title)\n        , __jsx('ul', { className: \"vx-related-list\",}\n          , items.map(item => (\n            __jsx('li', { key: item.slug,}\n              , __jsx(ProviderLogo, { provider: providers[item.provider], size: 20,} )\n              , __jsx('span', { className: \"vx-related-name\",}\n                , __jsx('a', { href: `/models/${item.slug}`,}, item.name)\n                , __jsx('span', { className: \"vx-muted\",}, (providers[item.provider] && providers[item.provider].name) || item.provider)\n              )\n              , __jsx('span', { className: \"vx-related-price\",}, relatedPrice(item))\n            )\n          ))\n        )\n      )\n    );\n  };\n\n  const ModelPage = ({ data }) => (data.family.task === 'chat' ? __jsx(ModelPageNext, { data: data,} )\n    : data.family.task === 'image-generation' ? __jsx(ImagePageNext, { data: data,} )\n      : data.family.task === 'video' ? __jsx(VideoPageNext, { data: data,} )\n        : data.family.task === 'embedding' ? __jsx(EmbeddingPageNext, { data: data,} )\n          : data.family.task === 'tts' ? __jsx(SpeechPageNext, { data: data,} )\n            : data.family.task === 'stt' ? __jsx(TranscriptionPageNext, { data: data,} )\n              : data.family.task === 'music' || data.family.task === 'sfx' ? __jsx(SoundPageNext, { data: data,} ) : __jsx(ModelPageClassic, { data: data,} ));\n\n  const ModelPageClassic = ({ data }) => {\n    const { family, models, related, providers } = data;\n    // ?v= names the variant. It's read on the first render, so the primary\n    // never flashes, and again on Back and Forward.\n    const variantFromUrl = () => {\n      const v = readParams().get('v');\n      return v && models.some(m => m.id === v) ? v : family.primary;\n    };\n    const [variantId, setVariantId] = useState(variantFromUrl);\n    const [endpointId, setEndpointId] = useState(null);\n    const now = useNow();\n\n    useEffect(() => {\n      const onPop = () => {\n        setVariantId(variantFromUrl());\n        setEndpointId(null);\n      };\n      window.addEventListener('popstate', onPop);\n      return () => window.removeEventListener('popstate', onPop);\n    }, []);\n\n    const model = models.find(m => m.id === variantId) || models[0];\n    const provider = providers[family.provider] || providers[model.provider];\n    const recommended = (model.endpoints || []).find(e => e.recommended) || (model.endpoints || [])[0];\n    const activeEndpoint = (model.endpoints || []).find(e => e.id === endpointId && e.supported !== false) || recommended;\n    const hasRelated = Boolean(related && ((related.versions || []).length || (related.similar || []).length));\n    const hasExamples = (model.modality === 'image' || model.modality === 'video') && models.some(m => (m.media || []).length);\n    const sections = pageSections(model, { variants: models.length, related: hasRelated, examples: hasExamples, capabilities: hasCapabilities(model, models) });\n    const activeSection = useScrollSpy(sections.map(([id]) => id));\n    const has = id => sections.some(([key]) => key === id);\n\n    const selectVariant = id => {\n      setVariantId(id);\n      setEndpointId(null);\n      writeParams({ v: id === family.primary ? null : id });\n    };\n\n    return (\n      __jsx('div', { className: \"vx vx-page not-prose\"  ,}\n        , __jsx(HoverTips, null )\n        , __jsx('div', { className: \"vx-page-grid\",}\n          , __jsx('aside', { className: \"vx-side\",}\n            , __jsx('div', { className: \"vx-side-inner\",}\n              , __jsx('nav', { className: \"vx-crumbs\", 'aria-label': \"Breadcrumb\",}\n                , __jsx('a', { href: \"/models/overview\",}, \"Models\")\n                , __jsx(Icon, { name: \"chevronRight\", size: 12,} )\n                , __jsx('span', { 'aria-current': \"page\",}, family.name)\n              )\n              , __jsx('nav', { className: \"vx-side-nav\", 'aria-label': \"On this page\"  ,}\n                , sections.map(([id, label]) => (\n                  __jsx('a', { key: id, href: `#${id}`, className: cls(activeSection === id && 'is-active'), 'aria-current': activeSection === id ? 'location' : undefined,}\n                    , __jsx(Icon, { name: SECTION_ICONS[id], size: 16,} ), label\n                  )\n                ))\n              )\n              , safeUrl(model.source) ? (\n                __jsx('div', { className: \"vx-side-actions\",}\n                  , __jsx('a', { className: \"vx-side-link\", href: safeUrl(model.source), target: \"_blank\", rel: \"noopener noreferrer\" ,}, \"Source\", __jsx(Icon, { name: \"external\", size: 12,} ))\n                )\n              ) : null\n            )\n          )\n\n          , __jsx('div', { className: \"vx-page-main\",}\n            , __jsx('header', { id: \"overview\", className: \"vx-model-head\",}\n              , __jsx('p', { className: \"vx-model-meta\",}\n                , [\n                  provider ? provider.name : family.provider,\n                  `Added ${fmtDate(model.created)}`,\n                  familyTask(family, models),\n                  PRIVACY[model.privacy] ? PRIVACY[model.privacy].label : null,\n                  model.openWeights ? 'Open weights' : null,\n                  model.license,\n                  model.uncensored ? 'Uncensored' : null,\n                  isNew(model.created, now) ? 'New' : null\n                ].filter(Boolean).map(item => __jsx('span', { key: item, className: \"vx-meta-item\",}, item))\n                , model.beta ? __jsx('span', { className: \"vx-meta-item is-warn\" , title: \"Experimental. May change or be removed without notice.\"       ,}, \"Beta\") : null\n                , model.deprecation ? __jsx('span', { className: \"vx-meta-item is-warn\" , title: \"Scheduled for removal. See Deprecations.\"    ,}, \"Deprecated\") : null\n              )\n              , __jsx('h1', { className: \"vx-h1\",}, family.name)\n              , model.description || family.description ? __jsx('p', { className: \"vx-description\",}, model.description || family.description) : null\n\n              , models.length > 1 ? (\n                __jsx('div', { className: \"vx-variants\", role: \"radiogroup\", 'aria-label': \"Variant\", onKeyDown: rovingKeys(models.map(m => m.id), model.id, selectVariant),}\n                  , models.map(m => (\n                    __jsx('button', { key: m.id, 'data-key': m.id, type: \"button\", role: \"radio\", 'aria-checked': m.id === model.id, tabIndex: m.id === model.id ? 0 : -1,\n                      className: cls('vx-variant', m.id === model.id && 'is-active'), onClick: () => selectVariant(m.id),}\n                      , __jsx('span', { className: \"vx-variant-name\",}, VARIANT_LABELS[m.variant] || m.variant)\n                      , __jsx('span', { className: \"vx-variant-sub\",}, [m.privacy !== m.variant && PRIVACY[m.privacy] ? PRIVACY[m.privacy].label : null, priceSummary(m)].filter(Boolean).join(' · '))\n                    )\n                  ))\n                )\n              ) : null\n\n              , __jsx('div', { className: \"vx-idbar\",}\n                , __jsx(ModelId, { id: model.id,} )\n                , recommended ? __jsx('span', { className: \"vx-endpoint-url\",}, recommended.method, \" \" , API, recommended.path) : null\n              )\n            )\n\n            , __jsx(KeyStats, { model: model, models: models,} )\n\n            , __jsx(Section, { id: \"pricing\", title: \"Pricing\", note: `USD ${priceUnit(model)}`,}\n              , model.modality === 'text' && model.task === 'chat' ? __jsx(TextPricing, { model: model, family: family, related: related,} ) : null\n              , model.modality === 'image' ? __jsx(ImagePricing, { model: model, models: models, family: family, related: related,} ) : null\n              , model.modality === 'video' ? __jsx(VideoCalculator, { model: model,} ) : null\n              , model.modality === 'audio' ? __jsx(AudioPricing, { model: model,} ) : null\n              , model.modality === 'embedding' ? (\n                __jsx(PriceCards, { items: [\n                  { label: 'Input', value: usd(model.pricing && model.pricing.input) },\n                  { label: '1M documents', value: usd(model.pricing && model.pricing.input != null ? model.pricing.input * 500 : null), sub: '500 tokens each, embedded once' }\n                ],} )\n              ) : null\n              , model.task === 'decision' ? (\n                __jsx(PriceCards, { items: [\n                  { label: 'State tokens in', value: usd(model.pricing && model.pricing.input) },\n                  { label: 'Decision tokens out', value: usd(model.pricing && model.pricing.output) }\n                ],} )\n              ) : null\n            )\n\n            , has('examples') ? (\n              __jsx(Section, { id: \"examples\", title: \"Examples\",}\n                , __jsx(MediaGallery, { model: model.media && model.media.length ? model : (models.find(m => m.media && m.media.length) || model),} )\n              )\n            ) : null\n\n            , has('voices') ? (\n              __jsx(Section, { id: \"voices\", title: \"Voices\",}\n                , __jsx(Voices, { model: model,} )\n              )\n            ) : null\n\n            , __jsx(Section, { id: \"specs\", title: \"Specs\",}\n              , __jsx(Specs, { model: model, models: models,} )\n            )\n\n            , has('capabilities') ? (\n              __jsx(Section, { id: \"capabilities\", title: \"Capabilities\",}\n                , __jsx(CapabilityMatrix, { model: model, models: models,} )\n              )\n            ) : null\n\n            , __jsx(Section, { id: \"api\", title: \"API\", actions: __jsx('a', { className: \"vx-link-btn\", href: \"https://venice.ai/settings/api\", target: \"_blank\", rel: \"noopener\",}, \"Get an API key\"   ),}\n              , __jsx(Endpoints, { model: model, endpointId: activeEndpoint && activeEndpoint.id, setEndpointId: setEndpointId,} )\n              , model.privacy === 'e2ee' ? __jsx('p', { className: \"vx-text\",}, \"E2EE requests encrypt the prompt on your device and send attestation headers; follow the \"              , __jsx('a', { href: \"/guides/features/tee-e2ee-models\",}, \"TEE and E2EE guide\"   ), \". The samples show the plain request shape.\"       ) : null\n              , __jsx(CodeTabs, { samples: codeSamples(model, activeEndpoint && activeEndpoint.id),} )\n            )\n\n            , has('variants') ? (\n              __jsx(Section, { id: \"variants\", title: \"Variants\",}\n                , __jsx(VariantsTable, { models: models, activeId: model.id, onSelect: selectVariant,} )\n              )\n            ) : null\n\n            , has('related') ? (\n              __jsx(Section, { id: \"related\", title: \"Related models\" ,}\n                , __jsx('div', { className: \"vx-related-grid\",}\n                  , __jsx(RelatedList, { title: \"Other versions\" , items: related.versions, providers: providers,} )\n                  , __jsx(RelatedList, { title: \"Similar price and capability\"   , items: related.similar, providers: providers,} )\n                )\n              )\n            ) : null\n          )\n        )\n      )\n    );\n  };\n\n  /* ------------------------------------------------------------ model page, next */\n\n  const CAP_GUIDES = {\n    tools: '/guides/features/function-calling', structured: '/guides/features/structured-responses',\n    reasoning: '/guides/features/reasoning-models', vision: '/guides/features/vision', caching: '/guides/features/prompt-caching'\n  };\n\n  // What a capability takes in a request, or what it adds.\n  const capDetail = (model, key) => {\n    const t = model.text || {};\n    const caps = t.caps || {};\n    const r = t.reasoning;\n    if (key === 'tools') return __jsx('code', null, \"tools\");\n    if (key === 'structured') return __jsx('code', null, \"response_format\");\n    if (key === 'reasoning') return r && r.effort && r.effort.length ? __jsx(__Fragment, null, __jsx('code', null, \"reasoning_effort\"), \" \" , r.effort.join(' · ')) : 'Always on';\n    if (key === 'vision') return caps.maxImages ? `Up to ${caps.maxImages} images` : 'Images in messages';\n    if (key === 'videoInput') return caps.maxVideos ? `Up to ${caps.maxVideos} videos` : 'Video in messages';\n    if (key === 'audioInput') return 'Audio in messages';\n    if (key === 'webSearch') return __jsx('code', null, \"enable_web_search\");\n    if (key === 'xSearch') return __jsx('code', null, \"enable_x_search\");\n    if (key === 'caching') return `Reads at ${usd(model.pricing && model.pricing.cacheRead)}`;\n    if (key === 'logprobs') return __jsx('code', null, \"logprobs\");\n    return 'Tuned for software work';\n  };\n\n  // Everything an agent needs to call the model, as Markdown.\n  const agentBrief = (family, model, sample, measured) => {\n    const t = model.text || {};\n    const p = model.pricing || {};\n    const r = t.reasoning;\n    const endpoint = (model.endpoints || []).find(e => e.recommended) || (model.endpoints || [])[0];\n    const supports = TEXT_CAPS.filter(c => c.key !== 'effort' && hasCap(model, c.key)).map(c => c.label.toLowerCase());\n    return [\n      `# ${family.name} on the Venice API`,\n      '',\n      `- Model ID: \\`${model.id}\\``,\n      endpoint ? `- Endpoint: \\`${endpoint.method} ${API}${endpoint.path}\\`, OpenAI-compatible with base URL ${API}` : null,\n      '- Auth: `Authorization: Bearer $VENICE_API_KEY`, with a key from https://venice.ai/settings/api',\n      p.input != null ? `- Price per 1M tokens: ${usd(p.input)} input, ${usd(p.output)} output${p.cacheRead != null ? `, ${usd(p.cacheRead)} cached input` : ''}` : null,\n      t.context ? `- Context: ${count(t.context)} tokens${t.maxOutput ? `, up to ${count(t.maxOutput)} out` : ''}` : null,\n      r && r.effort && r.effort.length ? `- Reasoning: \\`reasoning_effort\\` ${r.effort.join(' | ')}${r.defaultEffort ? `, default ${r.defaultEffort}` : ''}` : null,\n      supports.length ? `- Supports: ${listText(supports)}` : null,\n      PRIVACY[model.privacy] ? `- Privacy: ${PRIVACY[model.privacy].label}. ${PRIVACY[model.privacy].desc}` : null,\n      model.privacy === 'e2ee' ? '- The request below sends the prompt as plaintext, so it runs TEE-only. For end-to-end encryption, send encrypted messages with the E2EE headers: https://docs.venice.ai/guides/features/tee-e2ee-models#e2ee-models' : null,\n      measured,\n      ...benchmarkSummaries(model).map(([name, text]) => `- ${name}: ${text}. How it's run: https://docs.venice.ai/models/methodology#benchmarks`),\n      `- Docs: https://docs.venice.ai/models/${family.slug}`,\n      '',\n      '```bash',\n      sample,\n      '```'\n    ].filter(line => line != null).join('\\n');\n  };\n\n  const CodePanel = ({ model, endpoint, setEndpointId, endpoints = (model.endpoints || []).filter(e => e.supported !== false), options }) => {\n    const [lang, setLang] = useState('curl');\n    const samples = codeSamples(model, endpoint && endpoint.id, options);\n    const langs = [['curl', 'cURL'], ['python', 'Python'], ['typescript', 'TypeScript']];\n    return (\n      __jsx('div', { className: \"vxn-code\",}\n        , __jsx('div', { className: \"vxn-code-head\",}\n          , __jsx('div', { className: \"vxn-tabs\", role: \"tablist\", 'aria-label': \"Language\",}\n            , langs.map(([key, label]) => (\n              __jsx('button', { key: key, type: \"button\", role: \"tab\", 'aria-selected': lang === key, className: cls('vxn-tab', lang === key && 'is-active'), onClick: () => setLang(key),}, label)\n            ))\n          )\n          , endpoints.length > 1 ? (\n            __jsx('div', { className: \"vxn-switch\", role: \"radiogroup\", 'aria-label': \"Endpoint\",}\n              , endpoints.map(e => (\n                __jsx('button', { key: e.id, type: \"button\", role: \"radio\", 'aria-checked': endpoint && e.id === endpoint.id, className: cls(endpoint && e.id === endpoint.id && 'is-active'), onClick: () => setEndpointId(e.id),}, e.name)\n              ))\n            )\n          ) : null\n        )\n        , __jsx('pre', { className: \"vxn-code-body\",}, __jsx('code', null, samples[lang]))\n        , __jsx('div', { className: \"vxn-code-foot\",}\n          , __jsx('span', null, __jsx('span', { className: \"vx-muted\",}, \"Base URL\" ), \" \" , __jsx('code', null, API))\n          , __jsx(CopyButton, { text: samples[lang], label: \"Copy\", small: true,} )\n        )\n      )\n    );\n  };\n\n  // One place for everything an agent can take from the page.\n  const AgentMenu = ({ brief, slug }) => {\n    const [open, setOpen] = useState(false);\n    const [done, setDone] = useState(false);\n    const ref = useRef(null);\n    useEffect(() => {\n      if (!open) return undefined;\n      const close = e => { if (ref.current && !ref.current.contains(e.target)) setOpen(false); };\n      const key = e => { if (e.key === 'Escape') setOpen(false); };\n      document.addEventListener('pointerdown', close);\n      document.addEventListener('keydown', key);\n      return () => { document.removeEventListener('pointerdown', close); document.removeEventListener('keydown', key); };\n    }, [open]);\n    const copy = () => copyText(brief).then(() => { setDone(true); setTimeout(() => setDone(false), 1600); });\n    const ask = encodeURIComponent(`Read https://docs.venice.ai/models/${slug}.md and help me call this model through the Venice API.`);\n    return (\n      __jsx('div', { className: \"vxn-menu\", ref: ref,}\n        , __jsx('button', { type: \"button\", className: \"vxn-menu-main\", onClick: copy,}, __jsx(Icon, { name: done ? 'check' : 'copy', size: 14,} ), __jsx('span', { 'aria-live': \"polite\",}, done ? 'Copied' : 'Copy for agent'))\n        , __jsx('button', { type: \"button\", className: \"vxn-menu-toggle\", 'aria-label': \"More for agents\"  , 'aria-expanded': open, 'aria-haspopup': \"menu\", onClick: () => setOpen(!open),}, __jsx(Icon, { name: \"chevronDown\", size: 14,} ))\n        , open ? (\n          __jsx('div', { className: \"vxn-menu-list\", role: \"menu\",}\n            , __jsx('button', { type: \"button\", role: \"menuitem\", onClick: () => { copy(); setOpen(false); },}, __jsx(Icon, { name: \"copy\", size: 15,} ), __jsx('span', null, __jsx('strong', null, \"Copy for agent\"  ), __jsx('span', null, \"ID, endpoint, limits and a request, as Markdown\"       )))\n            , __jsx('a', { role: \"menuitem\", href: `/models/${slug}.md`,}, __jsx(Icon, { name: \"book\", size: 15,} ), __jsx('span', null, __jsx('strong', null, \"View as Markdown\"  ), __jsx('span', null, \"This page as plain text\"    )))\n            , __jsx('a', { role: \"menuitem\", href: `https://chatgpt.com/?q=${ask}`, target: \"_blank\", rel: \"noopener noreferrer\" ,}, __jsx(Icon, { name: \"external\", size: 15,} ), __jsx('span', null, __jsx('strong', null, \"Open in ChatGPT\"  ), __jsx('span', null, \"Ask questions about this model\"    )))\n            , __jsx('a', { role: \"menuitem\", href: `https://claude.ai/new?q=${ask}`, target: \"_blank\", rel: \"noopener noreferrer\" ,}, __jsx(Icon, { name: \"external\", size: 15,} ), __jsx('span', null, __jsx('strong', null, \"Open in Claude\"  ), __jsx('span', null, \"Ask questions about this model\"    )))\n          )\n        ) : null\n      )\n    );\n  };\n\n  // Where the model falls among every text model on price and limits, each\n  // drawn so that further right is better.\n  const STANDING = [\n    { key: 'price', label: 'Blended price', better: 'cheaper', lowerIsBetter: true, format: v => `$${v.toFixed(v >= 0.1 ? 2 : 3)}`, tip: 'Per 1M tokens, at three input tokens for each output token.' },\n    { key: 'context', label: 'Context window', better: 'larger', lowerIsBetter: false, format: v => tokens(v) },\n    { key: 'maxOutput', label: 'Max output', better: 'larger', lowerIsBetter: false, format: v => tokens(v) }\n  ];\n  const standingValues = model => {\n    const p = model.pricing || {};\n    const t = model.text || {};\n    return {\n      price: p.input != null && p.output != null ? (3 * p.input + p.output) / 4 : null,\n      context: t.context,\n      maxOutput: t.maxOutput\n    };\n  };\n  const Standing = ({ model, catalog, task = 'chat', noun = 'text models', metrics = STANDING, valuesOf = standingValues }) => {\n    const others = useMemo(() => (catalog ? catalog.families\n      .filter(f => f.task === task && !f.deprecated && f.primary !== model.id)\n      .map(f => ({ slug: f.slug, name: f.name, values: valuesOf(catalog.models[f.primary] || {}) })) : []), [catalog, model.id]);\n    const mine = valuesOf(model);\n    const rows = metrics.filter(m => mine[m.key] != null);\n    const hash = text => [...text].reduce((h, c) => (h * 31 + c.charCodeAt(0)) >>> 0, 7);\n    return (\n      __jsx('div', { className: \"vxn-standing\",}\n        , __jsx('div', { className: \"vxn-standing-head\",}\n          , __jsx('span', { className: \"vxn-price-label\",}, \"How it compares\"  )\n          , __jsx('span', { className: \"vx-muted\",}, catalog ? `among ${others.length + 1} ${noun}` : `among ${noun}`)\n        )\n        , rows.map(metric => {\n          const values = others.map(o => o.values[metric.key]).filter(v => v != null && v > 0);\n          const all = values.concat([mine[metric.key]]);\n          const lo = Math.log(Math.min(...all));\n          const hi = Math.log(Math.max(...all));\n          const at = v => {\n            const x = hi > lo ? (Math.log(v) - lo) / (hi - lo) : 0.5;\n            return (metric.lowerIsBetter ? 1 - x : x) * 100;\n          };\n          const worse = values.filter(v => (metric.lowerIsBetter ? v > mine[metric.key] : v < mine[metric.key])).length;\n          return (\n            __jsx('div', { key: metric.key, className: \"vxn-standing-row\",}\n              , __jsx('div', { className: \"vxn-standing-line\",}\n                , __jsx('span', { className: \"vxn-standing-name\",}, metric.label, metric.tip ? __jsx(InfoTip, { text: metric.tip, size: 11,} ) : null)\n                , values.length ? __jsx('span', { className: \"vx-muted\",}, metric.better, \" than \"  , Math.round((worse / values.length) * 100), \"%\") : null\n                , __jsx('span', { className: \"vxn-standing-value\",}, metric.format(mine[metric.key]))\n              )\n              , __jsx('div', { className: \"vxn-strip\",}\n                , others.filter(o => o.values[metric.key] != null && o.values[metric.key] > 0).map(o => (\n                  __jsx('a', { key: o.slug, className: \"vxn-strip-dot\", href: `/models/${o.slug}`, title: `${o.name}: ${metric.format(o.values[metric.key])}`,\n                    style: { left: `${at(o.values[metric.key])}%`, top: `${6 + (hash(o.slug + metric.key) % 3) * 5}px` },} )\n                ))\n                , __jsx('span', { className: \"vxn-strip-mine\", style: { left: `${at(mine[metric.key])}%` },} )\n              )\n            )\n          );\n        })\n        , __jsx('p', { className: \"vxn-caption\",}, \"Further right is better. Hover a dot for its model.\"         )\n      )\n    );\n  };\n\n  const Figure = ({ value, label, tip }) => (\n    __jsx('div', { className: \"vxn-fig\",}\n      , __jsx('div', { className: \"vxn-fig-value\",}, value)\n      , __jsx('div', { className: \"vxn-fig-label\",}, label, tip ? __jsx(InfoTip, { text: tip, size: 11,} ) : null)\n    )\n  );\n\n  const CapTile = ({ cap, model }) => {\n    const href = CAP_GUIDES[cap.key];\n    const body = (\n      __jsx(__Fragment, null\n        , __jsx('span', { className: \"vxn-tile-icon\",}, __jsx(Icon, { name: cap.icon, size: 16,} ))\n        , __jsx('span', { className: \"vxn-tile-text\",}\n          , __jsx('span', { className: \"vxn-tile-name\",}, cap.label === 'Image input' ? 'Vision' : cap.label)\n          , __jsx('span', { className: \"vxn-tile-detail\",}, capDetail(model, cap.key))\n        )\n      )\n    );\n    return href ? __jsx('a', { className: \"vxn-tile\", href: href,}, body) : __jsx('div', { className: \"vxn-tile\",}, body);\n  };\n\n  const IO_ICONS = { Text: 'text', Image: 'image', Video: 'video', Audio: 'mic' };\n  const IoFlow = ({ inputs, outputs }) => (\n    __jsx('div', { className: \"vxn-io\", 'aria-label': `Takes ${listText(inputs)}, returns ${listText(outputs)}`,}\n      , __jsx('div', { className: \"vxn-io-group\",}\n        , __jsx('span', { className: \"vxn-io-label\",}, \"In\")\n        , inputs.map(name => __jsx('span', { key: name, className: \"vxn-io-chip\",}, __jsx(Icon, { name: IO_ICONS[name], size: 14,} ), name))\n      )\n      , __jsx(Icon, { name: \"arrowRight\", size: 16,} )\n      , __jsx('div', { className: \"vxn-io-group\",}\n        , __jsx('span', { className: \"vxn-io-label\",}, \"Out\")\n        , outputs.map(name => __jsx('span', { key: name, className: \"vxn-io-chip\",}, __jsx(Icon, { name: IO_ICONS[name], size: 14,} ), name))\n      )\n    )\n  );\n\n  const Estimator = ({ pricing }) => {\n    const [inTok, setIn] = useState(2000);\n    const [outTok, setOut] = useState(500);\n    const [requests, setRequests] = useState(10000);\n    const per = ((inTok * (pricing.input || 0)) + (outTok * (pricing.output || 0))) / 1e6;\n    const field = (label, value, set, step) => (\n      __jsx('label', { className: \"vxn-field\",}\n        , __jsx('span', null, label)\n        , __jsx('input', { type: \"number\", min: \"0\", step: step, value: value, onChange: e => set(Math.max(0, Number(e.target.value) || 0)),} )\n      )\n    );\n    return (\n      __jsx('div', { className: \"vxn-est\",}\n        , __jsx('div', { className: \"vxn-est-fields\",}\n          , field('Input tokens', inTok, setIn, 100)\n          , field('Output tokens', outTok, setOut, 100)\n          , field('Requests', requests, setRequests, 1000)\n        )\n        , __jsx('div', { className: \"vxn-est-result\",}\n          , __jsx('div', null, __jsx('span', { className: \"vxn-est-value\",}, usd(per)), __jsx('span', { className: \"vx-muted\",}, \"per request\" ))\n          , __jsx('div', null, __jsx('span', { className: \"vxn-est-value is-total\" ,}, usd(per * requests)), __jsx('span', { className: \"vx-muted\",}, \"for \" , count(requests), \" requests\" ))\n        )\n      )\n    );\n  };\n\n  const Bars = ({ rows, format, caption }) => {\n    const max = Math.max(...rows.map(r => r.value || 0)) || 1;\n    return (\n      __jsx('div', { className: \"vxn-bars\",}\n        , rows.map(row => (\n          __jsx('div', { key: row.key, className: cls('vxn-bar-row', row.current && 'is-current'),}\n            , row.href && !row.current ? __jsx('a', { className: \"vxn-bar-name\", href: row.href,}, row.name) : __jsx('span', { className: \"vxn-bar-name\",}, row.name)\n            , __jsx('span', { className: \"vxn-bar-track\",}, __jsx('span', { className: \"vxn-bar-fill\", style: { width: `${Math.max(2, (row.value / max) * 100)}%` },} ))\n            , __jsx('span', { className: \"vxn-bar-value\",}, format(row.value))\n          )\n        ))\n        , caption ? __jsx('p', { className: \"vxn-caption\",}, caption) : null\n      )\n    );\n  };\n\n  const ParamTable = ({ model }) => {\n    const t = model.text || {};\n    const caps = t.caps || {};\n    const r = t.reasoning;\n    const inputs = ['text', caps.vision && 'image_url', caps.videoInput && 'video_url', caps.audioInput && 'input_audio'].filter(Boolean);\n    const rows = [\n      ['model', __jsx('code', null, model.id), 'Required'],\n      ['messages', __jsx(__Fragment, null, inputs.map((part, i) => __jsx('span', { key: part,}, i ? ' · ' : '', __jsx('code', null, part)))), 'Content parts the model reads'],\n      ['max_completion_tokens', t.maxOutput ? `Up to ${count(t.maxOutput)}` : 'Integer', r ? 'Counts reasoning tokens' : null],\n      r && r.effort && r.effort.length ? ['reasoning_effort', __jsx('code', null, r.effort.join(' | ')), r.defaultEffort ? `Default ${r.defaultEffort}` : null] : null,\n      caps.tools ? ['tools', 'Function definitions', __jsx(__Fragment, null, \"With \" , __jsx('code', null, \"tool_choice\"))] : null,\n      caps.structured ? ['response_format', __jsx('code', null, '{ type: \"json_schema\" }'), 'Output that matches a schema'] : null,\n      ['stream', __jsx('code', null, \"true | false\"  ), 'Server-sent events'],\n      caps.webSearch ? ['venice_parameters.enable_web_search', __jsx('code', null, \"auto | on | off\"    ), 'Web results and citations'] : null,\n      caps.xSearch ? ['venice_parameters.enable_x_search', __jsx('code', null, \"true | false\"  ), 'Posts from X'] : null,\n      caps.logprobs ? ['logprobs', __jsx('code', null, \"true | false\"  ), __jsx(__Fragment, null, \"With \" , __jsx('code', null, \"top_logprobs\"))] : null\n    ].filter(Boolean);\n    return __jsx(ParamRows, { rows: rows,} );\n  };\n\n  const ParamRows = ({ rows }) => (\n    __jsx('div', { className: \"vx-table-wrap vxn-params\" ,}\n      , __jsx('table', { className: \"vx-dtable\",}\n        , __jsx('thead', null, __jsx('tr', null, __jsx('th', null, \"Parameter\"), __jsx('th', null, \"Values\"), __jsx('th', { className: \"vx-hide-sm\",}, \"Notes\")))\n        , __jsx('tbody', null, rows.map(([name, values, note]) => __jsx('tr', { key: name,}, __jsx('td', null, __jsx('code', null, name)), __jsx('td', null, values), __jsx('td', { className: \"vx-muted vx-hide-sm\" ,}, note))))\n      )\n    )\n  );\n\n  // The section bar sticks below Mintlify's fixed header, whose height\n  // changes with the viewport.\n  const useHeaderHeight = () => {\n    const [height, setHeight] = useState(0);\n    useEffect(() => {\n      const header = document.getElementById('navbar');\n      if (!header) return undefined;\n      const update = () => setHeight(Math.round(header.getBoundingClientRect().height));\n      update();\n      window.addEventListener('resize', update);\n      return () => window.removeEventListener('resize', update);\n    }, []);\n    return height;\n  };\n\n  const NextTop = ({ scope, scopeHref, family, brief }) => (\n    __jsx('div', { className: \"vxn-top\",}\n      , __jsx('nav', { className: \"vxn-crumbs\", 'aria-label': \"Breadcrumb\",}\n        , __jsx('a', { href: \"/models/overview\",}, \"Models\")\n        , __jsx(Icon, { name: \"chevronRight\", size: 12,} )\n        , __jsx('a', { href: scopeHref,}, scope)\n        , __jsx(Icon, { name: \"chevronRight\", size: 12,} )\n        , __jsx('span', { 'aria-current': \"page\",}, family.name)\n      )\n      , __jsx(AgentMenu, { brief: brief, slug: family.slug,} )\n    )\n  );\n\n  // The model's name leads the nav, so it stays on screen once the nav sticks.\n  const NextNav = ({ title, sections, active }) => (\n    __jsx('nav', { className: \"vxn-nav\", 'aria-label': \"On this page\"  ,}\n      , __jsx('span', { className: \"vxn-nav-title\", 'aria-hidden': \"true\",}, title)\n      , sections.map(([id, label]) => (\n        __jsx('a', { key: id, href: `#${id}`, className: cls(active === id && 'is-active'),}, label)\n      ))\n    )\n  );\n\n  const VersionTimeline = ({ family, versions, created }) => (\n    __jsx('div', { className: \"vxn-timeline\",}\n      , __jsx('h3', { className: \"vxn-h3\",}, \"Other versions\" )\n      , __jsx('ol', null\n        , versions.concat([{ slug: family.slug, name: family.name, created, current: true }]).sort((a, b) => (a.created || 0) - (b.created || 0)).slice(-6).map(item => (\n          __jsx('li', { key: item.slug, className: cls(item.current && 'is-current'),}\n            , __jsx('span', { className: \"vxn-timeline-dot\",} )\n            , item.current ? __jsx('strong', null, item.name) : __jsx('a', { href: `/models/${item.slug}`,}, item.name)\n            , __jsx('span', { className: \"vx-muted\",}, shortDate(item.created))\n          )\n        ))\n      )\n    )\n  );\n\n  const NextSection = ({ id, title, lead, children }) => (\n    __jsx('section', { id: id, className: \"vxn-section\", 'aria-labelledby': `${id}-title`,}\n      , __jsx('div', { className: \"vxn-section-head\",}\n        , __jsx('h2', { id: `${id}-title`, className: \"vxn-h2\",}, title)\n        , lead ? __jsx('p', { className: \"vxn-lead\",}, lead) : null\n      )\n      , __jsx('div', { className: \"vxn-section-body\",}, children)\n    )\n  );\n\n  // Older figures read as unavailable rather than as the last 24 hours.\n  const PERFORMANCE_MAX_AGE = 6 * 3600 * 1000;\n  const DAY_MINUTES = 1440;\n  const freshPerformance = (data, now) => (data && data.window && Date.parse(data.window.end) > now - PERFORMANCE_MAX_AGE ? data : null);\n\n  // The period under the pointer: hovering with a mouse, or pressing and\n  // dragging on a touch screen. Lifting or leaving clears it.\n  const scrub = (count, set) => {\n    const at = e => {\n      const r = e.currentTarget.getBoundingClientRect();\n      set(Math.max(0, Math.min(count - 1, Math.floor(((e.clientX - r.left) / r.width) * count))));\n    };\n    const clear = () => set(null);\n    return { onPointerDown: at, onPointerMove: at, onPointerLeave: clear, onPointerCancel: clear };\n  };\n\n  // Each period flat across its own span, easing into the next, so a quiet\n  // model reads as steady steps and a busy one as a line. A period without\n  // requests breaks the line.\n  const periodRuns = values => values.reduce((runs, v, k) => {\n    if (v == null) return runs;\n    const run = runs[runs.length - 1];\n    if (run && run.end === k) {\n      run.values.push(v);\n      run.end = k + 1;\n    } else runs.push({ start: k, end: k + 1, values: [v] });\n    return runs;\n  }, []);\n  const periodPath = (run, minutes, y) => {\n    const ease = Math.min(minutes / 4, 30);\n    return run.values.reduce((d, v, i) => {\n      if (i === run.values.length - 1) return `${d}H${run.end * minutes}`;\n      const edge = (run.start + i + 1) * minutes;\n      return `${d}H${edge - ease}C${edge},${y(v)} ${edge},${y(run.values[i + 1])} ${edge + ease},${y(run.values[i + 1])}`;\n    }, `M${run.start * minutes},${y(run.values[0])}`);\n  };\n\n  // The median period sits halfway up, and one more than twice the median is\n  // drawn at the top.\n  const medianScale = values => {\n    const sorted = [...values].sort((a, b) => a - b);\n    const top = 2 * sorted[Math.floor((sorted.length - 1) / 2)] || 1;\n    return v => 100 - (Math.min(v, top) / top) * 100;\n  };\n\n  const PeriodLine = ({ chart, at, scale }) => {\n    const known = chart ? chart.values.filter(v => v != null) : [];\n    const y = known.length ? scale(known) : null;\n    const runs = y ? periodRuns(chart.values) : [];\n    const x = at != null && chart.values[at] != null ? `${(((at + 0.5) * chart.minutes) / DAY_MINUTES) * 100}%` : null;\n    return (\n      __jsx(__Fragment, null\n        , __jsx('svg', { className: \"vxn-perf-svg\", viewBox: `0 0 ${DAY_MINUTES} 100`, preserveAspectRatio: \"none\", 'aria-hidden': \"true\",}\n          , runs.map(run => {\n            const d = periodPath(run, chart.minutes, y);\n            return [\n              __jsx('path', { key: `f${run.start}`, className: \"vxn-perf-fill\", d: `${d}V100H${run.start * chart.minutes}Z`,} ),\n              __jsx('path', { key: `l${run.start}`, className: \"vxn-perf-line\", d: d, vectorEffect: \"non-scaling-stroke\",} )\n            ];\n          })\n        )\n        , x ? __jsx('span', { className: \"vxn-perf-guide\", style: { left: x },} ) : null\n        , x ? __jsx('span', { className: \"vxn-perf-dot\", style: { left: x, top: `${y(chart.values[at])}%` },} ) : null\n      )\n    );\n  };\n\n  // Uptime sits near 100%, where a line hides how often it dipped, so each\n  // quarter hour of the day gets two thin bars in the status the metrics job\n  // gives it: up, degraded (under 95%), down (under 80%), or grey without\n  // requests. A model without figures is grey throughout.\n  const QUARTERS = DAY_MINUTES / 15;\n  const QUARTER_STATUS = { u: ['is-up', 'up'], d: ['is-dip', 'degraded'], x: ['is-low', 'down'], '-': ['is-none', 'no requests'] };\n  const quarterStatuses = text => (typeof text === 'string' && text.length === QUARTERS && [...text].every(c => QUARTER_STATUS[c]) ? text : null);\n  const quarterSummary = statuses => {\n    const count = c => statuses.split(c).length - 1;\n    const parts = [['d', 'degraded'], ['x', 'down'], ['-', 'without requests']].filter(([c]) => count(c)).map(([c, word]) => `${word} for ${count(c)}`);\n    return parts.length ? `, ${listText(parts)} of ${QUARTERS} quarter hours` : ', up every quarter hour';\n  };\n  // On a quiet model whose quarter hours without requests are scattered,\n  // they shrink to a thin line, so its active stretches read as bursts.\n  const QuarterStrip = ({ statuses, at, sparse }) => (\n    __jsx('svg', { className: cls('vxn-perf-strip', at != null && 'is-scrubbing'), viewBox: `0 0 ${QUARTERS * 6} 1`, preserveAspectRatio: \"none\", 'aria-hidden': \"true\",}\n      , Array.from({ length: QUARTERS * 2 }, (_, k) => {\n        const state = statuses ? statuses[Math.floor(k / 2)] : '-';\n        const thin = sparse && state === '-';\n        return __jsx('rect', { key: k, x: k * 3, y: thin ? 0.45 : 0, width: \"2\", height: thin ? 0.1 : 1, className: cls(QUARTER_STATUS[state][0], k === at && 'is-at'),} );\n      })\n    )\n  );\n\n  // What a card without a figure says: the job publishes none for a model\n  // with too little traffic, and stale or unloadable figures say nothing.\n  const PERF_MISSING = { fresh: 'not enough traffic', unavailable: 'unavailable' };\n\n  const PERF_METRICS = [\n    { key: 'ttftMs', name: 'Time to first token', format: fmtMs, better: 'quicker', lowerIsBetter: true, day: f => (f.ttftMs && f.ttftMs['24h'] ? f.ttftMs['24h'].p50 : null), scale: medianScale },\n    { key: 'tokensPerSecond', name: 'Output speed', format: fmtSpeed, better: 'faster', lowerIsBetter: false, day: f => (f.tokensPerSecond ? f.tokensPerSecond['24h'] : null), scale: medianScale },\n    { key: 'uptime', name: 'Uptime', format: fmtUptime, day: f => f.uptime, strip: f => f.uptimeStatus }\n  ];\n\n  // Quarter hours as a duration: \"45m\", \"3h\", \"3h 30m\".\n  const quarterTime = n => (n < 4 ? `${n * 15}m` : `${Math.floor(n / 4)}h${n % 4 ? ` ${(n % 4) * 15}m` : ''}`);\n\n  // What a figure means, on the line under it: where the model ranks among\n  // the other text models, or for uptime how long it was down or degraded.\n  const figureNote = (metric, day, peers, statuses) => {\n    if (metric.strip) {\n      if (!statuses || !/[udx]/.test(statuses)) return null;\n      const parts = [['x', 'down'], ['d', 'degraded']].filter(([c]) => statuses.includes(c)).map(([c, word]) => `${word} ${quarterTime(statuses.split(c).length - 1)}`);\n      return parts.length ? parts.join(' \\u00b7 ') : 'no outages';\n    }\n    const values = peers.map(p => p.values[metric.key]).filter(v => v != null && v > 0);\n    if (!values.length) return null;\n    const worse = values.filter(v => (metric.lowerIsBetter ? v > day : v < day)).length;\n    return `${metric.better} than ${Math.round((worse / values.length) * 100)}% of models`;\n  };\n\n  // A line needs hourly or finer periods to say more than its daily figure,\n  // so a quieter card places its figure among the other text models' instead,\n  // as the comparison card places price and limits: further right is better.\n  const readableStrip = statuses => statuses.split('-').length - 1 <= QUARTERS / 8 || /^-*[^-]*$/.test(statuses);\n  const RankStrip = ({ metric, day, peers }) => {\n    const ranked = peers.filter(p => p.values[metric.key] != null && p.values[metric.key] > 0);\n    const all = ranked.map(p => p.values[metric.key]).concat([day]);\n    const lo = Math.log(Math.min(...all));\n    const hi = Math.log(Math.max(...all));\n    const at = v => {\n      const x = hi > lo ? (Math.log(v) - lo) / (hi - lo) : 0.5;\n      return (metric.lowerIsBetter ? 1 - x : x) * 100;\n    };\n    const hash = text => [...text].reduce((h, c) => (h * 31 + c.charCodeAt(0)) >>> 0, 7);\n    return (\n      __jsx('div', { className: \"vxn-strip\", 'aria-hidden': \"true\",}\n        , ranked.map(p => (\n          __jsx('a', { key: p.slug, className: \"vxn-strip-dot\", href: `/models/${p.slug}`, tabIndex: -1, title: `${p.name}: ${metric.format(p.values[metric.key])}`,\n            style: { left: `${at(p.values[metric.key])}%`, top: `${6 + (hash(p.slug + metric.key) % 3) * 5}px` },} )\n        ))\n        , __jsx('span', { className: \"vxn-strip-mine\", style: { left: `${at(day)}%` },} )\n      )\n    );\n  };\n\n  // A formatted figure as its number and its unit, so the unit can be set\n  // smaller: \"798 ms\", \"214 tok/s\", \"99.7%\". A dash has no unit.\n  const figureParts = text => {\n    const m = /^(.+?) ?(ms|s|tok\\/s|%)$/.exec(text);\n    return m ? [m[1], m[2]] : [text, null];\n  };\n\n  // The title stays put. While scrubbing, the number gives the hovered\n  // period's figure and the line under it that period's time, so the card\n  // needs no legend. Without periods, the day is a single period. Uptime\n  // scrubs bar by bar: a quarter hour gives its uptime, or its status where\n  // the performance file has none for it.\n  const PerfCard = ({ metric, figures, peers, status, start }) => {\n    const [hovered, setHovered] = useState(null);\n    const day = figures ? metric.day(figures) : null;\n    const statuses = metric.strip && figures ? quarterStatuses(metric.strip(figures)) : null;\n    const periods = figures && figures.periods ? figures.periods[metric.key] : null;\n    const chart = metric.strip ? null : periods || (day != null ? { minutes: DAY_MINUTES, values: [day] } : null);\n    const charted = !figures || metric.strip || (chart != null && chart.minutes <= 60);\n    const count = !charted ? 0 : statuses ? QUARTERS * 2 : chart ? chart.values.length : 0;\n    const at = hovered != null && hovered < count ? hovered : null;\n    const quarter = statuses && at != null ? Math.floor(at / 2) : null;\n    const state = quarter != null ? statuses[quarter] : null;\n    const percent = quarter != null && figures.uptimeQuarters ? figures.uptimeQuarters[quarter] : null;\n    const word = state && state !== '-' && percent == null ? QUARTER_STATUS[state][1] : null;\n    const figure = at == null ? null : statuses ? percent : chart.values[at];\n    const span = (k, minutes) => (minutes === DAY_MINUTES ? 'last 24 hours'\n      : `${fmtTime(start + k * minutes * 60000)} \\u2013 ${fmtTime(start + (k + 1) * minutes * 60000)}`);\n    const note = at == null ? (day == null ? PERF_MISSING[status] || null : figureNote(metric, day, peers, statuses))\n      : statuses ? `${span(quarter, 15)}${percent != null ? ` \\u00b7 ${QUARTER_STATUS[state][1]}` : state === '-' ? ' \\u00b7 no requests' : ''}`\n        : `${span(at, chart.minutes)}${figure == null ? ' \\u00b7 no requests' : ''}`;\n    const known = chart ? chart.values.filter(v => v != null) : [];\n    const range = statuses ? quarterSummary(statuses) : known.length > 1 ? `, ranging from ${metric.format(Math.min(...known))} to ${metric.format(Math.max(...known))}` : '';\n    const scrubbing = count ? { ...scrub(count, setHovered), role: 'img', 'aria-label': `${metric.name} over the last 24 hours: ${day != null ? metric.format(day) : PERF_MISSING.fresh}${range}` } : {};\n    const [number, unit] = figureParts(word ? upperFirst(word) : figure != null ? metric.format(figure) : state === '-' ? '\\u2014' : metric.format(day));\n    return (\n      __jsx('div', { className: \"vxn-perf\",}\n        , __jsx('span', { className: \"vxn-perf-label\",}, metric.name)\n        , __jsx('span', { className: \"vxn-perf-value\",}, number, unit ? __jsx('span', { className: cls('vxn-perf-unit', unit === '%' && 'is-tight'),}, unit) : null)\n        , __jsx('span', { className: \"vxn-perf-note\",}, note || '\\u00a0')\n        , __jsx('div', { className: cls('vxn-perf-chart', !charted ? 'is-rank' : metric.strip && 'is-strip'), ...scrubbing,}\n          , !charted ? __jsx(RankStrip, { metric: metric, day: day, peers: peers,} )\n            : metric.strip ? __jsx(QuarterStrip, { statuses: statuses, at: at, sparse: statuses != null && !readableStrip(statuses),} ) : __jsx(PeriodLine, { chart: chart, at: at, scale: metric.scale,} )\n        )\n      )\n    );\n  };\n\n  // The first screen, a failed load, stale figures and a model without any\n  // all draw the same frame, so figures arriving don't move the page.\n  const PerformanceCards = ({ model, catalog, fresh, status, now }) => {\n    const figures = fresh && fresh.models ? fresh.models[model.id] || null : null;\n    const shown = status === 'loading' ? PERF_METRICS : figures ? PERF_METRICS.filter(m => m.day(figures) != null) : [];\n    const peers = useMemo(() => (catalog && fresh ? catalog.families\n      .filter(f => f.task === 'chat' && !f.deprecated && f.primary !== model.id)\n      .map(f => ({ slug: f.slug, name: f.name, values: dayFigures(fresh, f.primary) })) : []), [catalog, fresh, model.id]);\n    const start = fresh ? Date.parse(fresh.window.start) : 0;\n    const updated = fresh && fresh.generatedAt ? now - Date.parse(fresh.generatedAt) : null;\n    if (!shown.length) return null;\n    return (\n      __jsx(__Fragment, null\n        , __jsx('div', { className: cls('vxn-perfs', shown.length < 3 && `is-${shown.length}`),}\n          , shown.map(metric => __jsx(PerfCard, { key: metric.key, metric: metric, figures: figures, peers: peers, status: status, start: start,} ))\n        )\n        , __jsx('p', { className: \"vxn-caption\",}, __jsx('span', null, `Last 24 hours of Venice traffic${updated != null ? `, updated ${fmtAgo(updated)}` : ''}.`), __jsx('a', { href: \"/models/methodology#performance\",}, \"How it's measured\"  ))\n      )\n    );\n  };\n\n  // A model's figure for each Performance card, keyed like the cards.\n  const dayFigures = (fresh, id) => {\n    const f = fresh && fresh.models ? fresh.models[id] : null;\n    return Object.fromEntries(PERF_METRICS.map(m => [m.key, f ? m.day(f) : null]));\n  };\n\n  // The brief's performance line carries its date, since a brief is read\n  // long after it's copied.\n  const measuredLine = (fresh, id) => {\n    const f = fresh && fresh.models ? fresh.models[id] : null;\n    if (!f) return null;\n    const day = dayFigures(fresh, id);\n    const p90 = f.ttftMs && f.ttftMs['24h'] ? f.ttftMs['24h'].p90 : null;\n    const parts = [\n      day.ttftMs != null ? `first token ${fmtMs(day.ttftMs)} median${p90 != null ? `, ${fmtMs(p90)} at p90` : ''}` : null,\n      day.tokensPerSecond != null ? `output ${fmtSpeed(day.tokensPerSecond)}` : null,\n      day.uptime != null ? `uptime ${fmtUptime(day.uptime)}` : null\n    ].filter(Boolean);\n    const end = fresh.window.end.slice(0, 16).replace('T', ' ');\n    return parts.length ? `- Measured on Venice traffic in the 24 hours to ${end} UTC: ${parts.join('; ')}. Hourly figures: https://docs.venice.ai/data/model-performance.json` : null;\n  };\n\n  const E2eeSummary = ({ model }) => (model.privacy === 'e2ee' ? (\n    __jsx('ul', { className: \"vxn-e2ee\",}\n      , __jsx('li', null, __jsx(Icon, { name: \"shieldCheck\", size: 16,} ), __jsx('span', null, \"Prompts are decrypted only inside an attested TEE on the GPU.\"          ))\n      , __jsx('li', null, __jsx(Icon, { name: \"terminal\", size: 16,} ), __jsx('span', null, \"Calls need the E2EE handshake. Without it, requests reach Venice as plaintext and run TEE-only. \"               , __jsx('a', { href: \"/guides/features/tee-e2ee-models#e2ee-models\",}, \"How to call an E2EE model\"     )))\n    )\n  ) : null);\n\n  // The same model called the other way: a model's E2EE build, or an E2EE\n  // build's model.\n  const Counterpart = ({ item }) => {\n    if (!item) return null;\n    const e2ee = item.privacy.includes('e2ee');\n    return (\n      __jsx('a', { className: \"vxn-counterpart\", href: `/models/${item.slug}`,}\n        , e2ee ? __jsx(Icon, { name: \"lock\", size: 12,} ) : null\n        , __jsx('span', { className: \"vxn-counterpart-name\",}, e2ee ? 'Also available end-to-end encrypted' : 'Also available without end-to-end encryption')\n        , __jsx('span', { className: \"vxn-counterpart-sub\",}, relatedPrice(item))\n        , __jsx(Icon, { name: \"arrowRight\", size: 12,} )\n      )\n    );\n  };\n\n  /* ------------------------------------------------------------ benchmarks */\n\n  // The benchmarks pages show, in order. One the data adds before the page\n  // knows it stays off the page.\n  const BENCHMARKS = [{ key: 'gpqa-diamond', name: 'GPQA Diamond' }];\n  const fmtAccuracy = v => (v == null ? '—' : `${v.toFixed(1)}%`);\n  const ordinal = n => {\n    const v = n % 100;\n    return `${n}${['th', 'st', 'nd', 'rd'][(v - 20) % 10] || ['th', 'st', 'nd', 'rd'][v] || 'th'}`;\n  };\n\n  // A model's score: its run made the way the API runs it by default, or its\n  // best run until it has one.\n  const headlineRun = (model, key) => {\n    const runs = model && model.benchmarks ? model.benchmarks[key] : null;\n    if (!runs || !runs.length) return null;\n    return runs.find(r => r.reasoning === 'default') || runs.reduce((a, b) => (b.accuracy > a.accuracy ? b : a));\n  };\n  const hasBenchmarks = model => BENCHMARKS.some(b => headlineRun(model, b.key));\n\n  // Each benchmark score with how its run was made, for agents: what the\n  // page leaves out of sight.\n  const benchmarkSummaries = model => BENCHMARKS.map(b => {\n    const run = headlineRun(model, b.key);\n    if (!run) return null;\n    const d = new Date(`${run.measuredOn}T00:00:00Z`);\n    const setting = !(model.text && model.text.reasoning) ? ''\n      : run.reasoning === 'default' ? ' at its default reasoning'\n        : run.reasoning === 'off' ? ' with reasoning off' : ` at reasoning_effort ${run.reasoning}`;\n    return [b.name, `${fmtAccuracy(run.accuracy)} \\u00b1${run.ci95.toFixed(1)} (95% interval), run by Venice through the API${setting} on ${MONTHS[d.getUTCMonth()]} ${d.getUTCDate()}, ${d.getUTCFullYear()}`];\n  }).filter(Boolean);\n\n  // A run is named with its reasoning setting when that isn't how the API\n  // runs the model by default, as Artificial Analysis names configurations.\n  const runName = (name, model, run) => (model.text && model.text.reasoning && run.reasoning !== 'default' ? `${name} (${run.reasoning})` : name);\n\n  // The comparison card on text pages leads with the model's GPQA Diamond\n  // score, named like its run.\n  const textStanding = model => {\n    const run = headlineRun(model, 'gpqa-diamond');\n    return [{ key: 'gpqa', label: run ? runName('GPQA Diamond', model, run) : 'GPQA Diamond', better: 'higher', lowerIsBetter: false, format: fmtAccuracy }, ...STANDING];\n  };\n  const textStandingValues = model => {\n    const run = headlineRun(model, 'gpqa-diamond');\n    return { ...standingValues(model), gpqa: run ? run.accuracy : null };\n  };\n\n  // Every other scored text model by its score, best first, each family\n  // counted once by its default variant.\n  const benchmarkPeers = (catalog, key, family) => (catalog ? catalog.families\n    .filter(f => f.task === 'chat' && !f.deprecated && f.slug !== family.slug)\n    .map(f => ({ family: f, model: catalog.models[f.primary], run: headlineRun(catalog.models[f.primary], key) }))\n    .filter(e => e.run)\n    .sort((a, b) => b.run.accuracy - a.run.accuracy) : []);\n\n  // Score against blended price, as Artificial Analysis plots intelligence\n  // against price: every text model with both, and the corner of models that\n  // score higher for less shaded. Scores start at chance.\n  const SCORE_FLOOR = 25;\n  const NAMED_DEALS = 3;\n  const PriceChart = ({ run, price, name, points, deals }) => {\n    const prices = points.map(e => e.price).concat([price]);\n    const lo = Math.log10(Math.min(...prices)) - 0.15;\n    const hi = Math.log10(Math.max(...prices)) + 0.15;\n    const x = p => ((Math.log10(p) - lo) / (hi - lo)) * 100;\n    const y = v => ((100 - v) / (100 - SCORE_FLOOR)) * 100;\n    const ticks = [];\n    for (let e = Math.ceil(lo); e <= Math.floor(hi); e++) ticks.push(10 ** e);\n    return (\n      __jsx('div', { className: \"vxb-chart\", role: \"img\", 'aria-label': `${name}: ${fmtAccuracy(run.accuracy)} at ${usd(price)} per 1M tokens. ${deals.length} of ${points.length} other text models score higher for less.`,}\n        , __jsx('div', { className: \"vxb-plot\",}\n          , [50, 75, 100].map(v => __jsx('span', { key: v, className: \"vxb-grid\", style: { top: `${y(v)}%` },}, __jsx('span', null, `${v}%`)))\n          , __jsx('span', { className: \"vxb-deals\", style: { width: `${x(price)}%`, height: `${y(run.accuracy)}%` },} )\n          , points.map(e => (\n            __jsx('a', { key: e.family.slug, className: cls('vxb-dot', deals.includes(e) && 'is-deal'), href: `/models/${e.family.slug}`, tabIndex: -1,\n              title: `${runName(e.family.name, e.model, e.run)}: ${fmtAccuracy(e.run.accuracy)} at ${usd(e.price)}`, style: { left: `${x(e.price)}%`, top: `${y(e.run.accuracy)}%` },} )\n          ))\n          , __jsx('span', { className: \"vxb-dot is-current\" , style: { left: `${x(price)}%`, top: `${y(run.accuracy)}%` },}, __jsx('span', { className: cls('vxb-label', x(price) > 60 && 'is-left'),}, name))\n        )\n        , __jsx('div', { className: \"vxb-ticks\", 'aria-hidden': \"true\",}, ticks.map(t => __jsx('span', { key: t, style: { left: `${x(t)}%` },}, `$${t}`)))\n      )\n    );\n  };\n\n  // How many models beat this one on both score and price, naming the best\n  // of them as links.\n  const DealsLine = ({ deals }) => {\n    if (!deals.length) return ' \\u00b7 none scores higher for less';\n    const named = deals.slice(0, NAMED_DEALS);\n    const links = named.flatMap((e, i) => [i ? (i === named.length - 1 ? ' and ' : ', ') : null, __jsx('a', { key: e.family.slug, href: `/models/${e.family.slug}`,}, runName(e.family.name, e.model, e.run))]).filter(Boolean);\n    return deals.length > NAMED_DEALS\n      ? __jsx(__Fragment, null, ` \\u00b7 ${deals.length} score higher for less, including `, links)\n      : __jsx(__Fragment, null, ' \\u00b7 ', links, deals.length === 1 ? ' scores higher for less' : ' score higher for less');\n  };\n\n  const BenchmarkCard = ({ bench, model, family, catalog }) => {\n    const run = headlineRun(model, bench.key);\n    const price = standingValues(model).price;\n    const peers = useMemo(() => benchmarkPeers(catalog, bench.key, family), [catalog, family.slug]);\n    const points = useMemo(() => peers.map(e => ({ ...e, price: standingValues(e.model).price })).filter(e => e.price > 0), [peers]);\n    const deals = price > 0 ? points.filter(e => e.run.accuracy > run.accuracy && e.price < price).sort((a, b) => b.run.accuracy - a.run.accuracy) : [];\n    const rank = 1 + peers.filter(e => e.run.accuracy > run.accuracy).length;\n    return (\n      __jsx('div', { className: \"vxb-card\",}\n        , __jsx('a', { className: \"vxb-title\", href: \"/models/methodology#benchmarks\",}, runName(bench.name, model, run))\n        , __jsx('div', { className: \"vxb-figure\",}\n          , __jsx('span', { className: \"vxb-value\", title: `95% confidence interval: \\u00b1${run.ci95.toFixed(1)} points`,}, fmtAccuracy(run.accuracy))\n          , catalog ? __jsx('span', { className: \"vxb-rank\",}, `${ordinal(rank)} of ${peers.length + 1}`, price > 0 ? __jsx(DealsLine, { deals: deals,} ) : null) : null\n        )\n        , price > 0 ? __jsx(PriceChart, { run: run, price: price, name: runName(family.name, model, run), points: points, deals: deals,} ) : null\n      )\n    );\n  };\n\n  const ModelPageNext = ({ data }) => {\n    const { family, models, related, counterpart, providers } = data;\n    const [variantId, setVariantId] = useState(() => {\n      const v = readParams().get('v');\n      return v && models.some(m => m.id === v) ? v : family.primary;\n    });\n    const [endpointId, setEndpointId] = useState(null);\n    const now = useNow();\n    const { catalog } = useCatalog();\n    // A ?v= link naming a model on another page, such as an E2EE build from\n    // before it had a page of its own, goes to that page.\n    useEffect(() => {\n      const v = readParams().get('v');\n      if (!v || models.some(m => m.id === v)) return;\n      const home = counterpart && counterpart.primary === v ? counterpart.slug : catalog && catalog.models[v] ? catalog.models[v].family : null;\n      if (home && home !== family.slug) window.location.replace(`/models/${home}`);\n    }, [catalog]);\n    const performance = usePerformance();\n    const fresh = freshPerformance(performance.data, now);\n    const performanceStatus = fresh ? 'fresh' : performance.data || performance.failed ? 'unavailable' : 'loading';\n    const model = models.find(m => m.id === variantId) || models[0];\n    const provider = providers[family.provider] || providers[model.provider];\n    const t = model.text || {};\n    const caps = t.caps || {};\n    const p = model.pricing || {};\n    const endpoints = (model.endpoints || []).filter(e => e.supported !== false);\n    const endpoint = endpoints.find(e => e.id === endpointId) || endpoints.find(e => e.recommended) || endpoints[0];\n    const source = safeUrl(model.source);\n    const similar = (related && related.similar) || [];\n    const versions = (related && related.versions) || [];\n    const supported = TEXT_CAPS.filter(c => c.key !== 'effort' && hasCap(model, c.key));\n    const missing = TEXT_CAPS.filter(c => !['effort', 'code'].includes(c.key) && !hasCap(model, c.key));\n    const inputs = ['Text', caps.vision && 'Image', caps.videoInput && 'Video', caps.audioInput && 'Audio'].filter(Boolean);\n    const benchmarked = hasBenchmarks(model);\n    const sections = [['capabilities', 'Capabilities'], benchmarked ? ['benchmarks', 'Benchmarks'] : null, ['specs', 'Specs'], similar.length || versions.length ? ['compare', 'Compare'] : null, ['pricing', 'Pricing'], ['quickstart', 'Quickstart']].filter(Boolean);\n    const activeSection = useScrollSpy(sections.map(([id]) => id));\n    const headerHeight = useHeaderHeight();\n    const selectVariant = id => {\n      setVariantId(id);\n      setEndpointId(null);\n      writeParams({ v: id === family.primary ? null : id });\n    };\n    const blended = item => (item.pricing && item.pricing.input != null ? (3 * item.pricing.input + item.pricing.output) / 4 : null);\n    const limits = id => ((catalog && catalog.models[id] && catalog.models[id].text) || {});\n    const gpqa = m => {\n      const run = headlineRun(m, 'gpqa-diamond');\n      return run ? runName(fmtAccuracy(run.accuracy), m, run) : '—';\n    };\n    const compareRows = [{ key: model.id, name: family.name, current: true, pricing: p, text: t, day: dayFigures(fresh, model.id), gpqa: gpqa(model) }]\n      .concat(similar.map(item => ({ key: item.slug, name: item.name, href: `/models/${item.slug}`, pricing: item.pricing || {}, text: limits(item.primary), day: dayFigures(fresh, item.primary), gpqa: catalog ? gpqa(catalog.models[item.primary]) : '—' })));\n\n    return (\n      __jsx('div', { className: \"vx vxn not-prose\"  , style: { '--vxn-header': `${headerHeight}px` },}\n        , __jsx(HoverTips, null )\n        , __jsx(NextTop, { scope: \"Text\", scopeHref: \"/models/text\", family: family, brief: agentBrief(family, model, codeSamples(model, endpoint && endpoint.id).curl, measuredLine(fresh, model.id)),} )\n\n        , __jsx('header', { className: \"vxn-hero\",}\n          , __jsx('div', { className: \"vxn-hero-main\",}\n            , __jsx('div', { className: \"vxn-provider\",}\n              , __jsx(ProviderLogo, { provider: provider, size: 22,} )\n              , __jsx('span', null, provider ? provider.name : family.provider)\n              , __jsx('span', { className: \"vxn-dot\",} )\n              , __jsx('span', null, fmtDate(model.created))\n              , isNew(model.created, now) ? __jsx(Tag, { tone: \"new\",}, \"New\") : null\n              , model.beta ? __jsx(Tag, { tone: \"beta\",}, \"Beta\") : null\n            )\n            , __jsx('h1', { className: \"vxn-h1\",}, model.privacy === 'e2ee' ? __jsx(__Fragment, null, family.name.replace(/ E2EE$/, ''), \" \" , __jsx('span', { className: \"vxn-h1-tag\", title: PRIVACY.e2ee.desc,}, __jsx(Icon, { name: \"lock\", size: 13,} ), \"E2EE\")) : family.name)\n            , __jsx('div', { className: \"vxn-meta\",}\n              , __jsx('span', { className: \"vxn-meta-id\",}, __jsx('code', null, model.id), __jsx(CopyButton, { text: model.id, iconOnly: true, label: `Copy model ID ${model.id}`,} ))\n              , PRIVACY[model.privacy] && model.privacy !== 'e2ee' ? __jsx('span', { className: \"vxn-meta-item\",}, PRIVACY[model.privacy].label, __jsx(InfoTip, { text: PRIVACY[model.privacy].desc, size: 12,} )) : null\n              , model.openWeights ? (source\n                ? __jsx('a', { className: \"vxn-meta-item\", href: source, target: \"_blank\", rel: \"noopener noreferrer\" ,}, \"Open weights\" , __jsx(Icon, { name: \"external\", size: 12,} ))\n                : __jsx('span', { className: \"vxn-meta-item\",}, \"Open weights\" )) : null\n              , model.uncensored ? __jsx('span', { className: \"vxn-meta-item\",}, \"Uncensored\") : null\n            )\n            , model.description || family.description ? __jsx('p', { className: \"vxn-desc\",}, model.description || family.description) : null\n            , __jsx(E2eeSummary, { model: model,} )\n            , __jsx('div', { className: \"vxn-figs\",}\n              , p.input != null ? __jsx(Figure, { value: __jsx(__Fragment, null, usd(p.input), __jsx('span', { className: \"vxn-sep\",}, \"/\"), usd(p.output)), label: \"per 1M in / out\"    ,} ) : null\n              , t.context ? __jsx(Figure, { value: tokens(t.context), label: \"context window\" ,} ) : null\n              , t.maxOutput ? __jsx(Figure, { value: tokens(t.maxOutput), label: \"max output\" ,} ) : null\n            )\n            , models.length > 1 ? (\n              __jsx('div', { className: \"vxn-variants\",}\n                , __jsx('span', { className: \"vxn-variants-label\",}, \"Variant\")\n                , __jsx('div', { className: \"vxn-switch\", role: \"radiogroup\", 'aria-label': \"Variant\",}\n                  , models.map(m => (\n                    __jsx('button', { key: m.id, type: \"button\", role: \"radio\", 'aria-checked': m.id === model.id, className: cls(m.id === model.id && 'is-active'), onClick: () => selectVariant(m.id),}\n                      , VARIANT_LABELS[m.variant] || m.variant, __jsx('span', { className: \"vx-muted\",}, priceSummary(m).replace(/ per 1M$/, ''))\n                    )\n                  ))\n                )\n              )\n            ) : null\n            , __jsx(Counterpart, { item: counterpart,} )\n            , __jsx('div', { className: \"vxn-ctas\",}\n              , __jsx('a', { className: \"vxn-btn is-primary\" , href: \"https://venice.ai/settings/api\", target: \"_blank\", rel: \"noopener noreferrer\" ,}, \"Get an API key\"   )\n              , model.task === 'chat' ? __jsx('a', { className: \"vxn-textlink\", href: `https://venice.ai/chat?model=${encodeURIComponent(model.id)}`, target: \"_blank\", rel: \"noopener noreferrer\" ,}, \"Try in Venice\"  , __jsx(Icon, { name: \"arrowRight\", size: 14,} )) : null\n            )\n          )\n          , __jsx('div', { className: \"vxn-hero-side\",}\n            , __jsx(Standing, { model: model, catalog: catalog, metrics: textStanding(model), valuesOf: textStandingValues,} )\n          )\n        )\n\n        , __jsx('section', { id: \"performance\", className: \"vxn-band\", 'aria-label': \"Performance\",}\n          , __jsx(PerformanceCards, { model: model, catalog: catalog, fresh: fresh, status: performanceStatus, now: now,} )\n        )\n\n        , __jsx(NextNav, { title: family.name, sections: sections, active: activeSection,} )\n\n        , __jsx(NextSection, { id: \"capabilities\", title: \"Capabilities\", lead: \"What the model takes in, returns and supports through the API.\"          ,}\n          , __jsx(IoFlow, { inputs: inputs, outputs: ['Text'],} )\n          , __jsx('div', { className: \"vxn-tiles\",}\n            , __jsx('div', { className: \"vxn-tile\",}, __jsx('span', { className: \"vxn-tile-icon\",}, __jsx(Icon, { name: \"bolt\", size: 16,} )), __jsx('span', { className: \"vxn-tile-text\",}, __jsx('span', { className: \"vxn-tile-name\",}, \"Streaming\"), __jsx('span', { className: \"vxn-tile-detail\",}, __jsx('code', null, \"stream: true\" ))))\n            , supported.map(cap => __jsx(CapTile, { key: cap.key, cap: cap, model: model,} ))\n            , Array.from({ length: (3 - ((supported.length + 1) % 3)) % 3 }, (_, i) => __jsx('span', { key: `fill-${i}`, className: \"vxn-tile is-empty\" , 'aria-hidden': \"true\",} ))\n          )\n          , missing.length ? __jsx('p', { className: \"vxn-missing\",}, __jsx('span', null, \"Not supported\" ), listText(missing.map(c => (c.key === 'xSearch' ? c.label : c.label.toLowerCase())))) : null\n        )\n\n        , benchmarked ? (\n          __jsx(NextSection, { id: \"benchmarks\", title: \"Benchmarks\",}\n            , BENCHMARKS.filter(b => headlineRun(model, b.key)).map(bench => (\n              __jsx(BenchmarkCard, { key: bench.key, bench: bench, model: model, family: family, catalog: catalog,} )\n            ))\n          )\n        ) : null\n\n        , __jsx(NextSection, { id: \"specs\", title: \"Specs\",}\n          , __jsx('dl', { className: \"vxn-sheet\",}\n            , [\n              ['Model ID', __jsx('code', null, model.id)],\n              endpoint ? ['Endpoint', __jsx('code', null, endpoint.method, \" /api/v1\" , endpoint.path)] : null,\n              ['Context window', t.context ? `${count(t.context)} tokens` : 'Not published'],\n              ['Max output', t.maxOutput ? `${count(t.maxOutput)} tokens` : 'Not published'],\n              ['Reasoning', !t.reasoning ? 'None' : t.reasoning.effort && t.reasoning.effort.length ? __jsx(__Fragment, null, __jsx('code', null, t.reasoning.effort.join(' · ')), t.reasoning.defaultEffort ? __jsx('span', { className: \"vx-muted\",}, \" · default \"   , t.reasoning.defaultEffort) : null) : 'Always on'],\n              ['Precision', t.quantization ? QUANT_LABELS[t.quantization] || t.quantization : model.privacy === 'anonymized' ? 'Set by the provider' : 'Not disclosed'],\n              PRIVACY[model.privacy] ? ['Privacy', __jsx(__Fragment, null, PRIVACY[model.privacy].label, __jsx(InfoTip, { text: PRIVACY[model.privacy].desc,} ))] : null,\n              ['Weights', model.openWeights ? (source ? __jsx('a', { href: source, target: \"_blank\", rel: \"noopener noreferrer\" ,}, weightsName(source), __jsx(Icon, { name: \"external\", size: 12,} )) : 'Open') : 'Closed'],\n              ['Added', fmtDate(model.created)]\n            ].filter(Boolean).map(([label, value]) => __jsx('div', { key: label, className: \"vxn-sheet-row\",}, __jsx('dt', null, label), __jsx('dd', null, value)))\n          )\n        )\n\n\n        , similar.length || versions.length ? (\n          __jsx(NextSection, { id: \"compare\", title: \"Compare\",}\n            , similar.length ? (\n              __jsx('div', { className: \"vx-table-wrap vxn-compare\" ,}\n                , __jsx('table', { className: \"vx-dtable\",}\n                  , __jsx('thead', null, __jsx('tr', null, __jsx('th', null, \"Model\"), __jsx('th', { className: \"vx-al-right\",}, \"Input\"), __jsx('th', { className: \"vx-al-right\",}, \"Output\"), __jsx('th', { className: \"vx-al-right vx-hide-sm\" ,}, \"GPQA Diamond\" ), __jsx('th', { className: \"vx-al-right vx-hide-sm\" ,}, \"Context\"), __jsx('th', { className: \"vx-al-right vx-hide-sm\" ,}, \"Max output\" ), __jsx('th', { className: \"vx-al-right vx-hide-sm\" ,}, \"First token\" ), __jsx('th', { className: \"vx-al-right vx-hide-sm\" ,}, \"Speed\")))\n                  , __jsx('tbody', null\n                    , compareRows.map(row => (\n                      __jsx('tr', { key: row.key, className: cls(row.current && 'is-current'),}\n                        , __jsx('td', null, row.href ? __jsx('a', { href: row.href,}, row.name) : __jsx('strong', null, row.name))\n                        , __jsx('td', { className: \"vx-al-right vx-num\" ,}, usd(row.pricing.input))\n                        , __jsx('td', { className: \"vx-al-right vx-num\" ,}, usd(row.pricing.output))\n                        , __jsx('td', { className: \"vx-al-right vx-num vx-hide-sm\"  ,}, row.gpqa)\n                        , __jsx('td', { className: \"vx-al-right vx-num vx-hide-sm\"  ,}, tokens(row.text.context))\n                        , __jsx('td', { className: \"vx-al-right vx-num vx-hide-sm\"  ,}, tokens(row.text.maxOutput))\n                        , __jsx('td', { className: \"vx-al-right vx-num vx-hide-sm\"  ,}, fmtMs(row.day.ttftMs))\n                        , __jsx('td', { className: \"vx-al-right vx-num vx-hide-sm\"  ,}, fmtSpeed(row.day.tokensPerSecond))\n                      )\n                    ))\n                  )\n                )\n              )\n            ) : null\n            , versions.length ? __jsx(VersionTimeline, { family: family, versions: versions, created: model.created,} ) : null\n          )\n        ) : null\n\n        , __jsx(NextSection, { id: \"pricing\", title: \"Pricing\", lead: \"Billed per token in USD. Reasoning tokens bill as output.\"         ,}\n          , __jsx('div', { className: \"vxn-prices\",}\n            , __jsx('div', { className: \"vxn-price\",}, __jsx('span', { className: \"vxn-price-label\",}, \"Input\"), __jsx('span', { className: \"vxn-price-value\",}, usd(p.input)), __jsx('span', { className: \"vx-muted\",}, \"per 1M tokens\"  ))\n            , p.cacheRead != null ? __jsx('div', { className: \"vxn-price\",}, __jsx('span', { className: \"vxn-price-label\",}, \"Cached input\" ), __jsx('span', { className: \"vxn-price-value\",}, usd(p.cacheRead)), __jsx('span', { className: \"vx-muted\",}, p.input ? `${Math.round((1 - p.cacheRead / p.input) * 100)}% off input` : 'per 1M tokens')) : null\n            , __jsx('div', { className: \"vxn-price\",}, __jsx('span', { className: \"vxn-price-label\",}, \"Output\"), __jsx('span', { className: \"vxn-price-value\",}, usd(p.output)), __jsx('span', { className: \"vx-muted\",}, \"per 1M tokens\"  ))\n          )\n          , __jsx('div', { className: \"vxn-split\",}\n            , __jsx('div', null\n              , __jsx('h3', { className: \"vxn-h3\",}, \"Estimate a workload\"  )\n              , __jsx(Estimator, { pricing: p,} )\n            )\n            , similar.length ? (\n              __jsx('div', null\n                , __jsx('h3', { className: \"vxn-h3\",}, \"Blended price against similar models\"    )\n                , __jsx(Bars, { rows: compareRows.map(r => ({ key: r.key, name: r.name, href: r.href, current: r.current, value: blended(r) })).filter(r => r.value != null),\n                  format: v => usd(v), caption: \"Per 1M tokens at three input tokens for each output token.\"          ,} )\n              )\n            ) : null\n          )\n        )\n\n        , __jsx(NextSection, { id: \"quickstart\", title: \"Quickstart\", lead: \"OpenAI-compatible: point any OpenAI SDK at the Venice base URL with a Venice API key.\"              ,}\n          , __jsx(CodePanel, { model: model, endpoint: endpoint, setEndpointId: setEndpointId,} )\n          , model.privacy === 'e2ee' ? __jsx('p', { className: \"vxn-callout\",}, __jsx(Icon, { name: \"lock\", size: 14,} ), __jsx('span', null, \"These samples send the prompt as plaintext, so the request runs TEE-only. For end-to-end encryption, send encrypted messages with the E2EE headers, as the \"                        , __jsx('a', { href: \"/guides/features/tee-e2ee-models#e2ee-models\",}, \"TEE and E2EE guide\"   ), \" shows.\" )) : null\n          , __jsx('h3', { className: \"vxn-h3 vxn-gap\" ,}, \"Parameters\")\n          , __jsx(ParamTable, { model: model,} )\n          , __jsx('div', { className: \"vxn-guides\",}\n            , supported.filter(cap => CAP_GUIDES[cap.key]).map(cap => (\n              __jsx('a', { key: cap.key, className: \"vxn-guide\", href: CAP_GUIDES[cap.key],}, __jsx(Icon, { name: cap.icon, size: 16,} ), __jsx('span', null, cap.label === 'Image input' ? 'Vision' : cap.label), __jsx(Icon, { name: \"arrowRight\", size: 14,} ))\n            ))\n          )\n        )\n      )\n    );\n  };\n\n  /* ------------------------------------------------------------ image page, next */\n\n  const RES_SIDE = { '1K': 1, '2K': 2, '4K': 4 };\n  const RENDER_ORDER = ['photoreal', 'style', 'text', 'composition'];\n  const QUALITY_LEVELS = ['low', 'medium', 'high'];\n  const imageQualities = pricing => {\n    const byQuality = pricing.byQuality || {};\n    return QUALITY_LEVELS.filter(level => Object.values(byQuality).some(row => row && row[level] != null));\n  };\n  const IMAGE_STANDING = [\n    { key: 'price', label: 'Price per image', better: 'cheaper', lowerIsBetter: true, format: v => usd(v), tip: 'At 1K and the default quality, or the single price of models without resolution tiers.' },\n    { key: 'prompt', label: 'Prompt limit', better: 'longer', lowerIsBetter: false, format: v => `${count(v)} characters` }\n  ];\n  const imageStandingValues = model => {\n    const p = model.pricing || {};\n    return { price: p.byResolution && p.byResolution['1K'] != null ? p.byResolution['1K'] : p.perImage, prompt: (model.image || {}).promptLimit };\n  };\n  const imagePrices = pricing => [...new Set([pricing.perImage, ...Object.values(pricing.byResolution || {}),\n    ...Object.values(pricing.byQuality || {}).flatMap(row => Object.values(row || {}))].filter(v => v != null))];\n\n  // Everything an agent needs to generate with the model, as Markdown.\n  const imageBrief = (family, model, editor, sample) => {\n    const p = model.pricing || {};\n    const image = model.image || {};\n    const endpoint = (model.endpoints || []).find(e => e.recommended) || (model.endpoints || [])[0];\n    const openai = (model.endpoints || []).find(e => e.id === 'images-generations');\n    const editEndpoint = editor && ((editor.endpoints || []).find(e => e.recommended) || (editor.endpoints || [])[0]);\n    const byRes = row => Object.entries(row || {}).filter(([, v]) => v != null).map(([res, v]) => `${res} ${usd(v)}`).join(', ');\n    const qualities = imageQualities(p);\n    const prices = qualities.length > 1\n      ? ['- Price per image, by quality:', ...qualities.map(level => `  - ${level}${level === p.defaultQuality ? ' (default)' : ''}: ${byRes(Object.fromEntries(Object.entries(p.byQuality).map(([res, row]) => [res, row[level]])))}`)]\n      : [`- Price per image: ${p.byResolution ? byRes(p.byResolution) : usd(p.perImage)}`];\n    const ratios = (image.aspectRatios || []).filter(r => r !== 'auto');\n    return [\n      `# ${family.name} on the Venice API`,\n      '',\n      `- Model ID: \\`${model.id}\\``,\n      endpoint ? `- Endpoint: \\`${endpoint.method} ${API}${endpoint.path}\\`${openai ? `, or the OpenAI-compatible \\`${openai.method} ${API}${openai.path}\\`` : ''}` : null,\n      editor ? `- Edit model ID: \\`${editor.id}\\`${editEndpoint ? `, on \\`${editEndpoint.method} ${API}${editEndpoint.path}\\`` : ''}` : null,\n      '- Auth: `Authorization: Bearer $VENICE_API_KEY`, with a key from https://venice.ai/settings/api',\n      ...prices,\n      image.resolutions && image.resolutions.length ? `- Resolutions: ${image.resolutions.join(', ')}${image.defaultResolution ? `, default ${image.defaultResolution}` : ''}` : null,\n      ratios.length ? `- Aspect ratios: ${ratios.join(', ')}${image.defaultAspectRatio ? `, default ${image.defaultAspectRatio}` : ''}` : null,\n      image.promptLimit ? `- Prompt: up to ${count(image.promptLimit)} characters` : null,\n      p.upscale ? `- Upscale: ${Object.entries(p.upscale).filter(([, v]) => v != null).map(([k, v]) => `${k} ${usd(v)}`).join(', ')}` : null,\n      PRIVACY[model.privacy] ? `- Privacy: ${PRIVACY[model.privacy].label}. ${PRIVACY[model.privacy].desc}` : null,\n      `- Docs: https://docs.venice.ai/models/${family.slug}`,\n      '',\n      '```bash',\n      sample,\n      '```'\n    ].filter(line => line != null).join('\\n');\n  };\n\n  const byRenderOrder = (a, b) => RENDER_ORDER.indexOf(a.prompt) - RENDER_ORDER.indexOf(b.prompt);\n\n  const RenderFeature = ({ item, onOpen }) => (\n    __jsx('button', { type: \"button\", className: cls('vxi-feature', item.type === 'video' && 'is-video'), onClick: () => onOpen(item), 'aria-label': `Open the ${item.title} render`,}\n      , item.type === 'video'\n        ? __jsx(HoverVideo, { key: item.url, src: item.url, className: \"vxv-media-el\", autoPlay: !prefersReducedMotion(),} )\n        : __jsx('img', { src: item.url, alt: item.caption || item.title,} )\n      , __jsx('span', { className: \"vxi-feature-cap\",}, __jsx('strong', null, item.title), __jsx('span', null, item.caption))\n    )\n  );\n\n  const RenderThumbs = ({ items, active, onSelect }) => (\n    __jsx('div', { className: \"vxi-thumbs\", role: \"group\", 'aria-label': \"Sample renders\" ,}\n      , items.map(item => (\n        __jsx('button', { key: item.url, type: \"button\", title: item.title, 'aria-pressed': item === active, className: cls('vxi-thumb', item === active && 'is-active'), onClick: () => onSelect(item),}\n          , __jsx('img', { src: item.url, alt: item.title, loading: \"lazy\",} )\n        )\n      ))\n    )\n  );\n\n  // Models of one type render the same reference prompts, so one prompt lines\n  // them up.\n  const CompareImage = ({ item, alt }) => __jsx('img', { src: item.url, alt: alt, loading: \"lazy\",} );\n  const imagePriceLabel = model => (model.headline ? `${usd(model.headline.value)} per image` : null);\n  const PromptCompare = ({ family, render, renders, onSelect, catalog, similar, task = 'image-generation', noun = 'image models', priceOf = imagePriceLabel, Media = CompareImage }) => {\n    const [all, setAll] = useState(false);\n    const others = useMemo(() => {\n      if (!catalog) return [];\n      const rank = new Map(similar.map((item, i) => [item.slug, i]));\n      const order = row => (rank.has(row.family.slug) ? rank.get(row.family.slug) : similar.length);\n      return catalog.families\n        .filter(f => f.task === task && f.slug !== family.slug)\n        .map(f => ({ family: f, model: catalog.models[f.primary], render: ((catalog.models[f.primary] || {}).media || []).find(item => item.prompt === render.prompt) }))\n        .filter(row => row.render)\n        .sort((a, b) => order(a) - order(b) || (b.family.created || 0) - (a.family.created || 0));\n    }, [catalog, render.prompt]);\n    const shown = all ? others : others.slice(0, 7);\n    return (\n      __jsx('div', { className: \"vxi-compare\",}\n        , __jsx('div', { className: \"vxi-compare-head\",}\n          , renders.length > 1 ? (\n            __jsx('div', { className: \"vxn-switch\", role: \"radiogroup\", 'aria-label': \"Reference prompt\" ,}\n              , renders.map(item => (\n                __jsx('button', { key: item.prompt, type: \"button\", role: \"radio\", 'aria-checked': item === render, className: cls(item === render && 'is-active'), onClick: () => onSelect(item),}, item.title)\n              ))\n            )\n          ) : null\n          , render.caption ? __jsx('q', { className: \"vxi-prompt\",}, render.caption) : null\n        )\n        , __jsx('div', { className: \"vxi-grid\",}\n          , __jsx('div', { className: \"vxi-tile is-current\" ,}\n            , __jsx(Media, { item: render, alt: `${family.name}: ${render.title}`,} )\n            , __jsx('span', { className: \"vxi-tile-cap\",}, __jsx('strong', null, family.name), __jsx('span', null, \"This model\" ))\n          )\n          , shown.map(row => (\n            __jsx('a', { key: row.family.slug, className: \"vxi-tile\", href: `/models/${row.family.slug}`,}\n              , __jsx(Media, { item: row.render, alt: `${row.family.name}: ${render.title}`,} )\n              , __jsx('span', { className: \"vxi-tile-cap\",}, __jsx('strong', null, row.family.name), __jsx('span', null, row.model ? priceOf(row.model) : null))\n            )\n          ))\n        )\n        , others.length > 7 ? __jsx('button', { type: \"button\", className: \"vxn-btn vxi-more\" , onClick: () => setAll(!all),}, all ? 'Show fewer' : `Show all ${others.length + 1} ${noun}`) : null\n      )\n    );\n  };\n\n  // Resolution tiers drawn to scale with the model's own render, priced at\n  // each quality.\n  const PriceGrid = ({ pricing, render }) => {\n    const resolutions = Object.keys(pricing.byResolution || {}).filter(res => pricing.byResolution[res] != null);\n    const qualities = imageQualities(pricing);\n    const columns = resolutions.length ? resolutions : [null];\n    const rows = qualities.length > 1\n      ? qualities.map(level => [level, upperFirst(level), res => (pricing.byQuality[res] || {})[level]])\n      : [['default', 'Per image', res => (res ? pricing.byResolution[res] : pricing.perImage)]];\n    const most = Math.max(...columns.map(res => RES_SIDE[res] || 1));\n    return (\n      __jsx('div', { className: \"vx-table-wrap\",}\n        , __jsx('table', { className: \"vxi-price-grid\",}\n          , __jsx('thead', null\n            , __jsx('tr', null\n              , __jsx('td', null )\n              , columns.map(res => (\n                __jsx('th', { key: res || 'any', scope: \"col\",}\n                  , __jsx('span', { className: \"vxi-step-box\", style: { '--vxi-side': (RES_SIDE[res] || most) / most, backgroundImage: render ? `url(\"${render.url}\")` : null }, 'aria-hidden': \"true\",} )\n                  , __jsx('span', { className: \"vxi-step-res\",}, res || 'Flat price', res && res === pricing.defaultResolution ? __jsx('span', { className: \"vx-hide-sm\",}, \" · default\"  ) : null)\n                )\n              ))\n            )\n          )\n          , __jsx('tbody', null\n            , rows.map(([key, label, price]) => (\n              __jsx('tr', { key: key,}\n                , __jsx('th', { scope: \"row\",}, label, key === pricing.defaultQuality ? __jsx('span', { className: \"vx-muted\",}, \" · default\"  ) : null)\n                , columns.map(res => __jsx('td', { key: res || 'any',}, usd(price(res))))\n              )\n            ))\n          )\n        )\n      )\n    );\n  };\n\n  const ImageEstimator = ({ pricing }) => {\n    const resolutions = Object.keys(pricing.byResolution || {});\n    const qualities = imageQualities(pricing);\n    const [images, setImages] = useState(1000);\n    const [res, setRes] = useState(pricing.defaultResolution || resolutions[0]);\n    const [quality, setQuality] = useState(pricing.defaultQuality || qualities[0]);\n    const each = quality && pricing.byQuality && pricing.byQuality[res] && pricing.byQuality[res][quality] != null ? pricing.byQuality[res][quality]\n      : pricing.byResolution && pricing.byResolution[res] != null ? pricing.byResolution[res] : pricing.perImage;\n    return (\n      __jsx('div', { className: \"vxn-est\",}\n        , __jsx('div', { className: \"vxi-est-controls\",}\n          , __jsx('label', { className: \"vxn-field\",}, __jsx('span', null, \"Images\"), __jsx('input', { type: \"number\", min: \"0\", step: \"100\", value: images, onChange: e => setImages(Math.max(0, Number(e.target.value) || 0)),} ))\n          , resolutions.length > 1 ? __jsx('div', { className: \"vxn-field\",}, __jsx('span', null, \"Resolution\"), __jsx(Segmented, { ariaLabel: \"Resolution\", value: res, onChange: setRes, options: resolutions.map(r => ({ value: r, label: r })),} )) : null\n          , qualities.length > 1 ? __jsx('div', { className: \"vxn-field\",}, __jsx('span', null, \"Quality\"), __jsx(Segmented, { ariaLabel: \"Quality\", value: quality, onChange: setQuality, options: qualities.map(q => ({ value: q, label: upperFirst(q) })),} )) : null\n        )\n        , __jsx('div', { className: \"vxn-est-result\",}\n          , __jsx('div', null, __jsx('span', { className: \"vxn-est-value\",}, usd(each)), __jsx('span', { className: \"vx-muted\",}, \"per image\" ))\n          , __jsx('div', null, __jsx('span', { className: \"vxn-est-value is-total\" ,}, usd(each != null ? each * images : null)), __jsx('span', { className: \"vx-muted\",}, \"for \" , count(images), \" images\" ))\n        )\n      )\n    );\n  };\n\n  const ImagePageNext = ({ data }) => {\n    const { family, models, related, providers } = data;\n    const now = useNow();\n    const { catalog } = useCatalog();\n    const headerHeight = useHeaderHeight();\n    const [endpointId, setEndpointId] = useState(null);\n    const model = models.find(m => m.id === family.primary) || models[0];\n    const editor = models.find(m => m.task === 'image-edit');\n    const remover = models.find(m => m.task === 'background-removal');\n    const provider = providers[family.provider] || providers[model.provider];\n    const p = model.pricing || {};\n    const image = model.image || {};\n    const source = safeUrl(model.source);\n    const endpoints = (model.endpoints || []).filter(e => e.supported !== false);\n    const endpoint = endpoints.find(e => e.id === endpointId) || endpoints.find(e => e.recommended) || endpoints[0];\n    const similar = (related && related.similar) || [];\n    const versions = (related && related.versions) || [];\n    const qualities = imageQualities(p);\n    const resolutions = image.resolutions || Object.keys(p.byResolution || {});\n    const ratios = (image.aspectRatios || []).filter(r => r !== 'auto');\n    const upscale = Object.entries(p.upscale || {}).filter(([, v]) => v != null);\n    const editPrice = editor && editor.pricing ? (editor.pricing.edit != null ? editor.pricing.edit : editor.pricing.perImage) : null;\n    const renders = [...(model.media || [])].filter(item => item.type === 'image').sort(byRenderOrder);\n    const [promptId, setPromptId] = useState(renders[0] ? renders[0].prompt : null);\n    const [opened, setOpened] = useState(null);\n    const render = renders.find(item => item.prompt === promptId) || renders[0];\n    const selectRender = item => setPromptId(item.prompt);\n    const sections = [render ? ['compare', 'Same prompt'] : null, ['pricing', 'Pricing'], ['capabilities', 'Capabilities'], ['specs', 'Specs'], ['quickstart', 'Quickstart']].filter(Boolean);\n    const activeSection = useScrollSpy(sections.map(([id]) => id));\n    const brief = imageBrief(family, model, editor, codeSamples(model, endpoint && endpoint.id).curl);\n    const tasks = [\n      { key: 'generate', icon: 'image', name: 'Generate', detail: __jsx('code', null, model.id) },\n      editor ? { key: 'edit', icon: 'wand', name: 'Edit', detail: __jsx(__Fragment, null, __jsx('code', null, editor.id), editor.image && editor.image.maxInputImages > 1 ? ` · up to ${editor.image.maxInputImages} images` : editor.image && editor.image.combineImages ? ' · combines images' : '') } : null,\n      upscale.length ? { key: 'upscale', icon: 'maximize', name: 'Upscale', detail: upscale.map(([k, v]) => `${k} ${usd(v)}`).join(' · ') } : null,\n      remover ? { key: 'remove', icon: 'layers', name: 'Background removal', detail: __jsx('code', null, remover.id) } : null,\n      qualities.length > 1 ? { key: 'quality', icon: 'sliders', name: 'Quality', detail: __jsx('code', null, qualities.join(' · ')) } : null,\n      image.styleReferences ? { key: 'style', icon: 'sparkles', name: 'Style references', detail: __jsx('code', null, \"style_references\") } : null,\n      image.webSearch ? { key: 'web', icon: 'globe', name: 'Web-grounded', detail: __jsx('code', null, \"enable_web_search\") } : null,\n      { key: 'seed', icon: 'flask', name: 'Repeatable', detail: __jsx('code', null, \"seed\") }\n    ].filter(Boolean);\n    const params = [\n      ['model', __jsx('code', null, model.id), 'Required'],\n      ['prompt', image.promptLimit ? `Up to ${count(image.promptLimit)} characters` : 'Text', 'Required'],\n      resolutions.length ? ['resolution', __jsx('code', null, resolutions.join(' | ')), image.defaultResolution ? `Default ${image.defaultResolution}` : null] : null,\n      ratios.length ? ['aspect_ratio', `${ratios.length} ratios`, image.defaultAspectRatio ? `Default ${image.defaultAspectRatio}` : null] : null,\n      qualities.length ? ['quality', __jsx('code', null, qualities.join(' | ')), p.defaultQuality ? `Default ${p.defaultQuality}` : null] : null,\n      image.steps ? ['steps', `Up to ${image.steps.max}`, `Default ${image.steps.default}`] : null,\n      ['seed', 'Integer', 'Repeats a result'],\n      ['variants', __jsx('code', null, \"1 – 4\"  ), 'Images per request'],\n      image.styleReferences ? ['style_references', 'Image URLs', 'Match a style'] : null,\n      image.webSearch ? ['enable_web_search', __jsx('code', null, \"true | false\"  ), 'Ground the image in search results'] : null,\n      ['format', __jsx('code', null, \"webp | png | jpeg\"    ), 'Default webp'],\n      ['safe_mode', __jsx('code', null, \"true | false\"  ), 'Default true, which blurs adult content']\n    ].filter(Boolean);\n    const prices = imagePrices(p);\n    const top = resolutions[resolutions.length - 1];\n\n    return (\n      __jsx('div', { className: \"vx vxn vxi not-prose\"   , style: { '--vxn-header': `${headerHeight}px` },}\n        , __jsx(HoverTips, null )\n        , __jsx(NextTop, { scope: \"Image\", scopeHref: \"/models/image\", family: family, brief: brief,} )\n\n        , __jsx('header', { className: \"vxn-hero vxi-hero\" ,}\n          , __jsx('div', { className: \"vxn-hero-main\",}\n            , __jsx('div', { className: \"vxn-provider\",}\n              , __jsx(ProviderLogo, { provider: provider, size: 22,} )\n              , __jsx('span', null, provider ? provider.name : family.provider)\n              , __jsx('span', { className: \"vxn-dot\",} )\n              , __jsx('span', null, fmtDate(model.created))\n              , isNew(model.created, now) ? __jsx(Tag, { tone: \"new\",}, \"New\") : null\n              , model.beta ? __jsx(Tag, { tone: \"beta\",}, \"Beta\") : null\n            )\n            , __jsx('h1', { className: \"vxn-h1\",}, family.name)\n            , __jsx('div', { className: \"vxn-meta\",}\n              , __jsx('span', { className: \"vxn-meta-id\",}, __jsx('code', null, model.id), __jsx(CopyButton, { text: model.id, iconOnly: true, label: `Copy model ID ${model.id}`,} ))\n              , PRIVACY[model.privacy] ? __jsx('span', { className: \"vxn-meta-item\",}, PRIVACY[model.privacy].label, __jsx(InfoTip, { text: PRIVACY[model.privacy].desc, size: 12,} )) : null\n              , model.openWeights ? (source\n                ? __jsx('a', { className: \"vxn-meta-item\", href: source, target: \"_blank\", rel: \"noopener noreferrer\" ,}, \"Open weights\" , __jsx(Icon, { name: \"external\", size: 12,} ))\n                : __jsx('span', { className: \"vxn-meta-item\",}, \"Open weights\" )) : null\n              , model.uncensored ? __jsx('span', { className: \"vxn-meta-item\",}, \"Uncensored\") : null\n            )\n            , model.description || family.description ? __jsx('p', { className: \"vxn-desc\",}, model.description || family.description) : null\n            , __jsx('div', { className: \"vxn-figs\",}\n              , prices.length ? __jsx(Figure, { value: __jsx(__Fragment, null, prices.length > 1 ? __jsx('span', { className: \"vxn-unit is-lead\" ,}, \"from\") : null, usd(Math.min(...prices))), label: \"per image\" ,} ) : null\n              , top ? __jsx(Figure, { value: top, label: `max resolution${resolutions.length > 1 ? `, ${resolutions.length} sizes` : ''}`,} ) : null\n              , ratios.length ? __jsx(Figure, { value: ratios.length, label: `aspect ratios${image.defaultAspectRatio ? `, ${image.defaultAspectRatio} default` : ''}`,} ) : null\n            )\n            , renders.length > 1 ? __jsx(RenderThumbs, { items: renders, active: render, onSelect: selectRender,} ) : null\n            , __jsx('div', { className: \"vxn-ctas\",}\n              , __jsx('a', { className: \"vxn-btn is-primary\" , href: \"https://venice.ai/settings/api\", target: \"_blank\", rel: \"noopener noreferrer\" ,}, \"Get an API key\"   )\n              , __jsx('a', { className: \"vxn-textlink\", href: `https://venice.ai/studio/image?model=${encodeURIComponent(model.id)}`, target: \"_blank\", rel: \"noopener noreferrer\" ,}, \"Try in Venice\"  , __jsx(Icon, { name: \"arrowRight\", size: 14,} ))\n            )\n          )\n          , render ? (\n            __jsx('div', { className: \"vxi-hero-side\",}\n              , __jsx(RenderFeature, { item: render, onOpen: setOpened,} )\n              , renders.length > 1 ? __jsx(RenderThumbs, { items: renders, active: render, onSelect: selectRender,} ) : null\n            )\n          ) : null\n        )\n        , __jsx(Lightbox, { item: opened, onClose: () => setOpened(null),} )\n\n        , __jsx(NextNav, { title: family.name, sections: sections, active: activeSection,} )\n\n        , render ? (\n          __jsx(NextSection, { id: \"compare\", title: \"Same prompt, other models\"   , lead: \"Every image model renders the same reference prompts, so their results line up side by side.\"               ,}\n            , __jsx(PromptCompare, { family: family, render: render, renders: renders, onSelect: selectRender, catalog: catalog, similar: similar,} )\n          )\n        ) : null\n\n        , __jsx(NextSection, { id: \"pricing\", title: \"Pricing\", lead: `Billed per image in USD${p.byResolution ? `, by resolution${qualities.length > 1 ? ' and quality' : ''}. Each resolution is drawn to scale` : ''}.`,}\n          , __jsx(PriceGrid, { pricing: p, render: render,} )\n          , editPrice != null || p.extraInputImage != null || upscale.length ? (\n            __jsx('div', { className: \"vxi-extras\",}\n              , editPrice != null ? __jsx('div', { className: \"vxi-extra\",}, __jsx('span', { className: \"vxn-price-label\",}, \"Edit\"), __jsx('span', null, usd(editPrice))) : null\n              , p.extraInputImage != null || (editor && editor.pricing && editor.pricing.extraInputImage != null) ? __jsx('div', { className: \"vxi-extra\",}, __jsx('span', { className: \"vxn-price-label\",}, \"Extra input image\"  ), __jsx('span', null, usd(p.extraInputImage != null ? p.extraInputImage : editor.pricing.extraInputImage))) : null\n              , upscale.map(([factor, value]) => __jsx('div', { key: factor, className: \"vxi-extra\",}, __jsx('span', { className: \"vxn-price-label\",}, factor, \" upscale\" ), __jsx('span', null, usd(value))))\n            )\n          ) : null\n          , __jsx('div', { className: \"vxn-split\",}\n            , __jsx('div', null\n              , __jsx('h3', { className: \"vxn-h3\",}, \"Estimate a batch\"  )\n              , __jsx(ImageEstimator, { pricing: p,} )\n            )\n            , __jsx('div', null\n              , __jsx('h3', { className: \"vxn-h3\",}, \"Against other image models\"   )\n              , __jsx(Standing, { model: model, catalog: catalog, task: \"image-generation\", noun: \"image models\" , metrics: IMAGE_STANDING, valuesOf: imageStandingValues,} )\n            )\n          )\n        )\n\n        , __jsx(NextSection, { id: \"capabilities\", title: \"Capabilities\", lead: \"What the family does, and every shape it renders.\"        ,}\n          , __jsx('div', { className: \"vxn-tiles\",}\n            , tasks.map(task => (\n              __jsx('div', { key: task.key, className: \"vxn-tile\",}\n                , __jsx('span', { className: \"vxn-tile-icon\",}, __jsx(Icon, { name: task.icon, size: 16,} ))\n                , __jsx('span', { className: \"vxn-tile-text\",}, __jsx('span', { className: \"vxn-tile-name\",}, task.name), __jsx('span', { className: \"vxn-tile-detail\",}, task.detail))\n              )\n            ))\n            , Array.from({ length: (3 - (tasks.length % 3)) % 3 }, (_, i) => __jsx('span', { key: `fill-${i}`, className: \"vxn-tile is-empty\" , 'aria-hidden': \"true\",} ))\n          )\n          , ratios.length ? (\n            __jsx(__Fragment, null\n              , __jsx('h3', { className: \"vxn-h3 vxn-gap\" ,}, \"Aspect ratios\" )\n              , __jsx('div', { className: \"vxi-ratios\",}, ratios.map(ratio => __jsx(AspectShape, { key: ratio, ratio: ratio, active: ratio === image.defaultAspectRatio,} )))\n            )\n          ) : null\n        )\n\n        , __jsx(NextSection, { id: \"specs\", title: \"Specs\",}\n          , __jsx('dl', { className: \"vxn-sheet\",}\n            , [\n              ['Model ID', __jsx('code', null, model.id)],\n              editor ? ['Edit model ID', __jsx('code', null, editor.id)] : null,\n              endpoint ? ['Endpoint', __jsx('code', null, endpoint.method, \" /api/v1\" , endpoint.path)] : null,\n              resolutions.length ? ['Resolutions', `${resolutions.join(', ')}${image.defaultResolution ? ` · default ${image.defaultResolution}` : ''}`] : null,\n              ratios.length ? ['Aspect ratios', `${ratios.length}${image.defaultAspectRatio ? ` · default ${image.defaultAspectRatio}` : ''}`] : null,\n              image.promptLimit ? ['Prompt limit', `${count(image.promptLimit)} characters`] : null,\n              image.steps ? ['Steps', `default ${image.steps.default}, max ${image.steps.max}`] : null,\n              PRIVACY[model.privacy] ? ['Privacy', __jsx(__Fragment, null, PRIVACY[model.privacy].label, __jsx(InfoTip, { text: PRIVACY[model.privacy].desc,} ))] : null,\n              ['Weights', model.openWeights ? (source ? __jsx('a', { href: source, target: \"_blank\", rel: \"noopener noreferrer\" ,}, weightsName(source), __jsx(Icon, { name: \"external\", size: 12,} )) : 'Open') : 'Closed'],\n              ['Added', fmtDate(model.created)]\n            ].filter(Boolean).map(([label, value]) => __jsx('div', { key: label, className: \"vxn-sheet-row\",}, __jsx('dt', null, label), __jsx('dd', null, value)))\n          )\n          , versions.length ? __jsx(VersionTimeline, { family: family, versions: versions, created: model.created,} ) : null\n        )\n\n        , __jsx(NextSection, { id: \"quickstart\", title: \"Quickstart\", lead: \"Generate with Venice's image endpoint, or with the OpenAI-compatible one from any OpenAI SDK.\"             ,}\n          , __jsx(CodePanel, { model: model, endpoint: endpoint, setEndpointId: setEndpointId,} )\n          , __jsx('h3', { className: \"vxn-h3 vxn-gap\" ,}, \"Parameters\")\n          , __jsx(ParamRows, { rows: params,} )\n        )\n      )\n    );\n  };\n\n  /* ------------------------------------------------------------ video page, next */\n\n  const MODE_ORDER = ['t2v', 'i2v', 'r2v', 'flf', 'transition', 'motion', 'v2v', 'multi-angle', 'upscale'];\n  const MODE_ICONS = { t2v: 'text', i2v: 'image', r2v: 'layers', flf: 'film', transition: 'film', motion: 'activity', v2v: 'wand', 'multi-angle': 'eye', upscale: 'maximize' };\n  const VIDEO_RENDER_ORDER = ['cinematic-landscape', 'urban-night', 'ocean-loop', 'upscaled', 'recast', 'extended', 'bicubic', 'source'];\n  const VIDEO_SUITE = VIDEO_RENDER_ORDER.slice(0, 3);\n  const AUDIO_TEXT = { native: 'Generated with every clip', optional: 'Optional, on by default', none: 'None' };\n  const INPUT_FIELDS = [['image', 'image_url'], ['endImage', 'end_image_url'], ['reference', 'reference_image_urls'], ['video', 'video_url'], ['referenceVideo', 'reference_video_urls'], ['audio', 'audio_url']];\n  const JOB_FLOW = [\n    ['Quote', 'quote', 'Optional. Prices the job in USD without charging for it.'],\n    ['Queue', 'queue', 'Checks and charges the job, then returns a queue_id at once.'],\n    ['Retrieve', 'retrieve', 'Poll it with the queue_id until the {noun} is ready.']\n  ];\n  const VIDEO_STANDING = [\n    { key: 'price', label: 'Price per second', better: 'cheaper', lowerIsBetter: true, format: v => usd(v), tip: 'The lowest rate across its resolutions and audio settings.' },\n    { key: 'length', label: 'Longest clip', better: 'longer', lowerIsBetter: false, format: v => `${v}s` }\n  ];\n  const videoStandingValues = model => ({\n    price: (model.pricing || {}).status === 'quoted' ? model.pricing.fromPerSecond : null,\n    length: maxVideoSeconds(model) || null\n  });\n  const prefersReducedMotion = () => typeof window !== 'undefined' && Boolean(window.matchMedia) && window.matchMedia('(prefers-reduced-motion: reduce)').matches;\n  const byVideoOrder = (a, b) => (VIDEO_RENDER_ORDER.indexOf(a.prompt) + 1 || 99) - (VIDEO_RENDER_ORDER.indexOf(b.prompt) + 1 || 99);\n  const videoRate = model => {\n    const p = model.pricing || {};\n    if (p.status !== 'quoted' || p.fromPerSecond == null) return null;\n    return `${p.toPerSecond > p.fromPerSecond ? 'from ' : ''}${usd(p.fromPerSecond)} / sec`;\n  };\n  const audioChangesPrice = model => {\n    const quotes = (model.pricing || {}).quotes || {};\n    return (model.video || {}).audio === 'optional' && Object.keys(quotes).some(k => k.endsWith('|on') && quotes[k] !== quotes[k.replace(/\\|on$/, '|off')]);\n  };\n  const sortedResolutions = video => ((video && video.resolutions) || []).filter(r => r.height).sort((a, b) => a.height - b.height);\n  const timedDurations = video => ((video && video.durations) || []).filter(d => d.seconds).sort((a, b) => a.seconds - b.seconds);\n\n  // Everything an agent needs to generate with the family, as Markdown.\n  const videoBrief = (family, modes, model, sample) => {\n    const video = model.video || {};\n    const p = model.pricing || {};\n    const res = sortedResolutions(video);\n    const ratios = video.aspectRatios || [];\n    const rates = key => res.map(r => ((p.perSecond || {})[`${r.value}|${key}`] != null ? `${r.label} ${usd(p.perSecond[`${r.value}|${key}`])}` : null)).filter(Boolean).join(', ');\n    const price = p.status === 'quoted'\n      ? (audioChangesPrice(model) ? `- Price per second (USD): with audio ${rates('on')}; silent ${rates('off')}` : `- Price per second (USD): ${rates(video.audio === 'none' ? 'off' : 'on') || rates('off')}`)\n        + (p.quotedAt ? `, quoted ${fmtDate(Math.floor(new Date(p.quotedAt).getTime() / 1000))}` : '')\n      : p.status === 'input-dependent' ? '- Price: billed by the length of the source video; quote it with `POST /video/quote` and its `video_url`'\n        : '- Price: quote it with `POST /video/quote`';\n    const fields = [video.mode !== 'upscale' ? 'prompt' : null, ...INPUT_FIELDS.filter(([key]) => (video.inputs || {})[key]).map(([, field]) => field)].filter(Boolean);\n    return [\n      `# ${family.name} on the Venice API`,\n      '',\n      modes.length > 1\n        ? `- Model IDs: ${modes.map(m => `\\`${m.id}\\` (${(VARIANT_LABELS[m.variant] || m.variant).toLowerCase()})`).join(', ')}`\n        : `- Model ID: \\`${model.id}\\``,\n      `- Flow: \\`POST ${API}/video/queue\\` returns a \\`queue_id\\`. Poll \\`POST ${API}/video/retrieve\\` with the \\`model\\` and \\`queue_id\\` until it returns the MP4. When the queue response has a \\`download_url\\`, retrieve reports \\`COMPLETED\\` instead and the MP4 is at that URL. \\`POST ${API}/video/quote\\` prices a job without charging for it.`,\n      '- Auth: `Authorization: Bearer $VENICE_API_KEY`, with a key from https://venice.ai/settings/api',\n      modes.length > 1 ? `\\n## ${model.id}\\n` : null,\n      price,\n      timedDurations(video).length ? `- Lengths: ${durationText(video.durations)}; \\`duration\\` is required` : '- Length: matches the source video; omit `duration`',\n      res.length ? `- Resolutions: ${res.map(r => r.value).join(', ')}` : null,\n      ratios.length ? `- Aspect ratios: ${ratios.join(', ')}; \\`aspect_ratio\\` is required` : '- Aspect ratio: set by the input or the model; `aspect_ratio` is rejected',\n      `- Audio: ${(AUDIO_TEXT[video.audio] || 'none').toLowerCase()}${video.audio === 'optional' ? ' (`audio`)' : ''}`,\n      fields.length ? `- Inputs: ${listText(fields.map(f => `\\`${f}\\``))}` : null,\n      video.mode !== 'upscale' ? `- Prompt: up to ${count(video.promptLimit || 2500)} characters` : null,\n      PRIVACY[model.privacy] ? `- Privacy: ${PRIVACY[model.privacy].label}. ${PRIVACY[model.privacy].desc}` : null,\n      `- Docs: https://docs.venice.ai/models/${family.slug}`,\n      '',\n      '```bash',\n      sample,\n      '```'\n    ].filter(line => line != null).join('\\n');\n  };\n\n  const VideoThumbs = ({ items, active, onSelect }) => (\n    __jsx('div', { className: \"vxv-thumbs\", role: \"group\", 'aria-label': \"Sample renders\" , style: { '--vxv-n': Math.max(3, items.length) },}\n      , items.map(item => (\n        __jsx('button', { key: item.url, type: \"button\", 'aria-pressed': item === active, className: cls('vxv-thumb', item === active && 'is-active'), onClick: () => onSelect(item),}\n          , __jsx('span', { className: \"vxv-thumb-media\",}, __jsx(HoverVideo, { src: item.url, className: \"vxv-media-el\",} ))\n          , __jsx('span', null, item.title)\n        )\n      ))\n    )\n  );\n\n  const CompareVideo = ({ item }) => __jsx('span', { className: \"vxv-tile-media\",}, __jsx(HoverVideo, { src: item.url, className: \"vxv-media-el\",} ));\n\n  // Each resolution drawn to scale as a frame playing the model's own render,\n  // and each length as a bar, priced per clip.\n  const VideoPriceGrid = ({ model, render, audio }) => {\n    const video = model.video || {};\n    const p = model.pricing || {};\n    const res = sortedResolutions(video);\n    const cols = res.length ? res : [{ value: '-', label: 'Default', height: 0 }];\n    const audioKey = video.audio === 'optional' ? audio : video.audio === 'native' ? 'on' : 'off';\n    const table = clipTable(model, cols, audioKey) || { rows: timedDurations(video), rates: null };\n    const top = Math.max(...cols.map(c => c.height || 0)) || 1;\n    const longest = Math.max(...table.rows.map(d => d.seconds), 1);\n    return (\n      __jsx('div', { className: \"vx-table-wrap\",}\n        , __jsx('table', { className: \"vxi-price-grid\",}\n          , __jsx('caption', { className: \"vx-sr-only\",}, \"Price per clip by length and resolution\"      , video.audio === 'optional' ? (audioKey === 'on' ? ', with audio' : ', silent') : '')\n          , __jsx('thead', null\n            , __jsx('tr', null\n              , __jsx('td', null )\n              , cols.map(c => (\n                __jsx('th', { key: c.value, scope: \"col\",}\n                  , __jsx('span', { className: \"vxv-frame\", style: { '--vxv-side': (c.height || top) / top }, 'aria-hidden': \"true\",}\n                    , render ? __jsx(HoverVideo, { src: render.url, className: \"vxv-media-el\", autoPlay: !prefersReducedMotion(),} ) : null\n                  )\n                  , __jsx('span', { className: \"vxi-step-res\",}, c.label)\n                )\n              ))\n            )\n          )\n          , __jsx('tbody', null\n            , table.rates ? (\n              __jsx('tr', null\n                , __jsx('th', { scope: \"row\",}, \"Per second\" )\n                , table.rates.map((rate, i) => __jsx('td', { key: cols[i].value,}, usd(rate)))\n              )\n            ) : null\n            , table.rows.map(d => (\n              __jsx('tr', { key: d.value,}\n                , __jsx('th', { scope: \"row\",}, d.seconds, \"s clip\" , __jsx('span', { className: \"vxv-len\", 'aria-hidden': \"true\",}, __jsx('span', { style: { width: `${(d.seconds / longest) * 100}%` },} )))\n                , cols.map(c => __jsx('td', { key: c.value,}, usd((p.quotes || {})[`${c.value}|${d.value}|${audioKey}`])))\n              )\n            ))\n          )\n        )\n      )\n    );\n  };\n\n  const VideoEstimator = ({ model, audio, onAudio }) => {\n    const video = model.video || {};\n    const res = sortedResolutions(video);\n    const durs = timedDurations(video);\n    const prefer = (list, key, want) => (list.find(x => x[key] === want) || list[0] || {})[key];\n    const [clips, setClips] = useState(10);\n    const [h, setH] = useState(() => prefer(res, 'height', 720) || 720);\n    const [s, setS] = useState(() => prefer(durs, 'seconds', 5) || 5);\n    useEffect(() => {\n      setH(prefer(res, 'height', 720) || 720);\n      setS(prefer(durs, 'seconds', 5) || 5);\n    }, [model.id]);\n    const vp = videoPrice(model, { h, s, a: audio });\n    const lengths = durationSteps(durs);\n    const slider = durs.length > 6 && lengths.step ? lengths : null;\n    return (\n      __jsx('div', { className: \"vxn-est\",}\n        , __jsx('div', { className: \"vxi-est-controls\",}\n          , __jsx('label', { className: \"vxn-field\",}, __jsx('span', null, \"Clips\"), __jsx('input', { type: \"number\", min: \"0\", step: \"1\", value: clips, onChange: e => setClips(Math.max(0, Math.round(Number(e.target.value) || 0))),} ))\n          , res.length > 1 ? __jsx('div', { className: \"vxn-field\",}, __jsx('span', null, \"Resolution\"), __jsx(Segmented, { ariaLabel: \"Resolution\", value: h, onChange: setH, options: res.map(r => ({ value: r.height, label: r.label })),} )) : null\n          , durs.length > 1 ? (\n            __jsx('div', { className: \"vxn-field\",}, __jsx('span', null, \"Length\")\n              , slider ? (\n                __jsx('span', { className: \"vx-range\",}\n                  , __jsx('input', { type: \"range\", min: slider.secs[0], max: slider.secs[slider.secs.length - 1], step: slider.step, value: s, 'aria-label': \"Length\", 'aria-valuetext': `${s} seconds`, onChange: e => setS(Number(e.target.value)),} )\n                  , __jsx('span', { className: \"vx-range-value\",}, s, \"s\")\n                )\n              ) : __jsx(Segmented, { ariaLabel: \"Length\", value: s, onChange: setS, options: durs.map(d => ({ value: d.seconds, label: `${d.seconds}s` })),} )\n            )\n          ) : null\n          , video.audio === 'optional' ? __jsx('div', { className: \"vxn-field\",}, __jsx('span', null, \"Audio\"), __jsx(Segmented, { ariaLabel: \"Audio\", value: audio, onChange: onAudio, options: [{ value: 'on', label: 'With audio' }, { value: 'off', label: 'Silent' }],} )) : null\n        )\n        , __jsx('div', { className: \"vxn-est-result\", 'aria-live': \"polite\",}\n          , __jsx('div', null, __jsx('span', { className: \"vxn-est-value\",}, usd(vp.clip)), __jsx('span', { className: \"vx-muted\",}, \"per \" , vp.seconds ? `${vp.seconds}s ` : '', \"clip\"))\n          , __jsx('div', null, __jsx('span', { className: \"vxn-est-value is-total\" ,}, usd(vp.clip != null ? vp.clip * clips : null)), __jsx('span', { className: \"vx-muted\",}, \"for \" , count(clips), \" clips\" ))\n        )\n      )\n    );\n  };\n\n  const JobFlow = ({ base, noun }) => (\n    __jsx('ol', { className: \"vxv-flow\",}\n      , JOB_FLOW.map(([name, step, note], i) => (\n        __jsx('li', { key: step,}\n          , __jsx('span', { className: \"vxv-flow-head\",}, __jsx('span', { className: \"vxv-flow-step\",}, i + 1), name)\n          , __jsx('code', null, \"POST \" , base, \"/\", step)\n          , __jsx('span', { className: \"vx-muted\",}, note.replace('{noun}', noun))\n        )\n      ))\n    )\n  );\n\n  const videoParams = model => {\n    const video = model.video || {};\n    const inputs = video.inputs || {};\n    const upscale = video.mode === 'upscale';\n    const res = sortedResolutions(video);\n    const timed = timedDurations(video);\n    const ratios = video.aspectRatios || [];\n    return [\n      ['model', __jsx('code', null, model.id), 'Required'],\n      upscale ? null : ['prompt', `Up to ${count(video.promptLimit || 2500)} characters`, video.mode === 'multi-angle' ? 'Optional' : 'Required'],\n      timed.length\n        ? ['duration', timed.length > 6 ? durationText(video.durations) : __jsx('code', null, timed.map(d => d.value).join(' | ')), 'Required']\n        : ['duration', 'Omit it', 'Read from the source video'],\n      res.length ? ['resolution', __jsx('code', null, res.map(r => r.value).join(' | ')), 'Optional'] : null,\n      upscale ? ['upscale_factor', __jsx('code', null, \"1 | 2 | 4\"    ), '1 enhances without enlarging'] : null,\n      ratios.length ? ['aspect_ratio', __jsx('code', null, ratios.join(' | ')), 'Required'] : null,\n      video.audio === 'optional' ? ['audio', __jsx('code', null, \"true | false\"  ), 'Default true'] : null,\n      inputs.image ? ['image_url', 'URL or data URL', video.mode === 'motion' ? 'The character to animate' : 'The first frame'] : null,\n      inputs.endImage ? ['end_image_url', 'URL or data URL', ['flf', 'transition'].includes(video.mode) ? 'The last frame, required' : 'The last frame'] : null,\n      inputs.reference ? ['reference_image_urls', 'Image URLs', 'Characters or styles to keep'] : null,\n      inputs.video ? ['video_url', 'URL or data URL', 'The source video, required'] : null,\n      inputs.referenceVideo ? ['reference_video_urls', 'Video URLs', 'Reference clips, or the clip to edit'] : null,\n      inputs.audio ? ['audio_url', 'WAV or MP3 URL', 'Audio for the clip to follow'] : null\n    ].filter(Boolean);\n  };\n\n  const VideoPageNext = ({ data }) => {\n    const { family, models, related, providers } = data;\n    const modes = [...models].sort((a, b) => MODE_ORDER.indexOf(a.variant) - MODE_ORDER.indexOf(b.variant));\n    const [variantId, setVariantId] = useState(() => {\n      const v = readParams().get('v');\n      return v && models.some(m => m.id === v) ? v : family.primary;\n    });\n    const [audio, setAudio] = useState('on');\n    const now = useNow();\n    const { catalog } = useCatalog();\n    const headerHeight = useHeaderHeight();\n    const primary = models.find(m => m.id === family.primary) || models[0];\n    const model = models.find(m => m.id === variantId) || primary;\n    const provider = providers[family.provider] || providers[model.provider];\n    const video = model.video || {};\n    const p = model.pricing || {};\n    const source = safeUrl(model.source);\n    const endpoints = (model.endpoints || []).filter(e => e.supported !== false);\n    const endpoint = endpoints.find(e => e.recommended) || endpoints[0];\n    const similar = (related && related.similar) || [];\n    const versions = (related && related.versions) || [];\n    const res = sortedResolutions(video);\n    const timed = timedDurations(video);\n    const ratios = video.aspectRatios || [];\n    const renders = [...(primary.media || [])].filter(item => item.type === 'video').sort(byVideoOrder);\n    const suite = renders.filter(item => VIDEO_SUITE.includes(item.prompt));\n    const [promptId, setPromptId] = useState(renders[0] ? renders[0].prompt : null);\n    const [opened, setOpened] = useState(null);\n    const render = renders.find(item => item.prompt === promptId) || renders[0];\n    const compared = suite.find(item => item.prompt === promptId) || suite[0];\n    const selectRender = item => setPromptId(item.prompt);\n    const selectMode = id => {\n      setVariantId(id);\n      writeParams({ v: id === family.primary ? null : id });\n    };\n    const sections = [compared ? ['compare', 'Same prompt'] : null, ['pricing', 'Pricing'], ['capabilities', 'Capabilities'], ['specs', 'Specs'], ['quickstart', 'Quickstart']].filter(Boolean);\n    const activeSection = useScrollSpy(sections.map(([id]) => id));\n    const sample = codeSamples(model, endpoint && endpoint.id).curl;\n    const figures = [\n      p.status === 'quoted' && p.fromPerSecond != null\n        ? __jsx(Figure, { key: \"price\", value: __jsx(__Fragment, null, p.toPerSecond > p.fromPerSecond ? __jsx('span', { className: \"vxn-unit is-lead\" ,}, \"from\") : null, usd(p.fromPerSecond)), label: \"per second of video\"   ,} )\n        : null,\n      res.length ? __jsx(Figure, { key: \"res\", value: heightLabel(maxVideoHeight(model)), label: `max resolution${res.length > 1 ? `, ${res.length} sizes` : ''}`,} ) : null,\n      timed.length ? __jsx(Figure, { key: \"length\", value: `${maxVideoSeconds(model)}s`, label: timed.length > 1 ? `longest clip, from ${minVideoSeconds(model)}s` : 'clip length',} ) : null\n    ].filter(Boolean);\n    const tiles = [\n      ...modes.map(m => ({ key: m.id, icon: MODE_ICONS[m.variant] || 'video', name: VARIANT_LABELS[m.variant] || m.variant, active: m.id === model.id && modes.length > 1,\n        detail: __jsx(__Fragment, null, __jsx('code', null, m.id), __jsx('br', null ), \"Takes \" , listText(videoInputList(m.video))) })),\n      { key: 'audio', icon: video.audio === 'none' ? 'mute' : 'volume', name: video.audio === 'none' ? 'Silent' : 'Audio', detail: video.audio === 'optional' ? __jsx('code', null, \"audio: true | false\"   ) : AUDIO_TEXT[video.audio] || 'None' }\n    ];\n\n    return (\n      __jsx('div', { className: \"vx vxn vxi vxv not-prose\"    , style: { '--vxn-header': `${headerHeight}px` },}\n        , __jsx(HoverTips, null )\n        , __jsx(NextTop, { scope: \"Video\", scopeHref: \"/models/video\", family: family, brief: videoBrief(family, modes, model, sample),} )\n\n        , __jsx('header', { className: \"vxn-hero vxv-hero\" ,}\n          , __jsx('div', { className: \"vxn-hero-main\",}\n            , __jsx('div', { className: \"vxn-provider\",}\n              , __jsx(ProviderLogo, { provider: provider, size: 22,} )\n              , __jsx('span', null, provider ? provider.name : family.provider)\n              , __jsx('span', { className: \"vxn-dot\",} )\n              , __jsx('span', null, fmtDate(model.created))\n              , isNew(model.created, now) ? __jsx(Tag, { tone: \"new\",}, \"New\") : null\n              , model.beta ? __jsx(Tag, { tone: \"beta\",}, \"Beta\") : null\n            )\n            , __jsx('h1', { className: \"vxn-h1\",}, family.name)\n            , __jsx('div', { className: \"vxn-meta\",}\n              , __jsx('span', { className: \"vxn-meta-id\",}, __jsx('code', null, model.id), __jsx(CopyButton, { text: model.id, iconOnly: true, label: `Copy model ID ${model.id}`,} ))\n              , PRIVACY[model.privacy] ? __jsx('span', { className: \"vxn-meta-item\",}, PRIVACY[model.privacy].label, __jsx(InfoTip, { text: PRIVACY[model.privacy].desc, size: 12,} )) : null\n              , model.openWeights ? (source\n                ? __jsx('a', { className: \"vxn-meta-item\", href: source, target: \"_blank\", rel: \"noopener noreferrer\" ,}, \"Open weights\" , __jsx(Icon, { name: \"external\", size: 12,} ))\n                : __jsx('span', { className: \"vxn-meta-item\",}, \"Open weights\" )) : null\n              , model.uncensored ? __jsx('span', { className: \"vxn-meta-item\",}, \"Uncensored\") : null\n            )\n            , model.description || family.description ? __jsx('p', { className: \"vxn-desc\",}, model.description || family.description) : null\n            , figures.length ? __jsx('div', { className: \"vxn-figs\",}, figures) : null\n            , modes.length > 1 ? (\n              __jsx('div', { className: \"vxn-variants vxv-modes\" ,}\n                , __jsx('span', { className: \"vxn-variants-label\",}, \"Mode\")\n                , __jsx('div', { className: \"vxn-switch\", role: \"radiogroup\", 'aria-label': \"Mode\",}\n                  , modes.map(m => (\n                    __jsx('button', { key: m.id, type: \"button\", role: \"radio\", 'aria-checked': m.id === model.id, className: cls(m.id === model.id && 'is-active'), onClick: () => selectMode(m.id),}, VARIANT_LABELS[m.variant] || m.variant)\n                  ))\n                )\n              )\n            ) : null\n            , __jsx('div', { className: \"vxn-ctas\",}\n              , __jsx('a', { className: \"vxn-btn is-primary\" , href: \"https://venice.ai/settings/api\", target: \"_blank\", rel: \"noopener noreferrer\" ,}, \"Get an API key\"   )\n              , __jsx('a', { className: \"vxn-textlink\", href: `https://venice.ai/studio/video?model=${encodeURIComponent(model.id)}`, target: \"_blank\", rel: \"noopener noreferrer\" ,}, \"Try in Venice\"  , __jsx(Icon, { name: \"arrowRight\", size: 14,} ))\n            )\n          )\n          , render ? (\n            __jsx('div', { className: \"vxv-hero-side\",}\n              , __jsx(RenderFeature, { item: render, onOpen: setOpened,} )\n              , renders.length > 1 ? __jsx(VideoThumbs, { items: renders, active: render, onSelect: selectRender,} ) : null\n            )\n          ) : null\n        )\n        , __jsx(Lightbox, { item: opened, onClose: () => setOpened(null),} )\n\n        , __jsx(NextNav, { title: family.name, sections: sections, active: activeSection,} )\n\n        , compared ? (\n          __jsx(NextSection, { id: \"compare\", title: \"Same prompt, other models\"   , lead: \"Every video model renders the same reference prompts, so their clips line up side by side. Hover a clip to play it.\"                     ,}\n            , __jsx(PromptCompare, { family: family, render: compared, renders: suite, onSelect: selectRender, catalog: catalog, similar: similar,\n              task: \"video\", noun: \"video models\" , priceOf: videoRate, Media: CompareVideo,} )\n          )\n        ) : null\n\n        , __jsx(NextSection, { id: \"pricing\", title: \"Pricing\", lead: p.status === 'quoted' ? 'Billed per clip in USD, by length and resolution. Each resolution is drawn to scale.' : 'Quoted per job.',}\n          , p.status === 'quoted' ? (\n            __jsx(__Fragment, null\n              , audioChangesPrice(model) ? (\n                __jsx('div', { className: \"vxv-audio\",}\n                  , __jsx(Segmented, { ariaLabel: \"Audio\", value: audio, onChange: setAudio, options: [{ value: 'on', label: 'With audio' }, { value: 'off', label: 'Silent' }],} )\n                )\n              ) : null\n              , __jsx(VideoPriceGrid, { model: model, render: suite[0] || render, audio: audio,} )\n              , __jsx('p', { className: \"vxn-caption\",}\n                , video.audio === 'optional' && !audioChangesPrice(model) ? 'Audio on or off costs the same. ' : video.audio === 'native' ? 'Every clip comes with audio. ' : '', \"Quoted from \"\n                  , __jsx('code', null, \"POST /video/quote\" ), p.quotedAt ? ` on ${fmtDate(Math.floor(new Date(p.quotedAt).getTime() / 1000))}` : '', \". Prices can change, so quote a job before you queue it.\"\n              )\n              , __jsx('div', { className: \"vxn-split vxn-gap\" ,}\n                , __jsx('div', null\n                  , __jsx('h3', { className: \"vxn-h3\",}, \"Estimate a batch\"  )\n                  , __jsx(VideoEstimator, { model: model, audio: audio, onAudio: setAudio,} )\n                )\n                , __jsx('div', null\n                  , __jsx('h3', { className: \"vxn-h3\",}, \"Against other video models\"   )\n                  , __jsx(Standing, { model: model, catalog: catalog, task: \"video\", noun: \"video models\" , metrics: VIDEO_STANDING, valuesOf: videoStandingValues,} )\n                )\n              )\n            )\n          ) : (\n            __jsx('p', { className: \"vx-text\",}\n              , p.status === 'input-dependent'\n                ? __jsx(__Fragment, null, \"This mode bills by the length of the source video. Call \"           , __jsx('code', null, \"POST /video/quote\" ), \" with your \"   , __jsx('code', null, \"video_url\"), \" for the price before you queue the job.\"        )\n                : __jsx(__Fragment, null, \"Call \" , __jsx('code', null, \"POST /video/quote\" ), \" for this mode's price before you queue a job.\"         )\n            )\n          )\n        )\n\n        , __jsx(NextSection, { id: \"capabilities\", title: \"Capabilities\", lead: modes.length > 1 ? `${modes.length} modes, each with its own model ID.` : 'What the model takes in and renders.',}\n          , __jsx('div', { className: \"vxn-tiles\",}\n            , tiles.map(tile => (\n              __jsx('div', { key: tile.key, className: cls('vxn-tile', tile.active && 'is-active'),}\n                , __jsx('span', { className: \"vxn-tile-icon\",}, __jsx(Icon, { name: tile.icon, size: 16,} ))\n                , __jsx('span', { className: \"vxn-tile-text\",}, __jsx('span', { className: \"vxn-tile-name\",}, tile.name), __jsx('span', { className: \"vxn-tile-detail\",}, tile.detail))\n              )\n            ))\n            , Array.from({ length: (3 - (tiles.length % 3)) % 3 }, (_, i) => __jsx('span', { key: `fill-${i}`, className: \"vxn-tile is-empty\" , 'aria-hidden': \"true\",} ))\n          )\n          , ratios.length ? (\n            __jsx(__Fragment, null\n              , __jsx('h3', { className: \"vxn-h3 vxn-gap\" ,}, \"Aspect ratios\" )\n              , __jsx('div', { className: \"vxi-ratios\",}, ratios.filter(r => /^\\d/.test(r)).map(ratio => __jsx(AspectShape, { key: ratio, ratio: ratio,} )))\n            )\n          ) : null\n        )\n\n        , __jsx(NextSection, { id: \"specs\", title: \"Specs\",}\n          , __jsx('dl', { className: \"vxn-sheet\",}\n            , [\n              ['Model ID', __jsx('code', null, model.id)],\n              modes.length > 1 ? ['Mode', VARIANT_LABELS[model.variant] || model.variant] : null,\n              endpoint ? ['Endpoint', __jsx('code', null, endpoint.method, \" /api/v1\" , endpoint.path)] : null,\n              res.length ? ['Resolutions', res.map(r => r.label).join(', ')] : null,\n              ['Lengths', timed.length ? durationText(video.durations) : 'Matches the source video'],\n              ['Aspect ratios', ratios.length ? ratios.join(', ') : 'Set by the input or the model'],\n              ['Audio', AUDIO_TEXT[video.audio] || 'None'],\n              ['Inputs', upperFirst(listText(videoInputList(video)))],\n              video.mode !== 'upscale' ? ['Prompt limit', `${count(video.promptLimit || 2500)} characters`] : null,\n              PRIVACY[model.privacy] ? ['Privacy', __jsx(__Fragment, null, PRIVACY[model.privacy].label, __jsx(InfoTip, { text: PRIVACY[model.privacy].desc,} ))] : null,\n              ['Weights', model.openWeights ? (source ? __jsx('a', { href: source, target: \"_blank\", rel: \"noopener noreferrer\" ,}, weightsName(source), __jsx(Icon, { name: \"external\", size: 12,} )) : 'Open') : 'Closed'],\n              ['Added', fmtDate(model.created)]\n            ].filter(Boolean).map(([label, value]) => __jsx('div', { key: label, className: \"vxn-sheet-row\",}, __jsx('dt', null, label), __jsx('dd', null, value)))\n          )\n          , versions.length ? __jsx(VersionTimeline, { family: family, versions: versions, created: model.created,} ) : null\n        )\n\n        , __jsx(NextSection, { id: \"quickstart\", title: \"Quickstart\", lead: \"Video is asynchronous: queue a job, then poll for the clip.\"          ,}\n          , __jsx(JobFlow, { base: \"/video\", noun: \"video\",} )\n          , __jsx(CodePanel, { model: model, endpoint: endpoint, endpoints: [],} )\n          , __jsx('h3', { className: \"vxn-h3 vxn-gap\" ,}, \"Parameters\")\n          , __jsx(ParamRows, { rows: videoParams(model),} )\n        )\n      )\n    );\n  };\n\n  /* ------------------------------------------------------------ embedding page, next */\n\n  // Each square of the vector grid stands for 64 dimensions, 16 to a row.\n  const VECTOR_CELL = 64;\n  const EMBEDDING_BATCH = 2048;\n  const EMBEDDING_STANDING = [\n    { key: 'price', label: 'Price', better: 'cheaper', lowerIsBetter: true, format: v => usd(v), tip: 'Per 1M input tokens.' },\n    { key: 'input', label: 'Max input', better: 'longer', lowerIsBetter: false, format: v => `${count(v)} tokens`, tip: 'Tokens per input string that Venice accepts.' }\n  ];\n  const embeddingStandingValues = model => ({ price: (model.pricing || {}).input, input: (model.embedding || {}).maxInputTokens });\n  const inputCapNote = e => (e.modelInputTokens\n    ? `The model reads up to ${count(e.modelInputTokens)} tokens, but Venice accepts up to ${count(e.maxInputTokens)} per input, estimated from its length: about 27,500 characters.`\n    : null);\n  const storageSize = n => (n >= 1e12 ? `${(n / 1e12).toFixed(1)} TB` : n >= 1e9 ? `${(n / 1e9).toFixed(1)} GB` : n >= 1e6 ? `${(n / 1e6).toFixed(1)} MB` : `${Math.max(1, Math.round(n / 1e3))} KB`);\n\n  // Everything an agent needs to embed with the model, as Markdown.\n  const embeddingBrief = (family, model, sample) => {\n    const e = model.embedding || {};\n    const p = model.pricing || {};\n    return [\n      `# ${family.name} on the Venice API`,\n      '',\n      `- Model ID: \\`${model.id}\\``,\n      `- Endpoint: \\`POST ${API}/embeddings\\`, OpenAI-compatible`,\n      '- Auth: `Authorization: Bearer $VENICE_API_KEY`, with a key from https://venice.ai/settings/api',\n      `- Price: ${usd(p.input)} per 1M input tokens`,\n      e.dimensions ? `- Dimensions: ${count(e.dimensions)}${e.customDimensions ? ', or fewer with `dimensions`' : ', fixed'}` : null,\n      `- Input: a string, or up to ${count(EMBEDDING_BATCH)} strings${e.maxInputTokens ? `, each up to ${count(e.maxInputTokens)} tokens` : ''}${e.modelInputTokens ? ` (Venice's cap, estimated from length; the model reads up to ${count(e.modelInputTokens)})` : ''}. Token-ID arrays are rejected, so set \\`check_embedding_ctx_length=False\\` on LangChain's \\`OpenAIEmbeddings\\``,\n      '- `encoding_format`: `float` (default) or `base64`, a smaller payload',\n      '- Similarities from different models are not comparable: store the model ID, and `dimensions` if set, with each vector',\n      PRIVACY[model.privacy] ? `- Privacy: ${PRIVACY[model.privacy].label}. ${PRIVACY[model.privacy].desc}` : null,\n      `- Docs: https://docs.venice.ai/models/${family.slug}`,\n      '',\n      '```bash',\n      sample,\n      '```'\n    ].filter(line => line != null).join('\\n');\n  };\n\n  // The vector drawn as squares of 64 dimensions; with a shorter size asked\n  // for, the squares past it fade.\n  const VectorGrid = ({ native, kept }) => (\n    __jsx('div', { className: \"vxe-grid\", role: \"img\", 'aria-label': `${count(kept)} of ${count(native)} dimensions`,}\n      , Array.from({ length: Math.ceil(native / VECTOR_CELL) }, (_, i) => __jsx('span', { key: i, className: cls(i * VECTOR_CELL < kept && 'is-on'),} ))\n    )\n  );\n\n  const VectorStorage = ({ model }) => {\n    const e = model.embedding || {};\n    const native = e.dimensions || 0;\n    const sizes = e.customDimensions ? [...new Set([256, 512, 1024, 2048].filter(d => d < native).concat(native))] : [native];\n    const [kept, setKept] = useState(native);\n    const [vectors, setVectors] = useState(1000000);\n    useEffect(() => setKept(native), [model.id]);\n    if (!native) return null;\n    return (\n      __jsx('div', { className: \"vxe-vector\",}\n        , __jsx(VectorGrid, { native: native, kept: kept,} )\n        , __jsx('p', { className: \"vxn-caption\",}, \"Each square is \"   , VECTOR_CELL, \" dimensions, and each row \"     , count(VECTOR_CELL * 16), \".\")\n        , __jsx('div', { className: \"vxn-est vxn-gap\" ,}\n          , __jsx('div', { className: \"vxi-est-controls\",}\n            , __jsx('label', { className: \"vxn-field\",}, __jsx('span', null, \"Vectors\"), __jsx('input', { type: \"number\", min: \"0\", step: \"100000\", value: vectors, onChange: ev => setVectors(Math.max(0, Math.round(Number(ev.target.value) || 0))),} ))\n            , sizes.length > 1 ? (\n              __jsx('div', { className: \"vxn-field\",}, __jsx('span', null, \"Dimensions\"), __jsx(Segmented, { ariaLabel: \"Dimensions\", value: kept, onChange: setKept, options: sizes.map(d => ({ value: d, label: count(d) })),} ))\n            ) : null\n          )\n          , __jsx('div', { className: \"vxn-est-result\", 'aria-live': \"polite\",}\n            , __jsx('div', null, __jsx('span', { className: \"vxn-est-value\",}, count(kept)), __jsx('span', { className: \"vx-muted\",}, kept < native ? `of ${count(native)} dimensions` : 'dimensions per vector'))\n            , __jsx('div', null, __jsx('span', { className: \"vxn-est-value is-total\" ,}, storageSize(vectors * kept * 4)), __jsx('span', { className: \"vx-muted\",}, \"for \" , count(vectors), \" vectors as float32\"   ))\n          )\n        )\n      )\n    );\n  };\n\n  const EmbeddingEstimator = ({ price }) => {\n    const [docs, setDocs] = useState(100000);\n    const [each, setEach] = useState(500);\n    const total = docs * each;\n    return (\n      __jsx('div', { className: \"vxn-est\",}\n        , __jsx('div', { className: \"vxi-est-controls\",}\n          , __jsx('label', { className: \"vxn-field\",}, __jsx('span', null, \"Documents\"), __jsx('input', { type: \"number\", min: \"0\", step: \"1000\", value: docs, onChange: ev => setDocs(Math.max(0, Math.round(Number(ev.target.value) || 0))),} ))\n          , __jsx('label', { className: \"vxn-field\",}, __jsx('span', null, \"Tokens each\" ), __jsx('input', { type: \"number\", min: \"0\", step: \"100\", value: each, onChange: ev => setEach(Math.max(0, Math.round(Number(ev.target.value) || 0))),} ))\n        )\n        , __jsx('div', { className: \"vxn-est-result\", 'aria-live': \"polite\",}\n          , __jsx('div', null, __jsx('span', { className: \"vxn-est-value\",}, tokens(total)), __jsx('span', { className: \"vx-muted\",}, \"tokens\"))\n          , __jsx('div', null, __jsx('span', { className: \"vxn-est-value is-total\" ,}, usd(price != null ? (price * total) / 1e6 : null)), __jsx('span', { className: \"vx-muted\",}, \"to embed them once\"   ))\n        )\n      )\n    );\n  };\n\n  // A model type has few enough models to list them all.\n  const TaskCompare = ({ model, catalog, includes, order, columns }) => {\n    const rows = useMemo(() => (catalog ? catalog.families\n      .filter(f => catalog.models[f.primary] && includes(catalog.models[f.primary]))\n      .map(f => ({ family: f, model: catalog.models[f.primary] }))\n      .sort((a, b) => order(a.model) - order(b.model) || a.family.name.localeCompare(b.family.name)) : []), [catalog]);\n    if (!rows.length) return null;\n    const cols = columns(rows.map(row => row.model));\n    return (\n      __jsx('div', { className: \"vx-table-wrap vxn-compare\" ,}\n        , __jsx('table', { className: \"vx-dtable\",}\n          , __jsx('thead', null, __jsx('tr', null, __jsx('th', null, \"Model\"), cols.map(c => __jsx('th', { key: c.label, className: cls(c.right && 'vx-al-right', c.hide && 'vx-hide-sm') || undefined,}, c.label))))\n          , __jsx('tbody', null\n            , rows.map(({ family, model: m }) => {\n              const current = m.id === model.id;\n              return (\n                __jsx('tr', { key: family.slug, className: cls(current && 'is-current'),}\n                  , __jsx('td', null, current ? __jsx('strong', null, family.name) : __jsx('a', { href: `/models/${family.slug}`,}, family.name))\n                  , cols.map(c => __jsx('td', { key: c.label, className: cls(c.right && 'vx-al-right vx-num', c.hide && 'vx-hide-sm') || undefined,}, c.render(m)))\n                )\n              );\n            })\n          )\n        )\n      )\n    );\n  };\n\n  const embeddingColumns = models => {\n    const most = Math.max(...models.map(m => (m.embedding || {}).dimensions || 0), 1);\n    return [\n      { label: 'Dimensions', render: m => {\n        const e = m.embedding || {};\n        return (\n          __jsx('span', { className: \"vxe-dims\",}, __jsx('span', { className: \"vxe-dims-track\",}, __jsx('span', { style: { width: `${((e.dimensions || 0) / most) * 100}%` },} ))\n            , __jsx('span', { className: \"vx-num\",}, e.dimensions ? count(e.dimensions) : '—'), e.customDimensions ? __jsx('span', { className: \"vx-muted vx-hide-sm\" ,}, \"or fewer\" ) : null)\n        );\n      } },\n      { label: 'Max input', right: true, hide: true, render: m => ((m.embedding || {}).maxInputTokens ? count(m.embedding.maxInputTokens) : '—') },\n      { label: 'Privacy', hide: true, render: m => (PRIVACY[m.privacy] ? PRIVACY[m.privacy].label : m.privacy) },\n      { label: 'Per 1M tokens', right: true, render: m => usd((m.pricing || {}).input) }\n    ];\n  };\n\n  const EmbeddingPageNext = ({ data }) => {\n    const { family, models, related, providers } = data;\n    const now = useNow();\n    const { catalog } = useCatalog();\n    const headerHeight = useHeaderHeight();\n    const model = models.find(m => m.id === family.primary) || models[0];\n    const provider = providers[family.provider] || providers[model.provider];\n    const e = model.embedding || {};\n    const p = model.pricing || {};\n    const source = safeUrl(model.source);\n    const endpoints = (model.endpoints || []).filter(ep => ep.supported !== false);\n    const endpoint = endpoints.find(ep => ep.recommended) || endpoints[0];\n    const versions = (related && related.versions) || [];\n    const sections = [['vectors', 'Vectors'], ['pricing', 'Pricing'], ['specs', 'Specs'], ['compare', 'Compare'], ['quickstart', 'Quickstart']];\n    const activeSection = useScrollSpy(sections.map(([id]) => id));\n    const sample = codeSamples(model, endpoint && endpoint.id).curl;\n    const capNote = inputCapNote(e);\n    const params = [\n      ['model', __jsx('code', null, model.id), 'Required'],\n      ['input', `A string, or up to ${count(EMBEDDING_BATCH)} strings`, e.maxInputTokens ? `Required, up to ${count(e.maxInputTokens)} tokens each` : 'Required'],\n      e.customDimensions ? ['dimensions', `Up to ${count(e.dimensions)}`, 'Returns a shorter vector'] : null,\n      ['encoding_format', __jsx('code', null, \"float | base64\"  ), 'Default float; base64 is a smaller payload']\n    ].filter(Boolean);\n\n    return (\n      __jsx('div', { className: \"vx vxn vxe not-prose\"   , style: { '--vxn-header': `${headerHeight}px` },}\n        , __jsx(HoverTips, null )\n        , __jsx(NextTop, { scope: \"Embeddings\", scopeHref: \"/models/embeddings\", family: family, brief: embeddingBrief(family, model, sample),} )\n\n        , __jsx('header', { className: \"vxn-hero\",}\n          , __jsx('div', { className: \"vxn-hero-main\",}\n            , __jsx('div', { className: \"vxn-provider\",}\n              , __jsx(ProviderLogo, { provider: provider, size: 22,} )\n              , __jsx('span', null, provider ? provider.name : family.provider)\n              , __jsx('span', { className: \"vxn-dot\",} )\n              , __jsx('span', null, fmtDate(model.created))\n              , isNew(model.created, now) ? __jsx(Tag, { tone: \"new\",}, \"New\") : null\n              , model.beta ? __jsx(Tag, { tone: \"beta\",}, \"Beta\") : null\n            )\n            , __jsx('h1', { className: \"vxn-h1\",}, family.name)\n            , __jsx('div', { className: \"vxn-meta\",}\n              , __jsx('span', { className: \"vxn-meta-id\",}, __jsx('code', null, model.id), __jsx(CopyButton, { text: model.id, iconOnly: true, label: `Copy model ID ${model.id}`,} ))\n              , PRIVACY[model.privacy] ? __jsx('span', { className: \"vxn-meta-item\",}, PRIVACY[model.privacy].label, __jsx(InfoTip, { text: PRIVACY[model.privacy].desc, size: 12,} )) : null\n              , model.openWeights ? (source\n                ? __jsx('a', { className: \"vxn-meta-item\", href: source, target: \"_blank\", rel: \"noopener noreferrer\" ,}, \"Open weights\" , __jsx(Icon, { name: \"external\", size: 12,} ))\n                : __jsx('span', { className: \"vxn-meta-item\",}, \"Open weights\" )) : null\n            )\n            , model.description || family.description ? __jsx('p', { className: \"vxn-desc\",}, model.description || family.description) : null\n            , __jsx('div', { className: \"vxn-figs\",}\n              , p.input != null ? __jsx(Figure, { value: usd(p.input), label: \"per 1M input tokens\"   ,} ) : null\n              , e.dimensions ? __jsx(Figure, { value: count(e.dimensions), label: e.customDimensions ? 'dimensions, or fewer' : 'dimensions',} ) : null\n              , e.maxInputTokens ? __jsx(Figure, { value: count(e.maxInputTokens), label: \"tokens per input\"  , tip: capNote,} ) : null\n            )\n            , __jsx('div', { className: \"vxn-ctas\",}\n              , __jsx('a', { className: \"vxn-btn is-primary\" , href: \"https://venice.ai/settings/api\", target: \"_blank\", rel: \"noopener noreferrer\" ,}, \"Get an API key\"   )\n              , __jsx('a', { className: \"vxn-textlink\", href: \"/guides/features/embeddings\",}, \"Embeddings guide\" , __jsx(Icon, { name: \"arrowRight\", size: 14,} ))\n            )\n          )\n          , __jsx('div', { className: \"vxn-hero-side\",}\n            , __jsx(Standing, { model: model, catalog: catalog, task: \"embedding\", noun: \"embedding models\" , metrics: EMBEDDING_STANDING, valuesOf: embeddingStandingValues,} )\n          )\n        )\n\n        , __jsx(NextNav, { title: family.name, sections: sections, active: activeSection,} )\n\n        , __jsx(NextSection, { id: \"vectors\", title: \"Vectors\", lead: `Each input comes back as ${count(e.dimensions || 0)} numbers${e.customDimensions ? ', or fewer when you ask for them with dimensions' : ''}. Stored as float32, each number takes 4 bytes.`,}\n          , __jsx(VectorStorage, { model: model,} )\n          , __jsx('p', { className: \"vxn-caption\",}, \"Similarities from different models aren't comparable, so store the model ID\"          , e.customDimensions ? ' and dimensions' : '', \" with each vector.\"   )\n        )\n\n        , __jsx(NextSection, { id: \"pricing\", title: \"Pricing\", lead: \"Billed per 1M input tokens, in USD.\"      ,}\n          , __jsx('div', { className: \"vxn-prices\",}\n            , __jsx('div', { className: \"vxn-price\",}, __jsx('span', { className: \"vxn-price-label\",}, \"Input\"), __jsx('span', { className: \"vxn-price-value\",}, usd(p.input)), __jsx('span', { className: \"vx-muted\",}, \"per 1M tokens\"  ))\n          )\n          , __jsx('h3', { className: \"vxn-h3 vxn-gap\" ,}, \"Estimate a corpus\"  )\n          , __jsx(EmbeddingEstimator, { price: p.input,} )\n        )\n\n        , __jsx(NextSection, { id: \"specs\", title: \"Specs\",}\n          , __jsx('dl', { className: \"vxn-sheet\",}\n            , [\n              ['Model ID', __jsx('code', null, model.id)],\n              endpoint ? ['Endpoint', __jsx('code', null, endpoint.method, \" /api/v1\" , endpoint.path)] : null,\n              e.dimensions ? ['Dimensions', e.customDimensions ? __jsx(__Fragment, null, count(e.dimensions), \", or fewer with \"    , __jsx('code', null, \"dimensions\")) : count(e.dimensions)] : null,\n              e.maxInputTokens ? ['Max input', __jsx(__Fragment, null, count(e.maxInputTokens), \" tokens per input\"   , capNote ? __jsx(InfoTip, { text: capNote,} ) : null)] : null,\n              ['Batch', `Up to ${count(EMBEDDING_BATCH)} inputs per request`],\n              ['Encodings', __jsx(__Fragment, null, __jsx('code', null, \"float\"), \" or \"  , __jsx('code', null, \"base64\"))],\n              ['Input', 'Text only'],\n              PRIVACY[model.privacy] ? ['Privacy', __jsx(__Fragment, null, PRIVACY[model.privacy].label, __jsx(InfoTip, { text: PRIVACY[model.privacy].desc,} ))] : null,\n              ['Weights', model.openWeights ? (source ? __jsx('a', { href: source, target: \"_blank\", rel: \"noopener noreferrer\" ,}, weightsName(source), __jsx(Icon, { name: \"external\", size: 12,} )) : 'Open') : 'Closed'],\n              ['Added', fmtDate(model.created)]\n            ].filter(Boolean).map(([label, value]) => __jsx('div', { key: label, className: \"vxn-sheet-row\",}, __jsx('dt', null, label), __jsx('dd', null, value)))\n          )\n          , versions.length ? __jsx(VersionTimeline, { family: family, versions: versions, created: model.created,} ) : null\n        )\n\n        , __jsx(NextSection, { id: \"compare\", title: \"Compare\", lead: \"Every embedding model on Venice, cheapest first.\"      ,}\n          , __jsx(TaskCompare, { model: model, catalog: catalog, includes: m => m.task === 'embedding', order: m => (m.pricing || {}).input || 0, columns: embeddingColumns,} )\n        )\n\n        , __jsx(NextSection, { id: \"quickstart\", title: \"Quickstart\", lead: \"OpenAI-compatible: point any OpenAI SDK at the Venice base URL with a Venice API key.\"              ,}\n          , __jsx(CodePanel, { model: model, endpoint: endpoint, endpoints: [],} )\n          , __jsx('h3', { className: \"vxn-h3 vxn-gap\" ,}, \"Parameters\")\n          , __jsx(ParamRows, { rows: params,} )\n          , __jsx('p', { className: \"vxn-callout\",}, __jsx(Icon, { name: \"info\", size: 14,} ), __jsx('span', null, \"LangChain's \" , __jsx('code', null, \"OpenAIEmbeddings\"), \" sends token IDs, which Venice rejects. Set \"        , __jsx('code', null, \"check_embedding_ctx_length=False\"), \".\"))\n        )\n      )\n    );\n  };\n\n  /* ------------------------------------------------------------ speech page, next */\n\n  // POST /audio/speech takes up to 4,096 characters of input per request.\n  const SPEECH_INPUT_CAP = 4096;\n  // 150 words a minute, the conversion the catalog's per-minute prices use.\n  const TTS_CHARS_PER_MINUTE = 825;\n  const SPEECH_STANDING = [\n    { key: 'price', label: 'Price', better: 'cheaper', lowerIsBetter: true, format: v => usd(v), tip: 'Per 1M characters of input.' },\n    { key: 'voices', label: 'Voices', better: 'more', lowerIsBetter: false, format: v => count(v) }\n  ];\n  const voiceCount = model => (model.audio || {}).voiceCount || ((model.audio || {}).voices || []).length || null;\n  const speechStandingValues = model => ({ price: (model.pricing || {}).per1MChars, voices: voiceCount(model) });\n  const speechColumns = () => [\n    { label: 'Voices', right: true, render: m => (voiceCount(m) ? count(voiceCount(m)) : '—') },\n    { label: 'Formats', hide: true, render: m => ((m.audio || {}).formats || []).join(', ') || '—' },\n    { label: 'Privacy', hide: true, render: m => (PRIVACY[m.privacy] ? PRIVACY[m.privacy].label : m.privacy) },\n    { label: 'Per 1M characters', right: true, render: m => usd((m.pricing || {}).per1MChars) }\n  ];\n\n  // Everything an agent needs to speak with the model, as Markdown.\n  const speechBrief = (family, model, sample) => {\n    const a = model.audio || {};\n    const p = model.pricing || {};\n    return [\n      `# ${family.name} on the Venice API`,\n      '',\n      `- Model ID: \\`${model.id}\\``,\n      a.async\n        ? `- Flow: \\`POST ${API}/audio/queue\\` with the text as \\`prompt\\` returns a \\`queue_id\\`; poll \\`POST ${API}/audio/retrieve\\` with the \\`model\\` and \\`queue_id\\` until it returns the audio. \\`POST ${API}/audio/quote\\` prices a job without charging for it.`\n        : `- Endpoint: \\`POST ${API}/audio/speech\\`, OpenAI-compatible; returns the audio`,\n      '- Auth: `Authorization: Bearer $VENICE_API_KEY`, with a key from https://venice.ai/settings/api',\n      `- Price: ${usd(p.per1MChars)} per 1M characters${p.perHour != null ? `, about ${usd(p.perHour)} per hour of speech at ${TTS_CHARS_PER_MINUTE} characters a minute` : ''}`,\n      (a.voices || []).length ? `- Voices (case-sensitive): ${a.voices.map(v => `\\`${v}\\``).join(', ')}${a.customVoice ? '; any ElevenLabs voice ID also works' : ''}` : null,\n      (a.formats || []).length ? `- Formats: ${a.formats.join(', ')}${a.defaultFormat ? `; default ${a.defaultFormat}` : ''}` : null,\n      a.async ? null : `- Input: up to ${count(SPEECH_INPUT_CAP)} characters per request; \\`streaming: true\\` streams the audio as it is generated`,\n      a.cloning ? `- Voice cloning: \\`POST ${API}/audio/voices\\` with a ${listText(a.cloning.formats)} sample of at least ${a.cloning.minSeconds} seconds returns a voice to pass as \\`voice\\`; it lasts ${a.cloning.retentionDays} days` : null,\n      PRIVACY[model.privacy] ? `- Privacy: ${PRIVACY[model.privacy].label}. ${PRIVACY[model.privacy].desc}` : null,\n      `- Docs: https://docs.venice.ai/models/${family.slug}`,\n      '',\n      '```bash',\n      sample,\n      '```'\n    ].filter(line => line != null).join('\\n');\n  };\n\n  // Voice names are case-sensitive; picking one rewrites the request.\n  const VoiceBoard = ({ voices, value, onPick, customVoice }) => {\n    const [query, setQuery] = useState('');\n    const shown = query ? voices.filter(v => v.toLowerCase().includes(query.trim().toLowerCase())) : voices;\n    return (\n      __jsx('div', { className: \"vxs-voices\",}\n        , __jsx('div', { className: \"vxn-standing-head\",}\n          , __jsx('span', { className: \"vxn-price-label\",}, count(voices.length), \" voices\" )\n          , voices.length > 16 ? __jsx('input', { className: \"vxs-voice-search\", type: \"search\", placeholder: \"Filter\", value: query, onChange: e => setQuery(e.target.value), 'aria-label': \"Filter voices\" ,} ) : null\n        )\n        , __jsx('div', { className: \"vxs-voice-list\", role: \"radiogroup\", 'aria-label': \"Voice\",}\n          , shown.map(v => __jsx('button', { key: v, type: \"button\", role: \"radio\", 'aria-checked': v === value, className: cls('vxs-voice', v === value && 'is-active'), onClick: () => onPick(v),}, v))\n          , shown.length ? null : __jsx('span', { className: \"vx-muted\",}, \"No voice matches.\"  )\n        )\n        , __jsx('p', { className: \"vxn-caption\",}, \"Names are case-sensitive.\"  , customVoice ? ' Any ElevenLabs voice ID works too.' : '', \" Pick one to use it in the request below.\"         )\n      )\n    );\n  };\n\n  const SpeechEstimator = ({ price }) => {\n    const [chars, setChars] = useState(100000);\n    return (\n      __jsx('div', { className: \"vxn-est\",}\n        , __jsx('div', { className: \"vxi-est-controls\",}\n          , __jsx('label', { className: \"vxn-field\",}, __jsx('span', null, \"Characters\"), __jsx('input', { type: \"number\", min: \"0\", step: \"10000\", value: chars, onChange: e => setChars(Math.max(0, Math.round(Number(e.target.value) || 0))),} ))\n        )\n        , __jsx('div', { className: \"vxn-est-result\", 'aria-live': \"polite\",}\n          , __jsx('div', null, __jsx('span', { className: \"vxn-est-value\",}, count(Math.round(chars / TTS_CHARS_PER_MINUTE)), \" min\" ), __jsx('span', { className: \"vx-muted\",}, \"of speech, estimated\"  ))\n          , __jsx('div', null, __jsx('span', { className: \"vxn-est-value is-total\" ,}, usd(price != null ? (price * chars) / 1e6 : null)), __jsx('span', { className: \"vx-muted\",}, \"to speak them\"  ))\n        )\n      )\n    );\n  };\n\n  const SpeechPageNext = ({ data }) => {\n    const { family, models, related, providers } = data;\n    const now = useNow();\n    const { catalog } = useCatalog();\n    const headerHeight = useHeaderHeight();\n    const model = models.find(m => m.id === family.primary) || models[0];\n    const provider = providers[family.provider] || providers[model.provider];\n    const a = model.audio || {};\n    const p = model.pricing || {};\n    const voices = a.voices || [];\n    const [voice, setVoice] = useState(voices[0] || null);\n    const source = safeUrl(model.source);\n    const endpoints = (model.endpoints || []).filter(ep => ep.supported !== false);\n    const endpoint = endpoints.find(ep => ep.recommended) || endpoints[0];\n    const versions = (related && related.versions) || [];\n    const sections = [['capabilities', 'Capabilities'], ['pricing', 'Pricing'], ['specs', 'Specs'], ['compare', 'Compare'], ['quickstart', 'Quickstart']];\n    const activeSection = useScrollSpy(sections.map(([id]) => id));\n    const options = { voice: voice || undefined };\n    const sample = codeSamples(model, endpoint && endpoint.id, options).curl;\n    const perHourTip = `Estimated at ${TTS_CHARS_PER_MINUTE} characters a minute, about 150 spoken words.`;\n    const params = a.async ? [\n      ['model', __jsx('code', null, model.id), 'Required'],\n      ['prompt', 'The text to speak', 'Required'],\n      voices.length ? ['voice', `${count(voices.length)} voices${a.customVoice ? ', or a voice ID' : ''}`, \"The model's own by default\"] : null\n    ].filter(Boolean) : [\n      ['model', __jsx('code', null, model.id), 'Required'],\n      ['input', `Up to ${count(SPEECH_INPUT_CAP)} characters`, 'Required'],\n      voices.length ? ['voice', `${count(voices.length)} voices${a.customVoice ? ', or a voice ID' : ''}`, \"The model's own by default\"] : null,\n      (a.formats || []).length ? ['response_format', __jsx('code', null, a.formats.join(' | ')), a.defaultFormat ? `Default ${a.defaultFormat}` : null] : null,\n      ['speed', __jsx('code', null, \"0.25 – 4.0\"  ), 'Some models clamp it or ignore it'],\n      ['streaming', __jsx('code', null, \"true | false\"  ), 'Streams the audio as it is generated']\n    ].filter(Boolean);\n    const tiles = [\n      (a.formats || []).length ? { key: 'formats', icon: 'music', name: 'Formats', detail: __jsx(__Fragment, null, a.formats.map(f => __jsx('code', { key: f,}, f)).reduce((acc, el) => (acc.length ? [...acc, ' · ', el] : [el]), []), a.defaultFormat ? `, ${a.defaultFormat} by default` : '') } : null,\n      a.async ? { key: 'queue', icon: 'clock', name: 'Queued', detail: 'Quote, queue and retrieve, like music' } : { key: 'stream', icon: 'activity', name: 'Streaming', detail: __jsx('code', null, \"streaming: true\" ) },\n      a.async ? null : { key: 'openai', icon: 'code', name: 'OpenAI-compatible', detail: __jsx('code', null, \"client.audio.speech.create()\") },\n      a.customVoice ? { key: 'custom', icon: 'mic', name: 'Any ElevenLabs voice', detail: 'Pass its voice ID as voice' } : null,\n      a.cloning ? { key: 'clone', icon: 'mic', name: 'Voice cloning', detail: __jsx(__Fragment, null, __jsx('code', null, \"POST /audio/voices\" ), __jsx('br', null ), \"A \" , a.cloning.minSeconds, \"s+ sample; the voice lasts \"     , a.cloning.retentionDays, \" days\" ) } : null\n    ].filter(Boolean);\n\n    return (\n      __jsx('div', { className: \"vx vxn vxs not-prose\"   , style: { '--vxn-header': `${headerHeight}px` },}\n        , __jsx(HoverTips, null )\n        , __jsx(NextTop, { scope: \"Text to speech\"  , scopeHref: \"/models/text-to-speech\", family: family, brief: speechBrief(family, model, sample),} )\n\n        , __jsx('header', { className: \"vxn-hero\",}\n          , __jsx('div', { className: \"vxn-hero-main\",}\n            , __jsx('div', { className: \"vxn-provider\",}\n              , __jsx(ProviderLogo, { provider: provider, size: 22,} )\n              , __jsx('span', null, provider ? provider.name : family.provider)\n              , __jsx('span', { className: \"vxn-dot\",} )\n              , __jsx('span', null, fmtDate(model.created))\n              , isNew(model.created, now) ? __jsx(Tag, { tone: \"new\",}, \"New\") : null\n              , model.beta ? __jsx(Tag, { tone: \"beta\",}, \"Beta\") : null\n            )\n            , __jsx('h1', { className: \"vxn-h1\",}, family.name)\n            , __jsx('div', { className: \"vxn-meta\",}\n              , __jsx('span', { className: \"vxn-meta-id\",}, __jsx('code', null, model.id), __jsx(CopyButton, { text: model.id, iconOnly: true, label: `Copy model ID ${model.id}`,} ))\n              , PRIVACY[model.privacy] ? __jsx('span', { className: \"vxn-meta-item\",}, PRIVACY[model.privacy].label, __jsx(InfoTip, { text: PRIVACY[model.privacy].desc, size: 12,} )) : null\n              , model.openWeights ? (source\n                ? __jsx('a', { className: \"vxn-meta-item\", href: source, target: \"_blank\", rel: \"noopener noreferrer\" ,}, \"Open weights\" , __jsx(Icon, { name: \"external\", size: 12,} ))\n                : __jsx('span', { className: \"vxn-meta-item\",}, \"Open weights\" )) : null\n            )\n            , model.description || family.description ? __jsx('p', { className: \"vxn-desc\",}, model.description || family.description) : null\n            , __jsx('div', { className: \"vxn-figs\",}\n              , p.per1MChars != null ? __jsx(Figure, { value: usd(p.per1MChars), label: \"per 1M characters\"  ,} ) : null\n              , p.perHour != null ? __jsx(Figure, { value: usd(p.perHour), label: \"per hour of speech\"   , tip: perHourTip,} ) : null\n              , voices.length ? __jsx(Figure, { value: count(voices.length), label: a.customVoice ? 'voices, or any voice ID' : 'voices',} ) : null\n            )\n            , __jsx('div', { className: \"vxn-ctas\",}\n              , __jsx('a', { className: \"vxn-btn is-primary\" , href: \"https://venice.ai/settings/api\", target: \"_blank\", rel: \"noopener noreferrer\" ,}, \"Get an API key\"   )\n            )\n          )\n          , voices.length ? (\n            __jsx('div', { className: \"vxn-hero-side\",}\n              , __jsx(VoiceBoard, { voices: voices, value: voice, onPick: setVoice, customVoice: a.customVoice,} )\n            )\n          ) : null\n        )\n\n        , __jsx(NextNav, { title: family.name, sections: sections, active: activeSection,} )\n\n        , __jsx(NextSection, { id: \"capabilities\", title: \"Capabilities\",}\n          , __jsx('div', { className: \"vxn-tiles\",}\n            , tiles.map(tile => (\n              __jsx('div', { key: tile.key, className: \"vxn-tile\",}\n                , __jsx('span', { className: \"vxn-tile-icon\",}, __jsx(Icon, { name: tile.icon, size: 16,} ))\n                , __jsx('span', { className: \"vxn-tile-text\",}, __jsx('span', { className: \"vxn-tile-name\",}, tile.name), __jsx('span', { className: \"vxn-tile-detail\",}, tile.detail))\n              )\n            ))\n            , Array.from({ length: (3 - (tiles.length % 3)) % 3 }, (_, i) => __jsx('span', { key: `fill-${i}`, className: \"vxn-tile is-empty\" , 'aria-hidden': \"true\",} ))\n          )\n        )\n\n        , __jsx(NextSection, { id: \"pricing\", title: \"Pricing\", lead: \"Billed per 1M characters of input, in USD.\"       ,}\n          , __jsx('div', { className: \"vxn-prices\",}\n            , __jsx('div', { className: \"vxn-price\",}, __jsx('span', { className: \"vxn-price-label\",}, \"Input\"), __jsx('span', { className: \"vxn-price-value\",}, usd(p.per1MChars)), __jsx('span', { className: \"vx-muted\",}, \"per 1M characters\"  ))\n            , p.perMinute != null ? __jsx('div', { className: \"vxn-price\",}, __jsx('span', { className: \"vxn-price-label\",}, \"Speech, about\" ), __jsx('span', { className: \"vxn-price-value\",}, usd(p.perMinute)), __jsx('span', { className: \"vx-muted\",}, \"per minute\" )) : null\n            , p.perHour != null ? __jsx('div', { className: \"vxn-price\",}, __jsx('span', { className: \"vxn-price-label\",}, \"Speech, about\" ), __jsx('span', { className: \"vxn-price-value\",}, usd(p.perHour)), __jsx('span', { className: \"vx-muted\",}, \"per hour\" )) : null\n          )\n          , __jsx('p', { className: \"vxn-caption\",}, perHourTip)\n          , __jsx('div', { className: \"vxn-split vxn-gap\" ,}\n            , __jsx('div', null\n              , __jsx('h3', { className: \"vxn-h3\",}, \"Estimate a script\"  )\n              , __jsx(SpeechEstimator, { price: p.per1MChars,} )\n            )\n            , __jsx('div', null\n              , __jsx('h3', { className: \"vxn-h3\",}, \"Against other speech models\"   )\n              , __jsx(Standing, { model: model, catalog: catalog, task: \"tts\", noun: \"speech models\" , metrics: SPEECH_STANDING, valuesOf: speechStandingValues,} )\n            )\n          )\n        )\n\n        , __jsx(NextSection, { id: \"specs\", title: \"Specs\",}\n          , __jsx('dl', { className: \"vxn-sheet\",}\n            , [\n              ['Model ID', __jsx('code', null, model.id)],\n              endpoint ? ['Endpoint', __jsx('code', null, endpoint.method, \" /api/v1\" , endpoint.path)] : null,\n              voices.length ? ['Voices', `${count(voices.length)}${a.customVoice ? ', or any ElevenLabs voice ID' : ''}`] : null,\n              (a.formats || []).length ? ['Formats', `${a.formats.join(', ')}${a.defaultFormat ? ` · default ${a.defaultFormat}` : ''}`] : null,\n              a.async ? null : ['Input', `Up to ${count(SPEECH_INPUT_CAP)} characters per request`],\n              ['Streaming', a.async ? 'No, it runs as a queued job' : 'Yes'],\n              ['Voice cloning', a.cloning ? `Yes, kept ${a.cloning.retentionDays} days` : 'No'],\n              PRIVACY[model.privacy] ? ['Privacy', __jsx(__Fragment, null, PRIVACY[model.privacy].label, __jsx(InfoTip, { text: PRIVACY[model.privacy].desc,} ))] : null,\n              ['Weights', model.openWeights ? (source ? __jsx('a', { href: source, target: \"_blank\", rel: \"noopener noreferrer\" ,}, weightsName(source), __jsx(Icon, { name: \"external\", size: 12,} )) : 'Open') : 'Closed'],\n              ['Added', fmtDate(model.created)]\n            ].filter(Boolean).map(([label, value]) => __jsx('div', { key: label, className: \"vxn-sheet-row\",}, __jsx('dt', null, label), __jsx('dd', null, value)))\n          )\n          , versions.length ? __jsx(VersionTimeline, { family: family, versions: versions, created: model.created,} ) : null\n        )\n\n        , __jsx(NextSection, { id: \"compare\", title: \"Compare\", lead: \"Every text-to-speech model on Venice, cheapest first.\"      ,}\n          , __jsx(TaskCompare, { model: model, catalog: catalog, includes: m => m.task === 'tts', order: m => (m.pricing || {}).per1MChars || 0, columns: speechColumns,} )\n        )\n\n        , __jsx(NextSection, { id: \"quickstart\", title: \"Quickstart\", lead: a.async ? 'This model runs as a queued job: queue the text, then poll for the audio.' : 'OpenAI-compatible: point any OpenAI SDK at the Venice base URL with a Venice API key.',}\n          , a.async ? __jsx(JobFlow, { base: \"/audio\", noun: \"audio\",} ) : null\n          , __jsx(CodePanel, { model: model, endpoint: endpoint, endpoints: [], options: options,} )\n          , __jsx('h3', { className: \"vxn-h3 vxn-gap\" ,}, \"Parameters\")\n          , __jsx(ParamRows, { rows: params,} )\n        )\n      )\n    );\n  };\n\n  /* ------------------------------------------------------------ transcription page, next */\n\n  // POST /audio/transcriptions takes one file of up to 25 MB in these containers.\n  const STT_FILE_CAP = 25 * 1024 * 1024;\n  const STT_FORMATS = ['wav', 'flac', 'm4a', 'aac', 'mp4', 'mp3', 'ogg', 'webm'];\n  const FIT_BITRATES = [\n    ['Opus in OGG or WebM', '32 kbps', 32],\n    ['M4A or AAC', '64 kbps', 64],\n    ['MP3', '128 kbps', 128],\n    ['WAV', '16 kHz mono', 256],\n    ['WAV', '44.1 kHz stereo', 1411]\n  ];\n  const TRANSCRIPTION_STANDING = [\n    { key: 'price', label: 'Price', better: 'cheaper', lowerIsBetter: true, format: v => usd(v), tip: 'Per hour of audio.' }\n  ];\n  const transcriptionStandingValues = model => ({ price: (model.pricing || {}).perHour });\n  const transcriptionColumns = () => [\n    { label: 'Privacy', render: m => (PRIVACY[m.privacy] ? PRIVACY[m.privacy].label : m.privacy) },\n    { label: 'Per minute', right: true, hide: true, render: m => usd((m.pricing || {}).perMinute) },\n    { label: 'Per hour', right: true, render: m => usd((m.pricing || {}).perHour) }\n  ];\n\n  // Everything an agent needs to transcribe with the model, as Markdown.\n  const transcriptionBrief = (family, model, sample) => {\n    const p = model.pricing || {};\n    return [\n      `# ${family.name} on the Venice API`,\n      '',\n      `- Model ID: \\`${model.id}\\``,\n      `- Endpoint: \\`POST ${API}/audio/transcriptions\\`, OpenAI-compatible, \\`multipart/form-data\\` with the audio as \\`file\\``,\n      '- Auth: `Authorization: Bearer $VENICE_API_KEY`, with a key from https://venice.ai/settings/api',\n      `- Price: ${usd(p.perHour)} per hour of audio (${usd(p.perMinute)} per minute); failed transcriptions are not charged`,\n      `- File: ${STT_FORMATS.join(', ')}, up to 25 MB; split longer recordings and send each part`,\n      '- `response_format`: `json` (default) or `text`; `timestamps: true` adds word or segment times to the JSON; there is no SRT or VTT output',\n      '- `language`: an ISO 639-1 hint such as `en`; some models detect the language themselves',\n      PRIVACY[model.privacy] ? `- Privacy: ${PRIVACY[model.privacy].label}. ${PRIVACY[model.privacy].desc}` : null,\n      `- Docs: https://docs.venice.ai/models/${family.slug}`,\n      '',\n      '```bash',\n      sample,\n      '```'\n    ].filter(line => line != null).join('\\n');\n  };\n\n  // How long a recording fits in one upload at common bitrates.\n  const FileFit = () => {\n    const rows = FIT_BITRATES.map(([name, note, kbps]) => ({ name, note, minutes: (STT_FILE_CAP * 8) / (kbps * 1000) / 60 }));\n    const most = Math.max(...rows.map(row => row.minutes));\n    return (\n      __jsx('div', { className: \"vxt-fit\",}\n        , __jsx('div', { className: \"vxn-standing-head\",}\n          , __jsx('span', { className: \"vxn-price-label\",}, \"One file, up to 25 MB\"     )\n          , __jsx('span', { className: \"vx-muted\",}, \"minutes of audio\"  )\n        )\n        , rows.map(row => (\n          __jsx('div', { key: `${row.name} ${row.note}`, className: \"vxt-fit-row\",}\n            , __jsx('span', { className: \"vxt-fit-name\",}, row.name, __jsx('span', { className: \"vx-muted\",}, row.note))\n            , __jsx('span', { className: \"vxt-fit-track\",}, __jsx('span', { style: { width: `${(row.minutes / most) * 100}%` },} ))\n            , __jsx('span', { className: \"vxt-fit-value\",}, row.minutes >= 10 ? Math.round(row.minutes) : row.minutes.toFixed(1))\n          )\n        ))\n        , __jsx('p', { className: \"vxn-caption\",}, \"Split a longer recording and send each part.\"       )\n      )\n    );\n  };\n\n  const TranscriptionEstimator = ({ perHour }) => {\n    const [hours, setHours] = useState(100);\n    return (\n      __jsx('div', { className: \"vxn-est\",}\n        , __jsx('div', { className: \"vxi-est-controls\",}\n          , __jsx('label', { className: \"vxn-field\",}, __jsx('span', null, \"Hours of audio\"  ), __jsx('input', { type: \"number\", min: \"0\", step: \"10\", value: hours, onChange: e => setHours(Math.max(0, Number(e.target.value) || 0)),} ))\n        )\n        , __jsx('div', { className: \"vxn-est-result\", 'aria-live': \"polite\",}\n          , __jsx('div', null, __jsx('span', { className: \"vxn-est-value\",}, count(Math.round(hours * 60)), \" min\" ), __jsx('span', { className: \"vx-muted\",}, \"of audio\" ))\n          , __jsx('div', null, __jsx('span', { className: \"vxn-est-value is-total\" ,}, usd(perHour != null ? perHour * hours : null)), __jsx('span', { className: \"vx-muted\",}, \"to transcribe it\"  ))\n        )\n      )\n    );\n  };\n\n  const TranscriptionPageNext = ({ data }) => {\n    const { family, models, related, providers } = data;\n    const now = useNow();\n    const { catalog } = useCatalog();\n    const headerHeight = useHeaderHeight();\n    const model = models.find(m => m.id === family.primary) || models[0];\n    const provider = providers[family.provider] || providers[model.provider];\n    const p = model.pricing || {};\n    const source = safeUrl(model.source);\n    const endpoints = (model.endpoints || []).filter(ep => ep.supported !== false);\n    const endpoint = endpoints.find(ep => ep.recommended) || endpoints[0];\n    const versions = (related && related.versions) || [];\n    const sections = [['capabilities', 'Capabilities'], ['pricing', 'Pricing'], ['specs', 'Specs'], ['compare', 'Compare'], ['quickstart', 'Quickstart']];\n    const activeSection = useScrollSpy(sections.map(([id]) => id));\n    const sample = codeSamples(model, endpoint && endpoint.id).curl;\n    const params = [\n      ['file', STT_FORMATS.join(', '), 'Required, up to 25 MB'],\n      ['model', __jsx('code', null, model.id), 'Required'],\n      ['response_format', __jsx('code', null, \"json | text\"  ), 'Default json'],\n      ['timestamps', __jsx('code', null, \"true | false\"  ), 'Adds word or segment times to the JSON'],\n      ['language', 'An ISO 639-1 code, such as en', 'A hint; some models detect it themselves']\n    ];\n    const tiles = [\n      { key: 'formats', icon: 'music', name: 'Formats', detail: STT_FORMATS.join(' · ') },\n      { key: 'times', icon: 'clock', name: 'Timestamps', detail: __jsx('code', null, \"timestamps: true\" ) },\n      { key: 'lang', icon: 'globe', name: 'Language hint', detail: __jsx('code', null, \"language: \\\"en\\\"\" ) },\n      { key: 'openai', icon: 'code', name: 'OpenAI-compatible', detail: __jsx('code', null, \"client.audio.transcriptions.create()\") },\n      { key: 'subs', icon: 'text', name: 'Subtitles', detail: 'Build them from timestamps; there is no SRT or VTT output' },\n      { key: 'refund', icon: 'check', name: 'Failures are free', detail: 'A failed transcription is not charged' }\n    ];\n\n    return (\n      __jsx('div', { className: \"vx vxn vxt not-prose\"   , style: { '--vxn-header': `${headerHeight}px` },}\n        , __jsx(HoverTips, null )\n        , __jsx(NextTop, { scope: \"Speech to text\"  , scopeHref: \"/models/speech-to-text\", family: family, brief: transcriptionBrief(family, model, sample),} )\n\n        , __jsx('header', { className: \"vxn-hero\",}\n          , __jsx('div', { className: \"vxn-hero-main\",}\n            , __jsx('div', { className: \"vxn-provider\",}\n              , __jsx(ProviderLogo, { provider: provider, size: 22,} )\n              , __jsx('span', null, provider ? provider.name : family.provider)\n              , __jsx('span', { className: \"vxn-dot\",} )\n              , __jsx('span', null, fmtDate(model.created))\n              , isNew(model.created, now) ? __jsx(Tag, { tone: \"new\",}, \"New\") : null\n              , model.beta ? __jsx(Tag, { tone: \"beta\",}, \"Beta\") : null\n            )\n            , __jsx('h1', { className: \"vxn-h1\",}, family.name)\n            , __jsx('div', { className: \"vxn-meta\",}\n              , __jsx('span', { className: \"vxn-meta-id\",}, __jsx('code', null, model.id), __jsx(CopyButton, { text: model.id, iconOnly: true, label: `Copy model ID ${model.id}`,} ))\n              , PRIVACY[model.privacy] ? __jsx('span', { className: \"vxn-meta-item\",}, PRIVACY[model.privacy].label, __jsx(InfoTip, { text: PRIVACY[model.privacy].desc, size: 12,} )) : null\n              , model.openWeights ? (source\n                ? __jsx('a', { className: \"vxn-meta-item\", href: source, target: \"_blank\", rel: \"noopener noreferrer\" ,}, \"Open weights\" , __jsx(Icon, { name: \"external\", size: 12,} ))\n                : __jsx('span', { className: \"vxn-meta-item\",}, \"Open weights\" )) : null\n            )\n            , model.description || family.description ? __jsx('p', { className: \"vxn-desc\",}, model.description || family.description) : null\n            , __jsx('div', { className: \"vxn-figs\",}\n              , p.perHour != null ? __jsx(Figure, { value: usd(p.perHour), label: \"per hour of audio\"   ,} ) : null\n              , p.perMinute != null ? __jsx(Figure, { value: usd(p.perMinute), label: \"per minute\" ,} ) : null\n              , __jsx(Figure, { value: \"25 MB\" , label: \"per file\" ,} )\n            )\n            , __jsx('div', { className: \"vxn-ctas\",}\n              , __jsx('a', { className: \"vxn-btn is-primary\" , href: \"https://venice.ai/settings/api\", target: \"_blank\", rel: \"noopener noreferrer\" ,}, \"Get an API key\"   )\n            )\n          )\n          , __jsx('div', { className: \"vxn-hero-side\",}\n            , __jsx(FileFit, null )\n          )\n        )\n\n        , __jsx(NextNav, { title: family.name, sections: sections, active: activeSection,} )\n\n        , __jsx(NextSection, { id: \"capabilities\", title: \"Capabilities\",}\n          , __jsx('div', { className: \"vxn-tiles\",}\n            , tiles.map(tile => (\n              __jsx('div', { key: tile.key, className: \"vxn-tile\",}\n                , __jsx('span', { className: \"vxn-tile-icon\",}, __jsx(Icon, { name: tile.icon, size: 16,} ))\n                , __jsx('span', { className: \"vxn-tile-text\",}, __jsx('span', { className: \"vxn-tile-name\",}, tile.name), __jsx('span', { className: \"vxn-tile-detail\",}, tile.detail))\n              )\n            ))\n          )\n        )\n\n        , __jsx(NextSection, { id: \"pricing\", title: \"Pricing\", lead: \"Billed per second of audio, in USD.\"      ,}\n          , __jsx('div', { className: \"vxn-prices\",}\n            , p.perHour != null ? __jsx('div', { className: \"vxn-price\",}, __jsx('span', { className: \"vxn-price-label\",}, \"Per hour\" ), __jsx('span', { className: \"vxn-price-value\",}, usd(p.perHour)), __jsx('span', { className: \"vx-muted\",}, \"of audio\" )) : null\n            , p.perMinute != null ? __jsx('div', { className: \"vxn-price\",}, __jsx('span', { className: \"vxn-price-label\",}, \"Per minute\" ), __jsx('span', { className: \"vxn-price-value\",}, usd(p.perMinute)), __jsx('span', { className: \"vx-muted\",}, \"of audio\" )) : null\n            , p.perSecond != null ? __jsx('div', { className: \"vxn-price\",}, __jsx('span', { className: \"vxn-price-label\",}, \"Per second\" ), __jsx('span', { className: \"vxn-price-value\",}, usd(p.perSecond)), __jsx('span', { className: \"vx-muted\",}, \"as billed\" )) : null\n          )\n          , __jsx('div', { className: \"vxn-split vxn-gap\" ,}\n            , __jsx('div', null\n              , __jsx('h3', { className: \"vxn-h3\",}, \"Estimate an archive\"  )\n              , __jsx(TranscriptionEstimator, { perHour: p.perHour,} )\n            )\n            , __jsx('div', null\n              , __jsx('h3', { className: \"vxn-h3\",}, \"Against other transcription models\"   )\n              , __jsx(Standing, { model: model, catalog: catalog, task: \"stt\", noun: \"transcription models\" , metrics: TRANSCRIPTION_STANDING, valuesOf: transcriptionStandingValues,} )\n            )\n          )\n        )\n\n        , __jsx(NextSection, { id: \"specs\", title: \"Specs\",}\n          , __jsx('dl', { className: \"vxn-sheet\",}\n            , [\n              ['Model ID', __jsx('code', null, model.id)],\n              endpoint ? ['Endpoint', __jsx('code', null, endpoint.method, \" /api/v1\" , endpoint.path)] : null,\n              ['Formats', STT_FORMATS.join(', ')],\n              ['File', 'Up to 25 MB, sent as multipart'],\n              ['Output', __jsx(__Fragment, null, __jsx('code', null, \"json\"), \" or \"  , __jsx('code', null, \"text\"))],\n              ['Timestamps', 'Word or segment, depending on the model'],\n              PRIVACY[model.privacy] ? ['Privacy', __jsx(__Fragment, null, PRIVACY[model.privacy].label, __jsx(InfoTip, { text: PRIVACY[model.privacy].desc,} ))] : null,\n              ['Weights', model.openWeights ? (source ? __jsx('a', { href: source, target: \"_blank\", rel: \"noopener noreferrer\" ,}, weightsName(source), __jsx(Icon, { name: \"external\", size: 12,} )) : 'Open') : 'Closed'],\n              ['Added', fmtDate(model.created)]\n            ].filter(Boolean).map(([label, value]) => __jsx('div', { key: label, className: \"vxn-sheet-row\",}, __jsx('dt', null, label), __jsx('dd', null, value)))\n          )\n          , versions.length ? __jsx(VersionTimeline, { family: family, versions: versions, created: model.created,} ) : null\n        )\n\n        , __jsx(NextSection, { id: \"compare\", title: \"Compare\", lead: \"Every speech-to-text model on Venice, cheapest first.\"      ,}\n          , __jsx(TaskCompare, { model: model, catalog: catalog, includes: m => m.task === 'stt', order: m => (m.pricing || {}).perHour || 0, columns: transcriptionColumns,} )\n        )\n\n        , __jsx(NextSection, { id: \"quickstart\", title: \"Quickstart\", lead: \"OpenAI-compatible: send the recording as a multipart file to the Venice base URL with a Venice API key.\"                 ,}\n          , __jsx(CodePanel, { model: model, endpoint: endpoint, endpoints: [],} )\n          , __jsx('h3', { className: \"vxn-h3 vxn-gap\" ,}, \"Parameters\")\n          , __jsx(ParamRows, { rows: params,} )\n        )\n      )\n    );\n  };\n\n  /* ------------------------------------------------------------ music and sound page, next */\n\n  const lengthText = s => (s < 60 ? `${s}s` : s % 60 === 0 ? `${s / 60} min` : `${Math.floor(s / 60)}:${String(s % 60).padStart(2, '0')}`);\n  // The lengths a job can ask for: listed options, a range, or, for the voice\n  // changer, the length of the source it accepts.\n  const soundLengths = a => (a.durationOptions ? { options: a.durationOptions, min: Math.min(...a.durationOptions), max: Math.max(...a.durationOptions) }\n    : a.voiceChanger && a.maxSourceSeconds ? { min: 1, max: a.maxSourceSeconds }\n      : a.maxDuration ? { min: a.minDuration || 1, max: a.maxDuration } : null);\n  const soundPrice = (p, seconds) => {\n    const value = p.kind === 'tiered' ? ((p.tiers || []).find(t => seconds <= t.upTo) || {}).usd\n      : p.kind === 'per-second' && p.perSecond != null ? p.perSecond * seconds\n        : p.kind === 'per-track' ? p.perTrack : null;\n    return value == null ? null : value;\n  };\n  // Tiers a minute wide charge by the started minute; others by length option.\n  const byMinute = p => p.kind === 'tiered' && (p.tiers || []).every((t, i, list) => t.upTo - (i ? list[i - 1].upTo : 0) === 60);\n  const isSfxModel = model => model.task === 'sfx';\n  const axisUsd = v => (v === 0 ? '$0' : usd(v));\n  const soundRate = p => (p.kind === 'per-track' ? `${usd(p.perTrack)} / track`\n    : p.kind === 'tiered' && !byMinute(p) && (p.tiers || []).length ? `from ${usd(p.tiers[0].usd)}`\n      : p.perMinute != null ? `${usd(p.perMinute)} / min` : '—');\n  const soundColumns = () => [\n    { label: 'Lengths', render: m => { const r = soundLengths(m.audio || {}); return r ? `${lengthText(r.min)} – ${lengthText(r.max)}` : 'Set by the model'; } },\n    { label: 'Takes', hide: true, render: m => { const a = m.audio || {}; return [a.lyrics && (a.lyricsRequired ? 'lyrics, required' : 'lyrics'), a.instrumental && 'instrumental', a.loop && 'loop'].filter(Boolean).join(', ') || '—'; } },\n    { label: 'Privacy', hide: true, render: m => (PRIVACY[m.privacy] ? PRIVACY[m.privacy].label : m.privacy) },\n    { label: 'Price', right: true, render: m => soundRate(m.pricing || {}) }\n  ];\n\n  // Price against length: steps for a price per started minute, a line for a\n  // price per second, flat for one price per track.\n  const PriceCurve = ({ pricing, range, options }) => {\n    const W = 320;\n    const H = 150;\n    const pad = { l: 44, r: 12, t: 12, b: 26 };\n    const xs = options || Array.from({ length: 61 }, (_, i) => Math.round(range.min + ((range.max - range.min) * i) / 60));\n    const points = (pricing.kind === 'tiered' && !options\n      ? (pricing.tiers || []).filter(t => t.upTo >= range.min).flatMap(t => [[Math.max(range.min, t.from || range.min), t.usd], [Math.min(range.max, t.upTo), t.usd]])\n      : xs.map(sec => [sec, soundPrice(pricing, sec)])).filter(([, v]) => v != null);\n    if (!points.length) return null;\n    const top = Math.max(...points.map(([, v]) => v)) || 1;\n    const x = sec => pad.l + ((sec - 0) / (range.max || 1)) * (W - pad.l - pad.r);\n    const y = v => H - pad.b - (v / top) * (H - pad.t - pad.b);\n    const path = points.map(([sec, v], i) => `${i ? 'L' : 'M'}${x(sec).toFixed(1)},${y(v).toFixed(1)}`).join(' ');\n    const ticks = [0, range.max / 2, range.max].map(sec => Math.round(sec));\n    return (\n      __jsx('svg', { className: \"vxm-curve\", viewBox: `0 0 ${W} ${H}`, role: \"img\", 'aria-label': `From ${usd(points[0][1])} at ${lengthText(points[0][0])} to ${usd(points[points.length - 1][1])} at ${lengthText(points[points.length - 1][0])}`,}\n        , [0, 0.5, 1].map(f => __jsx('line', { key: f, className: \"vxm-grid\", x1: pad.l, x2: W - pad.r, y1: y(top * f), y2: y(top * f),} ))\n        , [0, 0.5, 1].map(f => __jsx('text', { key: `y${f}`, className: \"vxm-label\", x: pad.l - 8, y: y(top * f) + 4, textAnchor: \"end\",}, axisUsd(top * f)))\n        , ticks.map((sec, i) => __jsx('text', { key: `x${sec}`, className: \"vxm-label\", x: x(sec), y: H - 6, textAnchor: i === 0 ? 'start' : i === ticks.length - 1 ? 'end' : 'middle',}, lengthText(sec)))\n        , options ? points.map(([sec, v]) => __jsx('circle', { key: sec, className: \"vxm-dot\", cx: x(sec), cy: y(v), r: 3.5,} )) : __jsx('path', { className: \"vxm-line\", d: path,} )\n      )\n    );\n  };\n\n  const SoundCard = ({ model }) => {\n    const a = model.audio || {};\n    const p = model.pricing || {};\n    const range = soundLengths(a);\n    return (\n      __jsx('div', { className: \"vxm-card\",}\n        , __jsx('div', { className: \"vxn-standing-head\",}\n          , __jsx('span', { className: \"vxn-price-label\",}, a.voiceChanger ? 'Price by source length' : 'Price by length')\n          , __jsx('span', { className: \"vx-muted\",}, byMinute(p) ? 'by the started minute' : p.kind === 'tiered' ? 'by length' : p.kind === 'per-second' ? 'by the second' : p.kind === 'per-track' ? 'one price per track' : '')\n        )\n        , range ? __jsx(PriceCurve, { pricing: p, range: range, options: a.durationOptions,} )\n          : __jsx('p', { className: \"vxm-flat\",}, __jsx('span', { className: \"vxn-est-value\",}, p.kind === 'per-track' ? usd(p.perTrack) : usd(p.perSecond)), __jsx('span', { className: \"vx-muted\",}, p.kind === 'per-track' ? 'per track. The model picks the length.' : 'per second of audio. The model picks the length.'))\n      )\n    );\n  };\n\n  const SoundEstimator = ({ model }) => {\n    const a = model.audio || {};\n    const p = model.pricing || {};\n    const range = soundLengths(a);\n    const [jobs, setJobs] = useState(10);\n    const [seconds, setSeconds] = useState(() => (range ? (a.durationOptions ? a.durationOptions[0] : Math.min(range.max, Math.max(range.min, a.defaultDuration || 60))) : 0));\n    const each = range ? soundPrice(p, seconds) : p.kind === 'per-track' ? p.perTrack : null;\n    return (\n      __jsx('div', { className: \"vxn-est\",}\n        , __jsx('div', { className: \"vxi-est-controls\",}\n          , __jsx('label', { className: \"vxn-field\",}, __jsx('span', null, a.voiceChanger ? 'Recordings' : isSfxModel(model) ? 'Sounds' : 'Tracks'), __jsx('input', { type: \"number\", min: \"0\", step: \"1\", value: jobs, onChange: e => setJobs(Math.max(0, Math.round(Number(e.target.value) || 0))),} ))\n          , range ? (\n            __jsx('div', { className: \"vxn-field\",}, __jsx('span', null, \"Length\")\n              , a.durationOptions\n                ? __jsx(Segmented, { ariaLabel: \"Length\", value: seconds, onChange: setSeconds, options: a.durationOptions.map(o => ({ value: o, label: lengthText(o) })),} )\n                : (\n                  __jsx('span', { className: \"vx-range\",}\n                    , __jsx('input', { type: \"range\", min: range.min, max: range.max, step: 1, value: seconds, 'aria-label': \"Length\", 'aria-valuetext': lengthText(seconds), onChange: e => setSeconds(Number(e.target.value)),} )\n                    , __jsx('span', { className: \"vx-range-value\",}, lengthText(seconds))\n                  )\n                )\n            )\n          ) : null\n        )\n        , __jsx('div', { className: \"vxn-est-result\", 'aria-live': \"polite\",}\n          , __jsx('div', null, __jsx('span', { className: \"vxn-est-value\",}, usd(each)), __jsx('span', { className: \"vx-muted\",}, a.voiceChanger ? 'per recording' : isSfxModel(model) ? 'per sound' : 'per track'))\n          , __jsx('div', null, __jsx('span', { className: \"vxn-est-value is-total\" ,}, usd(each != null ? each * jobs : null)), __jsx('span', { className: \"vx-muted\",}, \"for \" , count(jobs), \" \" , a.voiceChanger ? 'recordings' : isSfxModel(model) ? 'sounds' : 'tracks'))\n        )\n      )\n    );\n  };\n\n  // Everything an agent needs to queue a job with the model, as Markdown.\n  const soundBrief = (family, model, sample) => {\n    const a = model.audio || {};\n    const p = model.pricing || {};\n    const range = soundLengths(a);\n    const base = a.voiceChanger ? '/audio/voice-changer' : '/audio';\n    return [\n      `# ${family.name} on the Venice API`,\n      '',\n      `- Model ID: \\`${model.id}\\``,\n      `- Flow: \\`POST ${API}${base}/queue\\` returns a \\`queue_id\\`; poll \\`POST ${API}${base}/retrieve\\` with the \\`model\\` and \\`queue_id\\` until it returns the audio. \\`POST ${API}${base}/quote\\` prices a job without charging for it.`,\n      '- Auth: `Authorization: Bearer $VENICE_API_KEY`, with a key from https://venice.ai/settings/api',\n      p.kind === 'tiered' ? `- Price by ${a.voiceChanger ? 'source ' : ''}length: ${(p.tiers || []).map(t => `up to ${lengthText(t.upTo)} ${usd(t.usd)}`).join(', ')}`\n        : p.kind === 'per-second' ? `- Price: ${usd(p.perSecond)} per second (${usd(p.perMinute)} per minute)`\n          : p.kind === 'per-track' ? `- Price: ${usd(p.perTrack)} per track` : '- Price: quote it first',\n      a.voiceChanger\n        ? `- Source: a ${listText(a.sourceFormats || [])} recording up to ${lengthText(a.maxSourceSeconds)} and 25 MB, as a multipart \\`file\\` or an \\`audio_url\\``\n        : range ? `- \\`duration_seconds\\`: ${a.durationOptions ? a.durationOptions.join(', ') : `${range.min} to ${range.max}`}${a.defaultDuration ? `, default ${a.defaultDuration}` : ''}` : '- Length: set by the model; it takes no `duration_seconds`',\n      a.voiceChanger ? `- Voices: ${(a.voices || []).map(v => `\\`${v}\\``).join(', ')}${a.customVoice ? '; any ElevenLabs voice ID also works' : ''}` : null,\n      a.voiceChanger && a.noiseRemoval ? '- `remove_background_noise: true` cleans the source first' : null,\n      a.lyrics ? `- \\`lyrics_prompt\\`: ${a.lyricsRequired ? 'required' : a.instrumental ? 'needed for vocals' : 'optional'}` : null,\n      a.instrumental ? '- `force_instrumental: true` makes a track without vocals' : null,\n      a.loop ? '- `loop: true` renders a seamless loop' : null,\n      a.promptLimit ? `- \\`prompt\\`: up to ${count(a.promptLimit)} characters` : null,\n      (a.formats || []).length ? `- Output: ${a.formats.join(', ')}` : null,\n      PRIVACY[model.privacy] ? `- Privacy: ${PRIVACY[model.privacy].label}. ${PRIVACY[model.privacy].desc}` : null,\n      `- Docs: https://docs.venice.ai/models/${family.slug}`,\n      '',\n      '```bash',\n      sample,\n      '```'\n    ].filter(line => line != null).join('\\n');\n  };\n\n  const SoundPageNext = ({ data }) => {\n    const { family, models, related, providers } = data;\n    const now = useNow();\n    const { catalog } = useCatalog();\n    const headerHeight = useHeaderHeight();\n    const model = models.find(m => m.id === family.primary) || models[0];\n    const provider = providers[family.provider] || providers[model.provider];\n    const a = model.audio || {};\n    const p = model.pricing || {};\n    const range = soundLengths(a);\n    const source = safeUrl(model.source);\n    const endpoints = (model.endpoints || []).filter(ep => ep.supported !== false);\n    const endpoint = endpoints.find(ep => ep.recommended) || endpoints[0];\n    const versions = (related && related.versions) || [];\n    const isSfx = isSfxModel(model);\n    const sections = [['capabilities', 'Capabilities'], ['pricing', 'Pricing'], ['specs', 'Specs'], a.voiceChanger ? null : ['compare', 'Compare'], ['quickstart', 'Quickstart']].filter(Boolean);\n    const activeSection = useScrollSpy(sections.map(([id]) => id));\n    const sample = codeSamples(model, endpoint && endpoint.id).curl;\n    const voices = a.voices || [];\n    const params = a.voiceChanger ? [\n      ['model', __jsx('code', null, model.id), 'Required'],\n      ['file', listText(a.sourceFormats || []), 'The recording, up to 25 MB; or send audio_url'],\n      ['audio_url', 'A public URL', 'Instead of file'],\n      voices.length ? ['voice', `${count(voices.length)} voices${a.customVoice ? ', or a voice ID' : ''}`, a.defaultVoice ? `Default ${a.defaultVoice}` : null] : null,\n      a.noiseRemoval ? ['remove_background_noise', __jsx('code', null, \"true | false\"  ), 'Cleans the source first'] : null,\n      a.seed ? ['seed', 'Integer', 'Repeats a result'] : null\n    ].filter(Boolean) : [\n      ['model', __jsx('code', null, model.id), 'Required'],\n      ['prompt', a.promptLimit ? `Up to ${count(a.promptLimit)} characters` : 'Text', 'Required'],\n      a.lyrics ? ['lyrics_prompt', 'Song lyrics', a.lyricsRequired ? 'Required' : a.instrumental ? 'Needed for vocals' : 'Optional'] : null,\n      range ? ['duration_seconds', a.durationOptions ? __jsx('code', null, a.durationOptions.join(' | ')) : `${range.min} to ${range.max}`, a.defaultDuration ? `Default ${a.defaultDuration}` : null] : null,\n      a.instrumental ? ['force_instrumental', __jsx('code', null, \"true | false\"  ), 'A track without vocals'] : null,\n      a.loop ? ['loop', __jsx('code', null, \"true | false\"  ), 'A seamless loop'] : null\n    ].filter(Boolean);\n    const tiles = (a.voiceChanger ? [\n      { key: 'source', icon: 'mic', name: 'Source', detail: `${listText(a.sourceFormats || [])}, up to ${lengthText(a.maxSourceSeconds)}` },\n      voices.length ? { key: 'voices', icon: 'volume', name: 'Voices', detail: `${count(voices.length)}${a.customVoice ? ', or any ElevenLabs voice ID' : ''}` } : null,\n      a.noiseRemoval ? { key: 'noise', icon: 'sliders', name: 'Noise removal', detail: __jsx('code', null, \"remove_background_noise\") } : null,\n      a.seed ? { key: 'seed', icon: 'flask', name: 'Repeatable', detail: __jsx('code', null, \"seed\") } : null\n    ] : [\n      a.lyrics ? { key: 'lyrics', icon: 'text', name: 'Lyrics', detail: a.lyricsRequired ? __jsx(__Fragment, null, __jsx('code', null, \"lyrics_prompt\"), \", required\" ) : __jsx('code', null, \"lyrics_prompt\") } : null,\n      a.instrumental ? { key: 'inst', icon: 'music', name: 'Instrumental', detail: __jsx('code', null, \"force_instrumental\") } : null,\n      a.loop ? { key: 'loop', icon: 'activity', name: 'Seamless loop', detail: __jsx('code', null, \"loop: true\" ) } : null,\n      { key: 'length', icon: 'clock', name: 'Lengths', detail: range ? (a.durationOptions ? a.durationOptions.map(lengthText).join(' · ') : `${lengthText(range.min)} to ${lengthText(range.max)}`) : 'Set by the model' }\n    ]).concat([\n      (a.formats || []).length ? { key: 'format', icon: 'music', name: 'Output', detail: a.formats.join(' · ') } : null,\n      { key: 'queue', icon: 'clock', name: 'Queued', detail: 'Quote, queue and retrieve' }\n    ]).filter(Boolean);\n    const figures = [\n      p.kind === 'per-track' ? __jsx(Figure, { key: \"price\", value: usd(p.perTrack), label: \"per track\" ,} )\n        : p.kind === 'tiered' && !byMinute(p) && (p.tiers || []).length ? __jsx(Figure, { key: \"price\", value: __jsx(__Fragment, null, __jsx('span', { className: \"vxn-unit is-lead\" ,}, \"from\"), usd(p.tiers[0].usd)), label: `for ${lengthText(p.tiers[0].upTo)}`,} )\n          : p.perMinute != null ? __jsx(Figure, { key: \"price\", value: usd(p.perMinute), label: p.kind === 'tiered' ? 'per started minute' : 'per minute of audio', tip: p.kind === 'per-second' ? `Billed by the second: ${usd(p.perSecond)} a second.` : null,} ) : null,\n      range ? __jsx(Figure, { key: \"length\", value: lengthText(range.max), label: a.voiceChanger ? 'longest source' : `longest ${isSfx ? 'sound' : 'track'}, from ${lengthText(range.min)}`,} ) : null,\n      a.voiceChanger && voices.length ? __jsx(Figure, { key: \"voices\", value: count(voices.length), label: \"voices\",} )\n        : a.promptLimit ? __jsx(Figure, { key: \"prompt\", value: count(a.promptLimit), label: \"prompt characters\" ,} ) : null\n    ].filter(Boolean);\n    const scope = isSfx ? 'Sound effects' : 'Music';\n\n    return (\n      __jsx('div', { className: \"vx vxn vxm not-prose\"   , style: { '--vxn-header': `${headerHeight}px` },}\n        , __jsx(HoverTips, null )\n        , __jsx(NextTop, { scope: scope, scopeHref: \"/models/music\", family: family, brief: soundBrief(family, model, sample),} )\n\n        , __jsx('header', { className: \"vxn-hero\",}\n          , __jsx('div', { className: \"vxn-hero-main\",}\n            , __jsx('div', { className: \"vxn-provider\",}\n              , __jsx(ProviderLogo, { provider: provider, size: 22,} )\n              , __jsx('span', null, provider ? provider.name : family.provider)\n              , __jsx('span', { className: \"vxn-dot\",} )\n              , __jsx('span', null, fmtDate(model.created))\n              , isNew(model.created, now) ? __jsx(Tag, { tone: \"new\",}, \"New\") : null\n              , model.beta ? __jsx(Tag, { tone: \"beta\",}, \"Beta\") : null\n            )\n            , __jsx('h1', { className: \"vxn-h1\",}, family.name)\n            , __jsx('div', { className: \"vxn-meta\",}\n              , __jsx('span', { className: \"vxn-meta-id\",}, __jsx('code', null, model.id), __jsx(CopyButton, { text: model.id, iconOnly: true, label: `Copy model ID ${model.id}`,} ))\n              , PRIVACY[model.privacy] ? __jsx('span', { className: \"vxn-meta-item\",}, PRIVACY[model.privacy].label, __jsx(InfoTip, { text: PRIVACY[model.privacy].desc, size: 12,} )) : null\n              , model.openWeights ? (source\n                ? __jsx('a', { className: \"vxn-meta-item\", href: source, target: \"_blank\", rel: \"noopener noreferrer\" ,}, \"Open weights\" , __jsx(Icon, { name: \"external\", size: 12,} ))\n                : __jsx('span', { className: \"vxn-meta-item\",}, \"Open weights\" )) : null\n            )\n            , model.description || family.description ? __jsx('p', { className: \"vxn-desc\",}, model.description || family.description) : null\n            , figures.length ? __jsx('div', { className: \"vxn-figs\",}, figures) : null\n            , __jsx('div', { className: \"vxn-ctas\",}\n              , __jsx('a', { className: \"vxn-btn is-primary\" , href: \"https://venice.ai/settings/api\", target: \"_blank\", rel: \"noopener noreferrer\" ,}, \"Get an API key\"   )\n            )\n          )\n          , __jsx('div', { className: \"vxn-hero-side\",}\n            , __jsx(SoundCard, { model: model,} )\n          )\n        )\n\n        , __jsx(NextNav, { title: family.name, sections: sections, active: activeSection,} )\n\n        , __jsx(NextSection, { id: \"capabilities\", title: \"Capabilities\",}\n          , __jsx('div', { className: \"vxn-tiles\",}\n            , tiles.map(tile => (\n              __jsx('div', { key: tile.key, className: \"vxn-tile\",}\n                , __jsx('span', { className: \"vxn-tile-icon\",}, __jsx(Icon, { name: tile.icon, size: 16,} ))\n                , __jsx('span', { className: \"vxn-tile-text\",}, __jsx('span', { className: \"vxn-tile-name\",}, tile.name), __jsx('span', { className: \"vxn-tile-detail\",}, tile.detail))\n              )\n            ))\n            , Array.from({ length: (3 - (tiles.length % 3)) % 3 }, (_, i) => __jsx('span', { key: `fill-${i}`, className: \"vxn-tile is-empty\" , 'aria-hidden': \"true\",} ))\n          )\n        )\n\n        , __jsx(NextSection, { id: \"pricing\", title: \"Pricing\", lead: byMinute(p) ? `Billed by the started minute of ${a.voiceChanger ? 'the source' : 'audio'}, in USD.` : p.kind === 'tiered' ? 'Billed by the length you ask for, in USD.' : p.kind === 'per-second' ? 'Billed per second of audio, in USD.' : 'One price per track, in USD.',}\n          , p.kind === 'tiered' ? (\n            __jsx('div', { className: \"vx-table-wrap vxm-tiers\" ,}\n              , __jsx('table', { className: \"vx-dtable\",}\n                , __jsx('thead', null, __jsx('tr', null, __jsx('th', null, a.voiceChanger ? 'Source length' : 'Length'), (p.tiers || []).map(t => __jsx('th', { key: t.upTo, className: \"vx-al-right\",}, `up to ${lengthText(t.upTo)}`))))\n                , __jsx('tbody', null, __jsx('tr', null, __jsx('th', { scope: \"row\",}, \"Price\"), (p.tiers || []).map(t => __jsx('td', { key: t.upTo, className: \"vx-al-right vx-num\" ,}, usd(t.usd)))))\n              )\n            )\n          ) : (\n            __jsx('div', { className: \"vxn-prices\",}\n              , p.kind === 'per-track' ? __jsx('div', { className: \"vxn-price\",}, __jsx('span', { className: \"vxn-price-label\",}, \"Per track\" ), __jsx('span', { className: \"vxn-price-value\",}, usd(p.perTrack)), __jsx('span', { className: \"vx-muted\",}, range ? `any length up to ${lengthText(range.max)}` : 'at the length the model picks')) : null\n              , p.kind === 'per-second' ? __jsx('div', { className: \"vxn-price\",}, __jsx('span', { className: \"vxn-price-label\",}, \"Per minute\" ), __jsx('span', { className: \"vxn-price-value\",}, usd(p.perMinute)), __jsx('span', { className: \"vx-muted\",}, \"billed by the second, \"    , usd(p.perSecond), \" each\" )) : null\n            )\n          )\n          , __jsx('h3', { className: \"vxn-h3 vxn-gap\" ,}, \"Estimate a batch\"  )\n          , __jsx(SoundEstimator, { model: model,} )\n          , __jsx('p', { className: \"vxn-caption\",}, \"Quote a job with \"    , __jsx('code', null, \"POST \" , a.voiceChanger ? '/audio/voice-changer' : '/audio', \"/quote\"), \" for its exact price before you queue it.\"        )\n        )\n\n        , __jsx(NextSection, { id: \"specs\", title: \"Specs\",}\n          , __jsx('dl', { className: \"vxn-sheet\",}\n            , [\n              ['Model ID', __jsx('code', null, model.id)],\n              endpoint ? ['Endpoint', __jsx('code', null, endpoint.method, \" /api/v1\" , endpoint.path)] : null,\n              a.voiceChanger ? ['Source', `${listText(a.sourceFormats || [])}, up to ${lengthText(a.maxSourceSeconds)}`] : ['Lengths', range ? (a.durationOptions ? a.durationOptions.map(lengthText).join(', ') : `${lengthText(range.min)} to ${lengthText(range.max)}`) : 'Set by the model'],\n              a.voiceChanger ? ['Voices', `${count(voices.length)}${a.customVoice ? ', or any ElevenLabs voice ID' : ''}`] : null,\n              a.promptLimit ? ['Prompt', `Up to ${count(a.promptLimit)} characters`] : null,\n              a.voiceChanger ? null : ['Lyrics', a.lyrics ? (a.lyricsRequired ? 'Required' : 'Yes') : 'No'],\n              a.instrumental ? ['Instrumental', 'Yes'] : null,\n              a.loop ? ['Seamless loop', 'Yes'] : null,\n              (a.formats || []).length ? ['Output', a.formats.join(', ')] : null,\n              PRIVACY[model.privacy] ? ['Privacy', __jsx(__Fragment, null, PRIVACY[model.privacy].label, __jsx(InfoTip, { text: PRIVACY[model.privacy].desc,} ))] : null,\n              ['Weights', model.openWeights ? (source ? __jsx('a', { href: source, target: \"_blank\", rel: \"noopener noreferrer\" ,}, weightsName(source), __jsx(Icon, { name: \"external\", size: 12,} )) : 'Open') : 'Closed'],\n              ['Added', fmtDate(model.created)]\n            ].filter(Boolean).map(([label, value]) => __jsx('div', { key: label, className: \"vxn-sheet-row\",}, __jsx('dt', null, label), __jsx('dd', null, value)))\n          )\n          , versions.length ? __jsx(VersionTimeline, { family: family, versions: versions, created: model.created,} ) : null\n        )\n\n        , a.voiceChanger ? null : (\n          __jsx(NextSection, { id: \"compare\", title: \"Compare\", lead: `Every ${isSfx ? 'sound effects' : 'music'} model on Venice.`,}\n            , __jsx(TaskCompare, { model: model, catalog: catalog, includes: m => m.task === model.task && !(m.audio || {}).voiceChanger, order: () => 0, columns: soundColumns,} )\n          )\n        )\n\n        , __jsx(NextSection, { id: \"quickstart\", title: \"Quickstart\", lead: a.voiceChanger ? 'Upload a recording as a queued job, then poll for it in the new voice.' : 'Music and sound effects run as queued jobs: queue the prompt, then poll for the audio.',}\n          , __jsx(JobFlow, { base: a.voiceChanger ? '/audio/voice-changer' : '/audio', noun: \"audio\",} )\n          , __jsx(CodePanel, { model: model, endpoint: endpoint, endpoints: [],} )\n          , __jsx('h3', { className: \"vxn-h3 vxn-gap\" ,}, \"Parameters\")\n          , __jsx(ParamRows, { rows: params,} )\n        )\n      )\n    );\n  };\n\n  // scripts/build-model-catalog.js writes each page's static text with these,\n  // so it reads the same as the page.\n  const helpers = { usd, tokens, fmtDate, listText, heightLabel, VARIANT_LABELS, PRIVACY, videoPrice, DRAFT_CLIP, priceSummary, statusText, clipTable, durationText, safeUrl, weightsName, benchmarkSummaries };\n\n  // Hands over a catalog that loaded before the explorer's first render, so\n  // the view opens on its results instead of a loading skeleton.\n  const setCatalog = catalog => { store.catalog = catalog; };\n\n  return { ModelExplorer, ModelPage, ModelPageNext, codeSamples, helpers, setCatalog };\n}"}