Add metadata saving functionality and enhance LoraCard with usage tips and notes

This commit is contained in:
Will Miao
2025-02-19 20:49:54 +08:00
parent ebc4196071
commit 39ad18bfbc
4 changed files with 53 additions and 5 deletions

View File

@@ -15,6 +15,8 @@ class LoraMetadata:
sha256: str # SHA256 hash of the file
base_model: str # Base model (SD1.5/SD2.1/SDXL/etc.)
preview_url: str # Preview image URL
usage_tips: str = "" # Usage tips for the model
notes: str = "" # Additional notes
from_civitai: bool = True # Whether the lora is from Civitai
civitai: Optional[Dict] = None # Civitai API data if available