Method DownloadAsync
DownloadAsync(ModelDownloadingProgressCallback)
Asynchronously downloads the model file from its specified URI and saves it locally.
public Task DownloadAsync(LM.ModelDownloadingProgressCallback downloadingProgress = null)
Parameters
downloadingProgress
LM.ModelDownloadingProgressCallbackAn optional callback of type LM.ModelDownloadingProgressCallback that is invoked to report download progress. The callback receives the temporary download path, the total content length (in bytes, if available), and the number of bytes downloaded so far. It should return a bool indicating whether the download should continue.
Returns
Remarks
The method determines the local storage path for the model based on its URI. If the model file already exists locally, the method returns immediately without performing any download.