MCPcopy
hub / github.com/mudler/LocalAI / ModelFileName

Method ModelFileName

core/config/model_config.go:1194–1202  ·  view source on GitHub ↗

ModelFileName returns the filename of the model If the model is a URL, it will return the MD5 of the URL which is the filename

()

Source from the content-addressed store, hash-verified

1192// ModelFileName returns the filename of the model
1193// If the model is a URL, it will return the MD5 of the URL which is the filename
1194func (c *ModelConfig) ModelFileName() string {
1195 uri := downloader.URI(c.Model)
1196 if uri.LooksLikeURL() {
1197 f, _ := uri.FilenameFromUrl()
1198 return f
1199 }
1200
1201 return c.Model
1202}
1203
1204func (c *ModelConfig) FunctionToCall() string {
1205 if c.functionCallNameString != "" &&

Callers 4

listModelFilesFunction · 0.95
guessGGUFFromFileFunction · 0.80
llamaCppDefaultsFunction · 0.80
PreloadMethod · 0.80

Calls 3

URITypeAlias · 0.92
LooksLikeURLMethod · 0.80
FilenameFromUrlMethod · 0.80

Tested by

no test coverage detected