import Link from 'next/link'; import { APPLE_PRESETS, NVIDIA_PRESETS, QUANTS } from '@/components/hardware/fit-form'; import { BTN_GHOST, CTRL, Field } from './bits'; /* GET form for /find-a-model — "What do you need?" Every field maps 1:1 to a `/find-a-model` parameter. */ export const FINDER_USE_CASES = [ { value: '', label: 'Any' }, { value: 'chat', label: 'Chat / assistant' }, { value: 'coding', label: 'Coding' }, { value: 'reasoning', label: 'Reasoning / math' }, { value: 'agentic', label: 'Agentic / tool use' }, { value: 'long_context', label: 'Long context' }, { value: 'vision', label: 'Vision' }, { value: 'embeddings', label: 'Embeddings' }, { value: 'low_cost', label: 'Low cost' }, { value: 'local', label: 'Runs locally' }, ]; export const MODALITIES = ['text', 'image', 'audio', 'video', 'embedding']; export type FinderInputs = { useCase: string; deployment: 'any' | 'local' | 'api'; memory: number | null; quant: string; contextMin: number | null; license: 'any' | 'commercial'; openness: string; maxIn: number | null; maxOut: number | null; modalities: string[] }; export function FinderForm({ v, className }: { v: FinderInputs; className?: string }) { const presets = [...APPLE_PRESETS, ...NVIDIA_PRESETS]; const presetSelected = v.memory !== null && presets.includes(v.memory) ? String(v.memory) : ''; const radio = (name: string, value: string, current: string, label: string) => ( ); return (
Deployment
{radio('deployment', 'any', v.deployment, 'Any')} {radio('deployment', 'local', v.deployment, 'Local')} {radio('deployment', 'api', v.deployment, 'API')}
Licence
{radio('license', 'any', v.license, 'Any')} {radio('license', 'commercial', v.license, 'Commercial use allowed')}
Modalities (all required)
{MODALITIES.map((m) => ( ))}
Reset
); }