Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CivitaiBaseForTest ¶
func CivitaiBaseForTest() string
CivitaiBaseForTest returns the current base for tests.
func ClearCache ¶
ClearCache removes all resolver cache entries.
func SetCivitaiBaseForTest ¶
func SetCivitaiBaseForTest(u string)
SetCivitaiBaseForTest overrides the base URL for CivitAI API (tests only).
Types ¶
type HuggingFace ¶
type HuggingFace struct{}
func (*HuggingFace) CanHandle ¶
func (h *HuggingFace) CanHandle(u string) bool
Accepts URIs of the form:
hf://{owner}/{repo}/{path}?rev=main
If rev is omitted, defaults to "main".
type Resolved ¶
type Resolved struct {
URL string
Headers map[string]string
// Optional metadata (primarily for CivitAI) — may be empty for other resolvers
ModelName string
VersionName string
VersionID string
FileName string
FileType string // Source-specific type (e.g., CivitAI file.type: Model|VAE|TextualInversion)
SuggestedFilename string
// Optional metadata for Hugging Face
RepoOwner string
RepoName string
RepoPath string
Rev string
}
Click to show internal directories.
Click to hide internal directories.