if (FALSE) {
# Download TinyLlama model (large file, not run in checks)
model_path <- edge_download_model(
model_id = "TheBloke/TinyLlama-1.1B-Chat-v1.0-GGUF",
filename = "tinyllama-1.1b-chat-v1.0.Q4_K_M.gguf"
)
# Use the downloaded model
if (file.exists(model_path)) {
ctx <- edge_load_model(model_path)
response <- edge_completion(ctx, "Hello, how are you?")
edge_free_model(ctx)
}
}
Run the code above in your browser using DataLab