Distribute and run LLMs with a single file.
C++ cross-platformggufllama-cpplocal-ailocal-inferencelocal-llmopen-source-aisingle-file-executablespeech-to-text
Make clickable HTTP server links easier to see
Justine Tunney7a8d5ee4e1bb
diff --git a/build/config.mk b/build/config.mkindex 2230b544..6a1d37bd 100644--- a/build/config.mk+++ b/build/config.mk@@ -13,9 +13,9 @@ MKDEPS = $(COSMOCC)/bin/mkdepsINSTALL = installARFLAGS = rcsD-CCFLAGS = -g -O3 -fexceptions-TARGET_ARCH = -Xx86_64-mavx+CCFLAGS = -g -O3 -fopenmp -fexceptionsCPPFLAGS_ = -iquote. -mcosmo -DGGML_MULTIPLATFORM+TARGET_ARCH = -Xx86_64-mavx -Xx86_64-mtune=alderlakeTMPDIR = o//tmpIGNORE := $(shell mkdir -p $(TMPDIR))diff --git a/build/llamafile-convert b/build/llamafile-convertindex 5346639e..39507742 100755--- a/build/llamafile-convert+++ b/build/llamafile-convert@@ -9,7 +9,7 @@ if [ x"$1" = x"--help" ]; thenecho "Your .llamafile is outputted to the current directory."echoecho "You can supply either a .gguf filename, or the URL to"- echo "to download one from an online service Hugging Face."+ echo "download one from an online service like Hugging Face."echoecho "When you run this program, it's recommended that you've"echo "downloaded or installed an official llamafile-VERSION.zip"diff --git a/llama.cpp/common.cpp b/llama.cpp/common.cppindex 75a3c180..12607944 100644--- a/llama.cpp/common.cpp+++ b/llama.cpp/common.cpp@@ -884,7 +884,6 @@ bool gpt_params_parse_ex(int argc, char ** argv, gpt_params & params) {}params.n_gpu_layers = llamafile_gpu_layers(params.n_gpu_layers);- // tinylog(__func__, ": parsed configuration flags\n", NULL);return true;}diff --git a/llama.cpp/server/server.cpp b/llama.cpp/server/server.cppindex e43daaf3..3d414091 100644--- a/llama.cpp/server/server.cpp+++ b/llama.cpp/server/server.cpp@@ -2535,6 +2535,17 @@ int server_cli(int argc, char **argv)}});+ // load the model+ if (!llama.load_model(params))+ {+ state.store(SERVER_STATE_ERROR);+ return 1;+ } else {+ llama.initialize();+ state.store(SERVER_STATE_READY);+ LOG_INFO("model loaded", {});+ }+// set timeouts and change hostname and portsvr.set_read_timeout (sparams.read_timeout);svr.set_write_timeout(sparams.write_timeout);@@ -2604,17 +2615,6 @@ int server_cli(int argc, char **argv)return 0;});- // load the model- if (!llama.load_model(params))- {- state.store(SERVER_STATE_ERROR);- return 1;- } else {- llama.initialize();- state.store(SERVER_STATE_READY);- LOG_INFO("model loaded", {});- }-// launch browser tabif (!sparams.nobrowser) {char url[128];