using System; namespace LLama.Exceptions; /// /// Base class for LLamaSharp runtime errors (i.e. errors produced by llama.cpp, converted into exceptions) /// public class RuntimeError : Exception { /// /// Create a new RuntimeError /// /// public RuntimeError(string message) : base(message) { } } /// /// Loading model weights failed /// public class LoadWeightsFailedException : RuntimeError { /// /// The model path which failed to load /// public string ModelPath { get; } /// public LoadWeightsFailedException(string modelPath) : base($"Failed to load model '{modelPath}'") { ModelPath = modelPath; } }