mirror of
https://github.com/LostRuins/koboldcpp.git
synced 2026-05-09 19:46:11 +00:00
update colab
This commit is contained in:
parent
8b29d5f848
commit
5ebc532ca9
1 changed files with 11 additions and 1 deletions
12
colab.ipynb
12
colab.ipynb
|
|
@ -60,6 +60,10 @@
|
|||
"LoadImgModel = False #@param {type:\"boolean\"}\r\n",
|
||||
"ImgModel = \"https://huggingface.co/koboldcpp/imgmodel/resolve/main/imgmodel_ftuned_q4_0.gguf\" #@param [\"https://huggingface.co/koboldcpp/imgmodel/resolve/main/imgmodel_ftuned_q4_0.gguf\"]{allow-input: true}\r\n",
|
||||
"SCommand = \"\"\r\n",
|
||||
"#@markdown <hr>\r\n",
|
||||
"LoadSpeechModel = False #@param {type:\"boolean\"}\r\n",
|
||||
"SpeechModel = \"https://huggingface.co/koboldcpp/whisper/resolve/main/whisper-base.en-q5_1.bin\" #@param [\"https://huggingface.co/koboldcpp/whisper/resolve/main/whisper-base.en-q5_1.bin\"]{allow-input: true}\r\n",
|
||||
"WCommand = \"\"\r\n",
|
||||
"\r\n",
|
||||
"import os\r\n",
|
||||
"if not os.path.isfile(\"/opt/bin/nvidia-smi\"):\r\n",
|
||||
|
|
@ -80,6 +84,10 @@
|
|||
" SCommand = \"--sdmodel imodel.gguf --sdthreads 4 --sdquant --sdclamped\"\r\n",
|
||||
"else:\r\n",
|
||||
" SCommand = \"\"\r\n",
|
||||
"if SpeechModel and LoadSpeechModel:\r\n",
|
||||
" WCommand = \"--whispermodel wmodel.bin\"\r\n",
|
||||
"else:\r\n",
|
||||
" WCommand = \"\"\r\n",
|
||||
"!echo Finding prebuilt binary for {kvers}\r\n",
|
||||
"!wget -O dlfile.tmp https://kcppcolab.concedo.workers.dev/?{kvers} && mv dlfile.tmp koboldcpp_cublas.so\r\n",
|
||||
"!test -f koboldcpp_cublas.so && echo Prebuilt Binary Exists || echo Prebuilt Binary Does Not Exist\r\n",
|
||||
|
|
@ -92,7 +100,9 @@
|
|||
" !aria2c -x 10 -o vmodel.gguf --summary-interval=5 --download-result=default --allow-overwrite=true --file-allocation=none $LLaVAmmproj\r\n",
|
||||
"if SCommand:\r\n",
|
||||
" !aria2c -x 10 -o imodel.gguf --summary-interval=5 --download-result=default --allow-overwrite=true --file-allocation=none $ImgModel\r\n",
|
||||
"!python koboldcpp.py model.gguf --usecublas 0 mmq --multiuser --gpulayers $Layers --contextsize $ContextSize --quiet --remotetunnel $VCommand $SCommand\r\n"
|
||||
"if WCommand:\r\n",
|
||||
" !aria2c -x 10 -o wmodel.bin --summary-interval=5 --download-result=default --allow-overwrite=true --file-allocation=none $SpeechModel\r\n",
|
||||
"!python koboldcpp.py model.gguf --usecublas 0 mmq --multiuser --gpulayers $Layers --contextsize $ContextSize --quiet --remotetunnel $VCommand $SCommand $WCommand\r\n"
|
||||
]
|
||||
}
|
||||
],
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue