Spaces:
Running
Running
File size: 1,269 Bytes
830f2f5 cd7a926 45fb44a 830f2f5 cd7a926 830f2f5 45fb44a 830f2f5 45fb44a 830f2f5 45fb44a 830f2f5 45fb44a 830f2f5 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 | 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;
}
|