export interface BaseModel { /** Folder name in the repo, e.g. "MOSS-Image". */ id: string; count: number; } export interface Preview { url: string; /** Content hash of the image file; the cache key (see lib/imageCache.ts). */ hash: string; } /** One LoRA file: a character trained on one base model. */ export interface Lora { /** Repo path, unique across models, e.g. "MOSS-Image/MOSS_abigailb.safetensors". */ id: string; /** Display name: file stem without the model prefix, e.g. "abigailb". */ name: string; file: string; model: string; size: number; sha256: string | null; updated: string | null; /** Preview images, in display order; empty → generated placeholder. */ previews: Preview[]; } /** A person, with one LoRA per base model they've been trained on. */ export interface Character { /** Lowercased name (after aliases); stable across models, e.g. "abigailb". */ key: string; name: string; /** In base-model order; never empty. */ variants: Lora[]; } export type SortKey = "name" | "updated" | "size"; export type ViewKey = "grid" | "table"; export interface Filters { /** Base models to filter by (a character matches if it has any of them); empty = all. */ models: string[]; q: string; sort: SortKey; view: ViewKey; }