What changed
Added gguf_init_from_buffer (load a GGUF model from a pre-allocated memory buffer) and gguf_init_from_callback (load via a custom callback function invoked per read), with hardened file offset calculations and overflow prevention.
Developer signal
Previously, loading a GGUF model in llama.cpp required a file path. The new buffer API lets you pass pre-loaded model bytes directly, useful when you've mmap'd the model, downloaded it into memory, or received it over a network stream. The callback API is more general — it invokes your function for each read operation, enabling lazy loading (only read the weight chunks you need), custom decryption, streaming from object storage, or any non-file data source. File offset overflow protection was added in the same build, making both APIs suitable for production use. If you are embedding llama.cpp in an application that manages model storage differently from local files — cloud functions where disk is expensive, edge devices, distributed caches, S3-backed weight storage — these APIs significantly reduce the I/O plumbing you need to write.