/** * Hand-written wrapper. DO NOT regenerate this file. * * The model data lives in `neon.models.json` (regenerated by * `fetch-neon-models.ts`). This wrapper re-exports it typed so consumers can * keep `import { models } from './neon.models'`. * * The data is loaded via `JSON.parse(readFileSync(...))` rather than an * `import ... with { type: 'json' }` attribute so the loader doesn't have * to support JSON import attributes. */ import { readFileSync } from 'node:fs' import { dirname, resolve } from 'node:path' import { fileURLToPath } from 'node:url' export interface NeonCatalogModel { id: string provider?: string released?: boolean /** `'embedding'` for an embedding model. Chat models have no `type`. */ type?: string reasoning?: boolean reasoning_options?: Array<{ type: string; values?: Array }> /** `false` when the model rejects `temperature` (and `top_p`). */ temperature?: boolean modalities?: { input?: Array output?: Array } capabilities?: { /** How `/v1/chat/completions` serves the model. */ chat?: 'conforms' | 'array-content' | 'not-served' | (string & {}) /** Whether `/openai/v1/responses` serves the model. */ responses?: boolean native_dialect?: string embeddings?: boolean } [key: string]: unknown } const __dirname = dirname(fileURLToPath(import.meta.url)) const DATA_PATH = resolve(__dirname, 'neon.models.json') export const models: Array = JSON.parse( readFileSync(DATA_PATH, 'utf-8'), )